v2client API Reference
Complete reference for the v2client verification portal endpoints. Server-to-server integration with your API key.
v2client Architecture
The v2client is a hosted verification portal with server-side endpoints for operator integration:
Your Server
Calls v2client with API key
v2client Portal
Verification interface + API endpoints
okID Backend
Verification processing engine
Security Model
Your API key is sent via X-SDK-Key header for verification generation. All subsequent user interactions use verification IDs.
Base URL
https://verify.prod.okid.io
https://verify.stage.okid.io
Authentication
Core Endpoints
/api/generate-verificationGenerates a verification ID using your API key. This must be called from your server.
Request Headers
Request Body (Optional)
Response
Extra Data
The optional extra_data field allows you to attach custom metadata to a verification. This data is stored with the verification and returned in webhook notifications, enabling you to track verifications with your internal identifiers (order IDs, user references, etc.).
Return URL
The optional return_url parameter specifies a URL where the user will be automatically redirected after completing verification. When provided:
- User sees verification result (success or manual review)
- A 3-second countdown is displayed
- User is automatically redirected to the specified URL
This is useful for integrations where you want to bring users back to your application after verification completes.
Basic Example
With Extra Data
/verifyUser-facing verification portal. Users complete their verification flow here.
Query Parameters
User Flow
1. Terms acceptance
2. Document upload
3. Liveness detection
4. Form data collection
5. Verification complete
Example URL
/generateInternal route for QR code verification generation. Redirects to verification portal.
Usage
This route is primarily used internally by QR codes. For operator integration, use the POST /api/generate-verification endpoint.
/api/get-verification-details/{verification_id}Retrieves the complete verification record including status, results, and metadata. API key must own the verification.
Request Headers
Response
Example Usage
Security Note
API keys can only retrieve verifications they created. Attempting to access another organization's verification will result in a 403 Forbidden error.
Image Retrieval Endpoints
Note: These endpoints return the final accepted images from completed verifications. To inspect individual submission attempts (including rejected ones), use the Dashboard.
curl Command Builder
curl -H "X-SDK-Key: YOUR_API_KEY" "https://verify.stage.okid.io/api/get-verification-image-front/YOUR_VERIFICATION_ID" -o "front.jpg"front.jpg in your current directory./api/get-verification-image-front/{verification_id}Directly retrieves the front document image without needing to determine attempt indices. Automatically finds the accepted front image and applies redaction based on API key settings. X-SDK-Key header is mandatory - requests without this header will be rejected with 401 Unauthorized.
Request Headers
Query Parameters (Optional)
Example Usage
Quick Test (curl)
Advantages
- No attempt index required - automatically finds the accepted front image
- Side-specific - explicitly get front document without guessing
- Authenticated - secure access control with API key verification
- Cleaner API - more intuitive for document-based workflows
/api/get-verification-image-back/{verification_id}Directly retrieves the back document image without needing to determine attempt indices. Automatically finds the accepted back image and applies redaction based on API key settings. X-SDK-Key header is mandatory - requests without this header will be rejected with 401 Unauthorized.
Request Headers
Query Parameters (Optional)
Example Usage
Quick Test (curl)
Advantages
- No attempt index required - automatically finds the accepted back image
- Side-specific - explicitly get back document without guessing
- Authenticated - secure access control with API key verification
- Cleaner API - more intuitive for document-based workflows
/api/get-verification-image-selfie/{verification_id}Retrieves the selfie image from the liveness verification module. Returns the accepted selfie used for face matching. X-SDK-Key header is mandatory - requests without this header will be rejected with 401 Unauthorized.
Request Headers
Response
Example Usage
Quick Test (curl)
Note
Returns 404 if the verification did not include a liveness module or if liveness verification was not completed.
Error Responses
HTTP Status Codes
401 - Missing X-SDK-Key header403 - API key doesn't own this verification404 - Verification not found OR no accepted image available for requested type404 - Selfie not available (liveness module not completed)Parameters Reference
image_type (optional, front/back only)
Type of image to retrieve. If not specified, returns the default processed image.
Error Responses
Common Error Codes
400Bad Request - Invalid parameters401Unauthorized - Invalid API key403Forbidden - API key cannot access verification404Not Found - Invalid verification ID500Server Error - Internal errorError Response Format
Common Integration Issues
- •
INVALID_API_KEY- API key not found or inactive - •
ACCESS_DENIED- API key cannot access this verification - •
SERVER_NOT_CONFIGURED- v2client missing base URL configuration - •
VERIFICATION_EXPIRED- verification_id has expired - •
VERIFICATION_NOT_FOUND- Invalid verification_id
Rate Limits & Best Practices
Rate Limits
100/minute300/minuteNo limit