Using FMZ's BitMEX API for Orders, Positions, and Leverage
Summary
This platform guide demonstrates basic BitMEX futures operations through FMZ: selecting a contract, reading ticker and account data, submitting market and limit orders, checking positions and orders, and canceling resting orders. It also shows changing leverage while a position is open, closing a short position through an asynchronous call, and directing requests to BitMEX's testnet. The examples use the XBTUSD contract and include a direct exchange API call for leverage settings.
The page gives sample code and example response data to illustrate the platform's behavior, including position and order retrieval. It notes that the platform can synthesize bar intervals beyond those natively supported by the exchange and discusses testing simultaneous long and short positions. This is an API walkthrough, not a trading strategy or performance study; it does not assess execution quality, fees in practice, or the risks of leverage. Its examples and exchange details may be outdated, so current platform and BitMEX documentation should be checked before use.
Key ideas
- The examples show how to retrieve BitMEX ticker, account, position, order, and contract information through FMZ.
- The guide demonstrates submitting and canceling market and limit orders.
- Leverage can be adjusted on an open position, and the page shows a direct API request for that operation.
- An asynchronous platform call is illustrated for closing a position.
- The material documents API mechanics rather than trading performance, and its age may limit applicability.
Tags
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.