Update Template Endpoint
PUT
/v1/templates/{template_id}
const url = 'http://localhost:8080/v1/templates/example';const options = { method: 'PUT', headers: {'Content-Type': 'application/json'}, body: '{"description":"example","prompt_overlay":"","json_schema":{},"validation_rules":[{}],"review_thresholds":{},"post_processing":{}}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url http://localhost:8080/v1/templates/example \ --header 'Content-Type: application/json' \ --data '{ "description": "example", "prompt_overlay": "", "json_schema": {}, "validation_rules": [ {} ], "review_thresholds": {}, "post_processing": {} }'Create a new version of an existing template.
Versions are immutable — every PUT creates a new row. The caller’s template name is derived from the referenced template_id.
Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” template_id
required
Template Id
string
Request Body required
Section titled “Request Body required ” Media type application/json
TemplateUpdatePayload
object
prompt_overlay
Prompt Overlay
string
json_schema
required
Json Schema
object
key
additional properties
any
validation_rules
Validation Rules
Array<object>
object
key
additional properties
any
review_thresholds
Review Thresholds
object
key
additional properties
any
Responses
Section titled “ Responses ”Successful Response
Media type application/json
Response Update Template Endpoint V1 Templates Template Id Put
object
key
additional properties
any
Example generated
{}Validation Error
Media type application/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
Example generated
{ "detail": [ { "loc": [ "example" ], "msg": "example", "type": "example", "input": "example", "ctx": {} } ]}