/api/v1/documents (POST)
POST
/api/v1/documents
const url = 'https://example.com/api/v1/documents';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","subject":{"thingId":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"},"kind":"registration","title":"example","expiresOn":"2026-04-15","leadDays":1,"issuedOn":"2026-04-15","cost":"example","currency":"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/api/v1/documents \ --header 'Content-Type: application/json' \ --data '{ "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "subject": { "thingId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" }, "kind": "registration", "title": "example", "expiresOn": "2026-04-15", "leadDays": 1, "issuedOn": "2026-04-15", "cost": "example", "currency": "example" }'Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
id
string format: uuid
subject
required
kind
required
string
title
string
expiresOn
required
string format: date
leadDays
integer
Responses
Section titled “Responses”Default Response
Media typeapplication/json
object
id
required
string format: uuid
locationId
required
string format: uuid
subject
required
object
type
required
string
id
required
string format: uuid
name
required
string
path
required
string
shortCode
string | null
kind
required
string
title
required
string | null
expiresOn
required
string
leadDays
required
integer
state
required
string
history
required
Array<object>
object
id
required
string format: uuid
expiresOn
required
string
documents
required
rowVersion
required
integer
issuedOn
required
string | null
cost
string
currency
string
moneyHidden
boolean
Example
{ "subject": { "type": "thing" }, "kind": "registration", "state": "ok", "moneyHidden": true}