---
updatedAt: 2026-04-23T13:45:10.000Z
agentTools:
  projectIndex: https://docs.br-dge.io/llms.txt
---

# Cancel a previously created BR-DGE Hosted Payment Page Order.

# OpenAPI definition

```json
{
  "openapi": "3.0.3",
  "info": {
    "title": "BR-DGE Transaction REST API",
    "description": "Use the BR-DGE Transaction REST API to manage and process transactions within BR-DGE. With these endpoints, you can create, retrieve, update and delete transactions securely and efficiently. These unlock access to various third-party payment services such as Payment Service Providers (PSPs), Digital Wallets and Alternative Payment Methods (APMs).\n\nPlease see our [Web SDK documentation] for more information about how we can help you integrate your client applications with us.\n## Authorization\nAPI keys can be generated via the BR-DGE portal and are grouped into two main classes based on their usage:\n- Server API keys for use by you in your secure back-end services, *and must not be exposed to your end users.*\n- Separate Client API keys will be provided for use in client applications to support certain features that need to\n  happen in untrusted client environments.\n\n## Environment Sub Domains\nThe BR-DGE REST API is hosted on a selection of subdomains. Use <https://sandbox.comcarde.com> for testing and either <https://secure.comcarde.com> or <https://secure-amer-01.api.br-dge.io> for live payments depending on your operational region.\n\n**IMPORTANT**: To ensure [PCI Compliance], please only use mock payment instrument data when interacting with our Sandbox API.\n\n[PCI Compliance]: https://www.pcisecuritystandards.org/\n[Web SDK documentation]: https://docs.br-dge.io/docs/web-sdk-introduction\n",
    "version": "v1.0.0",
    "contact": {
      "name": "Customer Support",
      "url": "https://docs.br-dge.io/docs/support#contact-support"
    },
    "license": {
      "name": "MIT",
      "url": "https://docs.br-dge.io/docs/openapi-license"
    }
  },
  "servers": [
    {
      "url": "https://sandbox.comcarde.com/v1",
      "description": "Sandbox subdomain for testing your integration works as expected, using mock payment instruments only.\n"
    },
    {
      "url": "https://secure.comcarde.com/v1",
      "description": "Use this subdomain for processing live payments in the EU region."
    },
    {
      "url": "https://secure-amer-01.api.br-dge.io/v1",
      "description": "Use this subdomain for processing live payments in the NA region."
    }
  ],
  "tags": [
    {
      "name": "Orders",
      "description": "Create and manage orders for the BR-DGE Hosted Payment Page"
    }
  ],
  "externalDocs": {
    "url": "https://docs.br-dge.io"
  },
  "paths": {
    "/orders/{orderId}/cancel": {
      "put": {
        "tags": [
          "Orders"
        ],
        "summary": "Cancel a previously created BR-DGE Hosted Payment Page Order.",
        "operationId": "cancelOrderUsingPUT",
        "security": [
          {
            "ServerApiKey": []
          }
        ],
        "parameters": [
          {
            "$ref": "#/components/parameters/pathOrderId"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrderResponse"
                },
                "examples": {
                  "Order cancelled": {
                    "description": "Order has been cancelled, and no further payment attempts can be made\n",
                    "value": {
                      "code": "1009",
                      "message": "Order cancelled - no future actions possible with this order"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/UnauthorizedRequest"
          },
          "403": {
            "description": "Forbidden request"
          },
          "404": {
            "$ref": "#/components/responses/EntityNotFound"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "OrderResponse": {
        "title": "OrderResponse",
        "type": "object",
        "properties": {
          "code": {
            "description": "A unique identifier covering the outcome of the request",
            "type": "string",
            "example": "1000"
          },
          "id": {
            "description": "The ID of this request",
            "type": "string",
            "example": "4fad8e2e06a15656"
          },
          "message": {
            "description": "A description of the outcome of the request",
            "type": "string"
          },
          "orderId": {
            "description": "The ID of this order",
            "type": "string"
          },
          "redirectUrl": {
            "description": "The URL to redirect your customer to in progress the order",
            "type": "string"
          }
        }
      },
      "ComcardeResponse": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "description": "[Response Code](https://docs.br-dge.io/docs/response-codes) signifying the outcome of the request.",
            "example": "1000"
          },
          "message": {
            "type": "string",
            "description": "A description of the outcome of the request."
          },
          "id": {
            "type": "string",
            "description": "The ID of this request. If you can include these when querying the outcome of individual requests, we can track down the root cause faster.\n",
            "example": "463ac35c9f6413ad48485a3953bb6124"
          }
        }
      },
      "ErrorResponse": {
        "allOf": [
          {
            "$ref": "#/components/schemas/ComcardeResponse"
          },
          {
            "type": "object",
            "properties": {
              "validationErrors": {
                "type": "object",
                "additionalProperties": {
                  "type": "string"
                },
                "description": "An object that contains validation errors."
              }
            }
          }
        ]
      }
    },
    "parameters": {
      "pathOrderId": {
        "name": "orderId",
        "in": "path",
        "description": "The unique identifier for the Order.\n\nThis can be sourced from the `orderId` field in the response we sent to you when creating the Order.\n",
        "required": true,
        "schema": {
          "type": "string"
        }
      }
    },
    "securitySchemes": {
      "ServerApiKey": {
        "type": "http",
        "scheme": "bearer",
        "description": "Operations intended for use by Merchant servers.\n\n**IMPORTANT** This key allows you to perform sensitive operations such as authorizing payments and refunds.\n\n**Production Server API keys must not be accessible outside your organization.**\n"
      }
    },
    "examples": {
      "entity-not-found": {
        "summary": "Entity Not Found Error",
        "description": "This example shows the [4040 error code].\nThis occurs when an entity was not found for a given ID, the entity should be clear from context.\nA full list of possible response codes is available [here].\n\n[4040 error code]: https://docs.br-dge.io/docs/response-codes#4040\n[here]: https://docs.br-dge.io/docs/response-codes\n",
        "value": {
          "code": "4040",
          "message": "Entity not found",
          "id": "4fad8e2e06a15656"
        }
      }
    },
    "responses": {
      "UnauthorizedRequest": {
        "description": "Unauthorized request."
      },
      "EntityNotFound": {
        "description": "The specified entity was not found.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorResponse"
            },
            "examples": {
              "entity-not-found": {
                "$ref": "#/components/examples/entity-not-found"
              }
            }
          }
        }
      }
    }
  }
}
```