Get countries
Returns the countries where your account can collect deposits in the current environment, optionally filtered by country or payment type. It is usually the first call of the integration flow.
GET
/api/v1/pay-in/deposit-creation/countries| Authentication | HTTP Basic (api_key:api_secret) |
| Moves money | No |
Query parameters
All optional.
| Parameter | Type | Description |
|---|---|---|
countries[] | array of strings | Only these countries. 3-letter ISO codes (MEX, CHL…). Up to 300 items. |
payment_types[] | array of strings | Only countries that offer these payment types (for example BANK_TRANSFER, CREDIT_CARD, VOUCHER, MOBILE_MONEY). Up to 50 items. Allowed values come from the live catalog. |
Request
curl -G https://sandbox-api.cashela.com/api/v1/pay-in/deposit-creation/countries \ -u "$CASHELA_API_KEY:$CASHELA_API_SECRET" \ -H "Accept: application/json" \ --data-urlencode "countries[]=MEX" \ --data-urlencode "payment_types[]=BANK_TRANSFER"Response 200
{ "success": true, "data": [ { "id": 142, "name": "Mexico", "iso_b": "MEX" } ], "message": "Countries retrieved successfully."}| Field | Description |
|---|---|
data[].id | Cashela’s country id. |
data[].name | Country name. |
data[].iso_b | 3-letter ISO code. Send it as country in the other Pay-In endpoints. |
Errors
| HTTP | When |
|---|---|
401 | Credentials missing or invalid. See Authentication. |
404 | No country matches your filters for your account (code: PARTNER_PAYIN_CATALOG_EMPTY). |
422 | A filter is malformed, for example countries sent as a string instead of an array ("The countries must be an array."), or a code longer than 3 letters. |
429 | Too many requests. Respect Retry-After. |
See Errors for the full list.