# Query Exchange Rate API (Common)

## :white\_check\_mark: **Query Exchange Rate API**

:ballot\_box\_with\_check: **Request Message Parameters**

| **Params Name** | **Description** | **Required** | **Notes**             |
| --------------- | --------------- | ------------ | --------------------- |
| action          | Action name     | Y            | EX\_RATE\_QUERY       |
| version         | Version number  | Y            | 1.0                   |
| merchant\_id    | Merchant ID     | Y            |                       |
| data            | encrypted data  | Y            | Refer to "Data" below |
| md5             | Message digest  | Y            |                       |

#### :white\_check\_mark: Dat&#x61;**(JSON Data, to be encrypted):**

| Params Name |  Description  | Required |              Notes             |
| :---------: | :-----------: | :------: | :----------------------------: |
|  fee\_type  | Currency type |     Y    | According to ISO-4217 standard |

:ballot\_box\_with\_check: **Response Message Parameters**

| **Params Name** | **Description**  | **Required** | **Notes**             |
| --------------- | ---------------- | ------------ | --------------------- |
| rsp\_code       | Response code    | Y            | Refer to Appendix B   |
| rsp\_msg        | Response message | Y            |                       |
| data            | encrypted data   | Y            | Refer to "Data" below |
| md5             | Message digest   | Y            |                       |

#### :white\_check\_mark: Dat&#x61;**(JSON Data, to be encrypted):**

| Params Name |      Description     | Required |                       Notes                       |
| :---------: | :------------------: | :------: | :-----------------------------------------------: |
|   feeType   |     Currency type    |     Y    |           According to ISO-4217 standard          |
|     rate    | Exchange rate to CNY |     Y    | If rate = 6.5，number is 650000000, ten power of 8 |
|   rateTime  |   rate setting time  |     Y    |                 string, timestamp                 |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.ottpay.com/payment-api/query-exchange-rate-api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
