Update Locale
contentful.update_locale
ActionBusiness appsconnection required
Calls the Contentful API with the connection's credentials.
Replace a locale's settings at a known version; every setting it should keep must be sent.
Connection
- Required
- Yes — the node will not save without one
- Auth type
- Bearer token
- Providers
- Contentful
- Secret shape
- the CMA access token, or {"access_token": "…"}
- Config it needs
- space_id, environment_id, base_url
- Resolved by
- config.connection_id, else node.connection_id
Configuration
10 fields, 4 required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.
| Field | Type | Required | Default | Constraints | Example |
|---|---|---|---|---|---|
locale_id The id of the locale to act on. | string | Yes | — | — | — |
name The locale's display name. | string | Yes | — | — | — |
code The locale code, such as 'de-DE'. | string | Yes | — | — | — |
version The entity's current sys.version. Contentful refuses the write when it is stale. | number | Yes | — | ≥ 1 | — |
fallback_code The locale to fall back to when a field is empty here, such as 'en-US'. | string | No | — | — | — |
optional Whether entries may leave required fields empty in this locale. | boolean | No | false | — | — |
content_delivery_api Whether content in this locale is served by the delivery API. | boolean | No | true | — | — |
content_management_api Whether this locale can be edited through the management API. | boolean | No | true | — | — |
space_id The space to act on. Leave blank to use the connection's space. | string | No | — | — | — |
environment_id The environment to act on. Leave blank to use the connection's environment, or 'master'. | string | No | — | — | — |
Example configuration
Every value below is the contract’s own example or default — nothing invented.
{
"content_delivery_api": true,
"content_management_api": true,
"optional": false
}Output
One shape.
result
| Field | Type | Example |
|---|---|---|
sys.id The locale id. | string | — |
sys.version The locale's version after this call. | number | — |
name The locale's display name. | string | — |
code The locale code, such as 'en-US'. | string | — |
fallbackCode The locale content falls back to, or null when there is none. | string | — |
default Whether this is the environment's default locale. | boolean | — |
{
"code": "",
"default": false,
"fallbackCode": "",
"name": "",
"sys": {
"id": "",
"version": 0
}
}Notes
- The 'version' is the entity's current sys.version — read it from the entry, asset, content type or locale first; Contentful answers 409 when the version is not the latest.
See Update Locale run in a workflow.
In a technical demo we add the Contentful connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.