curl --request POST \
--url https://app.amplopay.com/api/v1/gateway/producer/refunds \
--header 'Content-Type: application/json' \
--header 'x-public-key: SUA_CHAVE_PUBLICA_AQUI' \
--header 'x-secret-key: SUA_CHAVE_PRIVADA_AQUI' \
--data '{
"transactionId": "cmry2h8332sgs3ub44fh7",
"reason": "Cliente solicitou cancelamento",
"description": "Solicitacao recebida pelo atendimento."
}'
{
"id": "cmrefund123",
"transactionId": "cmry2h8332sgs3ub44fh7",
"producerId": "cmproducer123",
"status": "PENDING",
"amount": 49.8,
"reason": "Cliente solicitou cancelamento",
"description": "Solicitacao recebida pelo atendimento."
}
Endpoints
Request refund
Request a refund for a producer transaction
POST
/
gateway
/
producer
/
refunds
curl --request POST \
--url https://app.amplopay.com/api/v1/gateway/producer/refunds \
--header 'Content-Type: application/json' \
--header 'x-public-key: SUA_CHAVE_PUBLICA_AQUI' \
--header 'x-secret-key: SUA_CHAVE_PRIVADA_AQUI' \
--data '{
"transactionId": "cmry2h8332sgs3ub44fh7",
"reason": "Cliente solicitou cancelamento",
"description": "Solicitacao recebida pelo atendimento."
}'
{
"id": "cmrefund123",
"transactionId": "cmry2h8332sgs3ub44fh7",
"producerId": "cmproducer123",
"status": "PENDING",
"amount": 49.8,
"reason": "Cliente solicitou cancelamento",
"description": "Solicitacao recebida pelo atendimento."
}
Requests a refund for a transaction owned by the authenticated producer.
Body parameters
string
required
ID of the transaction to refund.
string
required
Reason for the refund request.
string
Optional description with additional details.
Request example
curl --request POST \
--url https://app.amplopay.com/api/v1/gateway/producer/refunds \
--header 'Content-Type: application/json' \
--header 'x-public-key: SUA_CHAVE_PUBLICA_AQUI' \
--header 'x-secret-key: SUA_CHAVE_PRIVADA_AQUI' \
--data '{
"transactionId": "cmry2h8332sgs3ub44fh7",
"reason": "Cliente solicitou cancelamento",
"description": "Solicitacao recebida pelo atendimento."
}'
Response
string
required
Created refund request ID.
string
required
Transaction ID linked to the refund.
string
required
ID of the producer that owns the transaction.
string
required
Current refund request status.
number
required
Requested refund amount.
string
required
Reason provided in the request.
string
Additional description provided in the request.
{
"id": "cmrefund123",
"transactionId": "cmry2h8332sgs3ub44fh7",
"producerId": "cmproducer123",
"status": "PENDING",
"amount": 49.8,
"reason": "Cliente solicitou cancelamento",
"description": "Solicitacao recebida pelo atendimento."
}
Error responses
This endpoint can return400 Bad Request, 401 Unauthorized, 404 Not Found, and 422 Unprocessable Entity with the default API error shape.
{
"statusCode": 422,
"errorCode": "GATEWAY_INVALID_ARGUMENT",
"message": "Ja existe uma solicitacao de reembolso para esta transacao"
}
Was this page helpful?

