> For the complete documentation index, see [llms.txt](https://cubexch.gitbook.io/cube-api/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cubexch.gitbook.io/cube-api/order-entry/rest-api.md).

# REST API

The base URL for endpoints described in this page of live trading API is `https://api.cube.exchange/os/v0`.

Definitions for requests and responses can be found in the [Trade OpenAPI Document](https://github.com/cubexch/gitbook/blob/main/generated/core/os_api_30.json).

Further specifics for field enums, reject codes, etc. can be found in the [Trade API Websocket Documentation](/cube-api/order-entry/websocket-api.md).

### Endpoints, authentication required

Endpoints in this section require [Authentication headers](/cube-api/exchange-info.md#authentication-headers). Note that only API keys with access-level `WRITE` are able to access *any* of these endpoints.

{% openapi src="/files/ZSsp2n40LTbzuWhuWKdg" path="/orders" method="get" %}
[os\_api\_30.json](https://398371474-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FlfNM0vNrk7VPr5UKauIS%2Fuploads%2Fgit-blob-115bbedbee1ed9d8b9c5c7bee0d4057fffbba4c6%2Fos_api_30.json?alt=media)
{% endopenapi %}

{% openapi src="/files/ZSsp2n40LTbzuWhuWKdg" path="/orders" method="delete" %}
[os\_api\_30.json](https://398371474-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FlfNM0vNrk7VPr5UKauIS%2Fuploads%2Fgit-blob-115bbedbee1ed9d8b9c5c7bee0d4057fffbba4c6%2Fos_api_30.json?alt=media)
{% endopenapi %}

{% openapi src="/files/ZSsp2n40LTbzuWhuWKdg" path="/order" method="post" %}
[os\_api\_30.json](https://398371474-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FlfNM0vNrk7VPr5UKauIS%2Fuploads%2Fgit-blob-115bbedbee1ed9d8b9c5c7bee0d4057fffbba4c6%2Fos_api_30.json?alt=media)
{% endopenapi %}

{% openapi src="/files/ZSsp2n40LTbzuWhuWKdg" path="/order" method="delete" %}
[os\_api\_30.json](https://398371474-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FlfNM0vNrk7VPr5UKauIS%2Fuploads%2Fgit-blob-115bbedbee1ed9d8b9c5c7bee0d4057fffbba4c6%2Fos_api_30.json?alt=media)
{% endopenapi %}

{% openapi src="/files/ZSsp2n40LTbzuWhuWKdg" path="/order" method="patch" %}
[os\_api\_30.json](https://398371474-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FlfNM0vNrk7VPr5UKauIS%2Fuploads%2Fgit-blob-115bbedbee1ed9d8b9c5c7bee0d4057fffbba4c6%2Fos_api_30.json?alt=media)
{% endopenapi %}

{% openapi src="/files/ZSsp2n40LTbzuWhuWKdg" path="/positions" method="get" %}
[os\_api\_30.json](https://398371474-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FlfNM0vNrk7VPr5UKauIS%2Fuploads%2Fgit-blob-115bbedbee1ed9d8b9c5c7bee0d4057fffbba4c6%2Fos_api_30.json?alt=media)
{% endopenapi %}
