Guarantees#
A Guarantee object represents a rent guarantee covering a specific tenant and property. If the tenant defaults, the landlord can file a claim to recover the guaranteed amount.
The Guarantee object#
| Attribute | Type | Description |
|---|---|---|
id | string | Unique identifier with grt_ prefix |
object | string | Always "guarantee" |
status | enum | pending, active, claimed, expired, cancelled |
policy | string | Guarantee Policy ID |
tenant | string | Customer/tenant ID |
coverage_amount | integer | Maximum guaranteed amount per period |
total_coverage | integer | Total lifetime coverage |
currency | string | ISO 4217 currency code |
start_date | timestamp | Coverage start date |
end_date | timestamp | Coverage end date |
claims_filed | integer | Number of claims filed |
claims_paid | integer | Total amount paid in claims |
metadata | hash | Key-value pairs |
created | timestamp | Time at which the object was created |
{
"id": "grt_def456",
"object": "guarantee",
"status": "active",
"policy": "gpol_abc123",
"tenant": "cus_123456789",
"coverage_amount": 120000,
"total_coverage": 1440000,
"currency": "eur",
"start_date": 1706140800,
"end_date": 1737676800,
"claims_filed": 0,
"claims_paid": 0,
"metadata": {
"property_id": "prop_456",
"lease_id": "lease_789"
},
"created": 1706140800
}Create a Guarantee#
POST /v1/guarantees
| Parameter | Type | Required | Description |
|---|---|---|---|
policy | string | Yes | Guarantee Policy ID |
tenant | string | Yes | Customer ID |
coverage_amount | integer | Yes | Monthly coverage amount |
currency | string | Yes | ISO 4217 currency code |
start_date | timestamp | Yes | Coverage start date |
end_date | timestamp | Yes | Coverage end date |
metadata | hash | No | Key-value pairs |
curl https://api.casapay.com/v1/guarantees \
-H "Authorization: Bearer sk_test_4eC39HqLyjWDarjtT1zdp7dc" \
-H "Content-Type: application/json" \
-d '{
"policy": "gpol_abc123",
"tenant": "cus_123456789",
"coverage_amount": 120000,
"currency": "eur",
"start_date": 1706140800,
"end_date": 1737676800
}'Retrieve, Update, List, Cancel#
GET /v1/guarantees/:id
POST /v1/guarantees/:id
GET /v1/guarantees
POST /v1/guarantees/:id/cancel