Skip to content

docs: drop the locale field and PUT ids from translation payloads - #99

Merged
paullla merged 1 commit into
Locastic:masterfrom
paullla:docs/translation-payload-rules
Dec 2, 2026
Merged

paullla merged 1 commit into
Locastic:masterfrom
paullla:docs/translation-payload-rules

Conversation

@paullla

@paullla paullla commented Dec 2, 2026

Copy link
Copy Markdown
Member
Q A
Bug fix? no
New feature? no
BC breaks? no
Deprecations? no
Issues relates to #81
License MIT

Problem

Since 2.0.0 (#81), the locale of each translation entry comes from its map key (a locale field in the entry is ignored), and PUT and PATCH match the submitted translations to the existing rows by locale. The README, the Context7 rules and the agent skills from #97 still say that each entry must repeat its locale field and that a PUT must send the id of each translation, so every example payload carries fields the bundle does not use. Checked over HTTP on API Platform 3.4, 4.3 and 5.0: entries without locale get the key as locale, a key that differs from the entry's locale wins, and a PUT without ids keeps the row ids and removes the locales that are not in the payload.

Changes

  • README: the POST, PATCH and PUT request examples drop the locale fields and the PUT ids. The POST and PUT texts say that the key sets the locale and that rows keep their ids. The response example still shows id and locale, because responses contain them.
  • context7.json: the two rules are rewritten to match.
  • Skills api-translation-writes and api-translation-resource: the same payload changes.
  • CHANGELOG entry under Unreleased.

Since 2.0.0 (Locastic#81) the map key sets the locale of each translation entry
(a `locale` field in the entry is ignored), and PUT and PATCH match the
submitted translations to their rows by locale. The README, the Context7
rules and the agent skills still asked for a `locale` field in every
entry and for the `id` of each translation in PUT payloads. Checked over
HTTP on API Platform 3.4, 4.3 and 5.0.
@paullla
paullla merged commit 2b5b937 into Locastic:master Dec 2, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant