Exit Position by ID
This API allows you to exit specific open positions using their position IDs.
USE CASE
Close one or a few positions while leaving the rest untouched.
Details
idtakes one position id, for exampleNSE:SBIN-EQ-MARGIN, or a list such as["NSE:SBIN-EQ-INTRADAY","NSE:SBIN-EQ-CNC"].- Only the open positions for the ids you pass are exited. Other positions are not affected.
- A position id is the symbol plus the product type, so the same stock held under two product types has two ids. Get them from Get Positions.
- This uses the same
DELETE /api/v3/positionsendpoint as Exit Position. Ifidis left out, all open positions are closed. - Rate limits differ between the Standard and Prime plans. See Plans & rate limits.
Request Attributes
| Attribute | Data Type | Description |
|---|---|---|
id | string or [string] |
|
Response Attributes
| Attribute | Data Type | Description |
|---|---|---|
s | string | Request status, e.g. ok on success. |
code | int | Response status code (e.g. 200 on success). |
message | string | Human-readable message describing the outcome, e.g. "The position is closed." |
Last updated on