---
title: "❌ Cancel Specific Order"
description: >-
  Cancel a specific order by its order ID using the Forkast SDK with TypeScript
  examples, required parameters, and authentication details.
---

> **For AI agents:** the complete documentation index is at [llms.txt](/llms.txt). Append `.md` to any page URL for its markdown version.

Cancels a single existing order by its order ID.

```typescript
import { ForkastSDK, Network } from "@forkastgg/client";

const sdk = new ForkastSDK(Network.TESTNET, "YOUR_API_KEY");
const accountService = sdk.getAccountService();
const orderService = sdk.getOrderService();

const { accessToken } = await accountService.loginWithPrivateKey(
  "YOUR_PRIVATE_KEY"
);

const result = await orderService.cancelOrder("ORDER_ID", accessToken);
```

**Parameters**

| **Field** | **Type** | **Required** | **Description** |
| ------------- | -------- | ------------ | ----------------------------------------- |
| `orderId`     | string   | Yes          | Order Id from order response              |
| `accessToken` | string   | Yes          | Access Token received from login response |
