# Post endpoints

### Place order

<pre><code><strong>POST /place_order
</strong></code></pre>

User must submit its [order](https://layer-akira.gitbook.io/layerakira-documentation/integration/trading/order) and signature of the order hash. The endpoint will process this[ ](https://layer-akira.gitbook.io/layerakira-documentation/integration/trading/order)and returns an associated hash.&#x20;

* Note: the "signature" is a result of signing the hash of the order message by the user's private key. The order message is a SNIP12-revision 0 typed offchain message

To receive updates on the order, users need to subscribe over [WebSockets](https://layer-akira.gitbook.io/layerakira-documentation/integration/endpoints/stream-subscriptions). In the case of an unsuccessful request, the error codes are returned ([see here](https://layer-akira.gitbook.io/layerakira-documentation/integration/endpoints/responses))

### Cancel single order offchain

<pre><code><strong>POST /cancel_order
</strong></code></pre>

#### Body json parameters:

* `maker`: trading account.
* `order_hash`: hash of the order to be cancelled
* `salt`: a random value used for ensuring the uniqueness of the cancel request
* `sign`: signature data that is required to authorise the cancellation
  * To sign a cancel request, you must first obtain the Pedersen hash of the typed message for the request and then sign it by  your signer private key

### Cancel all offchain

<pre><code><strong>POST /cancel_all_orders
</strong></code></pre>

Cancels all orders under a specified ticker hash

### Withdraw offchain

<pre><code><strong>POST /withdraw
</strong></code></pre>

Withdraws specified amount of tokens

### Cancel all onchain

<pre><code><strong>POST /increase_nonce
</strong></code></pre>

Cancels all orders onchain invalidating all orders with nonce less than the new one

For detailed description of endpoints please refer to the Swagger UI below

{% embed url="<https://layerakira.github.io/docs/>" %}
