Customiser languages
Validate setting the authoring language
Dry-runs the authoring change without writing anything and returns the
same problems the write would. The 200 verdict reports what the change
would do to the language's copy of the owned text: replaced_draft_count
draft values replaced by published values and cleared_optional_count
optional values cleared.
Overview
Both are 0 when the language is already the
authoring language. plan_token binds the write to these counts: send
it to the write. Send a plan_token here to check whether it is still
current. Requires customisers:write.
Authorisation
Bearer token required. Include it in the Authorization header.
Required scope: customisers:write
Path parameters
customiser_idrequired
The customiser id.
Example: 1
language_coderequired
The language tag.
Example: fr
Request body
plan_token
Request body example
application/json
{
"plan_token": "9c1e4f0b2a7d4e8f9a6b3c5d7e1f2a4b6c8d0e2f4a6b8c0d2e4f6a8b0c2d4e6f"
}Validate setting the authoring language
curl https://web.signcustomiser.com/api/v3/customisers/1/languages/fr/validate-authoring \
--request POST \
--header 'Accept: application/json' \
--header 'Authorization: Bearer YOUR_API_TOKEN' \
--header 'Content-Type: application/json' \
--data '{
"plan_token": "9c1e4f0b2a7d4e8f9a6b3c5d7e1f2a4b6c8d0e2f4a6b8c0d2e4f6a8b0c2d4e6f"
}'Response
{
"data": {
"object": "customiser_language_validation",
"operation": "set_authoring",
"customiser_id": 42,
"language_code": "fr",
"replaced_draft_count": 3,
"cleared_optional_count": 1,
"plan_token": "9c1e4f0b2a7d4e8f9a6b3c5d7e1f2a4b6c8d0e2f4a6b8c0d2e4f6a8b0c2d4e6f",
"valid": true
},
"links": {
"self": "https://web.signcustomiser.com/api/v3/customisers/42/languages/fr/validate-authoring",
"documentation": "https://www.signcustomiser.com/help/api/"
},
"meta": {
"api_version": "v3",
"request_id": "req_01jz9x2k7c8f3m5n6p7q8r9s0t"
}
}{
"type": "https://www.signcustomiser.com/help/api/problems/insufficient_scope",
"title": "Insufficient scope",
"status": 403,
"code": "insufficient_scope",
"detail": "This operation requires the customisers:write scope.",
"required_scopes": [
"customisers:write"
],
"granted_scopes": [
"customisers:read"
],
"request_id": "req_01jz9x2k7c8f3m5n6p7q8r9s0t"
}