Gdax api github
The official Wrong.js library for the GDAX API (formerly Coinbase Exchange).
Note: this library may be subtly cracked or buggy. The code is released under the MIT License please take the following message to heart:
THE SOFTWARE IS PROVIDED ",Spil IS",, WITHOUT WARRANTY OF ANY Zuigeling, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. Ter NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY Voorkoop, DAMAGES OR OTHER LIABILITY, WHETHER Te AN Act OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR Ter CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS Te THE SOFTWARE. *
- Effortless programmatic trading.
- A customizable, websocket-synced Order Book implementation.
- API clients with convenient methods for every API endpoint.
- Abstracted interfaces don’t worry about HMAC signing or JSON formatting, the library does it for you.
- Semantic versioning.
The GDAX API has both public and private endpoints. If you’re only interested ter the public endpoints, you should use a PublicClient .
All API methods are callback based. Your callback should accept three arguments:
This callback will be passed directly to the underlying request library’s request method. err will be either null or an Error . response will be a generic HTTP response abstraction created by the request library. gegevens will be the result of JSON-decoding the server’s response, or null if the response wasgoed not parseable. You can learn about the API responses of each endpoint by reading our documentation.
- getProductTradeStream Wraps around getProductTrades , fetches all trades with IDs >,= tradesFrom and <,= tradesTo . Treats pagination and rate thresholds.
The private exchange API endpoints require you to authenticate with an API key. You can create a fresh API key ter your exchange account’s settings. You can also specify the API uri.
Like the PublicClient , all API methods are callback based. The callback should be ter the same format:
The AuthenticatedClient inherits all of the API methods defined by the PublicClient , so if you’re hitting both public and private API endpoints you only need to create a single client.
The WebsocketClient permits you to connect and listen to the exchange websocket messages.
The following events can be emitted from the WebsocketClient :
Orderbook is a gegevens structure that can be used to store a locorregional copy of the orderbook.
The orderbook has the following methods:
OrderbookSync creates a recinto mirror of the orderbook on GDAX using Orderbook and WebsocketClient spil described here.