Position Conversion Inquiry
This API retrieves the actual OMS status of a position conversion request submitted via the Position Conversion API.
Prerequisite: You must first call the Position Conversion API to initiate a conversion and obtain an
orderId. ThatorderIdis the required input for this API.
🔍Query Parameters
| Field | Type | Required | Description | Example/ENUM |
|---|---|---|---|---|
| orderID | string | Yes | The orderId returned in the data object of the Position Conversion API response | "PCV1234567" |
🔑Header Parameters
| Header | Type | Required | Description | Example/ENUM |
|---|---|---|---|---|
| Content-Type | string | Yes | Media Type of the request body | application/json |
| Authorization | string | Yes | Bearer token for authentication | Bearer access_token |
| x-api-key | string | Yes | API key provided for authorization | x-api-key |
🟢Success Response - 200 OK
| Field | Type | Description | Example |
|---|---|---|---|
| status | string | Indicates the status of the API call | "success" |
| code | string | Response code for the request | "s-101" |
| message | string | Message conveying the response info | "Conversion Successful" |
🔴 Error / Rejection Response - 200 OK
The OMS may accept the API call but reject the conversion itself. In this case the response still returns HTTP 200 but with status: "error" and a pipe-separated message containing the orderId and the rejection reason.
| Field | Type | Description | Example |
|---|---|---|---|
| status | string | Indicates the conversion was rejected by the OMS | "error" |
| code | string | Response code | "s-101" |
| message | string | Pipe-separated string in the format "orderId|rejection reason" returned directly by the OMS | "NWSYF00005F5|Free Qty not available for Position Conversion of APITEST" |
Common rejection reasons include:
Free Qty not available for Position Conversion— The quantity requested for conversion exceeds the available free (unsettled) quantity for that position.- Margin shortfall — Insufficient margin to hold the position under the new product type.
Always parse the message field by splitting on
|to extract the rejection reason for display or logging.