Funding Credits

Receive a snapshot and updates for any funding credits (funds used in active positions) on your account.

Subscribe to the account information channel to keep track of your funding credits. The account information channel provides a snapshot and updates on the funding credits in your account. The snapshot is delivered upon subscribing and any changes to your funding credits will be provided as updates for as long as the channel remains open. Any authenticated connection is automatically subscribed to the account information channel.

Example code to open an authenticated connection can be found on our Authenticated Channels Page.

Funding credits events are sent with CHAN_ID = 0 and can be identified by looking at the TYPE stream field. Funding credits events will use one of the following abbreviations: 'fcs' (funding credits snapshot), 'fcn' (funding credits new), 'fcu' (funding credits update), 'fcc' (funding credits close).

[
  CHAN_ID,
  TYPE, //'fcs'
  [
    [
      ID,
      SYMBOL,
      SIDE,
      MTS_CREATE,
      MTS_UPDATE,
      AMOUNT,
      FLAGS,
      STATUS,
      _PLACEHOLDER,
      _PLACEHOLDER,
      _PLACEHOLDER,
      RATE,
      PERIOD,
      MTS_OPENING,
      MTS_LAST_PAYOUT,
      NOTIFY,
      HIDDEN,
      _PLACEHOLDER,
      RENEW,
      RATE_REAL,
      NO_CLOSE,
      POSITION_PAIR
    ],
    ...
  ]
]
    
[0,"fcs",[[26223578,"fUST",1,1575052261000,1575296187000,350,0,"ACTIVE",null,null,null,0,30,1575052261000,1575293487000,0,0,null,0,null,0,"tBTCUST"],[26223711,"fUSD",-1,1575291961000,1575296187000,180,0,"ACTIVE",null,null,null,0.002,7,1575282446000,1575295587000,0,0,null,0,null,0,"tETHUSD"]]]
[
  CHAN_ID,
  TYPE, // 'fcn', 'fcu', 'fcc':
  [
    ID, 
    SYMBOL, 
    SIDE, 
    MTS_CREATE, 
    MTS_UPDATE, 
    AMOUNT, 
    FLAGS, 
    STATUS,
    _PLACEHOLDER,
    _PLACEHOLDER,
    _PLACEHOLDER,
    RATE,
    PERIOD, 
    MTS_OPENING, 
    MTS_LAST_PAYOUT, 
    NOTIFY, 
    HIDDEN, 
    _PLACEHOLDER,
    RENEW,
    RATE_REAL, 
    NO_CLOSE, 
    POSITION_PAIR
  ]
]

[0,"fcu",[26223578,"fUST",1,1575052261000,1575296787000,350,0,"ACTIVE",null,null,null,0,30,1575052261000,1575293487000,0,0,null,0,null,0,"tBTCUST"]]

Stream Fields

TermTypeDescription
CHAN_IDintIdentification number for the channel subscribtion. Funding credits events are always sent through the account information channel with CHAN_ID = 0
TYPEstring'fcs' (funding credits snapshot), 'fcn' (funding credits new), 'fcu' (funding credits update), 'fcc' (funding credits close).
IDintegerOffer ID
SYMBOLstringThe currency of the offer (fUSD, etc)
SIDEint1 if you are the lender, 0 if you are both the lender and borrower, -1 if you're the borrower
MTS_CREATEintMillisecond Time Stamp when the offer was created
MTS_UPDATEintMillisecond Time Stamp when the offer was created
AMOUNTfloatAmount the offer is for
FLAGSobjectfuture params object (stay tuned)
STATUSstringOffer Status: ACTIVE, EXECUTED, PARTIALLY FILLED, CANCELED
RATEfloatRate of the offer
PERIODintPeriod of the offer
MTS_OPENINGintMillisecond Time Stamp when the funding was opened
MTS_LAST_PAYOUTintMillisecond Time Stamp when the last payout was received
NOTIFYint0 if false, 1 if true
HIDDENint0 if false, 1 if true
RENEWint0 if false, 1 if true
RATE_REALfloatthe calculated rate for FRR and FRRDELTAFIX
NO_CLOSEint0 if false, 1 if true (whether the funding should be closed when the position is closed)
POSITION_PAIRstringThe pair that the currency was used for