Edit a text template
PATCH
/v1/workspace/texting/templates/{template_id}
const url = 'https://api.vocapable.com/v1/workspace/texting/templates/example';const options = { method: 'PATCH', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"name":"example","body":"example","expected_revision":1}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PATCH \ --url https://api.vocapable.com/v1/workspace/texting/templates/example \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "name": "example", "body": "example", "expected_revision": 1 }'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”template_id
required
Template Id
string
Request Bodyrequired
Section titled “Request Bodyrequired”Responses
Section titled “Responses”Successful Response
Media typeapplication/json
WorkspaceTextTemplate
object
id
required
Id
string
name
required
Name
string
body
required
Body
string
fields
required
Fields
Array<string>
revision
required
Revision
integer
updated_at
required
Updated At
string format: date-time
Examplegenerated
{ "id": "example", "name": "example", "body": "example", "fields": [ "example" ], "revision": 1, "updated_at": "2026-04-15T12:00:00Z"}Validation Error
Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object
Examplegenerated
{ "detail": [ { "loc": [ "example" ], "msg": "example", "type": "example", "input": "example", "ctx": {} } ]}