# ChainHilt Hyperliquid Cancel Order Preview

> ChainHilt Hyperliquid Cancel Order Preview is a paid API for AI agents from chainhilt.ai, paid per call via x402, $0.001/call, status unknown (last checked 2026-11-16).

Generates the EIP-712 typed data payload that a user must sign to cancel an open Hyperliquid order by numeric order ID, without submitting the cancellation.

## Facts

- Endpoint: POST https://chainhilt.ai/api/v1/perp/hyperliquid/order/cancel/preview?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-16
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/chainhilt-hyperliquid-cancel-order-preview-76fd0ad4
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_2OYLHoUAGr93PPBOu0Pf1

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability chainhilt-hyperliquid-cancel-order-preview-76fd0ad4 -d '<json body>'
```

Example prompt: Show me the Hyperliquid cancel action I need to sign to cancel order 77738308 on my account 0xAbCd...1234 — just preview it, don't submit anything yet.

## When to prefer this

Use this endpoint when you need to safely inspect and verify the exact EIP-712 payload required to cancel a Hyperliquid order before the user signs it — especially in automated or agent-driven flows where confirming the action structure is critical before committing. Prefer this over directly calling the execute endpoint when user review, audit logging, or multi-step signing flows are required.

## Known failure modes

- Order ID not found or already cancelled — errors array populated, no action returned
- Invalid account or vault address format — input validation failure
- Order belongs to a different account — authorization mismatch error
- Nonce conflict or expiry issue — action may be rejected at submission time
- Network or Hyperliquid API unavailability — 5xx error or timeout

## How this service works

Preview the Hyperliquid cancel action the user must sign for an open numeric order ID. Errors: 400 invalid input or no matching open order, 502 provider failure; execution may return 422 exchange rejection. Treat spot and perp as one balance only when the account abstraction mode is "unifiedAccount".

## Output

Returns a structured action object containing the nonce, the Hyperliquid cancel action (with asset ID and order ID), the full EIP-712 typed data including domain and message fields, the target chainId (Arbitrum, 42161), the protocol identifier, and the submit path to use once the user has signed — along with any warnings or errors.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "fast": {
   "type": "boolean",
   "description": "true adds Hyperliquid's fast flag (f) to the cancel; otherwise it is omitted."
  },
  "nonce": {
   "type": "integer",
   "minimum": 0,
   "description": "Action nonce in milliseconds since the epoch; defaults to the current time."
  },
  "orderId": {
   "type": "integer",
   "minimum": 0,
   "description": "Numeric order ID (oid) of the open order."
  },
  "expiresAfter": {
   "type": "integer",
   "minimum": 0,
   "description": "Millisecond timestamp after which Hyperliquid rejects the action. Signed with the action."
  },
  "vaultAddress": {
   "type": "string",
   "pattern": "^0x[a-fA-F0-9]{40}$",
   "description": "Vault or subaccount to act for; omit to act for the signer. Signed with the action."
  },
  "accountAddress": {
   "type": "string",
   "pattern": "^0x[a-fA-F0-9]{40}$",
   "description": "Account that owns the open order; used to look up its asset ID."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "response": {
   "errors": [],
   "actions": [
    {
     "data": {
      "nonce": 1710000000000,
      "action": {
       "f": true,
       "type": "cancel",
       "cancels": [
        {
         "a": 0,
         "o": 77738308
        }
       ]
      },
      "typedData": {
       "types": {
        "Agent": [
         {
          "name": "source",
          "type": "string"
         },
         {
          "name": "connectionId",
          "type": "bytes32"
         }
        ],
        "EIP712Domain": [
         {
          "name": "name",
          "type": "string"
         },
         {
          "name": "version",
          "type": "string"
         },
         {
          "name": "chainId",
          "type": "uint256"
         },
         {
          "name": "verifyingContract",
          "type": "address"
         }
        ]
       },
       "domain": {
        "name": "Exchange",
        "chainId": 1337,
        "version": "1",
        "verifyingContract": "0x0000000000000000000000000000000000000000"
       },
       "message": {
        "source": "a",
        "connectionId": "0x77b75cb0a420adad7a889990c81470cb13ee6aad0c4b956dc4db3be805792961"
       },
       "primaryType": "Agent"
      }
     },
     "type": "signature",
     "chainId": 42161,
     "protocol": "hyperliquid",
     "submitPath": "/perp/hyperliquid/order/cancel/execute"
    }
   ],
   "warnings": []
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/chainhilt-hyperliquid-cancel-order-preview-76fd0ad4/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from chainhilt.ai](https://www.zero.xyz/host/chainhilt.ai/llms.txt)
