Exchange Quote
Cross Border routes are not enabled by default. Before integrating, you must align with Marlim's Risk and Development teams.
Use this route to estimate, before creating the transaction, how much your customer will pay and how much you receive, in both exchange directions.
| currency | pay_currency | What the quote answers |
|---|---|---|
| USD | BRL | Price announced in dollars and customer paying in reais. This is the direction of the Cross Border transaction, made with a credit card. The net_value is how much will be charged from the customer. |
| BRL | USD | Price announced in reais and customer paying in dollars. The exchange block shows how much the customer pays and the costs applied. |
The pay_currency is always the other side of currency, and can be omitted.
The values returned by this route are an estimate. The exchange rate is only locked at the time of the transaction, and a few cents may vary between the preview and the charge.
When creating the transaction in dollars, send only amount and currency. The net_value is not accepted in that mode, since the amount in reais is calculated from the exchange rate at that moment.
Request Query Params
| Attribute | Type | Description |
|---|---|---|
| amount | int32 | Announced price, in cents, in the currency set by currency. E.g.: US$ 85.99 → 8599 |
| currency | string | Optional parameter that sets the currency of amount, that is, the currency of the announced price. Accepted values: BRL and USD.Default: BRL |
| pay_currency | string | Optional parameter that sets the currency the customer pays in. It is always the other side: BRL when currency is USD, and USD when it is BRL. |
Response
| Attribute | Type | Description |
|---|---|---|
| currency | string | Currency of the amount sent. |
| amount | int32 | The amount sent, in cents. |
| net_value | int32 | Estimate, always in cents of real, at the commercial rate and without exchange costs. When the price is announced in dollars, it is the conversion of that amount. When the price is already in reais, it is the amount you sent. |
The converted amount must be at least 50 USD. Below that, the route returns the same error as the transaction creation.
{
"currency": "USD",
"amount": 8599,
"net_value": 44739
}
Reading the example: the product announced at US$ 85.99 will be charged from the customer at around R$ 447.39.
{
"currency": "BRL",
"amount": 44700,
"net_value": 44700
}
Here the product announced at R$ 447.00 will be charged from the customer at around US$ 86.14.