[SalesForce] How to translate picklist items with Metadata API

I have a picklist in my Metadata API :


I would like to know if it's possible to manage translations for picklist items ? In this example, no matter user language is, it always show 'Car' and 'Bus'.

Best Answer

In the Metadata API CustomFieldTranslation has a picklistValues field of type PicklistValueTranslation[]. It has a masterLabel and translation string.

So your package.xml for the retrieve call would be something like:


You will get something like:

<?xml version="1.0" encoding="UTF-8"?>
<CustomObjectTranslation xmlns="http://soap.sforce.com/2006/04/metadata">
<!-- SNIP... -->
        <masterLabel>Customer Event</masterLabel>
Related Topic