Rental API
SMSPVA / DOCUMENTATION
Canada PayPal days
GET /api/rent.php?method=get_days_canada_paypal
SMSPVA API
Send a GET request and check status in the JSON response: 1 means success and 0 means failure, even with HTTP 200. If it fails, read msg for the reason.
Authentication
You can call this method without an API key.
Parameters
| Name | Location | Type | Required | Example | Description |
|---|---|---|---|---|---|
method | query | string | Yes | "get_days_canada_paypal" | Method name |
How to use this method
Get the rental-day options for the Canada PayPal flow.
Request examples
Environment and dependencies. Each example encodes query values and allows 30 seconds for the request. Check HTTP and JSON status before using data. cURL prints the response for you to check; Java uses Jackson to read the JSON.
curl --get --fail-with-body --max-time 30 "https://smspva.com/api/rent.php" \
--data-urlencode "method=get_days_canada_paypal"Responses
Check the response that matches your request. Example values and dates are illustrative. Optional fields can depend on the outcome or the response format you selected.
HTTP 200
Success
application/json
Illustrative response
{
"status": 1,
"data": [
{
"Days": 30,
"Amount": 10
}
]
}| Name | Type | Description |
|---|---|---|
status | integer | Status of the response: 1 for success, 0 for failure |
data | array<object> | Rental period entries returned by the Canada PayPal flow. |
data[].Days | integer | Rental period in days. |
data[].Amount | integer | Amount associated with the rental period, as returned by the API. |
msg | string | Error message when status is 0. |