Set a term translation
curl --request PUT \
--url https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"value": "Se connecter"
}
'import requests
url = "https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}"
payload = { "value": "Se connecter" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({value: 'Se connecter'})
};
fetch('https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'value' => 'Se connecter'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}"
payload := strings.NewReader("{\n \"value\": \"Se connecter\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"value\": \"Se connecter\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"value\": \"Se connecter\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"term": {
"id": "a1b2c3d4-0000-4000-8000-000000000020",
"glossaryId": "a1b2c3d4-0000-4000-8000-000000000010",
"term": "Sign in",
"doNotTranslate": false,
"caseSensitive": false,
"usageStatus": "preferred",
"notes": "Use the verb form; never capitalize mid-sentence.",
"createdAt": "2026-01-15T09:24:00.000Z",
"updatedAt": "2026-02-02T14:05:00.000Z",
"translations": [
{
"languageCode": "fr",
"value": "Se connecter",
"status": "approved",
"approvedAt": "2026-01-16T11:00:00.000Z",
"proposedValue": null
}
]
}
}
}Glossary
Set a term translation
Upsert the translation of a term in one language, creating it if absent. When the glossary requires approval and you cannot approve, the value is stored as a proposal rather than applied — see the approval workflow.
Constraints:
- For a Translator-scoped token, the target language must be within the token owner’s assigned languages, or the request is rejected with 403.
PUT
/
glossaries
/
{glossaryId}
/
terms
/
{termId}
/
translations
/
{lang}
Set a term translation
curl --request PUT \
--url https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"value": "Se connecter"
}
'import requests
url = "https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}"
payload = { "value": "Se connecter" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({value: 'Se connecter'})
};
fetch('https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'value' => 'Se connecter'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}"
payload := strings.NewReader("{\n \"value\": \"Se connecter\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"value\": \"Se connecter\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.textsetu.com/api/v1/glossaries/{glossaryId}/terms/{termId}/translations/{lang}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"value\": \"Se connecter\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"term": {
"id": "a1b2c3d4-0000-4000-8000-000000000020",
"glossaryId": "a1b2c3d4-0000-4000-8000-000000000010",
"term": "Sign in",
"doNotTranslate": false,
"caseSensitive": false,
"usageStatus": "preferred",
"notes": "Use the verb form; never capitalize mid-sentence.",
"createdAt": "2026-01-15T09:24:00.000Z",
"updatedAt": "2026-02-02T14:05:00.000Z",
"translations": [
{
"languageCode": "fr",
"value": "Se connecter",
"status": "approved",
"approvedAt": "2026-01-16T11:00:00.000Z",
"proposedValue": null
}
]
}
}
}Authorizations
API token: tsu_pat_… (PAT) or tsu_proj_… (project token). The token's granted RBAC permissions determine access; see each operation's x-permission.
Path Parameters
Glossary id (UUID) or id-embedded path slug.
Glossary term id (UUID).
Language code, optionally with a file extension (fr or fr.json).
Body
application/json
The translated text for the term in the target language.
Example:
"Se connecter"

