Settlement Simulator
API data
API Gateway
This API is used for payment gateway operations:
- Production: https://api.sopague.com.br/gateway
- Sandbox: https://api-hmg.sopague.com.br/gateway
- Architecture: Representational State Transfer (REST)
Introduction
This endpoint allows you to calculate the gross amount to charge (across different installment options) to receive a specific net amount.
For this endpoint, the amount you send must be decimal, and the response also contains decimals. This differs from the payment and cancellation endpoints, where amounts are sent in cents (integer).
Run settlement simulation
GET /v1/payments-simulator?Brand=visa&netValue=1000
Via REST request.
Data dictionary - Parameters
| PROPERTY | DESCRIPTION | TYPE | LOCATION | REQUIRED |
|---|---|---|---|---|
| Brand | Card brand. | string | query | yes |
| netValue | Net amount you want to receive. | decimal | query | yes |
- 🟢 200
- 🔴 400
- 🔴 500
Simulation completed successfully
{
"installments": [
{
"installment": 1,
"amount": 1035.24
},
{
"installment": 2,
"amount": 1046.98
},
{
"installment": 3,
"amount": 1052.82
},
{
"installment": 4,
"amount": 1058.72
},
{
"installment": 5,
"amount": 1064.68
},
{
"installment": 6,
"amount": 1070.71
},
{
"installment": 7,
"amount": 1083.51
},
{
"installment": 8,
"amount": 1089.72
},
{
"installment": 9,
"amount": 1096.00
},
{
"installment": 10,
"amount": 1102.36
},
{
"installment": 11,
"amount": 1108.78
},
{
"installment": 12,
"amount": 1115.29
}
]
}
Data dictionary - Response
| PROPERTY | DESCRIPTION | TYPE |
|---|---|---|
| installments[].installment | Installment number. | integer |
| installments[].amount | Amount to charge for that installment option. | decimal |
Request error
[
{
"tag": "",
"description": "Bandeira não identificada"
}
]
Data dictionary - Response
| PROPERTY | DESCRIPTION | TYPE |
|---|---|---|
| tag | Error tag | string |
| description | Error description | string |
Internal error
[
{
"tag": "",
"description": "Não foi possível executar comando. Erro desconhecido."
}
]
Data dictionary - Response
| PROPERTY | DESCRIPTION | TYPE |
|---|---|---|
| tag | Error tag | string |
| description | Error description | string |