Locale does not work with picking fields - REST API

Hello, we are experiencing strange issue with getting content with proper locale along with picking only desired fields (NEW Cockpit).

We have collection with fields that can be localized. Translations are set in CMS.
If we make a request to collection with locale, example: ?locale=fr_FR, CMS is returning translated labels.

However, if we are passing locale along with picking only desired fields, we get default values instead of translated ones.
Example: ?locale=fr_FR&fields={label:1}. CMS is returning only label field, but with default value…

Also, we don’t see any possibility of getting every locale on normal get items request. Only the default values are returned.

Can you please create a new issue here: Issues · Cockpit-HQ/Cockpit · GitHub

Thanks!

In Cockpit v1 you had to specify the translated field, too. I didn’t test it in v2, but you could try ?locale=fr_FR&fields={label:1,label_fr_FR:1}.

@raffaelj is right.
I have had a similar issue.

You need to specify the field with the translation:
“title” becomes “title_fr_FR” in your query