# liquidationTrade

**POST api/liquidationTrade**

{% tabs %}
{% tab title="Payload" %}

```json
{
    "counterpartyId": 25,
    "instrument": "BTC-USD",
    "clientOrderId": 123456789,
    "price": 999900000000,
    "size": 10000000,
    "side": "bid",
}
```

{% endtab %}

{% tab title="200 OK" %}

```json
{
    "id": 1245,
    "clientOrderId": 123456789,
    "deal": [
        {
            "counterpartyId": 42,
            "id": 23,
            "price": 999900000000,
            "size": 2000000,
            "volume": 19998000000,
            "delta": 0
        }
    ]
}
```

{% endtab %}

{% tab title="400 Bad request" %}

```json
{
    "error": 2
}
```

{% endtab %}
{% endtabs %}

**Request parameters**

| Field name     | Type               | Description                                       |
| -------------- | ------------------ | ------------------------------------------------- |
| counterpartyId | Efx::ClientId      | Counterparty ID to trade with.                    |
| instrument     | string             | Instrument name                                   |
| clientOrderId  | Efx::ClientOrderId | *Optional.* User data attached to the order       |
| price          | Efx::Price         | Deal price.                                       |
| size           | Efx::Size          | Deal size.                                        |
| side           | string             | Deal side, use `"bid"` to buy and `"ask"` to sell |

**Response description**

| Filed name     | Type               | Description                              |
| -------------- | ------------------ | ---------------------------------------- |
| id             | Efx:OrderId        | New Order Id                             |
| clientOrderId  | Efx::ClientOrderId | Optional user data attached to the order |
| deal           | Deal               | Resulted deal.                           |
| **Deal**       |                    |                                          |
| id             | Efx::DealId        | Deal Id                                  |
| price          | Efx::Price         | Deal price                               |
| size           | Efx::Size          | Deal size                                |
| volume         | Efx::Size          | Deal volume                              |
| delta          | Efx::Size          | Deal delta in quote (balance) currency   |
| counterpartyId | unsigned int64     | Counterparty id                          |

{% hint style="info" %}
The operation produces a deal in feeds 'P' and 'O'.
{% endhint %}


---

# Agent Instructions: 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:

```
GET https://faq.finerymarkets.com/api-reference/rest-api/trading/adding-orders/liquidationtrade.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
