Skip to main content
POST
/
v1
/
documents
Create document
curl --request POST \
  --url https://api.zavu.dev/v1/documents \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "Passport Scan",
  "documentType": "passport",
  "storageId": "kg2abc123...",
  "mimeType": "image/jpeg",
  "fileSize": 102400
}
'
{
  "document": {
    "id": "<string>",
    "name": "<string>",
    "documentType": "passport",
    "status": "pending",
    "createdAt": "2023-11-07T05:31:56Z",
    "mimeType": "<string>",
    "fileSize": 123,
    "rejectionReason": "<string>",
    "updatedAt": "2023-11-07T05:31:56Z"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
name
string
required
Maximum string length: 200
documentType
enum<string>
required
Available options:
passport,
national_id,
drivers_license,
utility_bill,
tax_id,
business_registration,
proof_of_address,
other
storageId
string
required

Storage ID from the upload-url endpoint.

mimeType
string
required
fileSize
integer
required

Response

Document created and uploaded to verification provider.

document
object
required

A regulatory document for phone number requirements.