cURL
curl --request POST \ --url https://api.paytring.com/api/v1/currency/get \ --header 'Content-Type: application/json' \ --data '{ "key": "<string>", "hash": "<string>", "from": "<string>", "to": "<string>" }'
"{}"
{ "key": "string", // Merchant key "hash": "string", // Calculated hash for request validation "from": "string", // Base currency code "to": "string" // Target currency code }
{ "status": true, "conversion_rate": "number", // Conversion rate between the currencies "converted_amount": "number" // Converted amount }
{ "status": false, "error": { "message": "string", // Error message "code": 400 // Error code } }
Merchant key, available in dashboard profile section
to be calculated by key sort of all non-object key values of this request
base currency you want conversion to happen from
final currency you want conversion to happen to
200
The response is of type object.
object