Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
exchange-gdax-public-api
Advanced tools
Access public endpoints, to access market prices, from the GDAX/Coinbase Cryptocurrency Exchange, using Promises.
This package interacts with the public REST API endpoints for the GDAX Exchange that require no authentication using Promises
.
With this package, you should be able to get access to:
API requiring authentication has been decoupled, and will be created in an additional package as an add-on.
exchange-gdax-public-api
is available from npm and yarn:
npm install exchange-gdax-public-api
- or -
yarn add exchange-gdax-public-api
require()
or import
module:const GDAX = require('exchange-gdax-public-api')
or
import GDAX from 'exchange-gdax-public-api'
Object
:const gdax = new GDAX()
await/async
with try {} catch() {}
or .then().catch()
Responses should return a success
and result
property. Successful responses from the API should return as true
.
{
"success": true, // @bool
"result": <data> // @array or @object
}
.getMarkets()
- Get a list of available currency pairs for trading.
getOrderBook(pair, level)
- Get a list of open orders for a product. The amount of detail shown can be customized with the level parameter.
pair
- @string
Market Pair (ex: LTC-BTC)level
- @number
Control level of detail to include. 3-Levels max.getTicker(pair)
- Snapshot information about the last trade (tick), best bid/ask and 24h volume.
pair
- @string
Market Pair (ex: LTC-BTC)getMarketHistory(pair, query)
- List the latest trades for a product.
pair
- @string
Market Pair (ex: LTC-BTC)query
- @object
- Response is paginated. Control properties go here.
before
: @number
- Request page before (newer) this pagination id.after
: @number
- Request page after (older) this pagination id.limit
: @number
- Number of results per request. Maximum 100. (default 100)getHistoricCandles(pair, query)
- Historic rates for a product. Rates are returned in grouped buckets based on requested granularity.
pair
- @string
Market Pair (ex: LTC-BTC)query
- @object
- Response has additional controls to customize.
start
: @number
- Start time in ISO 8601 (Multiply by 1000 for UNIX)end
: @number
- End time in ISO 8601 (Multiply by 1000 for UNIX)granularity
: @number
- Desired timeslice in seconds. (Ex: 300 = 5min)getMarketSummary(pair)
- Get 24 hr stats for the product. volume is in base currency units. open, high, low are in quote currency units.
pair
- @string
Market Pair (ex: LTC-BTC)getCurrencies()
- List known currencies.
getEndpoint(path, query)
- Used to get any additional endpoint that might get added in the future.
path
- @string
Custom path to an endpoint (ex: /products
)query
- @object
Custom parameters to include (ex: { granularity: 300 }
)Please...if you find any issues or improvements needed, feel free to submit your improvements!
FAQs
Access public endpoints, to access market prices, from the GDAX/Coinbase Cryptocurrency Exchange, using Promises.
The npm package exchange-gdax-public-api receives a total of 12 weekly downloads. As such, exchange-gdax-public-api popularity was classified as not popular.
We found that exchange-gdax-public-api demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.