v1

latestOpenAPI 3.1.02026-07-24102785.8 KB
Refund API

Refund a Transaction

Requests a refund for a transaction processed by PagSeguro. Refunds can be requested for the full transaction amount or a partial amount. Requires Basic Authentication.

post/v3/transactions/{code}/refunds

Path parameters

codestring uuid required

Unique transaction identifier (UUID) received upon transaction creation. This code must have exactly 36 characters.

Request body

notification_urlstring url required

URL where PagSeguro will send status update notifications regarding the refund request.

amountnumber float

Amount to be refunded. If not provided, the full transaction amount will be refunded. The maximum value aceppted is equal to the transaction amount.

referencestring

Unique refund reference assigned by the merchant for tracking purposes.

Response

Refund request created successfully.

idinteger

Unique identifier of the refund request.

referencestring

Refund reference assigned by the merchant. Can be used for tracking purposes.

amountnumber float

Amount approved for refund. If a partial refund is processed, this field will reflect the refunded amount.

statusstring

Current status of the refund request. Possible values: - REQUESTED: Refund has been requested. - PROCESSING: Refund is being processed. - PROCESSED: Refund has been successfully completed. - REJECTED: Refund request was denied.

created_atstring date-time

Date and time when the refund request was created (UTC format).

updated_atstring date-time

Date and time when the refund request was last updated (UTC format).