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

# POST Place Order

```
POST https://api.swaycharts.io/dxsca-web/accounts/{account code}/orders
```

Places an order or a group of orders on an account

The API allows submitting a new order or a group of orders on an account. Users can always issue orders on their own accounts, but can only issue orders on behalf of other accounts if the corresponding permissions are configured.

The API is via `POST`, so it's not idempotent. To avoid issues with duplicate orders, a client is expected to submit a client-unique id of an order with the request. This id is used to track the order later on. [See client ids](/sway-charts-api-documentation/rest-api-specification/getting-started/data-types-and-formats.md).

```
// Request

Single Order Request or Order Group Request

Authorization header should be included in case of basic authentication
```

```
// Path Parameters

accountCode - unique code assigned to an account (URL-encoded, https://en.wikipedia.org/wiki/Percent-encoding). See account code
```

```
// Errors

Common errors

API is not permitted for the user or account with the given id doesn't exist or account with the given id is not accessible for the user

Status code: 404 Not Found
Error code: 2
Description: Entity not found at server
Order request or order group is not well-formed or is semantically incorrect (e.g. limit order doesn't have price or order group includes both OCO and Contingent fields)

Status code: 400 Bad Request
Error code: 33
Description: Incorrect request (<details about an error>)
Order didn't pass pre-issue checks

Status code: 409 Conflict
Error code: <various>
Description: <various>
Order with such a client order id already exists in the system

Status code: 409 Conflict
Error code: 100
Description: Order with this id already exists (<client order id>)
Client order id is invalid (see client ids)

Status code: 400 Bad Request
Error code: 101
Description: Client-originated identifier is not valid
```


---

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

```
GET https://sway-technologies.gitbook.io/sway-charts-api-documentation/rest-api-specification/trading/post-place-order.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.
