> For the complete documentation index, see [llms.txt](https://api-docs.vaultoro.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://api-docs.vaultoro.com/public/orders.md).

# Orders

## Get Orders

<mark style="color:blue;">`GET`</mark> `https://api.vaultoro.com/v1/public/orders`

This endpoint returns all the orders.

#### Query Parameters

| Name          | Type   | Description                                                            |
| ------------- | ------ | ---------------------------------------------------------------------- |
| until         | string | Unix timestamp to filter the results until.                            |
| since         | string | Unix timestamp to filter the results since.                            |
| sortDirection | string | Sort direction for the results. 1 for ascending and -1 for descending. |
| sort          | string | Sort the results by timestamp. Should be createdAt or updatedAt.       |
| limit         | number | Limit the number of results.                                           |
| page          | number | Return a specific page.                                                |
| type          | string | The type of order. Should be BUY or SELL.                              |
| status        | string | The status of the order. Can only be OPEN for the public endpoint.     |
| pair          | string | Filter by available pairs.                                             |
| matchType     | string | Filter the type of order. Currently only LIMIT.                        |

{% tabs %}
{% tab title="200 Cake successfully retrieved." %}

```
{
    "data": [
        {
            "createdAt": 1595357756,
            "initialQuantity": 1223,
            "matchType": "LIMIT",
            "pair": "GOLDBTC",
            "quantity": "1198.0000",
            "status": "OPEN",
            "type": "BUY",
            "updatedAt": 1595427428,
            "value": "0.00615450"
        }
    ],
    "pagination": {
        "count": 1
    }
}
```

{% endtab %}
{% endtabs %}

## Get Liquidity

<mark style="color:blue;">`GET`</mark> `https://api.vaultoro.com/v1/public/orders/liquidity`

Returns the current liquidity for a market. Will return FX data if you send in a currency handle.

#### Query Parameters

| Name      | Type   | Description                                                                    |
| --------- | ------ | ------------------------------------------------------------------------------ |
| until     | string | Unix timestamp to filter the results until.                                    |
| since     | string | Unix timestamp to filter the results since.                                    |
| type      | string | The type of order. Should be BUY or SELL.                                      |
| matchType | string | Filter the type of order. Currently only LIMIT.                                |
| fx        | string | Returns the FX data with the request. Must be EURCENT or CENT.                 |
| pair      | string | Enter the pair to filter by. Currently available: DASHBTC, GOLDBTC or GOLDDASH |

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

```
{
    "data": [
        {
            "count": 1,
            "currencyHandle": "EURCENT",
            "currencyValue": "6122",
            "matchType": "LIMIT",
            "pair": "GOLDBTC",
            "price": "0.00061545",
            "quantity": "12.0000",
            "sum": "12.0000",
            "total": "0.0074",
            "type": "BUY"
        },
        {
            "count": 1,
            "currencyHandle": "EURCENT",
            "currencyValue": "5127",
            "matchType": "LIMIT",
            "pair": "GOLDBTC",
            "price": "0.00051545",
            "quantity": "12.0000",
            "sum": "24.0000",
            "total": "0.0062",
            "type": "BUY"
        },
        {
            "count": 1,
            "currencyHandle": "EURCENT",
            "currencyValue": "52370",
            "matchType": "LIMIT",
            "pair": "GOLDBTC",
            "price": "0.00050545",
            "quantity": "125.0000",
            "sum": "149.0000",
            "total": "0.0632",
            "type": "BUY"
        },
        {
            "count": 1,
            "currencyHandle": "EURCENT",
            "currencyValue": "52267",
            "matchType": "LIMIT",
            "pair": "GOLDBTC",
            "price": "0.00050445",
            "quantity": "125.0000",
            "sum": "274.0000",
            "total": "0.0631",
            "type": "BUY"
        },
        {
            "count": 1,
            "currencyHandle": "EURCENT",
            "currencyValue": "5029",
            "matchType": "LIMIT",
            "pair": "GOLDBTC",
            "price": "0.00040445",
            "quantity": "15.0000",
            "sum": "289.0000",
            "total": "0.0061",
            "type": "BUY"
        }
    ]
}

```

{% endtab %}
{% endtabs %}
