According to Docs for USD-M Futures next API has GET and POST properties:
/fapi/v1/positionSide/dual
/fapi/v1/multiAssetsMargin
It’s helpful as you can check User setup and update it, if necessary.
Is there any reason why
/fapi/v1/marginType
has only POST property? How can I get User current setup for Margin Type, to be able to decide if I need to update it or not?
You can use /fapi/v2/positionRisk
→ there’s “marginType” in the response for each symbol
Thank you, it helped, I can get Margin Type now:
[{
"symbol": "BTCUSDT",
"positionAmt": "0.000",
...
"marginType": "cross",
}]
The only problem I see now, is that the “/fapi/v1/marginType” requires enum { ISOLATED, CROSSED } according to the API Docs, but the “/fapi/v2/positionRisk” returns me a string “cross”.
Is there any reason to have different types there? It’s a bit inconvenient when you use strongly typed languages like C#.