cw_sdk_dart library

Classes

Asset
An asset is something that is traded, like a crypto or fiat currency.
Candle
A representation of a traditional candlestick chart candle.
Exchange
An Exchange is a marketplace for securities, or in this case assets and pairs.
Market
A Market represents the listing/trading of a Pair on an Exchange.
OrderBook
An OrderBook is a sorted set of orders (asks and bids) for a particular Market.
OrderBookDelta
An OrderBookDelta represents a diff between 2 orderbook snapshots.
OrderBookSnapshot
An OrderBookSnapshot is the deterministic state of an OrderBook at any given point in time.
Pair
A pair represents an instrument traded on an Exchange.
PublicOrder
A PublicOrder is an offer to buy or sell some amount of an asset at a specific price.
PublicTrade
A PublicTrade is an exchange of a fixed amount of an asset at a fixed price between parties.
RestApiClient
RestApiClient is an API client for the Cryptowatch REST API.
Summary
A Summary is a 24 hour sliding window of a Market's metrics.

Constants

defaultApiDomain → const String
The current (as of May 1, 2020) production domain for Cryptowatch's REST API.
"api.cryptowat.ch"
version → const String
Current version of the sdk.
"0.1.1-alpha.1"

Functions

aggregatePublicOrders(Iterable<PublicOrder> orders, num aggLevel) Iterable<PublicOrder>
sortPublicOrders(Iterable<PublicOrder> orders, [bool asc = true]) List<PublicOrder>

Exceptions / Errors

ApplyingOldDeltaException
A instance ApplyingOldDeltaException is thrown whenver an attempt is made to apply a OrderBookDelta to an OrderBook with a higher seqNum.
ApplyingOldSnapshotException
A instance ApplyingOldSnapshotException is thrown whenver an attempt is made to apply a OrderBookSnapshot to an OrderBook with a higher seqNum.
RateLimitException
RateLimitException is thrown whenever the Cryptowatch REST API indicates that the client is making too many API requests.
RestServerException
RestServerException is thrown whenever the Cryptowatch REST API returns a 500+ status code.
UnexpectedResponseFormatException
UnexpectedResponseFormatException is thrown whenever the Cryptowatch REST API responds to a request with a body that the sdk is unable to parse.