Rentals
List your rentals
GET/v1/rentals
REQUEST
QUERY PARAMETERS
| Name | Type | Required | Description |
|---|---|---|---|
| status | string | Optional | Comma-separated filter: active, expired, refunded, force_released (also payment_pending for rentals created in the dashboard). |
| limit | integer | Optional | — |
| offset | integer | Optional | — |
curl "https://api.dogesms.com/v1/rentals?status=active" \ -H "Authorization: Bearer sk_live_…"
RESPONSE
Rentals, newest first.
{
data: {
items: [{
id: string
status: enum
Rentals created through the API never auto-renew, so
payment_pending only appears on rentals created in the dashboard.Allowed: active | payment_pending | expired | refunded | force_released
phone_number: string
E.164 with the leading
+. Present in every status, including after the rental ended.country_code: string
service_code: stringnull
null = rented for any service.duration_days: integer
tier: enum
Quality tier of the plan this rental was created from.
Allowed: standard | premium
price_cents: integer
Charged for the period at creation.
currency: string
auto_renew: boolean
Always
false for rentals created through the API.started_at: string
expires_at: string
The number is yours until this moment.
released_at: stringnull
Set once the rental has ended.
created_at: string
}]
total: integer
limit: integer
offset: integer
}
request_id: string
}
ERROR CODES
| Status | Code | When |
|---|---|---|
| 400 | VALIDATION_ERROR | VALIDATION_ERROR — unknown status value. |
| 401 | API_KEY_MISSING API_KEY_INVALID_FORMAT API_KEY_INVALID API_KEY_REVOKED | Missing or invalid API key (API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED). Emitted by the auth layer before the handler — flat shape, no request_id. |
| 403 | ACCOUNT_BANNED EMAIL_NOT_VERIFIED ACCOUNT_NOT_ACTIVE | Key is valid but the account is not eligible (ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE). Emitted by the auth layer — flat shape. |
Branch on code, not on the message. Full list: Errors.