Skip to main content
POST
/
api
/
documents
Upload Document
curl --request POST \
  --url https://api.example.com/api/documents/ \
  --header 'Content-Type: application/json' \
  --cookie sessionid= \
  --data '
{
  "file": "<string>",
  "original_name": "<string>",
  "case_id": 123,
  "check_id": 123,
  "customer_id": 123,
  "delete_after": 123
}
'
{
  "id": 123,
  "check": 123,
  "file": "<string>",
  "original_name": "<string>",
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z",
  "case": 123,
  "customer": 123,
  "delete_after": -1
}

Authorizations

sessionid
string
cookie
required

Body

Write serializer for Document upload.

file
string<uri>
required

Base64 encoded file content.

original_name
string
required
Maximum string length: 255
case_id
integer

ID of the case

check_id
integer

ID of the check

customer_id
integer

ID of the customer

delete_after
integer

Number of days until deletion. Max 365. For immediate deletion, use 0.

Response

201 - application/json

Read-only serializer for Document.

id
integer
required
check
integer
required
file
string
required

Base64 encoded file content.

original_name
string
required
Maximum string length: 255
created_at
string<date-time>
required
updated_at
string<date-time>
required
case
integer | null
customer
integer | null
delete_after
integer

Days until deletion.

Required range: -2147483648 <= x <= 2147483647