Options
All
  • Public
  • Public/Protected
  • All
Menu

dripjs

Index

Type aliases

Amount

Amount: number

Price

Price: number

Spy

SpyConfig

SpyConfig: Config

Symbol

Symbol: Pair | Stock

Variables

Const restApiBasePath

restApiBasePath: "/api/v1/" = "/api/v1/"

Functions

getRateLimit

  • getRateLimit(headers: HttpHeaders): RateLimit

getRestAuthHeaders

  • getRestAuthHeaders(method: HttpMethod, endpoint: string, apiKey: string, apiSecret: string, data?: any): AuthHeaders

getWSAuthQuery

  • getWSAuthQuery(apiKey: string, apiSecret: string): string

signMessage

  • signMessage(secret: string, verb: string, url: string, nonce: number, data?: any): string
  • Sign a message. hex( HMAC_SHA256(secret, verb + url + nonce + data) )

    Parameters

    • secret: string

      API secret.

    • verb: string

      Request verb (GET, POST, etc).

    • url: string

      Request URL.

    • nonce: number

      Nonce for this request.

    • Optional data: any

    Returns string

    Signature.

Object literals

Const restEndpoints

restEndpoints: object

production

production: string = "https://www.bitmex.com"

testnet

testnet: string = "https://testnet.bitmex.com"

Const testnetConfig

testnetConfig: object

apiKey

apiKey: string = `${process.env['SPEC_BITMEX_TEST_API_KEY']}`

apiSecret

apiSecret: string = `${process.env['SPEC_BITMEX_TEST_API_SECRET']}`

testnet

testnet: true = true

Const testnetReadonlyConfig

testnetReadonlyConfig: object

apiKey

apiKey: string = `${process.env['SPEC_BITMEX_TEST_TRADE_API_KEY']}`

apiSecret

apiSecret: string = `${process.env['SPEC_BITMEX_TEST_TRADE_API_SECRET']}`

testnet

testnet: true = true

Const wsEndpoints

wsEndpoints: object

production

production: string = "wss://www.bitmex.com/realtime"

testnet

testnet: string = "wss://testnet.bitmex.com/realtime"

Generated using TypeDoc