---
title: "Close all positions"
method: DELETE
path: "/trade/accounts/{accountId}/positions"
tags: ["Trading"]
---

# Close all positions

`DELETE /trade/accounts/{accountId}/positions`

Place closing orders for all open positions. Isn't guaranteed to close all positions, or close them immediately. Will attempt to place an IOC, then GTC closing order, so the execution might be delayed.

## Path parameters

- `accountId` integer, required

## Query parameters

- `tradableInstrumentId` integer
- `strategyId` string

## Headers

- `accNum` integer, required
- `developer-api-key` string

## Response `200`

- PositionsResponse — Positions response
  - `d` Positions, required
    - `positions` array[]
      - string[]
  - `s` string, required — Status will always be `ok`.

## Other responses

- `401` — Unauthorized
- `403` — Forbidden
- `404` — Not Found

---

[API](https://skmtc.net/tradelocker/apis/trading-api.md) · [All operations](https://skmtc.net/tradelocker/apis/trading-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/tradelocker/trading-api/versions/5b184d9b617c/schema)
