This guide takes you from a configured client to your first 200 response. The target is the document list endpoint — simple enough to be a clean connectivity test, real enough to prove your credentials and setup are solid.
GET https://api.doctavian.com/v1/documents/document/listMake sure you've worked through the Get Started page before continuing.
Doctavian authenticates each call with a few HTTP headers. For your first call you only need the first two:
x-api-key — identifies the API area you are calling.Authorization — a standard OAuth 2.0 bearer token that identifies who you are.Most operations also require signed headers — you'll cover those in the Authentication Guide once you're past your first request.
The fastest way in is the Postman Collection — base URL, headers, and OAuth login all come preconfigured. Prefer the command line? Skip to cURL.
After downloading the Doctavian Postman collection, in Postman choose Import and select the file. A Doctavian collection appears in your sidebar.
Select the Doctavian collection, open the Authorization tab, scroll to the bottom and click Get New Access Token. A browser window opens — sign in with your Microsoft or Google account and click Use Token when prompted. Postman handles the entire OAuth 2.0 flow for you.
In the sidebar, open Documents → Document → Document List and click Send. A 200 OK response — even an empty list — confirms everything is working.
You're done — jump to What you just proved to continue, or keep reading if you want to see the same call made with cURL instead.
No Postman required — you just need a bearer token and your Documents key.
Open the API Keys and copy the access token and API key.
Drop your token and Documents key into environment variables so they don't end up in your shell history:
export DOCTAVIAN_TOKEN="<paste your access token>"
export API_KEY="<paste your API key>"curl -i https://api.doctavian.com/v1/documents/document/list \
-H "Authorization: Bearer $DOCTAVIAN_TOKEN" \
-H "x-api-key: $API_KEY"A 200 in the response confirms your first successful Doctavian call.
That's the foundation every other endpoint builds on.
The error code points straight at what's wrong:
401 Unauthorized - ApiKeyInvalid → the x-api-key is missing or isn't the Documents key.401 → the Authorization token is missing, expired, or invalid — get a fresh one (tokens within ~2 minutes of expiry are rejected).The full lookup table is in Authentication → Troubleshooting.
You're authenticated and connected. Where you go next depends on what you're building: