Skip to main content

Cancel QR code

Cancel a QR code generated for point-of-sale transactions.

This unified endpoint acts as an orchestrator that automatically determines the correct cancellation route based on the QR type. The service identifies whether the QR is an external payment QR (PIX, BANCARD, DEPAY) or a Ueno/Internal QR, and handles the cancellation accordingly.

QR Type Identification

The service automatically identifies the QR type based on the QR ID:

  • External QR: QR codes associated with external payment connectors (PIX, BANCARD, DEPAY)
  • Ueno/Internal QR: QR codes generated internally by Geopagos

Cancellation Logic

External QR Codes

For external QR codes, the cancellation process follows these steps:

  1. The service identifies the external connector (PIX, BANCARD, or DEPAY)
  2. It invokes the cancellation endpoint of the corresponding connector.
  3. If the external cancellation is successful, the service proceeds to cancel the internal Payment Intent
  4. If the external cancellation fails, the Payment Intent is NOT cancelled, and an error response is returned

Ueno/Internal QR Codes

For Ueno/Internal QR codes:

  1. The service directly invokes the internal Payment Intent cancellation
  2. No external connector communication is required

Error Handling

If the cancellation fails at any step:

  • For external QR codes: If the external connector cancellation fails, the entire operation fails and the Payment Intent remains active
  • For internal QR codes: The error is returned directly to the caller
  • The service returns a standardized error response indicating the failure reason

The cancellation process ensures data consistency by handling both external connector cancellation and internal Payment Intent cancellation in the correct order.

Path Parameters
point_of_sale_id uuid REQUIRED

The point of sale identifier associated with the QR code

qr_id uuid REQUIRED

The unique identifier of the QR code to cancel

Responses
204

QR code cancelled successfully

400

Error response

Schema OPTIONAL
app_name string OPTIONAL
app_version string OPTIONAL
status_code number OPTIONAL
message string OPTIONAL
message_code string OPTIONAL
error_code string OPTIONAL
validations object[] OPTIONAL
property_name string OPTIONAL
error_message string OPTIONAL
error_code string OPTIONAL
attempted_value string OPTIONAL
404

QR code not found

500

Internal server error or external connector failure