Method
PUT /v1/contract-templates/:id
Path Parameters
uuid
required
Contract template ID.
Body Parameters
Show Translation object
Show Translation object
Headers
string
Bearer token (requires
contract-templates:write).string
application/jsonRequest Example
curl -X PUT "https://api.voyantcloud.com/v1/contract-templates/ct_01J0BE7Z3S494F9D4T3E2QJ0XR" \
-H "Authorization: Bearer $VOYANT_API_KEY" \
-H "content-type: application/json" \
-d '{
"name": "Customer Master Agreement (2025)",
"active": true,
"translation": {
"locale": "fr",
"bodyHtml": "<p>Version 2025 pour {{buyer.name}}.</p>",
"variables": {
"buyer.name": "Nom légal du client"
}
}
}'
await fetch("https://api.voyantcloud.com/v1/contract-templates/ct_01J0BE7Z3S494F9D4T3E2QJ0XR", {
method: "PUT",
headers: {
Authorization: `Bearer ${process.env.VOYANT_API_KEY}`,
"content-type": "application/json",
},
body: JSON.stringify({
templateJson: {
sections: [{ type: "paragraph", text: "Updated clause" }],
},
}),
})
import os, requests
payload = {
"type": "customer",
"description": None,
"translation": {
"locale": "en",
"bodyHtml": "<p>Updated contract body.</p>"
}
}
resp = requests.put(
"https://api.voyantcloud.com/v1/contract-templates/ct_01J0BE7Z3S494F9D4T3E2QJ0XR",
headers={
"Authorization": f"Bearer {os.environ['VOYANT_API_KEY']}",
"content-type": "application/json",
},
json=payload,
)
updated = resp.json()
Response
{
"template": {
"id": "ct_01J0BE7Z3S494F9D4T3E2QJ0XR",
"workspaceId": "ws_01HZYPM2QF2R8X9SZQ0J9SYBCN",
"name": "Customer Master Agreement (2025)",
"type": "customer",
"description": null,
"templateJson": {
"sections": [
{
"type": "paragraph",
"text": "Updated clause"
}
]
},
"active": true,
"createdBy": null,
"createdAt": "2025-01-10T11:08:44.000Z",
"updatedAt": "2025-03-22T09:52:10.000Z"
}
}
Translations are upserted per locale—sending a translation with the same
locale overwrites the existing localized body and metadata.