Localization
Request locale keys and preserve fallback across queries and cursors.
Pass one stable public locale key through GraphQL’s locale argument or REST’s locale query parameter. Omission selects the Backend default. Accept-Language is ignored.
Access
Delivery keys have Backend scope only. Preview requires content.read for every applicable Data Type and requested locale; term.read controls Term Vocabulary and locale access.
Fallback order
For a request with locale: "fr-CA", Jetrepo checks:
- the
fr-CAvalue; - configured fallbacks for
fr-CA; - the Backend default locale;
- a nonlocalized value;
null.
An explicitly empty value—such as "", [], or an empty Component container—stops fallback.
| Field | Authored values | Delivered for fr-CA |
|---|---|---|
title |
fr-CA: "Bonjour" |
"Bonjour" |
summary |
fr-CA absent, fr: "Résumé" |
"Résumé" when fr is configured as fallback |
code |
nonlocalized "A-17" |
"A-17" |
subtitle |
fr-CA: "", fr: "Texte" |
"" |
caption |
no value | null |
The same resolved locale drives projection, filters, sorts, cursors, and nested relations. Keep it unchanged while paging.
Public locale keys are the supported stable input. Current compatibility may also accept an internal locale ID, but clients should not depend on that behavior.
Errors and constraints
An unknown locale returns REST 400 or GraphQL BAD_USER_INPUT with HTTP status metadata 400. A known locale excluded by Preview authorization returns 404 to avoid disclosure. Preview also removes unauthorized locales from fallback.
One root or REST request returns one locale. There is no all-locales response or caller-defined fallback override. Search remains all-language.