---
title: "Cancel Order"
method: POST
path: "/v0/orders/cancel/build"
tags: ["Trading"]
---

# Cancel Order

`POST /v0/orders/cancel/build`

Start a cancel on an existing open order. Returns the cancel payload for the wallet to sign — you then submit the signature to `POST /v0/orders/cancel`.

The SDK's `cancelOrder()` chains both steps. Call this endpoint directly only if you need to show the cancel to a user before signing.

## Request body

- CancelBuildHostedRequest
  - `order_id` string, required — Unified order id, as returned by `fetchOpenOrdersHosted`.
  - `user_address` string, required — EVM wallet address that owns the resting order and will sign the cancel typed data.

## Response `200`

Cancel build response.

- CancelBuildHostedResponse
  - `cancel_id` string, required — Opaque server-side key for this cancel build. Pass it to `POST /v0/orders/cancel` with the EIP-712 signature(s) before `deadline`.
  - `typed_data` object, required — EIP-712 typed-data payload to sign locally with the wallet key matching `user_address`. Return the signature when submitting the cancel.
  - `pull_typed_data` object, nullable — Optional secondary EIP-712 payload for venues that require a pull-authorization cancel (Polymarket neg-risk markets). Sign with the same wallet and return as `pull_signature`. `null` when not required.
  - `deadline` integer, required — Unix epoch (s) after which the cancel build expires. Submit the signed cancel before this time or call `cancelOrderHosted` again.

## Other responses

- `401` — Invalid or missing PMXT API key.
- `404` — Order not found.
- `422` — Invalid order ID.

---

[API](https://skmtc.net/pmxt-dev/apis/pmxt-hosted-router-api.md) · [All operations](https://skmtc.net/pmxt-dev/apis/pmxt-hosted-router-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/pmxt-dev/pmxt-hosted-router-api/versions/9ee3cbe2dc87/schema)
