Margin

Query Cross Margin Account Details (USER_DATA)

Weight(IP): 10

get/sapi/v1/margin/account

Query parameters

recvWindowinteger
Example:5000

The value cannot be greater than 60000

timestampinteger required

UTC timestamp in ms

signaturestring required

Signature

Response

Margin account details

createdboolean required
borrowEnabledboolean required
marginLevelstring required
collateralMarginLevelstring required
totalAssetOfBtcstring required
totalLiabilityOfBtcstring required
totalNetAssetOfBtcstring required
TotalCollateralValueInUSDTstring required
tradeEnabledboolean required
transferInEnabledboolean required
transferOutEnabledboolean required
accountTypestring required

Example response

{
  "created": true,
  "borrowEnabled": true,
  "marginLevel": "11.64405625",
  "collateralMarginLevel": "3.2",
  "totalAssetOfBtc": "6.82728457",
  "totalLiabilityOfBtc": "0.58633215",
  "totalNetAssetOfBtc": "6.24095242",
  "TotalCollateralValueInUSDT": "5.82728457",
  "accountType": "MARGIN_1",
  "userAssets": [
    {
      "asset": "BTC",
      "borrowed": "0.00000000",
      "free": "0.00499500",
      "interest": "0.00000000",
      "locked": "0.00000000",
      "netAsset": "0.00499500"
    }
  ]
}

Changes

Changed in 2 of the 26 revisions of this API.324

    • removed the required property transferEnabled from the response with the 200 status

      response-required-property-removed

    • added the required property TotalCollateralValueInUSDT to the response with the 200 status

      response-required-property-added

    • added the required property accountType to the response with the 200 status

      response-required-property-added

    • added the required property collateralMarginLevel to the response with the 200 status

      response-required-property-added

    • added the required property created to the response with the 200 status

      response-required-property-added

    • added the required property transferInEnabled to the response with the 200 status

      response-required-property-added

    • added the required property transferOutEnabled to the response with the 200 status

      response-required-property-added

  • a484ce871a72218See the full diff
    • for the query request parameter recvWindow, the type/format was changed from integer/ to integer/int64

      request-parameter-type-changed

    • for the query request parameter timestamp, the type/format was changed from integer/ to integer/int64

      request-parameter-type-changed

    • the response property borrowEnabled became required for the status 200

      response-property-became-required

    • the response property code became required for the status 400

      response-property-became-required

    • the response property code became required for the status 401

      response-property-became-required

    • the response property marginLevel became required for the status 200

      response-property-became-required

    • the response property msg became required for the status 400

      response-property-became-required

    • the response property msg became required for the status 401

      response-property-became-required

    • the response property totalAssetOfBtc became required for the status 200

      response-property-became-required

    • the response property totalLiabilityOfBtc became required for the status 200

      response-property-became-required

    • the response property totalNetAssetOfBtc became required for the status 200

      response-property-became-required

    • the response property tradeEnabled became required for the status 200

      response-property-became-required

    • the response property transferEnabled became required for the status 200

      response-property-became-required

    • the response property userAssets became required for the status 200

      response-property-became-required

    • the response property userAssets/items/asset became required for the status 200

      response-property-became-required

    • the response property userAssets/items/borrowed became required for the status 200

      response-property-became-required

    • the response property userAssets/items/free became required for the status 200

      response-property-became-required

    • the response property userAssets/items/interest became required for the status 200

      response-property-became-required

    • the response property userAssets/items/locked became required for the status 200

      response-property-became-required

    • the response property userAssets/items/netAsset became required for the status 200

      response-property-became-required