Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Please note that this URL shall only be used for integration and testing procedures. Once the Payment Service Agreement is signed, you will receive the production environment's URL when you request your account to go live.

Request parameters:

Field

Description

Required

Length

secret

Secret phrase as defined in the PagBrasil Dashboard

Yes

128

pbtoken

Token assigned to your merchant account.
Your token is displayed at the PagBrasil Dashboard, menu Account > Settings.

Yes

32

order

Order number

Yes

64

amount_refunded

Amount requested to be refunded (Brazilian Real)

Yes

5.2

suspicious

Value "1" indicates that you are refunding the order because you suspect that it is a fraudulent order. That feeds our PagShield fraud prevention service database. Otherwise, set this parameter as "0" (or blank).

No

1

customer_bank

Only used when a refund is rejected. See note 6.2, item "c".

No

40

customer_branch

Only used when a refund is rejected. See note 6.2, item "c".

No

12

customer_account

Only used when a refund is rejected. See note 6.2, item "c".

No

12

Note: A successful response for the refund request will be "Refund request received".

...

You need to login to the PagBrasil Dashboard and specify the URL you want PagBrasil to notify you when the refund is processed.

PagBrasil's POST:

Field

Description

Length

secret

Secret phrase as defined in the PagBrasil Dashboard

128

payment_method

Value "C". This value specifies that the data being posted is the response to a credit card refund request.

1

order

Order number

64

amount_brl

Amount in Brazilian Real

5.2

amount_refunded

Amount refunded (Brazilian Real)

5.2

payment_status

C = Chargeback See note "a"   
P = Refund Processed See note "b"   
J = Refund rejected See note "c"   

1

signature

HMAC-MD5 hash that authenticates the IPN. See note "d"   

32

Notes:

Anchor
RefundA
RefundA
a) The payment status is returned as "C" (Chargeback) when a previously authorized transaction is reversed by the credit card issuer. In addition our system will send a chargeback notification to the e-mail address you registered at the PagBrasil Dashboard.

...

Anchor
RefundB
RefundB
b) The payment status is returned as "P" (Refund Processed) when the refund request was accepted by the credit card acquirer. The delay between the refund being accepted and the customer seeing the credit on their statement depends on the credit card issuer.

...

When a refund was processed via bank transfer, one of the parameters returned when requesting information about a specific order is refund_info (see item 5.2), which includes the contents for parameters customer_bank, customer_branch and customer_account, formatted in a way your operator may easily review such information. Please see the following example.

...