Score Requests#
A Score Request initiates the scoring process for a tenant based on data from a Verification Report. You specify which score types to generate.
The Score Request object#
| Attribute | Type | Description |
|---|---|---|
id | string | Unique identifier with sr_ prefix |
object | string | Always "score_request" |
verification_report | string | Linked Verification Report ID |
score_types | array | Score types requested: tenant_score, cash_flow_score, credit_score |
status | enum | pending, processing, completed, error |
score_report | string | ID of generated Score Report (when completed) |
error | object | Error details if status is error |
metadata | hash | Key-value pairs |
created | timestamp | Time at which the object was created |
{
"id": "sr_abc123def456",
"object": "score_request",
"verification_report": "vr_9z8y7x6w5v",
"score_types": ["tenant_score", "cash_flow_score", "credit_score"],
"status": "completed",
"score_report": "scrpt_xyz789",
"metadata": {},
"created": 1706140800
}Create a Score Request#
POST /v1/score_requests
| Parameter | Type | Required | Description |
|---|---|---|---|
verification_report | string | Yes | Verification Report ID to score |
score_types | array | Yes | Types of scores to generate |
metadata | hash | No | Key-value pairs |
curl https://api.casapay.com/v1/score_requests \
-H "Authorization: Bearer sk_test_4eC39HqLyjWDarjtT1zdp7dc" \
-H "Content-Type: application/json" \
-d '{
"verification_report": "vr_9z8y7x6w5v",
"score_types": ["tenant_score", "cash_flow_score", "credit_score"]
}'{
"id": "sr_abc123def456",
"object": "score_request",
"status": "processing",
"score_types": ["tenant_score", "cash_flow_score", "credit_score"],
"created": 1706140800
}Retrieve a Score Request#
GET /v1/score_requests/:id
curl https://api.casapay.com/v1/score_requests/sr_abc123def456 \
-H "Authorization: Bearer sk_test_4eC39HqLyjWDarjtT1zdp7dc"List Score Requests#
GET /v1/score_requests
| Parameter | Type | Description |
|---|---|---|
verification_report | string | Filter by Verification Report ID |
status | string | Filter by status |
limit | integer | Number of objects to return (1–100) |
starting_after | string | Cursor for pagination |
curl https://api.casapay.com/v1/score_requests?status=completed&limit=10 \
-H "Authorization: Bearer sk_test_4eC39HqLyjWDarjtT1zdp7dc"