Endpoints allowing manipulations with source keys.
Delete source key 🔗
[DELETE] /projects/{projectId}/keys/{keyId}
Description | Value |
---|---|
Accessible with project token | true |
Accessible with organization token | true |
Need write permission | true |
Available from role | manager |
API level | normal |
Deletes a source key specified by {keyId}
.
Sample Request 🔗
curl --request DELETE \
--url https://api.localazy.com/projects/{projectId}/keys/{keyId} \
--header 'Authorization: Bearer {{token}}'
Sample Response 🔗
{
"result": true
}
Update source key 🔗
[PUT] /projects/{projectId}/keys/{keyId}
Description | Value |
---|---|
Accessible with project token | true |
Accessible with organization token | true |
Need write permission | true |
Available from role | manager |
API level | normal |
Update source key properties (one of hidden, deprecated, character limit and comment for translators) for a key specified by {keyId}
.
Sample Request 🔗
curl --request PUT \
--url https://api.localazy.com/projects/{projectId}/keys/{keyId} \
--header 'Authorization: Bearer {{token}}' \
--header 'Content-Type: application/json' \
--data '{
"deprecated": 37,
"hidden": true,
"comment": "Custom comment for the translator",
"limit": 100
}'
Request Object
Field | Description |
---|---|
deprecated |
Set to 0 or greater to mark the key as deprecated in the corresponding version; set to -1 to mark the key as not deprecated. |
hidden |
Set to true to mark the key as hidden for translation in Localazy. |
comment |
Provide custom comment for translators. |
limit |
Change the limit of translation lenght or set to -1 to disable it. |
All fields are optional and if omitted, the corresponding property is left unchanged.
Sample Response 🔗
{
"result": true
}