Rental errors and responses
Check status and msg without changing the documented HTTP codes.
HTTP and application status are separate
Rental methods document HTTP 200 responses. A body with status=0 is still a failure. status=1 means success. Read msg when present; do not require Activation V2 fields such as statusCode or error.type.
{
"status": 0,
"msg": "Incorrect order id"
}This is an error you can receive from restore_user. Its method page shows both success and error responses, so check which one you received before reading the restored order ID.
Waiting and empty message lists
Activation V2's 202 / SMS_NOT_YET_RECEIVED handling does not apply to Rental. A successful sms response can contain an empty SmsList or OtherSms. Check order activation state and rental expiry through orders when deciding whether to wait.
Transport failures
A timeout, connection failure, empty HTTP body or non-JSON response does not provide a usable success result. Stop the one-shot example and decide how to recover. In particular, the source notes that get_min_paypal_days may return an empty body when country or service is missing; supply its required parameters.
If a request to create or change a rental times out, check your orders and history before trying again: it may already have completed. A GET request can also create a paid order, and the examples do not add duplicate-request protection.
Preserve the source error messages
The Restore Rental examples include Incorrect order id, Order not found, NOBALANCE_12.50, and The number is busy, there is already an order for this service. These are examples of messages you may receive; other methods can return different messages.
Use the HTTP method and response codes shown on the method page.