@burningflames/inj-exchange-sdk 0.0.0-stage → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +202 -0
- package/NOTICE +7 -0
- package/README.md +198 -2
- package/dist/ApiManager-BcwRSg4p.cjs +14 -0
- package/dist/ApiManager-VsZ_7GMj.js +9 -0
- package/dist/MsgIncreasePositionMargin-7_g04vle.d.ts +2285 -0
- package/dist/MsgIncreasePositionMargin-UQn6vCje.d.cts +2284 -0
- package/dist/bank-c5iv-fbg.cjs +480 -0
- package/dist/bank-xWl_W05K.js +451 -0
- package/dist/chain-CgjV0b1c.js +5868 -0
- package/dist/chain-LTb0TjXc.cjs +5903 -0
- package/dist/clients/chain.cjs +8 -0
- package/dist/clients/chain.d.cts +2 -0
- package/dist/clients/chain.d.ts +2 -0
- package/dist/clients/chain.js +1 -0
- package/dist/clients/indexer.cjs +14 -0
- package/dist/clients/indexer.d.cts +2 -0
- package/dist/clients/indexer.d.ts +2 -0
- package/dist/clients/indexer.js +1 -0
- package/dist/coin-8_Vn0T8-.cjs +73 -0
- package/dist/coin-CowdNxVV.js +68 -0
- package/dist/decimal-CIFXn110.js +27 -0
- package/dist/decimal-DJMaLHQO.cjs +38 -0
- package/dist/eip712-88KVCEnw.d.cts +21 -0
- package/dist/eip712-88KVCEnw.d.ts +21 -0
- package/dist/errors-CKG7zTvs.cjs +36 -0
- package/dist/errors-MWG_E5zA.js +25 -0
- package/dist/exchange-BPRx-kFI.js +4637 -0
- package/dist/exchange-CTLbPuA7.cjs +4966 -0
- package/dist/index-B3bDzB4S.d.cts +2169 -0
- package/dist/index-BHLUinQA.d.ts +220 -0
- package/dist/index-BPpDV6JA.d.cts +182 -0
- package/dist/index-BT_zyZW9.d.cts +220 -0
- package/dist/index-DcQT-y4U.d.ts +2169 -0
- package/dist/index-DfoLUPEo.d.ts +183 -0
- package/dist/index.cjs +73 -0
- package/dist/index.d.cts +11 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +13 -0
- package/dist/indexer-D7XfYsAZ.js +21699 -0
- package/dist/indexer-DI7-gHOA.cjs +21770 -0
- package/dist/msgs-Bi5b52-R.js +11359 -0
- package/dist/msgs-DNyc0UtV.cjs +11442 -0
- package/dist/msgs.cjs +16 -0
- package/dist/msgs.d.cts +2 -0
- package/dist/msgs.d.ts +2 -0
- package/dist/msgs.js +1 -0
- package/dist/query-DGTA8Lz_.js +13375 -0
- package/dist/query-L1m6tP9I.cjs +13530 -0
- package/dist/stream-BgKRWG60.d.cts +46 -0
- package/dist/stream-BgKRWG60.d.ts +46 -0
- package/dist/stream-D8ZvUQFy.cjs +29 -0
- package/dist/stream-RhVNTED5.js +18 -0
- package/dist/tendermint-CF_W9U6D.d.ts +49 -0
- package/dist/tendermint-zj8c-dVM.d.cts +49 -0
- package/dist/tx-BRaw1C6e.d.ts +66 -0
- package/dist/tx-BgpasOOk.cjs +464 -0
- package/dist/tx-CCt0zqng.d.cts +66 -0
- package/dist/tx-COcDYlg3.js +411 -0
- package/dist/tx-DIg8nbnn.cjs +1091 -0
- package/dist/tx-GN0SFql2.js +1026 -0
- package/dist/types.cjs +38 -0
- package/dist/types.d.cts +13 -0
- package/dist/types.d.ts +13 -0
- package/dist/types.js +26 -0
- package/dist/utils.cjs +131 -0
- package/dist/utils.d.cts +2 -0
- package/dist/utils.d.ts +2 -0
- package/dist/utils.js +115 -0
- package/package.json +124 -4
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
import { A as Data, D as EvidenceList, E as Block$1, G as PageRequest, K as PageResponse, O as BlockID, g as EvmChainId, h as ChainId, j as Consensus, k as Commit, q as Any } from "./MsgIncreasePositionMargin-7_g04vle.js";
|
|
2
|
+
import { a as TxRaw, c as PaginationOption, i as StdFee, n as CreateTransactionResult, o as Msg, s as Pagination, t as CreateTransactionParams } from "./tx-BRaw1C6e.js";
|
|
3
|
+
import { t as Eip712TypedData } from "./eip712-88KVCEnw.js";
|
|
4
|
+
import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
|
|
5
|
+
import "@grpc/grpc-js";
|
|
6
|
+
import { n as BlockResponse, t as Block$2 } from "./tendermint-CF_W9U6D.js";
|
|
7
|
+
declare function getEthereumAddress(injectiveAddress: string): string;
|
|
8
|
+
declare function getInjectiveAddress(ethAddress: string): string;
|
|
9
|
+
/**
|
|
10
|
+
* Chain format is the fixed-point string the chain stores: the human value
|
|
11
|
+
* shifted by 18 decimals, as a plain integer. "1.5" becomes
|
|
12
|
+
* "1500000000000000000".
|
|
13
|
+
*/
|
|
14
|
+
declare function toChainFormat(value: string | number, decimals?: number): string;
|
|
15
|
+
/**
|
|
16
|
+
* The Cosmos SDK decimal string the EIP-712 payload signs: the same value as
|
|
17
|
+
* toChainFormat, but with the decimal point restored. "1.5" becomes
|
|
18
|
+
* "1.500000000000000000".
|
|
19
|
+
*/
|
|
20
|
+
declare function toCosmosSdkDecString(value: string | number, decimals?: number): string;
|
|
21
|
+
/**
|
|
22
|
+
* The typed data an EIP-712 signer signs for a transaction. The message is two
|
|
23
|
+
* JSON strings rather than nested objects, which is what the chain's verifier
|
|
24
|
+
* rebuilds and compares against.
|
|
25
|
+
*
|
|
26
|
+
* Building the payload is as far as the SDK goes: it holds no key, so the
|
|
27
|
+
* caller signs these bytes with whatever account it owns and hands the
|
|
28
|
+
* signature to `createTransaction`.
|
|
29
|
+
*/
|
|
30
|
+
declare function getEip712TypedDataV2({ msgs, tx, fee, evmChainId }: {
|
|
31
|
+
msgs: Msg | Msg[];
|
|
32
|
+
tx: {
|
|
33
|
+
accountNumber: number;
|
|
34
|
+
sequence: number;
|
|
35
|
+
chainId: ChainId;
|
|
36
|
+
memo?: string;
|
|
37
|
+
timeoutHeight?: number;
|
|
38
|
+
};
|
|
39
|
+
fee: StdFee;
|
|
40
|
+
evmChainId: EvmChainId;
|
|
41
|
+
}): Eip712TypedData;
|
|
42
|
+
declare function hexToBytes(hex: string): Uint8Array;
|
|
43
|
+
declare function bytesToHex(bytes: Uint8Array): string;
|
|
44
|
+
declare function hexToBase64(hex: string): string;
|
|
45
|
+
/** Turns a caller's paging request into the proto request, key decoded. */
|
|
46
|
+
declare function toPageRequest(option: PaginationOption | undefined): PageRequest | undefined;
|
|
47
|
+
/** Turns the proto response's paging into the shape a caller receives. */
|
|
48
|
+
declare function toPagination(response: PageResponse | undefined): Pagination;
|
|
49
|
+
/**
|
|
50
|
+
* Block is tendermint type Block, with the Header proposer address
|
|
51
|
+
* field converted to bech32 string.
|
|
52
|
+
*/
|
|
53
|
+
interface Block {
|
|
54
|
+
header: Header | undefined;
|
|
55
|
+
data: Data | undefined;
|
|
56
|
+
evidence: EvidenceList | undefined;
|
|
57
|
+
lastCommit: Commit | undefined;
|
|
58
|
+
}
|
|
59
|
+
/** Header defines the structure of a Tendermint block header. */
|
|
60
|
+
interface Header {
|
|
61
|
+
/** basic block info */
|
|
62
|
+
version: Consensus | undefined;
|
|
63
|
+
chainId: string;
|
|
64
|
+
height: number;
|
|
65
|
+
time: Date | undefined;
|
|
66
|
+
/** prev block info */
|
|
67
|
+
lastBlockId: BlockID | undefined;
|
|
68
|
+
/** hashes of block data */
|
|
69
|
+
lastCommitHash: Buffer;
|
|
70
|
+
/** transactions */
|
|
71
|
+
dataHash: Buffer;
|
|
72
|
+
/** hashes from the app output from the prev block */
|
|
73
|
+
validatorsHash: Buffer;
|
|
74
|
+
/** validators for the next block */
|
|
75
|
+
nextValidatorsHash: Buffer;
|
|
76
|
+
/** consensus params for current block */
|
|
77
|
+
consensusHash: Buffer;
|
|
78
|
+
/** state after txs from the previous block */
|
|
79
|
+
appHash: Buffer;
|
|
80
|
+
/** root hash of all results from the txs from the previous block */
|
|
81
|
+
lastResultsHash: Buffer;
|
|
82
|
+
/** consensus info */
|
|
83
|
+
evidenceHash: Buffer;
|
|
84
|
+
/**
|
|
85
|
+
* proposer_address is the original block proposer address, formatted as a Bech32 string.
|
|
86
|
+
* In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string
|
|
87
|
+
* for better UX.
|
|
88
|
+
*/
|
|
89
|
+
proposerAddress: string;
|
|
90
|
+
}
|
|
91
|
+
declare const Block: MessageFns$2<Block>;
|
|
92
|
+
declare const Header: MessageFns$2<Header>;
|
|
93
|
+
type Builtin$2 = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
94
|
+
type DeepPartial$2<T> = T extends Builtin$2 ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial$2<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial$2<U>> : T extends {} ? { [K in keyof T]?: DeepPartial$2<T[K]>; } : Partial<T>;
|
|
95
|
+
type KeysOfUnion$2<T> = T extends T ? keyof T : never;
|
|
96
|
+
type Exact$2<P, I> = P extends Builtin$2 ? P : P & { [K in keyof P as Extract<K, keyof I>]: Exact$2<P[K], I[K & keyof I]>; } & { [K in Exclude<keyof I, KeysOfUnion$2<P>>]: never; };
|
|
97
|
+
interface MessageFns$2<T> {
|
|
98
|
+
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
99
|
+
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
100
|
+
fromJSON(object: any): T;
|
|
101
|
+
toJSON(message: T): unknown;
|
|
102
|
+
create<I extends Exact$2<DeepPartial$2<T>, I>>(base?: I): T;
|
|
103
|
+
fromPartial<I extends Exact$2<DeepPartial$2<T>, I>>(object: I): T;
|
|
104
|
+
}
|
|
105
|
+
/** GetLatestBlockResponse is the response type for the Query/GetLatestBlock RPC method. */
|
|
106
|
+
interface GetLatestBlockResponse {
|
|
107
|
+
blockId: BlockID | undefined;
|
|
108
|
+
/** Deprecated: please use `sdk_block` instead */
|
|
109
|
+
block: Block$1 | undefined;
|
|
110
|
+
/** Since: cosmos-sdk 0.47 */
|
|
111
|
+
sdkBlock: Block | undefined;
|
|
112
|
+
}
|
|
113
|
+
declare const GetLatestBlockResponse: MessageFns$1<GetLatestBlockResponse>;
|
|
114
|
+
type Builtin$1 = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
115
|
+
type DeepPartial$1<T> = T extends Builtin$1 ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial$1<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial$1<U>> : T extends {} ? { [K in keyof T]?: DeepPartial$1<T[K]>; } : Partial<T>;
|
|
116
|
+
type KeysOfUnion$1<T> = T extends T ? keyof T : never;
|
|
117
|
+
type Exact$1<P, I> = P extends Builtin$1 ? P : P & { [K in keyof P as Extract<K, keyof I>]: Exact$1<P[K], I[K & keyof I]>; } & { [K in Exclude<keyof I, KeysOfUnion$1<P>>]: never; };
|
|
118
|
+
interface MessageFns$1<T> {
|
|
119
|
+
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
120
|
+
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
121
|
+
fromJSON(object: any): T;
|
|
122
|
+
toJSON(message: T): unknown;
|
|
123
|
+
create<I extends Exact$1<DeepPartial$1<T>, I>>(base?: I): T;
|
|
124
|
+
fromPartial<I extends Exact$1<DeepPartial$1<T>, I>>(object: I): T;
|
|
125
|
+
}
|
|
126
|
+
type AnyBlock = Block$1 | Block;
|
|
127
|
+
declare function sanitizeBlock(block: AnyBlock): Block$2;
|
|
128
|
+
declare function sanitizeLatestBlock(response: GetLatestBlockResponse): BlockResponse;
|
|
129
|
+
interface ExtensionOptionsWeb3Tx {
|
|
130
|
+
/**
|
|
131
|
+
* typedDataChainID used only in EIP712 Domain and should match
|
|
132
|
+
* Ethereum network ID in a Web3 provider (e.g. Metamask).
|
|
133
|
+
*/
|
|
134
|
+
typedDataChainID: number;
|
|
135
|
+
/**
|
|
136
|
+
* feePayer is an account address for the fee payer. It will be validated
|
|
137
|
+
* during EIP712 signature checking.
|
|
138
|
+
*/
|
|
139
|
+
feePayer: string;
|
|
140
|
+
/**
|
|
141
|
+
* feePayerSig is a signature data from the fee paying account,
|
|
142
|
+
* allows to perform fee delegation when using EIP712 Domain.
|
|
143
|
+
*/
|
|
144
|
+
feePayerSig: Buffer;
|
|
145
|
+
}
|
|
146
|
+
declare const ExtensionOptionsWeb3Tx: MessageFns<ExtensionOptionsWeb3Tx>;
|
|
147
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
148
|
+
type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? { [K in keyof T]?: DeepPartial<T[K]>; } : Partial<T>;
|
|
149
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
150
|
+
type Exact<P, I> = P extends Builtin ? P : P & { [K in keyof P as Extract<K, keyof I>]: Exact<P[K], I[K & keyof I]>; } & { [K in Exclude<keyof I, KeysOfUnion<P>>]: never; };
|
|
151
|
+
interface MessageFns<T> {
|
|
152
|
+
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
153
|
+
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
154
|
+
fromJSON(object: any): T;
|
|
155
|
+
toJSON(message: T): unknown;
|
|
156
|
+
create<I extends Exact<DeepPartial<T>, I>>(base?: I): T;
|
|
157
|
+
fromPartial<I extends Exact<DeepPartial<T>, I>>(object: I): T;
|
|
158
|
+
}
|
|
159
|
+
declare function createTxBytes(txRaw: TxRaw): Buffer;
|
|
160
|
+
/**
|
|
161
|
+
* The extension a web3 transaction carries: the EVM chain id it was signed
|
|
162
|
+
* for and, when the fee is delegated, the paying account and its signature.
|
|
163
|
+
*/
|
|
164
|
+
declare function createWeb3Extension({ evmChainId, feePayer, feePayerSig }: {
|
|
165
|
+
evmChainId: EvmChainId;
|
|
166
|
+
feePayer?: string;
|
|
167
|
+
feePayerSig?: Buffer;
|
|
168
|
+
}): ExtensionOptionsWeb3Tx;
|
|
169
|
+
/**
|
|
170
|
+
* Appends the web3 extension to a transaction body, which is what makes the
|
|
171
|
+
* transaction readable by an EIP-712 signer.
|
|
172
|
+
*/
|
|
173
|
+
declare function createTxRawEIP712({ txRaw, extension, nonCriticalExtension }: {
|
|
174
|
+
txRaw: TxRaw;
|
|
175
|
+
extension: ExtensionOptionsWeb3Tx;
|
|
176
|
+
nonCriticalExtension?: Any | Any[];
|
|
177
|
+
}): TxRaw;
|
|
178
|
+
/**
|
|
179
|
+
* Builds a transaction body and auth info for one signer and returns everything
|
|
180
|
+
* a DIRECT signer needs, without signing anything.
|
|
181
|
+
*/
|
|
182
|
+
declare function createTransaction(params: CreateTransactionParams): CreateTransactionResult;
|
|
183
|
+
export { sanitizeBlock as a, toPagination as c, hexToBytes as d, getEip712TypedDataV2 as f, getInjectiveAddress as g, getEthereumAddress as h, createWeb3Extension as i, bytesToHex as l, toCosmosSdkDecString as m, createTxBytes as n, sanitizeLatestBlock as o, toChainFormat as p, createTxRawEIP712 as r, toPageRequest as s, createTransaction as t, hexToBase64 as u };
|
package/dist/index.cjs
ADDED
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
const require_query = require("./query-L1m6tP9I.cjs");
|
|
3
|
+
const require_tx = require("./tx-DIg8nbnn.cjs");
|
|
4
|
+
const require_exchange = require("./exchange-CTLbPuA7.cjs");
|
|
5
|
+
const require_types = require("./types.cjs");
|
|
6
|
+
const require_errors = require("./errors-CKG7zTvs.cjs");
|
|
7
|
+
const require_stream = require("./stream-D8ZvUQFy.cjs");
|
|
8
|
+
const require_msgs = require("./msgs-DNyc0UtV.cjs");
|
|
9
|
+
const require_decimal = require("./decimal-DJMaLHQO.cjs");
|
|
10
|
+
const require_chain = require("./chain-LTb0TjXc.cjs");
|
|
11
|
+
const require_tx$1 = require("./tx-BgpasOOk.cjs");
|
|
12
|
+
const require_indexer = require("./indexer-DI7-gHOA.cjs");
|
|
13
|
+
const require_utils = require("./utils.cjs");
|
|
14
|
+
exports.ApiError = require_errors.ApiError;
|
|
15
|
+
exports.BroadcastMode = require_query.BroadcastMode;
|
|
16
|
+
exports.ChainAuthApiClient = require_chain.ChainAuthApiClient;
|
|
17
|
+
exports.ChainAuthZApiClient = require_chain.ChainAuthZApiClient;
|
|
18
|
+
exports.ChainBankApiClient = require_chain.ChainBankApiClient;
|
|
19
|
+
exports.ChainExchangeApiClient = require_chain.ChainExchangeApiClient;
|
|
20
|
+
exports.ChainId = require_types.ChainId;
|
|
21
|
+
exports.ChainTendermintApiClient = require_chain.ChainTendermintApiClient;
|
|
22
|
+
exports.ChainTxApiClient = require_chain.ChainTxApiClient;
|
|
23
|
+
exports.EvmChainId = require_types.EvmChainId;
|
|
24
|
+
exports.ExecutionType = require_exchange.ExecutionType;
|
|
25
|
+
exports.IndexerAccountsApiClient = require_indexer.IndexerAccountsApiClient;
|
|
26
|
+
exports.IndexerAccountsStreamClient = require_indexer.IndexerAccountsStreamClient;
|
|
27
|
+
exports.IndexerArchiverApiClient = require_indexer.IndexerArchiverApiClient;
|
|
28
|
+
exports.IndexerDerivativesApiClient = require_indexer.IndexerDerivativesApiClient;
|
|
29
|
+
exports.IndexerDerivativesStreamClient = require_indexer.IndexerDerivativesStreamClient;
|
|
30
|
+
exports.IndexerOracleApiClient = require_indexer.IndexerOracleApiClient;
|
|
31
|
+
exports.IndexerOracleStreamClient = require_indexer.IndexerOracleStreamClient;
|
|
32
|
+
exports.IndexerPortfolioApiClient = require_indexer.IndexerPortfolioApiClient;
|
|
33
|
+
exports.IndexerPortfolioStreamClient = require_indexer.IndexerPortfolioStreamClient;
|
|
34
|
+
exports.IndexerSpotApiClient = require_indexer.IndexerSpotApiClient;
|
|
35
|
+
exports.IndexerSpotStreamClient = require_indexer.IndexerSpotStreamClient;
|
|
36
|
+
exports.MarketStatus = require_exchange.MarketStatus;
|
|
37
|
+
exports.MsgBatchCancelDerivativeOrders = require_msgs.MsgBatchCancelDerivativeOrders;
|
|
38
|
+
exports.MsgBatchCancelSpotOrders = require_msgs.MsgBatchCancelSpotOrders;
|
|
39
|
+
exports.MsgCancelDerivativeOrder = require_msgs.MsgCancelDerivativeOrder;
|
|
40
|
+
exports.MsgCancelSpotOrder = require_msgs.MsgCancelSpotOrder;
|
|
41
|
+
exports.MsgCreateDerivativeLimitOrder = require_msgs.MsgCreateDerivativeLimitOrder;
|
|
42
|
+
exports.MsgCreateDerivativeMarketOrder = require_msgs.MsgCreateDerivativeMarketOrder;
|
|
43
|
+
exports.MsgCreateSpotLimitOrder = require_msgs.MsgCreateSpotLimitOrder;
|
|
44
|
+
exports.MsgCreateSpotMarketOrder = require_msgs.MsgCreateSpotMarketOrder;
|
|
45
|
+
exports.MsgDeposit = require_msgs.MsgDeposit;
|
|
46
|
+
exports.MsgExternalTransfer = require_msgs.MsgExternalTransfer;
|
|
47
|
+
exports.MsgIncreasePositionMargin = require_msgs.MsgIncreasePositionMargin;
|
|
48
|
+
exports.MsgSend = require_msgs.MsgSend;
|
|
49
|
+
exports.MsgSubaccountTransfer = require_msgs.MsgSubaccountTransfer;
|
|
50
|
+
exports.MsgWithdraw = require_msgs.MsgWithdraw;
|
|
51
|
+
exports.OrderMask = require_exchange.OrderMask;
|
|
52
|
+
exports.OrderSide = require_query.OrderSide;
|
|
53
|
+
exports.OrderType = require_exchange.OrderType;
|
|
54
|
+
exports.SignMode = require_tx.SignMode;
|
|
55
|
+
exports.StreamDisconnectReason = require_stream.StreamDisconnectReason;
|
|
56
|
+
exports.StreamManager = require_indexer.StreamManager;
|
|
57
|
+
exports.StreamState = require_stream.StreamState;
|
|
58
|
+
exports.bytesToHex = require_utils.bytesToHex;
|
|
59
|
+
exports.createTransaction = require_tx$1.createTransaction;
|
|
60
|
+
exports.createTxBytes = require_tx$1.createTxBytes;
|
|
61
|
+
exports.createTxRawEIP712 = require_tx$1.createTxRawEIP712;
|
|
62
|
+
exports.createWeb3Extension = require_tx$1.createWeb3Extension;
|
|
63
|
+
exports.getEip712TypedDataV2 = require_utils.getEip712TypedDataV2;
|
|
64
|
+
exports.getEthereumAddress = require_utils.getEthereumAddress;
|
|
65
|
+
exports.getInjectiveAddress = require_utils.getInjectiveAddress;
|
|
66
|
+
exports.hexToBase64 = require_utils.hexToBase64;
|
|
67
|
+
exports.hexToBytes = require_utils.hexToBytes;
|
|
68
|
+
exports.sanitizeBlock = require_tx$1.sanitizeBlock;
|
|
69
|
+
exports.sanitizeLatestBlock = require_tx$1.sanitizeLatestBlock;
|
|
70
|
+
exports.toChainFormat = require_decimal.toChainFormat;
|
|
71
|
+
exports.toCosmosSdkDecString = require_decimal.toCosmosSdkDecString;
|
|
72
|
+
exports.toPageRequest = require_tx$1.toPageRequest;
|
|
73
|
+
exports.toPagination = require_tx$1.toPagination;
|
package/dist/index.d.cts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/** What a trader reaches for, in one import. */
|
|
2
|
+
import { D as OrderType, E as OrderMask, I as SignDoc, L as SignMode, O as MarketStatus, T as ExecutionType, _ as EvmChainId, a as MsgCreateDerivativeLimitOrder, c as MsgSubaccountTransfer, d as MsgCreateSpotLimitOrder, f as MsgCancelSpotOrder, g as ChainId, i as MsgCreateDerivativeMarketOrder, k as BroadcastMode, l as MsgDeposit, m as MsgSend, n as MsgBatchCancelDerivativeOrders, o as MsgWithdraw, p as MsgBatchCancelSpotOrders, r as MsgCancelDerivativeOrder, s as MsgExternalTransfer, t as MsgIncreasePositionMargin, u as MsgCreateSpotMarketOrder, v as OrderSide } from "./MsgIncreasePositionMargin-UQn6vCje.cjs";
|
|
3
|
+
import { n as Eip712TypedDataField, t as Eip712TypedData } from "./eip712-88KVCEnw.cjs";
|
|
4
|
+
import { a as TxRaw, c as PaginationOption, i as StdFee, n as CreateTransactionResult, o as Msg, r as SignerDetails, s as Pagination, t as CreateTransactionParams } from "./tx-CCt0zqng.cjs";
|
|
5
|
+
import { ApiError } from "./types.cjs";
|
|
6
|
+
import { i as StreamState, n as StreamDisconnectReason, r as StreamManagerRetryConfig, t as EventTypes } from "./stream-BgKRWG60.cjs";
|
|
7
|
+
import "./msgs.cjs";
|
|
8
|
+
import { a as ChainAuthZApiClient, i as ChainBankApiClient, n as ChainTendermintApiClient, o as ChainAuthApiClient, r as ChainExchangeApiClient, t as ChainTxApiClient } from "./index-BT_zyZW9.cjs";
|
|
9
|
+
import { a as IndexerAccountsStreamClient, c as IndexerPortfolioApiClient, d as IndexerArchiverApiClient, f as IndexerAccountsApiClient, i as IndexerDerivativesStreamClient, l as IndexerOracleApiClient, n as IndexerPortfolioStreamClient, o as StreamManager, r as IndexerOracleStreamClient, s as IndexerSpotApiClient, t as IndexerSpotStreamClient, u as IndexerDerivativesApiClient } from "./index-B3bDzB4S.cjs";
|
|
10
|
+
import { a as sanitizeBlock, c as toPagination, d as hexToBytes, f as getEip712TypedDataV2, g as getInjectiveAddress, h as getEthereumAddress, i as createWeb3Extension, l as bytesToHex, m as toCosmosSdkDecString, n as createTxBytes, o as sanitizeLatestBlock, p as toChainFormat, r as createTxRawEIP712, s as toPageRequest, t as createTransaction, u as hexToBase64 } from "./index-BPpDV6JA.cjs";
|
|
11
|
+
export { ApiError, BroadcastMode, ChainAuthApiClient, ChainAuthZApiClient, ChainBankApiClient, ChainExchangeApiClient, ChainId, ChainTendermintApiClient, ChainTxApiClient, CreateTransactionParams, CreateTransactionResult, Eip712TypedData, Eip712TypedDataField, EventTypes, EvmChainId, ExecutionType, IndexerAccountsApiClient, IndexerAccountsStreamClient, IndexerArchiverApiClient, IndexerDerivativesApiClient, IndexerDerivativesStreamClient, IndexerOracleApiClient, IndexerOracleStreamClient, IndexerPortfolioApiClient, IndexerPortfolioStreamClient, IndexerSpotApiClient, IndexerSpotStreamClient, MarketStatus, Msg, MsgBatchCancelDerivativeOrders, MsgBatchCancelSpotOrders, MsgCancelDerivativeOrder, MsgCancelSpotOrder, MsgCreateDerivativeLimitOrder, MsgCreateDerivativeMarketOrder, MsgCreateSpotLimitOrder, MsgCreateSpotMarketOrder, MsgDeposit, MsgExternalTransfer, MsgIncreasePositionMargin, MsgSend, MsgSubaccountTransfer, MsgWithdraw, OrderMask, OrderSide, OrderType, Pagination, PaginationOption, type SignDoc, SignMode, SignerDetails, StdFee, StreamDisconnectReason, StreamManager, StreamManagerRetryConfig, StreamState, TxRaw, bytesToHex, createTransaction, createTxBytes, createTxRawEIP712, createWeb3Extension, getEip712TypedDataV2, getEthereumAddress, getInjectiveAddress, hexToBase64, hexToBytes, sanitizeBlock, sanitizeLatestBlock, toChainFormat, toCosmosSdkDecString, toPageRequest, toPagination };
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/** What a trader reaches for, in one import. */
|
|
2
|
+
import { B as OrderMask, H as MarketStatus, M as OrderSide, T as SignMode, V as OrderType, _ as BroadcastMode, a as MsgCreateDerivativeLimitOrder, c as MsgSubaccountTransfer, d as MsgCreateSpotLimitOrder, f as MsgCancelSpotOrder, g as EvmChainId, h as ChainId, i as MsgCreateDerivativeMarketOrder, l as MsgDeposit, m as MsgSend, n as MsgBatchCancelDerivativeOrders, o as MsgWithdraw, p as MsgBatchCancelSpotOrders, r as MsgCancelDerivativeOrder, s as MsgExternalTransfer, t as MsgIncreasePositionMargin, u as MsgCreateSpotMarketOrder, w as SignDoc, z as ExecutionType } from "./MsgIncreasePositionMargin-7_g04vle.js";
|
|
3
|
+
import { ApiError } from "./types.js";
|
|
4
|
+
import { a as TxRaw, c as PaginationOption, i as StdFee, n as CreateTransactionResult, o as Msg, r as SignerDetails, s as Pagination, t as CreateTransactionParams } from "./tx-BRaw1C6e.js";
|
|
5
|
+
import "./msgs.js";
|
|
6
|
+
import { i as StreamState, n as StreamDisconnectReason, r as StreamManagerRetryConfig, t as EventTypes } from "./stream-BgKRWG60.js";
|
|
7
|
+
import { n as Eip712TypedDataField, t as Eip712TypedData } from "./eip712-88KVCEnw.js";
|
|
8
|
+
import { a as ChainAuthZApiClient, i as ChainBankApiClient, n as ChainTendermintApiClient, o as ChainAuthApiClient, r as ChainExchangeApiClient, t as ChainTxApiClient } from "./index-BHLUinQA.js";
|
|
9
|
+
import { a as IndexerAccountsStreamClient, c as IndexerPortfolioApiClient, d as IndexerArchiverApiClient, f as IndexerAccountsApiClient, i as IndexerDerivativesStreamClient, l as IndexerOracleApiClient, n as IndexerPortfolioStreamClient, o as StreamManager, r as IndexerOracleStreamClient, s as IndexerSpotApiClient, t as IndexerSpotStreamClient, u as IndexerDerivativesApiClient } from "./index-DcQT-y4U.js";
|
|
10
|
+
import { a as sanitizeBlock, c as toPagination, d as hexToBytes, f as getEip712TypedDataV2, g as getInjectiveAddress, h as getEthereumAddress, i as createWeb3Extension, l as bytesToHex, m as toCosmosSdkDecString, n as createTxBytes, o as sanitizeLatestBlock, p as toChainFormat, r as createTxRawEIP712, s as toPageRequest, t as createTransaction, u as hexToBase64 } from "./index-DfoLUPEo.js";
|
|
11
|
+
export { ApiError, BroadcastMode, ChainAuthApiClient, ChainAuthZApiClient, ChainBankApiClient, ChainExchangeApiClient, ChainId, ChainTendermintApiClient, ChainTxApiClient, CreateTransactionParams, CreateTransactionResult, Eip712TypedData, Eip712TypedDataField, EventTypes, EvmChainId, ExecutionType, IndexerAccountsApiClient, IndexerAccountsStreamClient, IndexerArchiverApiClient, IndexerDerivativesApiClient, IndexerDerivativesStreamClient, IndexerOracleApiClient, IndexerOracleStreamClient, IndexerPortfolioApiClient, IndexerPortfolioStreamClient, IndexerSpotApiClient, IndexerSpotStreamClient, MarketStatus, Msg, MsgBatchCancelDerivativeOrders, MsgBatchCancelSpotOrders, MsgCancelDerivativeOrder, MsgCancelSpotOrder, MsgCreateDerivativeLimitOrder, MsgCreateDerivativeMarketOrder, MsgCreateSpotLimitOrder, MsgCreateSpotMarketOrder, MsgDeposit, MsgExternalTransfer, MsgIncreasePositionMargin, MsgSend, MsgSubaccountTransfer, MsgWithdraw, OrderMask, OrderSide, OrderType, Pagination, PaginationOption, type SignDoc, SignMode, SignerDetails, StdFee, StreamDisconnectReason, StreamManager, StreamManagerRetryConfig, StreamState, TxRaw, bytesToHex, createTransaction, createTxBytes, createTxRawEIP712, createWeb3Extension, getEip712TypedDataV2, getEthereumAddress, getInjectiveAddress, hexToBase64, hexToBytes, sanitizeBlock, sanitizeLatestBlock, toChainFormat, toCosmosSdkDecString, toPageRequest, toPagination };
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { t as OrderSide, u as BroadcastMode } from "./query-DGTA8Lz_.js";
|
|
2
|
+
import { u as SignMode } from "./tx-GN0SFql2.js";
|
|
3
|
+
import { N as OrderMask, P as OrderType, U as MarketStatus, d as ExecutionType } from "./exchange-BPRx-kFI.js";
|
|
4
|
+
import { ChainId, EvmChainId } from "./types.js";
|
|
5
|
+
import { t as ApiError } from "./errors-MWG_E5zA.js";
|
|
6
|
+
import { n as StreamState, t as StreamDisconnectReason } from "./stream-RhVNTED5.js";
|
|
7
|
+
import { a as MsgDeposit, c as MsgCreateDerivativeMarketOrder, d as MsgCancelDerivativeOrder, f as MsgBatchCancelSpotOrders, i as MsgExternalTransfer, l as MsgCreateDerivativeLimitOrder, m as MsgSend, n as MsgSubaccountTransfer, o as MsgCreateSpotMarketOrder, p as MsgBatchCancelDerivativeOrders, r as MsgIncreasePositionMargin, s as MsgCreateSpotLimitOrder, t as MsgWithdraw, u as MsgCancelSpotOrder } from "./msgs-Bi5b52-R.js";
|
|
8
|
+
import { n as toCosmosSdkDecString, t as toChainFormat } from "./decimal-CIFXn110.js";
|
|
9
|
+
import { a as ChainAuthZApiClient, i as ChainBankApiClient, n as ChainTendermintApiClient, o as ChainAuthApiClient, r as ChainExchangeApiClient, t as ChainTxApiClient } from "./chain-CgjV0b1c.js";
|
|
10
|
+
import { a as sanitizeBlock, c as toPagination, i as createWeb3Extension, n as createTxBytes, o as sanitizeLatestBlock, r as createTxRawEIP712, s as toPageRequest, t as createTransaction } from "./tx-COcDYlg3.js";
|
|
11
|
+
import { a as IndexerAccountsStreamClient, c as IndexerPortfolioApiClient, d as IndexerArchiverApiClient, f as IndexerAccountsApiClient, i as IndexerDerivativesStreamClient, l as IndexerOracleApiClient, n as IndexerPortfolioStreamClient, o as StreamManager, r as IndexerOracleStreamClient, s as IndexerSpotApiClient, t as IndexerSpotStreamClient, u as IndexerDerivativesApiClient } from "./indexer-D7XfYsAZ.js";
|
|
12
|
+
import { bytesToHex, getEip712TypedDataV2, getEthereumAddress, getInjectiveAddress, hexToBase64, hexToBytes } from "./utils.js";
|
|
13
|
+
export { ApiError, BroadcastMode, ChainAuthApiClient, ChainAuthZApiClient, ChainBankApiClient, ChainExchangeApiClient, ChainId, ChainTendermintApiClient, ChainTxApiClient, EvmChainId, ExecutionType, IndexerAccountsApiClient, IndexerAccountsStreamClient, IndexerArchiverApiClient, IndexerDerivativesApiClient, IndexerDerivativesStreamClient, IndexerOracleApiClient, IndexerOracleStreamClient, IndexerPortfolioApiClient, IndexerPortfolioStreamClient, IndexerSpotApiClient, IndexerSpotStreamClient, MarketStatus, MsgBatchCancelDerivativeOrders, MsgBatchCancelSpotOrders, MsgCancelDerivativeOrder, MsgCancelSpotOrder, MsgCreateDerivativeLimitOrder, MsgCreateDerivativeMarketOrder, MsgCreateSpotLimitOrder, MsgCreateSpotMarketOrder, MsgDeposit, MsgExternalTransfer, MsgIncreasePositionMargin, MsgSend, MsgSubaccountTransfer, MsgWithdraw, OrderMask, OrderSide, OrderType, SignMode, StreamDisconnectReason, StreamManager, StreamState, bytesToHex, createTransaction, createTxBytes, createTxRawEIP712, createWeb3Extension, getEip712TypedDataV2, getEthereumAddress, getInjectiveAddress, hexToBase64, hexToBytes, sanitizeBlock, sanitizeLatestBlock, toChainFormat, toCosmosSdkDecString, toPageRequest, toPagination };
|