Position

Closes a contract position based on the provided request.

post/api/Position/closeContract

Request body

accountIdinteger required
contractIdstring required

Response

A response indicating the success or failure of the close operation.

successboolean required
errorCode0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 required

0 = Success 1 = AccountNotFound 2 = PositionNotFound 3 = ContractNotFound 4 = ContractNotActive 5 = OrderRejected 6 = OrderPending 7 = UnknownError 8 = AccountRejected

errorMessagestring

Changes

No recorded changes to this endpoint across all 1 revision of this API.