API collection
Ready-to-run requests for the Esnad API. Import into Postman, Insomnia, Bruno, Hoppscotch, or any HTTP client that supports Postman Collection v2.1. Base URL is https://api.esnadapi.com. Authenticate with your API key (zatca_test_ for sandbox or zatca_live_ for production).
Setup
- Download the zip (or both JSON files) and import them in your API client.
- Select the Esnad API environment (if your client uses environments).
- Set
apiKeyto the key from your dashboard.
Tip
Import both the collection and the environment. The collection alone does not create environment variables in most clients.
What’s in the collection
- Auth context — verify API key (
GET /v1/auth/context) - EGS units (create, status, renew, list via status)
- Invoices (simplified B2C, standard B2B, credit/debit notes, list, XML, PDF)
- Reference data
API keys and webhook configuration are done in the dashboard. Every invoice request must include egs_unit_id for the branch or POS that is issuing. See Flow & integration.
Suggested first run
- Verify your API key with
GET /v1/auth/context(see folder 0. Auth in the collection) - Create an EGS unit (sandbox OTP
123345with azatca_test_key). The collection savesegs_unit_idautomatically in clients that run the included scripts. - Poll EGS status until
onboarding_statusisactive. - Create a simplified or standard invoice.