Overview
Didit is the most agent-friendly identity verification platform. AI coding agents (Cursor, Claude Code, GitHub Copilot, Devin, OpenHands, Codex) can register, configure workflows, and start verifying identities — all programmatically, without ever opening a browser. Why agents love Didit:- 2 API calls from zero to credentials (register + verify-email).
- No browser required — fully headless, perfect for CI/CD and agent workflows.
- No second factor on a new API account: tokens are returned immediately after email verification.
- Auto-provisioned organization with a live and a sandbox application, both with their
api_keyin the verify response. - Full management API — configure workflows, questionnaires, lists, billing, all via API.
- MCP server available — agents can discover and use Didit tools natively.
Base URL
All endpoints in this guide live on the auth host:https://verification.didit.me/v3). The auth host issues JWT access tokens and manages applications. The verification host runs sessions, AML, workflows, etc., authenticated with the long-lived api_key you get from this flow.
Quick start
Step 1: Register
Use your mailbox address without a+tag. Registration rejects a tagged address such as you+test@yourdomain.com with HTTP 400 before looking up an account:
201 Created):
A3K9F2) is emailed to the address. The code expires 10 minutes after it is sent: if it lapses, call this endpoint again with the same email and password: for a still-unverified account it returns 200 with "A new verification code has been sent to your email." and a fresh code. A dedicated POST /programmatic/resend-otp/ endpoint also re-sends the code. Its body is the account’s email and password, {"email": "you@yourdomain.com", "password": "..."}, and it allows one send every 60 seconds per email (429 with Retry-After); both routes share the registration rate limit below.
Resending requires the password chosen at registration on every request, so knowing an email address alone cannot trigger another code. If you omit password, the response is HTTP 400 and no code is sent:
Step 2: Verify the code and get credentials
200 OK):
x-api-key header on every verification API call:
sandbox_application.api_keybuilds and tests the integration for free: every check is mocked and never billed, and each sandbox application can create 500 test sessions every 24 hours.application.api_keyverifies real people. Every live check is billed from the organization’s balance, which starts at $0.
uuid and the amount:
POST https://verification.didit.me/v3/billing/top-up/ with the live api_key returns a Stripe Checkout URL for the person to pay instead; check the result with GET /v3/billing/balance/.
Tokens are RS256-signed JWTs.
expires_in defaults to 86400 seconds (24 hours). The access token is only needed for the management endpoints on apx.didit.me/auth/v2 — verification API traffic on verification.didit.me/v3 is authenticated with the long-lived api_key, not the JWT.Step 3: Use the API
Build and test with the sandbox key (sandbox_application.api_key): every check is mocked and never billed. Switch to the live application.api_key only to go live, once the organization has credit.
Subsequent logins
From any future machine, exchange your email and password for a fresh JWT:access_token + refresh_token directly — no browser. From there, hit GET /organizations/me/ to discover your org_id (the organization’s uuid), then GET /organizations/me/{org_id}/applications/ to list the organization’s applications (each entry’s uuid is an app_id), and finally GET /organizations/me/{org_id}/applications/{app_id}/ to recover the api_key.
Console-created email/password accounts can also use
POST /programmatic/login/ after the email is verified. OAuth-only console accounts need to set a password before using this headless login endpoint.When login asks for more
POST /programmatic/login/ returns tokens only when the account has no second factor.
Three other answers are possible, and an agent scripting login should handle them:
An API key needs no login, so use one for anything automated: an account with a second factor cannot finish signing in through this endpoint.
To give an MCP client or coding agent user-level access to an account with a passkey or second factor on a machine with no browser, use the device code sign-in: you approve a short code from any device.
Password requirements
Enforced server-side, one rule at a time — the first failure short-circuits with a bare-array error like["Password must contain at least one uppercase letter."]. (Other validation errors on this endpoint use the field-keyed {"password": [...]} envelope. The bare-array shape on password-strength rules is a known server-side inconsistency; treat it as {"password": [...]} in client code.)
Rate limits and lockouts
Three independent controls protect the auth host. Any of them can trigger a429 response; the Retry-After response header tells you how long to back off.
A
429 body looks like this:
Managing applications
Once authenticated, you can retrieve, create, or update applications inside your organization. This is a perfect fit for resellers that want one application per customer. Each application has its ownclient_id, api_key, metadata, and settings. It is also useful when your organization has different products, brands, regions, environments, or use cases you want to keep separate.
403. An MCP token (a “Log in with Didit” grant) also needs the didit:management scope, which carries the applications resource: a grant limited to didit:verification is refused with 403 This token's scope does not permit this action. before any application is read or changed.
What can agents do after registration?
With theapi_key, agents have full access to the verification API. Audited paths on https://verification.didit.me/v3:
See the Management API reference for the full surface.
MCP server integration
For the best agent experience, use the hosted Didit MCP server athttps://mcp.didit.me/mcp. It needs no API key: on first connect your client opens a browser, you Log in with Didit (OAuth 2.1 with PKCE) and the server acts as you, with your console role’s permissions. Clients with native remote MCP support (Cursor, VS Code) take this entry; Claude web and Desktop add it as a custom connector:
claude mcp add --transport http didit https://mcp.didit.me/mcp. Clients that only speak stdio (Windsurf, Zed) go through the mcp-remote bridge, which runs the OAuth flow for you. On a machine with no browser (SSH, CI, a container), run npx -y @didit-protocol/mcp-server login and approve the code from any device; see Sign in without a browser.
The API key you receive from the registration flow above is for calling the REST API from your own backend; the MCP never takes it. See the MCP overview and per-client installation for details.
Error envelope reference
Allapx.didit.me/auth/v2 endpoints share the same three response shapes (see openapi-auth.json):
- Field-level validation —
{"field": ["message", ...]}with HTTP400. - Form-level validation (notably password strength and verification-code errors) — bare array
["Invalid or expired verification code."]with HTTP400. - Authentication / business rule —
{"detail": "..."}with400,401,403,404, or429.429responses carry aRetry-Afterresponse header telling you how long to back off (the body has onlydetail).
{"detail": "..."} and 429s include X-RateLimit-* and Retry-After — see Rate limiting.