get https://api-approval.tingg.africa/api/v3/forex/payout/conversion/fetch
Query for a single rate by providing the base currency and the exchange currency
Steps
- Authenticate to retrieve the bearer token.
- Query for a single rate.
Live endpoint
Request
Headers
Authorization is required to access this API
| Key | Value Type | Description |
|---|---|---|
| Authorization | String | Bearer token generated for your user |
Request Parameters
The API will accept the below query parameters
| Key | Value Type | Required | Description |
|---|---|---|---|
baseCurrencyCode | String | No | 3 letter currency code indicating the base currency for the exchange rate |
exchangeCurrencyCode | String | Yes | 3 letter currency code indicating the exchange currency for the exchange rate |
Response
Response Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| message | Integer | Yes | Response description |
| success | boolean | Yes | Success status of the request |
| statusCode | Integer | Yes | Status of the response. |
| data | Object | Yes | Contains the rates details |
| statusDescription | String | No | Narration on status code. |
| baseCurrencyCode | String | No | The currency to convert from. Null when none was found. |
| exchangeCurrencyCode | String | No | The currency to convert to. Null when none was found. |
| buyRate | Float | No | The currency buy rate. Null when none was found. |
| sellRate | Float | No | The currency sell rate. Null when none was found. |
| conversionRateID | String | No | The primary key for the rate |
Sample Response
{
"message": "Conversion rate found.",
"success": true,
"statusCode": 508,
"data": {
"statusDescription": "Conversion rate found.",
"baseCurrencyCode": "USD",
"exchangeCurrencyCode": "KES",
"buyRate": 158.1,
"sellRate": 158.1,
"conversionRateID": "650"
}
}
