Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bfx-api-node-rest

Package Overview
Dependencies
Maintainers
1
Versions
64
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bfx-api-node-rest - npm Package Compare versions

Comparing version 3.0.1 to 3.0.2

6

docs/rest2.md

@@ -33,3 +33,3 @@ <a name="RESTv2"></a>

* [.movements(ccy, start, end, limit, cb)](#RESTv2+movements) ⇒ <code>Promise</code>
* [.ledgers(ccy, start, end, limit, cb)](#RESTv2+ledgers) ⇒ <code>Promise</code>
* [.ledgers(filters, start, end, limit, cb)](#RESTv2+ledgers) ⇒ <code>Promise</code>
* [.orderHistory(symbol, start, end, limit, cb)](#RESTv2+orderHistory) ⇒ <code>Promise</code>

@@ -399,3 +399,3 @@ * [.orderTrades(symbol, start, end, limit, orderID, cb)](#RESTv2+orderTrades) ⇒ <code>Promise</code>

### resTv2.ledgers(ccy, start, end, limit, cb) ⇒ <code>Promise</code>
### resTv2.ledgers(filters, start, end, limit, cb) ⇒ <code>Promise</code>
**Kind**: instance method of [<code>RESTv2</code>](#RESTv2)

@@ -407,3 +407,3 @@ **Returns**: <code>Promise</code> - p

| --- | --- | --- | --- |
| ccy | <code>string</code> | | i.e. ETH |
| filters | <code>Object</code> | | i.e. { ccy: 'ETH', category: 28 } |
| start | <code>number</code> | <code></code> | |

@@ -410,0 +410,0 @@ | end | <code>number</code> | | |

@@ -695,3 +695,3 @@ 'use strict'

/**
* @param {string?} ccy - i.e. ETH
* @param {Object or string?} if Object { ccy: 'ETH', category: 28 }
* @param {number?} start

@@ -704,3 +704,8 @@ * @param {number?} end

*/
ledgers (ccy, start = null, end = Date.now(), limit = 25, cb) {
ledgers (filters, start = null, end = Date.now(), limit = 25, cb) {
const parseFilters = (sent) => {
if (typeof sent === 'string') return { ccy: sent }
return sent || {}
}
const { ccy, category } = parseFilters(filters)
const url = ccy

@@ -710,3 +715,5 @@ ? `/auth/r/ledgers/${ccy}/hist`

return this._makeAuthRequest(url, { start, end, limit }, cb, LedgerEntry)
return this._makeAuthRequest(url, {
start, end, limit, category
}, cb, LedgerEntry)
}

@@ -713,0 +720,0 @@

{
"name": "bfx-api-node-rest",
"version": "3.0.1",
"version": "3.0.2",
"description": "Official Bitfinex REST v1 & v2 API interfaces",

@@ -5,0 +5,0 @@ "engines": {

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc