circle-info
Ask something in the search bar to get a quick answer from our AI model

API - Cancel Pix

This endpoint cancels a pending PIX payment transaction before it is paid by the customer. It invalidates the PIX code and prevents the payment from being completed. This is useful when a customer abandons a transaction or when the merchant needs to stop a payment request.

POST {BASE_URL}/payment/{id}/cancel

Headers

Header

Required

Description

Example

Authorization

Yes

Bearer token for authentication

Bearer...

x-api-key

Yes

API key for service access

xxxxxxxxxxxxxxxxxx

Path Parameters

Parameter

Required

Description

Example

id

Yes

The payment ID to cancel

53045136-25-0-Ma9WgEPnRCiJXIfbbjS1XwOh

Example Request

https://virtual-pos-dev.wipay.es/api/wipay-payment-admin/payment/53045136-25-0-Ma9WgEPnRCiJXIfbbjS1XwOh/cancel
  

Response

{
    "success": true,
    "result": {
        "id": "53045136-25-0-Ma9WgEPnRCiJXIfbbjS1XwOh",
        "merchantId": "53045136",
        "status": "CANCELLED"
    }
}

Response Fields

Field

Type

Description

success

boolean

Indicates if the cancellation was successful

result.id

string

The cancelled payment ID

result.merchantId

string

Merchant identifier

result.status

string

New transaction status (CANCELLED)

Last updated