diff options
author | Steve Klebanoff <steve.klebanoff@gmail.com> | 2019-01-16 05:57:31 +0800 |
---|---|---|
committer | Steve Klebanoff <steve.klebanoff@gmail.com> | 2019-01-16 05:57:31 +0800 |
commit | af63934d2ca0d2830a8609c16bd685a02241e257 (patch) | |
tree | d684d886006ea50f44fe6a96fe9c44952e5d7f57 | |
parent | 600b44c9620494c976b5aac6e8a1912543cda81c (diff) | |
download | dexon-sol-tools-af63934d2ca0d2830a8609c16bd685a02241e257.tar dexon-sol-tools-af63934d2ca0d2830a8609c16bd685a02241e257.tar.gz dexon-sol-tools-af63934d2ca0d2830a8609c16bd685a02241e257.tar.bz2 dexon-sol-tools-af63934d2ca0d2830a8609c16bd685a02241e257.tar.lz dexon-sol-tools-af63934d2ca0d2830a8609c16bd685a02241e257.tar.xz dexon-sol-tools-af63934d2ca0d2830a8609c16bd685a02241e257.tar.zst dexon-sol-tools-af63934d2ca0d2830a8609c16bd685a02241e257.zip |
Export types and add additional documentation
-rw-r--r-- | packages/asset-buyer/src/index.ts | 4 | ||||
-rw-r--r-- | packages/asset-buyer/src/types.ts | 6 |
2 files changed, 10 insertions, 0 deletions
diff --git a/packages/asset-buyer/src/index.ts b/packages/asset-buyer/src/index.ts index a42d7e272..339d64616 100644 --- a/packages/asset-buyer/src/index.ts +++ b/packages/asset-buyer/src/index.ts @@ -1,3 +1,4 @@ +import { LiquidityRequestOpts } from './../lib/src/types.d'; export { JSONRPCRequestPayload, JSONRPCResponsePayload, @@ -19,6 +20,9 @@ export { BuyQuoteExecutionOpts, BuyQuoteInfo, BuyQuoteRequestOpts, + LiquidityForAssetData, + LiquidityRequestOpts, + OrdersAndFillableAmounts, OrderProvider, OrderProviderRequest, OrderProviderResponse, diff --git a/packages/asset-buyer/src/types.ts b/packages/asset-buyer/src/types.ts index da8b75c8f..0bf2323bd 100644 --- a/packages/asset-buyer/src/types.ts +++ b/packages/asset-buyer/src/types.ts @@ -76,6 +76,8 @@ export interface BuyQuoteRequestOpts { } /* + * Options for checking liquidity + * * shouldForceOrderRefresh: If set to true, new orders and state will be fetched instead of waiting for the next orderRefreshIntervalMs. Defaults to false. */ export interface LiquidityRequestOpts extends Pick<BuyQuoteRequestOpts, 'shouldForceOrderRefresh'> {} @@ -122,6 +124,10 @@ export enum AssetBuyerError { TransactionValueTooLow = 'TRANSACTION_VALUE_TOO_LOW', } +/** + * orders: An array of signed orders + * remainingFillableMakerAssetAmounts: A list of fillable amounts for the signed orders. The index of an item in the array associates the amount with the corresponding order. + */ export interface OrdersAndFillableAmounts { orders: SignedOrder[]; remainingFillableMakerAssetAmounts: BigNumber[]; |