API दस्तावेज़ीकरण

Close Position

post/api/v1/Trade/positions/close

Closes an open position with a market order for the full position quantity. The order goes through the same account and risk checks as any other order on the account.

Trade

पैरामीटर

version

path · string

आवश्यक

अनुरोध निकाय

{
  "accountId": 1001,
  "instrument": "EURUSD"
}

जवाब

  • 202Close order accepted; {orderId} is the closing order.application/json
    {
      "status": "accepted",
      "message": "Close position accepted.",
      "orderId": -46
    }
  • 400Validation failed, no open position for the instrument, or the order was rejected (for example the account may not trade); the message gives the reason.application/json
    {
      "status": "rejected",
      "message": "Instrument is required."
    }
Alipay
Stripe
Eurex
AWS
Azure
Google Cloud
Currenex
Velocity Trade
Bitcoin
CME
Interactive Brokers
Kraken
FIX API
XTX
Bloomberg
Binance

अपने प्लेटफ़ॉर्म को लॉन्च करें।