Futures Cross

Close position

POST/futures/cross/position/closePrivate

Close the running cross margin position. This will pass a market order opposite to the current position.

Permissions: futures:cross:write

Response Body

OK

application/json
  1. response
id*string

Internal order ID

Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Formatuuid
type*"limit"

Order type: limit or market

Value in"limit"
side*string

Order side: b (buy) or s (sell)

Value in"buy""sell"
quantity*number

Number of contracts in the order

price*number

Bitcoin price when the order was filled (in USD)

tradingFee*integer

Trading fee

createdAt*string

Timestamp when the order was created

Formatdate-time
filledAt*null

Timestamp when filled (null while order is open)

canceledAt*null

Timestamp when the order was canceled (null if not canceled)

open*boolean

Whether the order is open (not yet filled)

filled*boolean

Whether the order was filled

canceled*boolean

Whether the order was canceled

clientId*|

Optional custom data field (max 64 characters)

import { createHttpClient } from '@ln-markets/sdk/rest/v3'const client = createHttpClient({  key: 'your-key',  secret: 'your-secret',  passphrase: 'your-passphrase',})const result = await client.futures.cross.close()
{  "id": "d0b9f9a0-4f6e-4a5a-8b7a-7f0f5f9a8a1e",  "type": "limit",  "side": "buy",  "quantity": 100,  "price": 20000,  "tradingFee": 10,  "createdAt": "2025-09-01T15:04:21.129Z",  "filledAt": null,  "canceledAt": null,  "open": true,  "filled": false,  "canceled": false,  "clientId": "test-client-id-123"}