A locale is a language and region code, such as en_US or fr_FR, used to keep separate values for the same attribute. Translation in minipim works per attribute: an attribute marked Localizable stores one value per locale, and every other attribute stores one value for all locales.
In the admin
Add a locale:
- Go to System → Locales and click New locale.
- Enter a Code (for example
fr_FR) and a Label (for example “Français (France)”), then click Create. - To change the default, click Set default on another locale. To remove a locale, use the trash icon. The default locale can’t be deleted.
Make an attribute translatable: open it under Catalog → Attributes and turn on Localizable (“Different value per locale”).
Enter translations: when your organization has more than one locale, the product editor shows a Locale selector above the attributes. Choose a locale, fill in the localizable fields and save. Attributes that aren’t localizable keep one shared value whichever locale is selected.
With the API
| Method | Path | What it does |
|---|---|---|
| GET, POST | /v1/locales | List or create locales |
| PATCH, DELETE | /v1/locales/{id} | Change label/isDefault, or delete |
Attribute values are stored as records with a locale and a channel:
"description": [
{ "locale": "en_US", "channel": null, "value": "Waxed canvas tote" },
{ "locale": "fr_FR", "channel": null, "value": "Cabas en toile cirée" }
]
To get one value per attribute for a market, add ?locale= (and optionally ?channel=) to a single-product read. The response then includes a flat resolvedAttributes map:
const { data } = await pim.GET('/v1/products/{id}', {
params: { path: { id }, query: { locale: 'fr_FR', channel: 'web' } },
});
data.resolvedAttributes?.description; // "Cabas en toile cirée"
Full reference: api.minipim.com/docs.
How resolution works
For each attribute, resolvedAttributes takes the first record that matches, in this order:
- this locale and this channel
- this locale, no channel
- no locale, this channel
- no locale, no channel
It does not fall back to another locale. If a localizable attribute has only an en_US value, a fr_FR read leaves it out of the map. Fill in every locale you publish, or handle the gap in your storefront.
Rules and limits
- Each organization has exactly one default locale. Setting
isDefault: trueon one clears it everywhere else. - A locale’s
codecan’t be changed after it’s created. Codes are unique within an organization and at least 2 characters. Thelanguage_REGIONform is a convention, not something minipim enforces. - A localizable attribute’s records must have a locale string. A non-localizable attribute’s records must have
locale: null. minipim doesn’t check the code against your locales list. - Deleting a locale doesn’t delete values stored under it. They stay on the product and are no longer shown, and recreating the code brings them back.
- The list endpoint
GET /v1/productsacceptslocaleandchannelbut ignores them. Use the single-product read for resolved values. - A localizable attribute can’t have a default value.
- For channel readiness, a required localizable attribute only counts as filled when every locale on the channel has a value. Setting a product active only needs the attribute to have a value in some locale.
- In the admin, Set attribute in bulk editing and CSV import write localizable attributes to
en_US, whatever your default locale is. Use the API to bulk-write other locales. Media alt text in the admin is written for the default locale only.
See also
- Attributes — Attributes are the typed fields of a minipim catalog: codes, labels, localizable, scopable and variant-axis flags, requirement levels, validation, deletion.
- Channels and readiness — Channels are where your catalog is sold. Set per-channel required attributes, read readiness scores, and learn how channel-specific values and deletes work.
- Products — How minipim products work: family, slug, attribute payload and tags, plus creating, editing, duplicating and deleting them in the admin or via the API.
- Default values — Give a minipim product attribute a default value that is filled in when new products are created. Which types qualify, when defaults apply and when they don't.