> For the complete documentation index, see [llms.txt](https://docs.fonbnk.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.fonbnk.com/server-to-server/api-endpoints/merchant-balance/cancel-crypto-deposit.md).

# Cancel crypto deposit

## <mark style="color:$warning;">\[POST]</mark> /api/v2/merchant-balance/deposit/cancel

Cancels a deposit you created but have not paid for yet.

This is valid only while the order is still `deposit_awaiting`.

No crypto must have been observed on-chain.

Request body type:

{% code overflow="wrap" expandable="true" %}

```typescript
type RequestBody = {
  orderId: string;   // the deposit order id
}
```

{% endcode %}

Request body example:

{% code overflow="wrap" expandable="true" %}

```json
{
  "orderId": "69281d944a1db009177f0198"
}
```

{% endcode %}

Response type:

{% code overflow="wrap" expandable="true" %}

```typescript
type Response = {
  orderId: string;
  status: OrderStatus;       // "deposit_canceled" after cancel
  network: string;
  asset: string;
  currencyCode: string;
  address: string;
  amount: number;
  expiresAt: Date;
  createdAt: Date;
  updatedAt: Date;
}
```

{% endcode %}

Response example:

{% code overflow="wrap" expandable="true" %}

```json
{
  "orderId": "69281d944a1db009177f0198",
  "status": "deposit_canceled",
  "network": "POLYGON",
  "asset": "USDC",
  "currencyCode": "POLYGON_USDC",
  "address": "0x5b7ae3c6c87f4a3f94b35c77233b13191ebfad20",
  "amount": 100,
  "expiresAt": "2025-11-27T10:29:56.167Z",
  "createdAt": "2025-11-27T09:29:56.167Z",
  "updatedAt": "2025-11-27T09:35:00.000Z"
}
```

{% endcode %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.fonbnk.com/server-to-server/api-endpoints/merchant-balance/cancel-crypto-deposit.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
