Save the workspace's own letter (ADMIN+, dashboard user)
POST
/recovery-templates
const url = 'https://api.invogi.com/v1/recovery-templates';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"name":"example","purpose":"CLAIM","subject":"example","body":"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://api.invogi.com/v1/recovery-templates \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "name": "example", "purpose": "CLAIM", "subject": "example", "body": "example" }'A placeholder unknown for the letter’s purpose, or a stray {{/}}, is refused (400). Names are unique per workspace, ignoring case (409).
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
name
string
purpose
string
subject
string
body
string
Responses
Section titled “Responses”The template
Media typeapplication/json
object
id
required
Builtin:
string
name
required
string
purpose
required
string
subject
required
string
body
required
string
builtIn
required
boolean
description
string | null
updatedAt
string | null format: date-time
Example
{ "purpose": "CLAIM"}Invalid request
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
request_id
required
string
Example
{ "error": { "code": "NOT_FOUND" }}API key lacks required scope/role
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
request_id
required
string
Example
{ "error": { "code": "NOT_FOUND" }}Conflicting idempotency key or resource processing state
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
request_id
required
string
Example
{ "error": { "code": "NOT_FOUND" }}