Skip to main content
idto runs two environments. Request and response shapes are the same in both, so code written against staging works against production by changing only the base URL and the key pair. A few behaviours differ, listed in What differs between environments; code that handles them works in both.
There is no sandbox that returns canned results. Every staging call reaches a live verification source, exactly as in production. Test only with identities you have permission to verify, such as your own team’s documents with their consent.

Keys

Each environment has its own X-Client-ID and X-API-Key pair, and a pair from one environment does not authenticate against the other.
  • Staging: ask your idto account manager. Staging keys are issued by hand.
  • Production: generate them in the dashboard under API Credentials once your account has completed go-live. See the Go-live checklist.
Read the base URL from configuration rather than hardcoding it, so promoting a build to production is a configuration change only.

Sandbox Mode in the dashboard

A new dashboard account opens in Sandbox Mode. In that mode the dashboard’s built-in API tester shows sample output in the browser and makes no API call. It is a way to explore response shapes, not a test environment, and nothing it shows reaches either base URL above. See the Dashboard guide.

What differs between environments

What this means for your tests:
  • The same input can give a different outcome. Because the source can differ, a placeholder or edge-case input can come back as IDTO_001 on one environment and IDTO_202 on the other. Branch on error_code and billed, and never hardcode the outcome of a specific input.
  • Handle 202 on the employment and passbook routes. On staging, POST /verify/employment_history, /verify/uan_passbook_without_otp and /verify/pf_employee_passbook can answer 202 with status: "pending", error_code: "IDTO_203", a reference_id and a Retry-After header. Fetch the result with GET /verify/result/{reference_id} after the number of seconds in Retry-After; it returns the same 202 until the result is ready, then the final response with its own status code. A reference_id that is unknown, or belongs to another account, returns 404 with IDTO_207. Production does not return 202 on these routes today.
  • A slow bank can time out on staging only. Retry with the same Idempotency-Key before treating it as a failure.

Check connectivity

GET /health on either base URL returns {"status":"ok"} with HTTP 200 and needs no keys. Use it to confirm that your servers can reach idto, for example from a new network or after a firewall change, before you debug a verification call.

Testing on staging

Because staging reaches live sources, plan your tests so that most of them never need one.
  • Input errors are free. A malformed PAN, Aadhaar number, IFSC or GSTIN, or missing consent, is rejected with IDTO_001 or IDTO_005 and is never billed, so you can test every validation path as often as you like. A number with the right shape that no one holds may instead reach the source and come back as a billed IDTO_202.
  • Found and no-record results cost a credit each. Test them with a small set of identities you are authorised to verify, and reuse the same ones.
  • Retries can be tested without extra charges. Send a request with an Idempotency-Key, then send it again with the same key and body: the second call returns the stored response and is not billed. See Idempotency.
  • Billing is visible in every v2 response. Assert on the billed field in your tests rather than on your balance.
Each endpoint page has a Test scenarios table listing the inputs that produce each outcome.

Promote to production

  1. Complete Switch to Production in the dashboard and recharge your production balance.
  2. Create a production key pair under API Credentials. The secret is shown once, when you create it, so copy it straight into your secret manager.
  3. If you use webhooks, set the webhook URL and generate a secret in the production dashboard. Webhook settings from staging do not carry over.
  4. Change the base URL and key pair in your production configuration. No code change is needed.
  5. Call GET /health, then run one real verification and confirm the response carries billed: true and a tranx_id.

Rotate keys

You can hold more than one key pair in an environment. To rotate without downtime, create a new pair, deploy it, confirm traffic is flowing on it, then disable or delete the old pair in API Credentials. A disabled pair is rejected with HTTP 403 and Client is inactive, so you can disable first and delete once you are sure nothing still uses it. Your webhook URL and secret are held on one of your active key pairs. After you disable or delete a pair, open the webhook settings and confirm the URL and secret are still set. If they are empty, set them again, or deliveries stop.

Next steps

Quickstart

Make a first call against staging.

Go-live checklist

Everything to confirm before you switch the base URL.
Was this page helpful? Email us at tech@idto.ai with the page link.
Last modified on October 4, 2026