Copying and translating
Copying and translating in the management API. 5 endpoints.
Read the guideOpenAPI 3.1 document
Try it settings
https://api.bifrostorbit.com/cms/manage/v1
The management API takes a management token, which is secret and acts as a person, so nothing here is sent from the docs.
Try it sends each request straight from your browser to the API. The key stays in this page's memory: it is never saved, never sent to docs.bifrostorbit.com and gone when you leave or reload the page. Only reads are run; anything that changes data is described and never sent.
Brings a regional copy up to date with its source
POST/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/update-from-sourceKey required
Brings a regional copy up to date with its source. Permission: content:update.
Parameters
organisationIdstringpath, requiredThe organisation's id, from the Management tokens page.
spaceIdstringpath, requiredThe space's id.
environmentIdstringpath, requiredThe environment's id.
regionIdstringpath, requiredThe region's id.
localeIdstringpath, requiredThe language's id.
contentIdstringpath, requiredThe content item's id.
Idempotency-KeystringheaderOptional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.
Up to 255 characters.
Responses
200OK{ kept }.dataobjectFields of data
keptintegerFields kept because they were changed here.
400Bad requestIt isn't a regional copy, or its source is gone.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
401UnauthorisedNo token, or a token that is unknown, expired or revoked, or whose person no longer has access.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
403ForbiddenLacks content:update, or the token is read only.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
404Not foundNo such content item, or it's in another organisation.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
500Server errorSomething went wrong on our side. Try again in a moment.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
curl -X POST 'https://api.bifrostorbit.com/cms/manage/v1/organisations/6650f1c2a9e4b1d2c3f40a01/spaces/6650f1c2a9e4b1d2c3f40a02/environments/6650f1c2a9e4b1d2c3f40a13/regions/6650f1c2a9e4b1d2c3f40a17/locales/6650f1c2a9e4b1d2c3f40a18/content/6650f1c2a9e4b1d2c3f40a21/update-from-source' \ -H 'Authorization: Bearer cms_mt_…'Try it
Management tokens are secret and act as a person, so nothing is sent from the docs.
Example answer
{ "data": { "kept": 1 }}Copies pages or folders to another region or language
POST/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/copyKey required
Copies pages or folders to another region or language. Permission: content:copy here, content:create there.
Parameters
organisationIdstringpath, requiredThe organisation's id, from the Management tokens page.
spaceIdstringpath, requiredThe space's id.
environmentIdstringpath, requiredThe environment's id.
regionIdstringpath, requiredThe region's id.
localeIdstringpath, requiredThe language's id.
Idempotency-KeystringheaderOptional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.
Up to 255 characters.
Request body
environmentIdstringrequiredThe target environment.
regionIdstringrequiredThe target region.
localeIdstringrequiredThe target language.
folderIdstring or nulloptionalA folder to copy, with what it holds.
contentIdsstring[]optionalPages to copy. Without these and folderId, the whole language is copied.
Default true.includeContentbooleanoptional
Default true.includeSeobooleanoptional
Default true.includeMediabooleanoptional
Responses
201Created{ folders, content, target }.dataobjectFields of data
foldersintegercontentintegertargetobjectFields of target
environmentIdstringAn id.
regionIdstringAn id.
localeIdstringAn id.
pagesobject[]sometimesWhen you copied chosen pages: each copy's new id with the id it was copied from.
Fields of pages
sourceIdstringAn id.
idstringAn id.
namestring
400Bad requestThe body isn't valid JSON. Or the target is where it is now.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
401UnauthorisedNo token, or a token that is unknown, expired or revoked, or whose person no longer has access.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
403ForbiddenLacks content:copy here or content:create there.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
404Not foundNo such language, or it's in another organisation.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
422UnprocessableThe body doesn't match the schema. Each problem is in error.details.issues.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
500Server errorSomething went wrong on our side. Try again in a moment.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
curl -X POST 'https://api.bifrostorbit.com/cms/manage/v1/organisations/6650f1c2a9e4b1d2c3f40a01/spaces/6650f1c2a9e4b1d2c3f40a02/environments/6650f1c2a9e4b1d2c3f40a13/regions/6650f1c2a9e4b1d2c3f40a17/locales/6650f1c2a9e4b1d2c3f40a18/copy' \ -H 'Authorization: Bearer cms_mt_…' \ -H 'Content-Type: application/json' \ -d '{"environmentId":"6650f1c2a9e4b1d2c3f40a13","regionId":"6650f1c2a9e4b1d2c3f40a17","localeId":"6650f1c2a9e4b1d2c3f40a18","contentIds":["6650f1c2a9e4b1d2c3f40a21"]}'Try it
Management tokens are secret and act as a person, so nothing is sent from the docs.
Example answer
{ "data": { "folders": 1, "content": 1, "target": { "environmentId": "6650f1c2a9e4b1d2c3f40a13", "regionId": "6650f1c2a9e4b1d2c3f40a17", "localeId": "6650f1c2a9e4b1d2c3f40a18" }, "pages": [ { "sourceId": "6650f1c2a9e4b1d2c3f40a58", "id": "6650f1c2a9e4b1d2c3f40a40", "name": "Lofoten sea kayaking" } ] }}Machine-translates text into this language
POST/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/translateKey required
Machine-translates text into this language. Permission: content:update.
Parameters
organisationIdstringpath, requiredThe organisation's id, from the Management tokens page.
spaceIdstringpath, requiredThe space's id.
environmentIdstringpath, requiredThe environment's id.
regionIdstringpath, requiredThe region's id.
localeIdstringpath, requiredThe language's id.
Idempotency-KeystringheaderOptional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.
Up to 255 characters.
Request body
textstringrequiredWhat to translate into this language, up to 20,000 characters.
Up to 20000 characters.htmlbooleanoptionalThe text is rich text, so tags are kept.
Default false.
Responses
200OK{ text, to, usage }.dataobjectFields of data
textstringThe translation.
tostringThe language code, such as nb-NO.
usageobjectFields of usage
usedintegerCharacters used this month.
allowedinteger or nullThe plan's monthly allowance, or null for no limit.
400Bad requestThe body isn't valid JSON. Or machine translation is not set up.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
401UnauthorisedNo token, or a token that is unknown, expired or revoked, or whose person no longer has access.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
403ForbiddenLacks content:update, or the plan's monthly characters are used up.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
404Not foundNo such language, or it's in another organisation.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
422UnprocessableThe body doesn't match the schema. Each problem is in error.details.issues.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
500Server errorSomething went wrong on our side. Try again in a moment.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
curl -X POST 'https://api.bifrostorbit.com/cms/manage/v1/organisations/6650f1c2a9e4b1d2c3f40a01/spaces/6650f1c2a9e4b1d2c3f40a02/environments/6650f1c2a9e4b1d2c3f40a13/regions/6650f1c2a9e4b1d2c3f40a17/locales/6650f1c2a9e4b1d2c3f40a18/translate' \ -H 'Authorization: Bearer cms_mt_…' \ -H 'Content-Type: application/json' \ -d '{"text":"Six days of paddling between the peaks of Lofoten."}'Try it
Management tokens are secret and act as a person, so nothing is sent from the docs.
Example answer
{ "data": { "text": "…", "to": "…", "usage": { "used": 1, "allowed": 1 } }}A page or a folder's pages as an XLIFF 2.0 file for translation into another language of the region
GET/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/xliffKey required
A page or a folder's pages as an XLIFF 2.0 file for translation into another language of the region. Growth and up. Permission: content:read.
Parameters
organisationIdstringpath, requiredThe organisation's id, from the Management tokens page.
spaceIdstringpath, requiredThe space's id.
environmentIdstringpath, requiredThe environment's id.
regionIdstringpath, requiredThe region's id.
localeIdstringpath, requiredThe language's id.
contentIdstringqueryThe page to translate. Send this or folderId.
folderIdstringqueryA folder whose pages, with those of its subfolders, to translate. Up to 200 pages.
targetLocaleIdstringquery, requiredThe language to translate into: another language of the same region.
Responses
200OKXLIFF 2.0 with one file per page (its id) and one unit per text, long text, rich text and SEO title or description, including those inside blocks. Rich text keeps its tags as text.application/xliff+xml
400Bad requestNo page or folder, more than 200 pages, or a language outside the region.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
401UnauthorisedNo token, or a token that is unknown, expired or revoked, or whose person no longer has access.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
403ForbiddenThe plan is below Growth.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
404Not foundNo such language, or it's in another organisation.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
500Server errorSomething went wrong on our side. Try again in a moment.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
curl 'https://api.bifrostorbit.com/cms/manage/v1/organisations/6650f1c2a9e4b1d2c3f40a01/spaces/6650f1c2a9e4b1d2c3f40a02/environments/6650f1c2a9e4b1d2c3f40a13/regions/6650f1c2a9e4b1d2c3f40a17/locales/6650f1c2a9e4b1d2c3f40a18/xliff?targetLocaleId=6650f1c2a9e4b1d2c3f40a19' \ -H 'Authorization: Bearer cms_mt_…'Try it
Management tokens are secret and act as a person, so nothing is sent from the docs.
Imports a translated XLIFF file as drafts in the other language, making the pages there when they are missing
POST/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/xliffKey required
Imports a translated XLIFF file as drafts in the other language, making the pages there when they are missing. Never publishes. Growth and up. Permission: content:update there.
Parameters
organisationIdstringpath, requiredThe organisation's id, from the Management tokens page.
spaceIdstringpath, requiredThe space's id.
environmentIdstringpath, requiredThe environment's id.
regionIdstringpath, requiredThe region's id.
localeIdstringpath, requiredThe language's id.
Idempotency-KeystringheaderOptional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.
Up to 255 characters.
Request body
xliffstringrequiredThe translated file's text, XLIFF 2.0 or 1.2, up to 10 MB.
targetLocaleIdstringrequiredThe language the file is translated into.
Responses
200OK{ pages, created, units, skipped }.dataobjectFields of data
pagesintegerPages whose draft now holds the translation.
createdintegerPages made in the other language because they were missing.
unitsintegerTexts filled in.
skippedobject[]Fields of skipped
namestring
One of locked, invalid, noChanges.reasonstring
400Bad requestThe body isn't valid JSON. Or not XLIFF, or translated from or into another language.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
401UnauthorisedNo token, or a token that is unknown, expired or revoked, or whose person no longer has access.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
403ForbiddenThe plan is below Growth, or content:update is missing in the other language.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
404Not foundNo such language, or it's in another organisation.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
500Server errorSomething went wrong on our side. Try again in a moment.errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.
curl -X POST 'https://api.bifrostorbit.com/cms/manage/v1/organisations/6650f1c2a9e4b1d2c3f40a01/spaces/6650f1c2a9e4b1d2c3f40a02/environments/6650f1c2a9e4b1d2c3f40a13/regions/6650f1c2a9e4b1d2c3f40a17/locales/6650f1c2a9e4b1d2c3f40a18/xliff' \ -H 'Authorization: Bearer cms_mt_…' \ -H 'Content-Type: application/json' \ -d '{"xliff":"<?xml version=\"1.0\"?><xliff xmlns=\"urn:oasis:names:tc:xliff:document:2.0\" version=\"2.0\" srcLang=\"en-GB\" trgLang=\"nb-NO\">…</xliff>","targetLocaleId":"6650f1c2a9e4b1d2c3f40a19"}'Try it
Management tokens are secret and act as a person, so nothing is sent from the docs.
Example answer
{ "data": { "pages": 1, "created": 1, "units": 1, "skipped": [ { "name": "Lofoten sea kayaking", "reason": "locked" } ] }}SchemasThe shapes the endpoints above answer with and take.
Error
Every error has this shape. Write code against code and the status, never the message.
errorobjectFields of error
One of bad_request, unauthorized, forbidden, not_found, created_in_orbit, conflict, validation_failed, internal_error, unavailable.codestringmessagestringFollows Accept-Language when CMS Orbit has the language.
detailsanysometimesWhen there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received.