Make a template (a filename, a title)
POST
/v1/templates
const url = 'https://example.com/v1/templates';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"filename":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/v1/templates \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "filename": "example" }'Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
filename
string
Example generated
{ "filename": "example"}Responses
Section titled “Responses”Made; the answer describes it.
Media typeapplication/json
object
id
required
string
filename
required
string
title
required
null | string
policy
required
object
createdAt
required
string
versions
Array
Example generated
{ "id": "example", "filename": "example", "title": "example", "policy": {}, "createdAt": "example", "versions": [ "example" ]}No key, or not a valid one.
Media typeapplication/json
object
code
required
string
message
required
string
requestId
string
Example
{ "code": "field-unknown"}The key lacks the scope, or its tenant is suspended or deleted.
Media typeapplication/json
object
code
required
string
message
required
string
requestId
string
Example
{ "code": "field-unknown"}