Case Status Model
Each case has two different types of status:
1. Run Status – Workflow Execution
Tracks where the case is in the execution pipeline:
| Run Status | Description |
|---|---|
NOT_STARTED | Workflow not yet initiated |
SUBMITTED | User submitted details in UI |
RUNNING | Workflow executing |
PENDING | Waiting for external data or input |
COMPLETED | Execution finished |
FAILED | Workflow error |
2. Result Status – Verification Outcome
Represents the final decision:
| Result Status | Meaning |
|---|---|
APPROVED | Verification passed |
DECLINED | Verification failed |
REVIEW | Needs manual review |
UNKNOWN | No decision yet |
Typical Combinations
RUNNING + UNKNOWN→ In progressCOMPLETED + APPROVED→ Verification successfulCOMPLETED + DECLINED→ Verification failedCOMPLETED + REVIEW→ Requires manual reviewFAILED + UNKNOWN→ Workflow error
Case Metadata
Every case stores structured metadata that helps track and correlate verification attempts.
| Field | Description |
|---|---|
verification_session_id | Unique case/session ID |
entity_type | USER or BUSINESS |
template_id | Template used for verification |
client_reference_id | Your internal reference ID |
client_reference_data | Custom metadata (JSON) |
callback_url | URL for verification result delivery |
events_callback_url | URL for real-time event notifications |
created_at | Case creation timestamp |
processing_start_time | When workflow started |
processing_end_time | When workflow finished |
expires_at | Session expiration time (for hosted UI links) |
Client References
Client references allow you to map AiPrise cases to your internal systems.
Example Usage
{
"template_id": "template-uuid",
"client_reference_id": "order-12345",
"client_reference_data": {
"order_id": "order-12345",
"customer_tier": "premium",
"source": "mobile_app"
},
"user_data": { ... }
}Benefits:
- Correlation: Link verification to orders, users, workflows
- Analytics: Segment checks by region, tier, product, etc.
- Debugging: Easily search and track verifications
The same metadata is returned in API responses and webhook callbacks.
Updated about 7 hours ago
