Your First Request
Get up and running with the DayZero API in minutes.
Prerequisites
- A DayZero account with API access enabled
- An API token (see Authentication)
- Your business ID (found in the dashboard URL or settings)
Step 1: List Your Businesses
bash
curl "https://api.ondayzero.com/api/v1/businesses" \
-H "Authorization: Bearer dz_your_token_here"Response:
json
{
"items": [
{
"id": "01912345-abcd-7000-8000-000000000001",
"name": "Acme Corp",
"currency": "USD"
}
],
"next_cursor": null,
"has_more": false
}Step 2: Fetch Transactions
Use the id from above as your x-business-id:
bash
curl "https://api.ondayzero.com/api/v1/transactions?limit=5" \
-H "Authorization: Bearer dz_your_token_here" \
-H "x-business-id: 01912345-abcd-7000-8000-000000000001"Step 3: Create an Invoice
bash
curl -X POST "https://api.ondayzero.com/api/v1/invoices" \
-H "Authorization: Bearer dz_your_token_here" \
-H "x-business-id: 01912345-abcd-7000-8000-000000000001" \
-H "Content-Type: application/json" \
-d '{
"customer_id": "CUSTOMER_UUID",
"due_date": "2026-05-01",
"line_items": [
{
"description": "Consulting services",
"quantity": 1,
"unit_price": 15000
}
]
}'Note: All amounts are in cents.
15000= $150.00.
What's Next?
- Error Handling — understand API error responses
- Pagination — navigate large result sets
- Transactions — work with bank transactions
- MCP Server — connect AI assistants like Claude and Cursor