API ReferenceMargin & Lending

Credit state

GET/api/v1/px/creditBearer

PX Discovery & AccountE6 decimal strings throughoutA | B

Debt including interest, equity, health and the borrowing limit. When healthBps falls below maintenanceBps liquidation fires automatically — that is server behaviour; it neither needs nor accepts caller confirmation.

healthBps may be null (health is undefined with no debt), in which case healthy is true. Do not treat that null as 0.

Send Authorization: Bearer <token>. The token is issued by POST /api/v1/auth/verify, and expires after 24h idle or 7d after issuance.

Response

200Credit state
  • debtE6string

    Debt including accrued interest, as an E6 string

  • equityE6string

    Account equity, as an E6 string

  • grossE6string

    Gross exposure, as an E6 string

  • healthBpsstringnullable

    Health, in basis points. null when there is no debt (health is undefined then) — do not treat it as 0

  • healthyboolean

    Whether the account is above the maintenance line; true when there is no debt

    Examplefalse

  • borrowAprBpsstring

    Borrow APR, in basis points

  • maxBorrowE6string

    Current borrowing limit, as an E6 string

  • lendDepositE6string

    Principal currently lent out, as an E6 string

  • maintenanceBpsstring

    Maintenance margin rate, in basis points; liquidation triggers when healthBps falls below it

  • initialMarginBpsstring

    Initial margin rate, in basis points

Switch status codes in the response example to view errors. For all codes, see the Errors page.