ault-sdk-ts 0.0.2-alpha.5

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.
Files changed (138) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +932 -0
  3. package/dist/agent/create-agent-client.d.ts +3 -0
  4. package/dist/agent/sign-and-broadcast.d.ts +38 -0
  5. package/dist/agent/tx/clob.d.ts +7 -0
  6. package/dist/agent/tx-executor.d.ts +17 -0
  7. package/dist/client.d.ts +61 -0
  8. package/dist/core/address.d.ts +14 -0
  9. package/dist/core/base64.d.ts +2 -0
  10. package/dist/core/clob-msgs.d.ts +33 -0
  11. package/dist/core/errors.d.ts +17 -0
  12. package/dist/core/http.d.ts +14 -0
  13. package/dist/core/network.d.ts +59 -0
  14. package/dist/core/pagination.d.ts +14 -0
  15. package/dist/core/query.d.ts +5 -0
  16. package/dist/core/with-status-fallback.d.ts +5 -0
  17. package/dist/eip712/builder.d.ts +45 -0
  18. package/dist/eip712/field-order.d.ts +2 -0
  19. package/dist/eip712/msg-encoders.generated.d.ts +1 -0
  20. package/dist/eip712/msg.generated.d.ts +109 -0
  21. package/dist/eip712/registry.d.ts +36 -0
  22. package/dist/eip712/registry.generated.d.ts +2 -0
  23. package/dist/eip712/sign-and-broadcast.d.ts +55 -0
  24. package/dist/eip712/signers.d.ts +83 -0
  25. package/dist/eip712/types.d.ts +58 -0
  26. package/dist/high-level/address-utils.d.ts +2 -0
  27. package/dist/high-level/create-client.d.ts +26 -0
  28. package/dist/high-level/query-helpers.d.ts +3 -0
  29. package/dist/high-level/signer.d.ts +6 -0
  30. package/dist/high-level/tx/agent.d.ts +3 -0
  31. package/dist/high-level/tx/authority.d.ts +3 -0
  32. package/dist/high-level/tx/clob.d.ts +3 -0
  33. package/dist/high-level/tx/context.d.ts +5 -0
  34. package/dist/high-level/tx/license.d.ts +3 -0
  35. package/dist/high-level/tx/market.d.ts +3 -0
  36. package/dist/high-level/tx/miner.d.ts +3 -0
  37. package/dist/high-level/tx/ratelimit.d.ts +3 -0
  38. package/dist/high-level/tx/reward.d.ts +3 -0
  39. package/dist/high-level/tx/staking.d.ts +3 -0
  40. package/dist/high-level/tx/tokenregistry.d.ts +3 -0
  41. package/dist/high-level/tx-executor.d.ts +18 -0
  42. package/dist/high-level/types.d.ts +477 -0
  43. package/dist/high-level-client.d.ts +2 -0
  44. package/dist/index.cjs +18434 -0
  45. package/dist/index.cjs.map +1 -0
  46. package/dist/index.d.ts +38 -0
  47. package/dist/index.js +18162 -0
  48. package/dist/index.js.map +1 -0
  49. package/dist/proto/duration-json.d.ts +6 -0
  50. package/dist/proto/gen/amino/amino.d.ts +1 -0
  51. package/dist/proto/gen/ault/agent/v1/agent.d.ts +63 -0
  52. package/dist/proto/gen/ault/agent/v1/genesis.d.ts +44 -0
  53. package/dist/proto/gen/ault/agent/v1/params.d.ts +42 -0
  54. package/dist/proto/gen/ault/agent/v1/query.d.ts +73 -0
  55. package/dist/proto/gen/ault/agent/v1/tx.d.ts +91 -0
  56. package/dist/proto/gen/ault/authority/v1/authority.d.ts +15 -0
  57. package/dist/proto/gen/ault/authority/v1/genesis.d.ts +36 -0
  58. package/dist/proto/gen/ault/authority/v1/query.d.ts +53 -0
  59. package/dist/proto/gen/ault/authority/v1/tx.d.ts +50 -0
  60. package/dist/proto/gen/ault/clob/v1/fee.d.ts +37 -0
  61. package/dist/proto/gen/ault/clob/v1/genesis.d.ts +56 -0
  62. package/dist/proto/gen/ault/clob/v1/order_book.d.ts +32 -0
  63. package/dist/proto/gen/ault/clob/v1/params.d.ts +29 -0
  64. package/dist/proto/gen/ault/clob/v1/query.d.ts +56 -0
  65. package/dist/proto/gen/ault/clob/v1/tx.d.ts +116 -0
  66. package/dist/proto/gen/ault/license/v1/genesis.d.ts +140 -0
  67. package/dist/proto/gen/ault/license/v1/license.d.ts +151 -0
  68. package/dist/proto/gen/ault/license/v1/query.d.ts +273 -0
  69. package/dist/proto/gen/ault/license/v1/tx.d.ts +227 -0
  70. package/dist/proto/gen/ault/market/v1/genesis.d.ts +28 -0
  71. package/dist/proto/gen/ault/market/v1/market.d.ts +66 -0
  72. package/dist/proto/gen/ault/market/v1/params.d.ts +34 -0
  73. package/dist/proto/gen/ault/market/v1/query.d.ts +48 -0
  74. package/dist/proto/gen/ault/market/v1/tx.d.ts +87 -0
  75. package/dist/proto/gen/ault/miner/v1/genesis.d.ts +166 -0
  76. package/dist/proto/gen/ault/miner/v1/miner.d.ts +232 -0
  77. package/dist/proto/gen/ault/miner/v1/query.d.ts +254 -0
  78. package/dist/proto/gen/ault/miner/v1/tx.d.ts +207 -0
  79. package/dist/proto/gen/ault/ratelimit/v1/genesis.d.ts +27 -0
  80. package/dist/proto/gen/ault/ratelimit/v1/params.d.ts +35 -0
  81. package/dist/proto/gen/ault/ratelimit/v1/query.d.ts +42 -0
  82. package/dist/proto/gen/ault/ratelimit/v1/tx.d.ts +32 -0
  83. package/dist/proto/gen/ault/reward/v1/genesis.d.ts +67 -0
  84. package/dist/proto/gen/ault/reward/v1/query.d.ts +93 -0
  85. package/dist/proto/gen/ault/reward/v1/reward.d.ts +53 -0
  86. package/dist/proto/gen/ault/reward/v1/tx.d.ts +120 -0
  87. package/dist/proto/gen/ault/spot/v1/genesis.d.ts +26 -0
  88. package/dist/proto/gen/ault/spot/v1/order.d.ts +66 -0
  89. package/dist/proto/gen/ault/tokenregistry/v1/genesis.d.ts +34 -0
  90. package/dist/proto/gen/ault/tokenregistry/v1/query.d.ts +77 -0
  91. package/dist/proto/gen/ault/tokenregistry/v1/tokenregistry.d.ts +118 -0
  92. package/dist/proto/gen/ault/tokenregistry/v1/tx.d.ts +132 -0
  93. package/dist/proto/gen/cosmos/base/query/v1beta1/pagination.d.ts +82 -0
  94. package/dist/proto/gen/cosmos/base/v1beta1/coin.d.ts +59 -0
  95. package/dist/proto/gen/cosmos/distribution/v1beta1/distribution.d.ts +162 -0
  96. package/dist/proto/gen/cosmos/distribution/v1beta1/tx.d.ts +140 -0
  97. package/dist/proto/gen/cosmos/msg/v1/msg.d.ts +1 -0
  98. package/dist/proto/gen/cosmos/staking/v1beta1/staking.d.ts +310 -0
  99. package/dist/proto/gen/cosmos/staking/v1beta1/tx.d.ts +144 -0
  100. package/dist/proto/gen/cosmos_proto/cosmos.d.ts +80 -0
  101. package/dist/proto/gen/gogoproto/gogo.d.ts +1 -0
  102. package/dist/proto/gen/google/api/annotations.d.ts +1 -0
  103. package/dist/proto/gen/google/api/http.d.ts +379 -0
  104. package/dist/proto/gen/google/protobuf/any.d.ts +144 -0
  105. package/dist/proto/gen/google/protobuf/descriptor.d.ts +1285 -0
  106. package/dist/proto/gen/google/protobuf/duration.d.ts +99 -0
  107. package/dist/proto/gen/google/protobuf/timestamp.d.ts +128 -0
  108. package/dist/proto/gen/tendermint/abci/types.d.ts +507 -0
  109. package/dist/proto/gen/tendermint/crypto/keys.d.ts +27 -0
  110. package/dist/proto/gen/tendermint/crypto/proof.d.ts +57 -0
  111. package/dist/proto/gen/tendermint/types/params.d.ts +112 -0
  112. package/dist/proto/gen/tendermint/types/types.d.ts +197 -0
  113. package/dist/proto/gen/tendermint/types/validator.d.ts +54 -0
  114. package/dist/proto/gen/tendermint/version/types.d.ts +41 -0
  115. package/dist/proto/tx-encode.d.ts +78 -0
  116. package/dist/rest/agent.d.ts +12 -0
  117. package/dist/rest/authority.d.ts +12 -0
  118. package/dist/rest/clob.d.ts +11 -0
  119. package/dist/rest/context.d.ts +22 -0
  120. package/dist/rest/dex-fetcher.d.ts +10 -0
  121. package/dist/rest/dex-types.generated.d.ts +780 -0
  122. package/dist/rest/dex.d.ts +34 -0
  123. package/dist/rest/dex.generated.d.ts +1381 -0
  124. package/dist/rest/license.d.ts +79 -0
  125. package/dist/rest/market.d.ts +11 -0
  126. package/dist/rest/miner.d.ts +59 -0
  127. package/dist/rest/ratelimit.d.ts +7 -0
  128. package/dist/rest/reward.d.ts +25 -0
  129. package/dist/rest/staking.d.ts +38 -0
  130. package/dist/rest/tokenregistry.d.ts +11 -0
  131. package/dist/rest/types.d.ts +871 -0
  132. package/dist/utils/address.d.ts +6 -0
  133. package/dist/utils/chain-id.d.ts +1 -0
  134. package/dist/utils/cosmos-dec.d.ts +2 -0
  135. package/dist/ws/client.d.ts +37 -0
  136. package/dist/ws/index.d.ts +5 -0
  137. package/dist/ws/types.d.ts +66 -0
  138. package/package.json +103 -0
@@ -0,0 +1,1381 @@
1
+ export type HealthResponseStatus = (typeof HealthResponseStatus)[keyof typeof HealthResponseStatus];
2
+ export declare const HealthResponseStatus: {
3
+ readonly healthy: "healthy";
4
+ readonly unhealthy: "unhealthy";
5
+ };
6
+ export type HealthResponseDatabase = (typeof HealthResponseDatabase)[keyof typeof HealthResponseDatabase];
7
+ export declare const HealthResponseDatabase: {
8
+ readonly ok: "ok";
9
+ readonly unreachable: "unreachable";
10
+ };
11
+ export interface HealthResponse {
12
+ status: HealthResponseStatus;
13
+ database: HealthResponseDatabase;
14
+ }
15
+ export type ReadyResponseStatus = (typeof ReadyResponseStatus)[keyof typeof ReadyResponseStatus];
16
+ export declare const ReadyResponseStatus: {
17
+ readonly ready: "ready";
18
+ readonly not_ready: "not ready";
19
+ };
20
+ export interface ReadyResponse {
21
+ status: ReadyResponseStatus;
22
+ }
23
+ export type LiveResponseStatus = (typeof LiveResponseStatus)[keyof typeof LiveResponseStatus];
24
+ export declare const LiveResponseStatus: {
25
+ readonly alive: "alive";
26
+ };
27
+ export interface LiveResponse {
28
+ status: LiveResponseStatus;
29
+ }
30
+ export interface StatusResponse {
31
+ last_indexed_height: number;
32
+ last_indexed_at: string;
33
+ }
34
+ export type MarketResponseType = (typeof MarketResponseType)[keyof typeof MarketResponseType];
35
+ export declare const MarketResponseType: {
36
+ readonly spot: "spot";
37
+ };
38
+ export type MarketResponseInfo = {
39
+ [key: string]: unknown;
40
+ };
41
+ export interface MarketPrecision {
42
+ amount?: number;
43
+ price?: number;
44
+ cost?: number;
45
+ }
46
+ export interface MinMax {
47
+ /** @nullable */
48
+ min?: number | null;
49
+ /** @nullable */
50
+ max?: number | null;
51
+ }
52
+ export interface MarketLimits {
53
+ leverage?: MinMax;
54
+ amount?: MinMax;
55
+ price?: MinMax;
56
+ cost?: MinMax;
57
+ }
58
+ export interface MarketResponse {
59
+ id: string;
60
+ symbol: string;
61
+ base: string;
62
+ quote: string;
63
+ /** On-chain denom */
64
+ baseId: string;
65
+ quoteId: string;
66
+ active: boolean;
67
+ type: MarketResponseType;
68
+ spot: boolean;
69
+ margin?: boolean;
70
+ future?: boolean;
71
+ swap?: boolean;
72
+ option?: boolean;
73
+ contract?: boolean;
74
+ /** @nullable */
75
+ settle?: string | null;
76
+ /** @nullable */
77
+ settleId?: string | null;
78
+ /** @nullable */
79
+ contractSize?: number | null;
80
+ /** @nullable */
81
+ linear?: boolean | null;
82
+ /** @nullable */
83
+ inverse?: boolean | null;
84
+ /** @nullable */
85
+ expiry?: number | null;
86
+ /** @nullable */
87
+ expiryDatetime?: string | null;
88
+ /** @nullable */
89
+ strike?: number | null;
90
+ /** @nullable */
91
+ optionType?: string | null;
92
+ feeSide?: string;
93
+ /** Taker fee rate */
94
+ taker: number;
95
+ /** Maker fee rate */
96
+ maker: number;
97
+ percentage?: boolean;
98
+ tierBased?: boolean;
99
+ precision: MarketPrecision;
100
+ limits: MarketLimits;
101
+ /** @nullable */
102
+ created?: number | null;
103
+ info: MarketResponseInfo;
104
+ }
105
+ export type CurrencyResponseLimits = {
106
+ amount?: MinMax;
107
+ withdraw?: MinMax;
108
+ };
109
+ export type CurrencyResponseNetworks = {
110
+ [key: string]: unknown;
111
+ };
112
+ export type CurrencyResponseInfo = {
113
+ [key: string]: unknown;
114
+ };
115
+ export interface CurrencyResponse {
116
+ /** On-chain denom */
117
+ id: string;
118
+ /** Ticker symbol */
119
+ code: string;
120
+ /** @nullable */
121
+ name?: string | null;
122
+ active: boolean;
123
+ /** @nullable */
124
+ deposit?: boolean | null;
125
+ /** @nullable */
126
+ withdraw?: boolean | null;
127
+ /** @nullable */
128
+ fee?: number | null;
129
+ precision: number;
130
+ limits: CurrencyResponseLimits;
131
+ networks?: CurrencyResponseNetworks;
132
+ info: CurrencyResponseInfo;
133
+ }
134
+ export type TradingFeeResponseInfo = {
135
+ [key: string]: unknown;
136
+ };
137
+ export interface TradingFeeResponse {
138
+ symbol: string;
139
+ /** Maker fee rate */
140
+ maker: number;
141
+ /** Taker fee rate */
142
+ taker: number;
143
+ percentage: boolean;
144
+ tierBased: boolean;
145
+ info: TradingFeeResponseInfo;
146
+ }
147
+ export type TickerResponseInfo = {
148
+ [key: string]: unknown;
149
+ };
150
+ export interface TickerResponse {
151
+ symbol: string;
152
+ /** @nullable */
153
+ high?: number | null;
154
+ /** @nullable */
155
+ low?: number | null;
156
+ /** @nullable */
157
+ bid?: number | null;
158
+ /**
159
+ * Volume at the best bid price level. Extracted from the orderbook snapshot.
160
+ * @nullable
161
+ */
162
+ bidVolume?: number | null;
163
+ /** @nullable */
164
+ ask?: number | null;
165
+ /**
166
+ * Volume at the best ask price level. Extracted from the orderbook snapshot.
167
+ * @nullable
168
+ */
169
+ askVolume?: number | null;
170
+ /**
171
+ * Volume-weighted average price: quoteVolume / baseVolume
172
+ * @nullable
173
+ */
174
+ vwap?: number | null;
175
+ /** @nullable */
176
+ open?: number | null;
177
+ /** @nullable */
178
+ close?: number | null;
179
+ /** @nullable */
180
+ last?: number | null;
181
+ /**
182
+ * Close price of the last bar before the 24h window.
183
+ * @nullable
184
+ */
185
+ previousClose?: number | null;
186
+ /** @nullable */
187
+ change?: number | null;
188
+ /** @nullable */
189
+ percentage?: number | null;
190
+ /**
191
+ * Simple average: (open + close) / 2
192
+ * @nullable
193
+ */
194
+ average?: number | null;
195
+ baseVolume: number;
196
+ /** @nullable */
197
+ quoteVolume?: number | null;
198
+ /** Milliseconds */
199
+ timestamp: number;
200
+ datetime: string;
201
+ info: TickerResponseInfo;
202
+ }
203
+ export interface OrderbookResponse {
204
+ symbol: string;
205
+ bids: number[][];
206
+ asks: number[][];
207
+ timestamp: number;
208
+ datetime: string;
209
+ nonce: number;
210
+ }
211
+ /**
212
+ * Order type resolved via JOIN to orders table. Null if order not found.
213
+ * @nullable
214
+ */
215
+ export type TradeResponseType = (typeof TradeResponseType)[keyof typeof TradeResponseType] | null;
216
+ export declare const TradeResponseType: {
217
+ readonly limit: "limit";
218
+ readonly market: "market";
219
+ };
220
+ export type TradeResponseSide = (typeof TradeResponseSide)[keyof typeof TradeResponseSide];
221
+ export declare const TradeResponseSide: {
222
+ readonly buy: "buy";
223
+ readonly sell: "sell";
224
+ };
225
+ /**
226
+ * Always 'taker' — on-chain DEX treats all executed trades as taker fills.
227
+ */
228
+ export type TradeResponseTakerOrMaker = (typeof TradeResponseTakerOrMaker)[keyof typeof TradeResponseTakerOrMaker];
229
+ export declare const TradeResponseTakerOrMaker: {
230
+ readonly taker: "taker";
231
+ };
232
+ /**
233
+ * Estimated fee for the trade: cost = amount * price * taker_fee_rate
234
+ */
235
+ export type TradeResponseFee = {
236
+ /** Fee cost in quote currency */
237
+ cost?: number;
238
+ /** Quote currency ticker (e.g., "USDT") */
239
+ currency?: string;
240
+ /** Taker fee rate from the market */
241
+ rate?: number;
242
+ };
243
+ export type TradeResponseInfo = {
244
+ [key: string]: unknown;
245
+ };
246
+ export interface TradeResponse {
247
+ id: string;
248
+ /** @nullable */
249
+ order?: string | null;
250
+ timestamp: number;
251
+ datetime: string;
252
+ symbol: string;
253
+ /**
254
+ * Order type resolved via JOIN to orders table. Null if order not found.
255
+ * @nullable
256
+ */
257
+ type?: TradeResponseType;
258
+ side: TradeResponseSide;
259
+ /** Always 'taker' — on-chain DEX treats all executed trades as taker fills. */
260
+ takerOrMaker?: TradeResponseTakerOrMaker;
261
+ price: number;
262
+ amount: number;
263
+ /** price * amount */
264
+ cost: number;
265
+ /** Estimated fee for the trade: cost = amount * price * taker_fee_rate */
266
+ fee?: TradeResponseFee;
267
+ info: TradeResponseInfo;
268
+ }
269
+ export type OrderResponseStatus = (typeof OrderResponseStatus)[keyof typeof OrderResponseStatus];
270
+ export declare const OrderResponseStatus: {
271
+ readonly open: "open";
272
+ readonly closed: "closed";
273
+ readonly canceled: "canceled";
274
+ };
275
+ export type OrderResponseType = (typeof OrderResponseType)[keyof typeof OrderResponseType];
276
+ export declare const OrderResponseType: {
277
+ readonly limit: "limit";
278
+ readonly market: "market";
279
+ };
280
+ export type OrderResponseSide = (typeof OrderResponseSide)[keyof typeof OrderResponseSide];
281
+ export declare const OrderResponseSide: {
282
+ readonly buy: "buy";
283
+ readonly sell: "sell";
284
+ };
285
+ export type OrderResponseTradesItem = {
286
+ [key: string]: unknown;
287
+ };
288
+ /**
289
+ * Estimated fee for the order: cost = filled * price * taker_fee_rate
290
+ */
291
+ export type OrderResponseFee = {
292
+ /** Fee cost in quote currency */
293
+ cost?: number;
294
+ /** Quote currency ticker (e.g., "USDT") */
295
+ currency?: string;
296
+ /** Fee rate from the market */
297
+ rate?: number;
298
+ };
299
+ export type OrderResponseInfo = {
300
+ [key: string]: unknown;
301
+ };
302
+ export interface OrderResponse {
303
+ id: string;
304
+ /**
305
+ * Always null — not applicable for on-chain DEX orders.
306
+ * @nullable
307
+ */
308
+ clientOrderId?: string | null;
309
+ timestamp: number;
310
+ datetime: string;
311
+ /**
312
+ * Timestamp (ms) of the last trade executed against this order. Null if no trades.
313
+ * @nullable
314
+ */
315
+ lastTradeTimestamp?: number | null;
316
+ status: OrderResponseStatus;
317
+ symbol: string;
318
+ type: OrderResponseType;
319
+ /** @nullable */
320
+ timeInForce?: string | null;
321
+ side: OrderResponseSide;
322
+ price: number;
323
+ /**
324
+ * Average execution price: cost / filled. Null when filled is 0.
325
+ * @nullable
326
+ */
327
+ average?: number | null;
328
+ amount: number;
329
+ filled: number;
330
+ remaining: number;
331
+ /** filled * price */
332
+ cost: number;
333
+ trades?: OrderResponseTradesItem[];
334
+ /** Estimated fee for the order: cost = filled * price * taker_fee_rate */
335
+ fee?: OrderResponseFee;
336
+ reduceOnly?: boolean;
337
+ postOnly?: boolean;
338
+ /** @nullable */
339
+ stopPrice?: number | null;
340
+ /** @nullable */
341
+ triggerPrice?: number | null;
342
+ info: OrderResponseInfo;
343
+ }
344
+ export type BalancesResponseFree = {
345
+ [key: string]: number;
346
+ };
347
+ export type BalancesResponseUsed = {
348
+ [key: string]: number;
349
+ };
350
+ export type BalancesResponseTotal = {
351
+ [key: string]: number;
352
+ };
353
+ export type BalancesResponseInfo = {
354
+ [key: string]: unknown;
355
+ };
356
+ /**
357
+ * Balance object. Contains `free`, `used`, `total` dictionaries
358
+ (currency code -> number), plus per-currency entries with {free, used, total},
359
+ and `info`, `timestamp`, `datetime`.
360
+
361
+ */
362
+ export interface BalancesResponse {
363
+ free: BalancesResponseFree;
364
+ used: BalancesResponseUsed;
365
+ total: BalancesResponseTotal;
366
+ /** @nullable */
367
+ timestamp?: number | null;
368
+ /** @nullable */
369
+ datetime?: string | null;
370
+ info: BalancesResponseInfo;
371
+ }
372
+ /**
373
+ * [timestamp_ms, open, high, low, close, volume]
374
+ * @minItems 6
375
+ * @maxItems 6
376
+ */
377
+ export type OHLCVEntry = number[];
378
+ export interface UDFExchange {
379
+ value: string;
380
+ name: string;
381
+ desc: string;
382
+ }
383
+ export interface UDFSymbolType {
384
+ name: string;
385
+ value: string;
386
+ }
387
+ export interface UDFConfig {
388
+ supports_search: boolean;
389
+ supports_group_request: boolean;
390
+ supports_marks: boolean;
391
+ supports_timescale_marks: boolean;
392
+ supports_time: boolean;
393
+ supported_resolutions: string[];
394
+ exchanges: UDFExchange[];
395
+ symbols_types: UDFSymbolType[];
396
+ }
397
+ /**
398
+ * Data feed status
399
+ */
400
+ export type UDFSymbolInfoDataStatus = (typeof UDFSymbolInfoDataStatus)[keyof typeof UDFSymbolInfoDataStatus];
401
+ export declare const UDFSymbolInfoDataStatus: {
402
+ readonly streaming: "streaming";
403
+ readonly endofday: "endofday";
404
+ readonly pulsed: "pulsed";
405
+ readonly delayed_streaming: "delayed_streaming";
406
+ };
407
+ export interface UDFSymbolInfo {
408
+ name: string;
409
+ ticker: string;
410
+ description: string;
411
+ type: string;
412
+ session: string;
413
+ exchange: string;
414
+ listed_exchange: string;
415
+ timezone: string;
416
+ minmov: number;
417
+ pricescale: number;
418
+ has_intraday: boolean;
419
+ has_daily: boolean;
420
+ /** Whether the symbol has volume data */
421
+ has_no_volume: boolean;
422
+ /** Number of decimal places for volume */
423
+ volume_precision: number;
424
+ /** Data feed status */
425
+ data_status: UDFSymbolInfoDataStatus;
426
+ /** Quote currency code */
427
+ currency_code: string;
428
+ supported_resolutions: string[];
429
+ }
430
+ export type UDFHistoryResponseS = (typeof UDFHistoryResponseS)[keyof typeof UDFHistoryResponseS];
431
+ export declare const UDFHistoryResponseS: {
432
+ readonly ok: "ok";
433
+ readonly no_data: "no_data";
434
+ readonly error: "error";
435
+ };
436
+ export interface UDFHistoryResponse {
437
+ s: UDFHistoryResponseS;
438
+ /** Error message (present only when s = "error") */
439
+ errmsg?: string;
440
+ t?: number[];
441
+ o?: number[];
442
+ h?: number[];
443
+ l?: number[];
444
+ c?: number[];
445
+ v?: number[];
446
+ /** Unix seconds of next available bar (when s = "no_data") */
447
+ nextTime?: number;
448
+ }
449
+ export interface UDFSearchResult {
450
+ symbol: string;
451
+ full_name: string;
452
+ description: string;
453
+ exchange: string;
454
+ ticker: string;
455
+ type: string;
456
+ }
457
+ export type UDFQuotesResponseS = (typeof UDFQuotesResponseS)[keyof typeof UDFQuotesResponseS];
458
+ export declare const UDFQuotesResponseS: {
459
+ readonly ok: "ok";
460
+ readonly error: "error";
461
+ };
462
+ /**
463
+ * Per-symbol status
464
+ */
465
+ export type UDFQuoteDataS = (typeof UDFQuoteDataS)[keyof typeof UDFQuoteDataS];
466
+ export declare const UDFQuoteDataS: {
467
+ readonly ok: "ok";
468
+ readonly error: "error";
469
+ };
470
+ export interface UDFQuoteValues {
471
+ /**
472
+ * Price change
473
+ * @nullable
474
+ */
475
+ ch?: number | null;
476
+ /**
477
+ * Change percentage
478
+ * @nullable
479
+ */
480
+ chp?: number | null;
481
+ short_name?: string;
482
+ exchange?: string;
483
+ description?: string;
484
+ /**
485
+ * Last price
486
+ * @nullable
487
+ */
488
+ lp?: number | null;
489
+ /** @nullable */
490
+ ask?: number | null;
491
+ /** @nullable */
492
+ bid?: number | null;
493
+ /** @nullable */
494
+ open_price?: number | null;
495
+ /** @nullable */
496
+ high_price?: number | null;
497
+ /** @nullable */
498
+ low_price?: number | null;
499
+ /** @nullable */
500
+ prev_close_price?: number | null;
501
+ /** @nullable */
502
+ volume?: number | null;
503
+ }
504
+ export interface UDFQuoteData {
505
+ /** Per-symbol status */
506
+ s: UDFQuoteDataS;
507
+ /** Full symbol name */
508
+ n: string;
509
+ v: UDFQuoteValues;
510
+ }
511
+ export interface UDFQuotesResponse {
512
+ s: UDFQuotesResponseS;
513
+ errmsg?: string;
514
+ d: UDFQuoteData[];
515
+ }
516
+ export interface UDFMarksResponse {
517
+ id: number[];
518
+ time: number[];
519
+ color: string[];
520
+ text: string[];
521
+ label: string[];
522
+ labelFontColor: string[];
523
+ minSize: number[];
524
+ }
525
+ export interface UDFTimescaleMark {
526
+ id: number;
527
+ time: number;
528
+ color: string;
529
+ /** Single character displayed in a circle */
530
+ label: string;
531
+ tooltip: string;
532
+ }
533
+ export type ErrorResponseError = {
534
+ code: string;
535
+ message: string;
536
+ };
537
+ export interface ErrorResponse {
538
+ error: ErrorResponseError;
539
+ }
540
+ /**
541
+ * Bad request
542
+ */
543
+ export type BadRequestResponse = ErrorResponse;
544
+ /**
545
+ * Internal server error
546
+ */
547
+ export type InternalErrorResponse = ErrorResponse;
548
+ /**
549
+ * Rate limit exceeded
550
+ */
551
+ export type RateLimitedResponse = ErrorResponse;
552
+ export type ListCurrencies200 = {
553
+ [key: string]: CurrencyResponse;
554
+ };
555
+ export type GetAllTickers200 = {
556
+ [key: string]: TickerResponse;
557
+ };
558
+ export type GetOrderbookParams = {
559
+ /**
560
+ * @minimum 1
561
+ */
562
+ limit?: number;
563
+ };
564
+ export type ListTradesParams = {
565
+ /**
566
+ * @minimum 1
567
+ * @maximum 500
568
+ */
569
+ limit?: number;
570
+ /**
571
+ * Unix timestamp in milliseconds
572
+ */
573
+ since?: number;
574
+ };
575
+ export type GetTradingFees200 = {
576
+ [key: string]: TradingFeeResponse;
577
+ };
578
+ export type ListOrdersParams = {
579
+ /**
580
+ * Blockchain address of the account
581
+ */
582
+ address: string;
583
+ status?: ListOrdersStatus;
584
+ /**
585
+ * Symbol to filter by (e.g., AULT/USDT). Alternative to market_id.
586
+ */
587
+ symbol?: string;
588
+ /**
589
+ * Hex-encoded binary market ID to filter by. Takes precedence over symbol.
590
+ * @pattern ^[0-9a-fA-F]+$
591
+ */
592
+ market_id?: string;
593
+ /**
594
+ * Return orders created after this Unix timestamp (milliseconds)
595
+ */
596
+ since?: number;
597
+ /**
598
+ * @minimum 1
599
+ * @maximum 200
600
+ */
601
+ limit?: number;
602
+ };
603
+ export type ListOrdersStatus = (typeof ListOrdersStatus)[keyof typeof ListOrdersStatus];
604
+ export declare const ListOrdersStatus: {
605
+ readonly open: "open";
606
+ readonly closed: "closed";
607
+ readonly canceled: "canceled";
608
+ };
609
+ export type ListMyTradesParams = {
610
+ /**
611
+ * Blockchain address of the trader
612
+ */
613
+ address: string;
614
+ /**
615
+ * Symbol to filter by (e.g., AULT/USDT)
616
+ */
617
+ symbol?: string;
618
+ /**
619
+ * Unix timestamp in milliseconds
620
+ */
621
+ since?: number;
622
+ /**
623
+ * @minimum 1
624
+ * @maximum 500
625
+ */
626
+ limit?: number;
627
+ };
628
+ export type GetBalanceParams = {
629
+ address: string;
630
+ };
631
+ export type GetOHLCVParams = {
632
+ /**
633
+ * Timeframe: 1m, 5m, 15m, 30m, 1h, 4h, 1d. Also accepts TV format: 1, 5, 15, 60, 1D
634
+ */
635
+ timeframe?: string;
636
+ /**
637
+ * @minimum 1
638
+ * @maximum 1000
639
+ */
640
+ limit?: number;
641
+ /**
642
+ * Unix timestamp in milliseconds
643
+ */
644
+ since?: number;
645
+ };
646
+ export type GetUDFSymbolParams = {
647
+ symbol: string;
648
+ };
649
+ export type SearchUDFSymbolsParams = {
650
+ /**
651
+ * Text typed by the user in the search box
652
+ */
653
+ query?: string;
654
+ /**
655
+ * Symbol type filter
656
+ */
657
+ type?: string;
658
+ /**
659
+ * Exchange filter
660
+ */
661
+ exchange?: string;
662
+ /**
663
+ * Maximum number of results (default 30)
664
+ * @minimum 1
665
+ */
666
+ limit?: number;
667
+ };
668
+ export type GetUDFHistoryParams = {
669
+ symbol: string;
670
+ resolution: GetUDFHistoryResolution;
671
+ /**
672
+ * Unix seconds
673
+ */
674
+ from: number;
675
+ /**
676
+ * Unix seconds
677
+ */
678
+ to: number;
679
+ /**
680
+ * @minimum 1
681
+ * @maximum 1000
682
+ */
683
+ countback?: number;
684
+ };
685
+ export type GetUDFHistoryResolution = (typeof GetUDFHistoryResolution)[keyof typeof GetUDFHistoryResolution];
686
+ export declare const GetUDFHistoryResolution: {
687
+ readonly NUMBER_1: "1";
688
+ readonly NUMBER_5: "5";
689
+ readonly NUMBER_15: "15";
690
+ readonly NUMBER_30: "30";
691
+ readonly NUMBER_60: "60";
692
+ readonly "1D": "1D";
693
+ readonly "1W": "1W";
694
+ readonly "1M": "1M";
695
+ };
696
+ export type GetUDFQuotesParams = {
697
+ /**
698
+ * Comma-separated list of symbols
699
+ */
700
+ symbols: string;
701
+ };
702
+ export type GetUDFMarksParams = {
703
+ symbol: string;
704
+ /**
705
+ * Left boundary of the visible range (Unix seconds)
706
+ */
707
+ from: number;
708
+ /**
709
+ * Right boundary of the visible range (Unix seconds)
710
+ */
711
+ to: number;
712
+ /**
713
+ * Bar resolution (e.g. 1, 5, 15, 30, 60, 1D, 1W, 1M)
714
+ */
715
+ resolution?: string;
716
+ };
717
+ export type GetUDFTimescaleMarksParams = {
718
+ symbol: string;
719
+ /**
720
+ * Left boundary of the visible range (Unix seconds)
721
+ */
722
+ from: number;
723
+ /**
724
+ * Right boundary of the visible range (Unix seconds)
725
+ */
726
+ to: number;
727
+ /**
728
+ * Bar resolution (e.g. 1, 5, 15, 30, 60, 1D, 1W, 1M)
729
+ */
730
+ resolution?: string;
731
+ };
732
+ /**
733
+ * @summary Health check
734
+ */
735
+ export type getHealthResponse200 = {
736
+ data: HealthResponse;
737
+ status: 200;
738
+ };
739
+ export type getHealthResponse429 = {
740
+ data: RateLimitedResponse;
741
+ status: 429;
742
+ };
743
+ export type getHealthResponse503 = {
744
+ data: void;
745
+ status: 503;
746
+ };
747
+ export type getHealthResponseSuccess = getHealthResponse200 & {
748
+ headers: Headers;
749
+ };
750
+ export type getHealthResponseError = (getHealthResponse429 | getHealthResponse503) & {
751
+ headers: Headers;
752
+ };
753
+ export type getHealthResponse = getHealthResponseSuccess | getHealthResponseError;
754
+ export declare const getGetHealthUrl: () => string;
755
+ export declare const getHealth: (options?: RequestInit) => Promise<getHealthResponse>;
756
+ /**
757
+ * @summary Readiness probe
758
+ */
759
+ export type getReadyResponse200 = {
760
+ data: ReadyResponse;
761
+ status: 200;
762
+ };
763
+ export type getReadyResponse429 = {
764
+ data: RateLimitedResponse;
765
+ status: 429;
766
+ };
767
+ export type getReadyResponse503 = {
768
+ data: ReadyResponse;
769
+ status: 503;
770
+ };
771
+ export type getReadyResponseSuccess = getReadyResponse200 & {
772
+ headers: Headers;
773
+ };
774
+ export type getReadyResponseError = (getReadyResponse429 | getReadyResponse503) & {
775
+ headers: Headers;
776
+ };
777
+ export type getReadyResponse = getReadyResponseSuccess | getReadyResponseError;
778
+ export declare const getGetReadyUrl: () => string;
779
+ export declare const getReady: (options?: RequestInit) => Promise<getReadyResponse>;
780
+ /**
781
+ * @summary Liveness probe
782
+ */
783
+ export type getLiveResponse200 = {
784
+ data: LiveResponse;
785
+ status: 200;
786
+ };
787
+ export type getLiveResponse429 = {
788
+ data: RateLimitedResponse;
789
+ status: 429;
790
+ };
791
+ export type getLiveResponseSuccess = getLiveResponse200 & {
792
+ headers: Headers;
793
+ };
794
+ export type getLiveResponseError = getLiveResponse429 & {
795
+ headers: Headers;
796
+ };
797
+ export type getLiveResponse = getLiveResponseSuccess | getLiveResponseError;
798
+ export declare const getGetLiveUrl: () => string;
799
+ export declare const getLive: (options?: RequestInit) => Promise<getLiveResponse>;
800
+ /**
801
+ * @summary Get indexer sync status
802
+ */
803
+ export type getStatusResponse200 = {
804
+ data: StatusResponse;
805
+ status: 200;
806
+ };
807
+ export type getStatusResponse429 = {
808
+ data: RateLimitedResponse;
809
+ status: 429;
810
+ };
811
+ export type getStatusResponse500 = {
812
+ data: InternalErrorResponse;
813
+ status: 500;
814
+ };
815
+ export type getStatusResponseSuccess = getStatusResponse200 & {
816
+ headers: Headers;
817
+ };
818
+ export type getStatusResponseError = (getStatusResponse429 | getStatusResponse500) & {
819
+ headers: Headers;
820
+ };
821
+ export type getStatusResponse = getStatusResponseSuccess | getStatusResponseError;
822
+ export declare const getGetStatusUrl: () => string;
823
+ export declare const getStatus: (options?: RequestInit) => Promise<getStatusResponse>;
824
+ /**
825
+ * Returns all trading pairs in standard market format, ordered by ID.
826
+ * @summary List all markets
827
+ */
828
+ export type listMarketsResponse200 = {
829
+ data: MarketResponse[];
830
+ status: 200;
831
+ };
832
+ export type listMarketsResponse429 = {
833
+ data: RateLimitedResponse;
834
+ status: 429;
835
+ };
836
+ export type listMarketsResponse500 = {
837
+ data: InternalErrorResponse;
838
+ status: 500;
839
+ };
840
+ export type listMarketsResponseSuccess = listMarketsResponse200 & {
841
+ headers: Headers;
842
+ };
843
+ export type listMarketsResponseError = (listMarketsResponse429 | listMarketsResponse500) & {
844
+ headers: Headers;
845
+ };
846
+ export type listMarketsResponse = listMarketsResponseSuccess | listMarketsResponseError;
847
+ export declare const getListMarketsUrl: () => string;
848
+ export declare const listMarkets: (options?: RequestInit) => Promise<listMarketsResponse>;
849
+ /**
850
+ * Returns a dictionary of currencies keyed by code (e.g., "AULT", "BTC").
851
+ * @summary List all currencies
852
+ */
853
+ export type listCurrenciesResponse200 = {
854
+ data: ListCurrencies200;
855
+ status: 200;
856
+ };
857
+ export type listCurrenciesResponse429 = {
858
+ data: RateLimitedResponse;
859
+ status: 429;
860
+ };
861
+ export type listCurrenciesResponse500 = {
862
+ data: InternalErrorResponse;
863
+ status: 500;
864
+ };
865
+ export type listCurrenciesResponseSuccess = listCurrenciesResponse200 & {
866
+ headers: Headers;
867
+ };
868
+ export type listCurrenciesResponseError = (listCurrenciesResponse429 | listCurrenciesResponse500) & {
869
+ headers: Headers;
870
+ };
871
+ export type listCurrenciesResponse = listCurrenciesResponseSuccess | listCurrenciesResponseError;
872
+ export declare const getListCurrenciesUrl: () => string;
873
+ export declare const listCurrencies: (options?: RequestInit) => Promise<listCurrenciesResponse>;
874
+ /**
875
+ * @summary Get 24h ticker for a symbol
876
+ */
877
+ export type getTickerResponse200 = {
878
+ data: TickerResponse;
879
+ status: 200;
880
+ };
881
+ export type getTickerResponse400 = {
882
+ data: BadRequestResponse;
883
+ status: 400;
884
+ };
885
+ export type getTickerResponse429 = {
886
+ data: RateLimitedResponse;
887
+ status: 429;
888
+ };
889
+ export type getTickerResponse500 = {
890
+ data: InternalErrorResponse;
891
+ status: 500;
892
+ };
893
+ export type getTickerResponseSuccess = getTickerResponse200 & {
894
+ headers: Headers;
895
+ };
896
+ export type getTickerResponseError = (getTickerResponse400 | getTickerResponse429 | getTickerResponse500) & {
897
+ headers: Headers;
898
+ };
899
+ export type getTickerResponse = getTickerResponseSuccess | getTickerResponseError;
900
+ export declare const getGetTickerUrl: (symbol: string) => string;
901
+ export declare const getTicker: (symbol: string, options?: RequestInit) => Promise<getTickerResponse>;
902
+ /**
903
+ * @summary Get 24h tickers for all markets
904
+ */
905
+ export type getAllTickersResponse200 = {
906
+ data: GetAllTickers200;
907
+ status: 200;
908
+ };
909
+ export type getAllTickersResponse429 = {
910
+ data: RateLimitedResponse;
911
+ status: 429;
912
+ };
913
+ export type getAllTickersResponse500 = {
914
+ data: InternalErrorResponse;
915
+ status: 500;
916
+ };
917
+ export type getAllTickersResponseSuccess = getAllTickersResponse200 & {
918
+ headers: Headers;
919
+ };
920
+ export type getAllTickersResponseError = (getAllTickersResponse429 | getAllTickersResponse500) & {
921
+ headers: Headers;
922
+ };
923
+ export type getAllTickersResponse = getAllTickersResponseSuccess | getAllTickersResponseError;
924
+ export declare const getGetAllTickersUrl: () => string;
925
+ export declare const getAllTickers: (options?: RequestInit) => Promise<getAllTickersResponse>;
926
+ /**
927
+ * @summary Get order book for a symbol
928
+ */
929
+ export type getOrderbookResponse200 = {
930
+ data: OrderbookResponse;
931
+ status: 200;
932
+ };
933
+ export type getOrderbookResponse400 = {
934
+ data: BadRequestResponse;
935
+ status: 400;
936
+ };
937
+ export type getOrderbookResponse429 = {
938
+ data: RateLimitedResponse;
939
+ status: 429;
940
+ };
941
+ export type getOrderbookResponse500 = {
942
+ data: InternalErrorResponse;
943
+ status: 500;
944
+ };
945
+ export type getOrderbookResponseSuccess = getOrderbookResponse200 & {
946
+ headers: Headers;
947
+ };
948
+ export type getOrderbookResponseError = (getOrderbookResponse400 | getOrderbookResponse429 | getOrderbookResponse500) & {
949
+ headers: Headers;
950
+ };
951
+ export type getOrderbookResponse = getOrderbookResponseSuccess | getOrderbookResponseError;
952
+ export declare const getGetOrderbookUrl: (symbol: string, params?: GetOrderbookParams) => string;
953
+ export declare const getOrderbook: (symbol: string, params?: GetOrderbookParams, options?: RequestInit) => Promise<getOrderbookResponse>;
954
+ /**
955
+ * @summary Get recent trades for a symbol
956
+ */
957
+ export type listTradesResponse200 = {
958
+ data: TradeResponse[];
959
+ status: 200;
960
+ };
961
+ export type listTradesResponse400 = {
962
+ data: BadRequestResponse;
963
+ status: 400;
964
+ };
965
+ export type listTradesResponse429 = {
966
+ data: RateLimitedResponse;
967
+ status: 429;
968
+ };
969
+ export type listTradesResponse500 = {
970
+ data: InternalErrorResponse;
971
+ status: 500;
972
+ };
973
+ export type listTradesResponseSuccess = listTradesResponse200 & {
974
+ headers: Headers;
975
+ };
976
+ export type listTradesResponseError = (listTradesResponse400 | listTradesResponse429 | listTradesResponse500) & {
977
+ headers: Headers;
978
+ };
979
+ export type listTradesResponse = listTradesResponseSuccess | listTradesResponseError;
980
+ export declare const getListTradesUrl: (symbol: string, params?: ListTradesParams) => string;
981
+ export declare const listTrades: (symbol: string, params?: ListTradesParams, options?: RequestInit) => Promise<listTradesResponse>;
982
+ /**
983
+ * Returns trading fee schedule for all markets, keyed by symbol.
984
+ * @summary Get trading fees for all markets
985
+ */
986
+ export type getTradingFeesResponse200 = {
987
+ data: GetTradingFees200;
988
+ status: 200;
989
+ };
990
+ export type getTradingFeesResponse429 = {
991
+ data: RateLimitedResponse;
992
+ status: 429;
993
+ };
994
+ export type getTradingFeesResponse500 = {
995
+ data: InternalErrorResponse;
996
+ status: 500;
997
+ };
998
+ export type getTradingFeesResponseSuccess = getTradingFeesResponse200 & {
999
+ headers: Headers;
1000
+ };
1001
+ export type getTradingFeesResponseError = (getTradingFeesResponse429 | getTradingFeesResponse500) & {
1002
+ headers: Headers;
1003
+ };
1004
+ export type getTradingFeesResponse = getTradingFeesResponseSuccess | getTradingFeesResponseError;
1005
+ export declare const getGetTradingFeesUrl: () => string;
1006
+ export declare const getTradingFees: (options?: RequestInit) => Promise<getTradingFeesResponse>;
1007
+ /**
1008
+ * @summary List orders for an address
1009
+ */
1010
+ export type listOrdersResponse200 = {
1011
+ data: OrderResponse[];
1012
+ status: 200;
1013
+ };
1014
+ export type listOrdersResponse400 = {
1015
+ data: BadRequestResponse;
1016
+ status: 400;
1017
+ };
1018
+ export type listOrdersResponse429 = {
1019
+ data: RateLimitedResponse;
1020
+ status: 429;
1021
+ };
1022
+ export type listOrdersResponse500 = {
1023
+ data: InternalErrorResponse;
1024
+ status: 500;
1025
+ };
1026
+ export type listOrdersResponseSuccess = listOrdersResponse200 & {
1027
+ headers: Headers;
1028
+ };
1029
+ export type listOrdersResponseError = (listOrdersResponse400 | listOrdersResponse429 | listOrdersResponse500) & {
1030
+ headers: Headers;
1031
+ };
1032
+ export type listOrdersResponse = listOrdersResponseSuccess | listOrdersResponseError;
1033
+ export declare const getListOrdersUrl: (params: ListOrdersParams) => string;
1034
+ export declare const listOrders: (params: ListOrdersParams, options?: RequestInit) => Promise<listOrdersResponse>;
1035
+ /**
1036
+ * Returns a single order by its hex-encoded ID.
1037
+ * @summary Get a single order by ID
1038
+ */
1039
+ export type getOrderResponse200 = {
1040
+ data: OrderResponse;
1041
+ status: 200;
1042
+ };
1043
+ export type getOrderResponse400 = {
1044
+ data: BadRequestResponse;
1045
+ status: 400;
1046
+ };
1047
+ export type getOrderResponse404 = {
1048
+ data: ErrorResponse;
1049
+ status: 404;
1050
+ };
1051
+ export type getOrderResponse429 = {
1052
+ data: RateLimitedResponse;
1053
+ status: 429;
1054
+ };
1055
+ export type getOrderResponse500 = {
1056
+ data: InternalErrorResponse;
1057
+ status: 500;
1058
+ };
1059
+ export type getOrderResponseSuccess = getOrderResponse200 & {
1060
+ headers: Headers;
1061
+ };
1062
+ export type getOrderResponseError = (getOrderResponse400 | getOrderResponse404 | getOrderResponse429 | getOrderResponse500) & {
1063
+ headers: Headers;
1064
+ };
1065
+ export type getOrderResponse = getOrderResponseSuccess | getOrderResponseError;
1066
+ export declare const getGetOrderUrl: (id: string) => string;
1067
+ export declare const getOrder: (id: string, options?: RequestInit) => Promise<getOrderResponse>;
1068
+ /**
1069
+ * Returns trade history for a specific user (orderer).
1070
+ Unlike `/trades/{symbol}` which returns all public trades for a market,
1071
+ this endpoint returns only the authenticated user's fills.
1072
+
1073
+ * @summary Get user's own trades
1074
+ */
1075
+ export type listMyTradesResponse200 = {
1076
+ data: TradeResponse[];
1077
+ status: 200;
1078
+ };
1079
+ export type listMyTradesResponse400 = {
1080
+ data: BadRequestResponse;
1081
+ status: 400;
1082
+ };
1083
+ export type listMyTradesResponse429 = {
1084
+ data: RateLimitedResponse;
1085
+ status: 429;
1086
+ };
1087
+ export type listMyTradesResponse500 = {
1088
+ data: InternalErrorResponse;
1089
+ status: 500;
1090
+ };
1091
+ export type listMyTradesResponseSuccess = listMyTradesResponse200 & {
1092
+ headers: Headers;
1093
+ };
1094
+ export type listMyTradesResponseError = (listMyTradesResponse400 | listMyTradesResponse429 | listMyTradesResponse500) & {
1095
+ headers: Headers;
1096
+ };
1097
+ export type listMyTradesResponse = listMyTradesResponseSuccess | listMyTradesResponseError;
1098
+ export declare const getListMyTradesUrl: (params: ListMyTradesParams) => string;
1099
+ export declare const listMyTrades: (params: ListMyTradesParams, options?: RequestInit) => Promise<listMyTradesResponse>;
1100
+ /**
1101
+ * Returns the balance object with `free`, `used`, `total`
1102
+ dictionaries plus per-currency entries.
1103
+
1104
+ * @summary Get balances for an address
1105
+ */
1106
+ export type getBalanceResponse200 = {
1107
+ data: BalancesResponse;
1108
+ status: 200;
1109
+ };
1110
+ export type getBalanceResponse400 = {
1111
+ data: BadRequestResponse;
1112
+ status: 400;
1113
+ };
1114
+ export type getBalanceResponse429 = {
1115
+ data: RateLimitedResponse;
1116
+ status: 429;
1117
+ };
1118
+ export type getBalanceResponse500 = {
1119
+ data: InternalErrorResponse;
1120
+ status: 500;
1121
+ };
1122
+ export type getBalanceResponseSuccess = getBalanceResponse200 & {
1123
+ headers: Headers;
1124
+ };
1125
+ export type getBalanceResponseError = (getBalanceResponse400 | getBalanceResponse429 | getBalanceResponse500) & {
1126
+ headers: Headers;
1127
+ };
1128
+ export type getBalanceResponse = getBalanceResponseSuccess | getBalanceResponseError;
1129
+ export declare const getGetBalanceUrl: (params: GetBalanceParams) => string;
1130
+ export declare const getBalance: (params: GetBalanceParams, options?: RequestInit) => Promise<getBalanceResponse>;
1131
+ /**
1132
+ * @summary Get OHLCV candlestick data
1133
+ */
1134
+ export type getOHLCVResponse200 = {
1135
+ data: OHLCVEntry[];
1136
+ status: 200;
1137
+ };
1138
+ export type getOHLCVResponse400 = {
1139
+ data: BadRequestResponse;
1140
+ status: 400;
1141
+ };
1142
+ export type getOHLCVResponse429 = {
1143
+ data: RateLimitedResponse;
1144
+ status: 429;
1145
+ };
1146
+ export type getOHLCVResponse500 = {
1147
+ data: InternalErrorResponse;
1148
+ status: 500;
1149
+ };
1150
+ export type getOHLCVResponseSuccess = getOHLCVResponse200 & {
1151
+ headers: Headers;
1152
+ };
1153
+ export type getOHLCVResponseError = (getOHLCVResponse400 | getOHLCVResponse429 | getOHLCVResponse500) & {
1154
+ headers: Headers;
1155
+ };
1156
+ export type getOHLCVResponse = getOHLCVResponseSuccess | getOHLCVResponseError;
1157
+ export declare const getGetOHLCVUrl: (symbol: string, params?: GetOHLCVParams) => string;
1158
+ export declare const getOHLCV: (symbol: string, params?: GetOHLCVParams, options?: RequestInit) => Promise<getOHLCVResponse>;
1159
+ /**
1160
+ * @summary UDF configuration
1161
+ */
1162
+ export type getUDFConfigResponse200 = {
1163
+ data: UDFConfig;
1164
+ status: 200;
1165
+ };
1166
+ export type getUDFConfigResponse429 = {
1167
+ data: RateLimitedResponse;
1168
+ status: 429;
1169
+ };
1170
+ export type getUDFConfigResponseSuccess = getUDFConfigResponse200 & {
1171
+ headers: Headers;
1172
+ };
1173
+ export type getUDFConfigResponseError = getUDFConfigResponse429 & {
1174
+ headers: Headers;
1175
+ };
1176
+ export type getUDFConfigResponse = getUDFConfigResponseSuccess | getUDFConfigResponseError;
1177
+ export declare const getGetUDFConfigUrl: () => string;
1178
+ export declare const getUDFConfig: (options?: RequestInit) => Promise<getUDFConfigResponse>;
1179
+ /**
1180
+ * @summary Server time (plain text, Unix seconds)
1181
+ */
1182
+ export type getUDFTimeResponse200 = {
1183
+ data: number;
1184
+ status: 200;
1185
+ };
1186
+ export type getUDFTimeResponse429 = {
1187
+ data: RateLimitedResponse;
1188
+ status: 429;
1189
+ };
1190
+ export type getUDFTimeResponseSuccess = getUDFTimeResponse200 & {
1191
+ headers: Headers;
1192
+ };
1193
+ export type getUDFTimeResponseError = getUDFTimeResponse429 & {
1194
+ headers: Headers;
1195
+ };
1196
+ export type getUDFTimeResponse = getUDFTimeResponseSuccess | getUDFTimeResponseError;
1197
+ export declare const getGetUDFTimeUrl: () => string;
1198
+ export declare const getUDFTime: (options?: RequestInit) => Promise<getUDFTimeResponse>;
1199
+ /**
1200
+ * @summary Symbol info
1201
+ */
1202
+ export type getUDFSymbolResponse200 = {
1203
+ data: UDFSymbolInfo;
1204
+ status: 200;
1205
+ };
1206
+ export type getUDFSymbolResponse400 = {
1207
+ data: BadRequestResponse;
1208
+ status: 400;
1209
+ };
1210
+ export type getUDFSymbolResponse429 = {
1211
+ data: RateLimitedResponse;
1212
+ status: 429;
1213
+ };
1214
+ export type getUDFSymbolResponse500 = {
1215
+ data: InternalErrorResponse;
1216
+ status: 500;
1217
+ };
1218
+ export type getUDFSymbolResponseSuccess = getUDFSymbolResponse200 & {
1219
+ headers: Headers;
1220
+ };
1221
+ export type getUDFSymbolResponseError = (getUDFSymbolResponse400 | getUDFSymbolResponse429 | getUDFSymbolResponse500) & {
1222
+ headers: Headers;
1223
+ };
1224
+ export type getUDFSymbolResponse = getUDFSymbolResponseSuccess | getUDFSymbolResponseError;
1225
+ export declare const getGetUDFSymbolUrl: (params: GetUDFSymbolParams) => string;
1226
+ export declare const getUDFSymbol: (params: GetUDFSymbolParams, options?: RequestInit) => Promise<getUDFSymbolResponse>;
1227
+ /**
1228
+ * Search for symbols by name. Returns an array of matching symbols.
1229
+ * @summary Symbol search
1230
+ */
1231
+ export type searchUDFSymbolsResponse200 = {
1232
+ data: UDFSearchResult[];
1233
+ status: 200;
1234
+ };
1235
+ export type searchUDFSymbolsResponse429 = {
1236
+ data: RateLimitedResponse;
1237
+ status: 429;
1238
+ };
1239
+ export type searchUDFSymbolsResponseSuccess = searchUDFSymbolsResponse200 & {
1240
+ headers: Headers;
1241
+ };
1242
+ export type searchUDFSymbolsResponseError = searchUDFSymbolsResponse429 & {
1243
+ headers: Headers;
1244
+ };
1245
+ export type searchUDFSymbolsResponse = searchUDFSymbolsResponseSuccess | searchUDFSymbolsResponseError;
1246
+ export declare const getSearchUDFSymbolsUrl: (params?: SearchUDFSymbolsParams) => string;
1247
+ export declare const searchUDFSymbols: (params?: SearchUDFSymbolsParams, options?: RequestInit) => Promise<searchUDFSymbolsResponse>;
1248
+ /**
1249
+ * Timestamps in Unix seconds. Supports `from`/`to` range and `countback` mode.
1250
+ * @summary OHLCV history for charting
1251
+ */
1252
+ export type getUDFHistoryResponse200 = {
1253
+ data: UDFHistoryResponse;
1254
+ status: 200;
1255
+ };
1256
+ export type getUDFHistoryResponse400 = {
1257
+ data: BadRequestResponse;
1258
+ status: 400;
1259
+ };
1260
+ export type getUDFHistoryResponse429 = {
1261
+ data: RateLimitedResponse;
1262
+ status: 429;
1263
+ };
1264
+ export type getUDFHistoryResponse500 = {
1265
+ data: InternalErrorResponse;
1266
+ status: 500;
1267
+ };
1268
+ export type getUDFHistoryResponseSuccess = getUDFHistoryResponse200 & {
1269
+ headers: Headers;
1270
+ };
1271
+ export type getUDFHistoryResponseError = (getUDFHistoryResponse400 | getUDFHistoryResponse429 | getUDFHistoryResponse500) & {
1272
+ headers: Headers;
1273
+ };
1274
+ export type getUDFHistoryResponse = getUDFHistoryResponseSuccess | getUDFHistoryResponseError;
1275
+ export declare const getGetUDFHistoryUrl: (params: GetUDFHistoryParams) => string;
1276
+ export declare const getUDFHistory: (params: GetUDFHistoryParams, options?: RequestInit) => Promise<getUDFHistoryResponse>;
1277
+ /**
1278
+ * Returns quote data for one or more symbols.
1279
+ * @summary Real-time quotes
1280
+ */
1281
+ export type getUDFQuotesResponse200 = {
1282
+ data: UDFQuotesResponse;
1283
+ status: 200;
1284
+ };
1285
+ export type getUDFQuotesResponse400 = {
1286
+ data: BadRequestResponse;
1287
+ status: 400;
1288
+ };
1289
+ export type getUDFQuotesResponse429 = {
1290
+ data: RateLimitedResponse;
1291
+ status: 429;
1292
+ };
1293
+ export type getUDFQuotesResponse500 = {
1294
+ data: InternalErrorResponse;
1295
+ status: 500;
1296
+ };
1297
+ export type getUDFQuotesResponseSuccess = getUDFQuotesResponse200 & {
1298
+ headers: Headers;
1299
+ };
1300
+ export type getUDFQuotesResponseError = (getUDFQuotesResponse400 | getUDFQuotesResponse429 | getUDFQuotesResponse500) & {
1301
+ headers: Headers;
1302
+ };
1303
+ export type getUDFQuotesResponse = getUDFQuotesResponseSuccess | getUDFQuotesResponseError;
1304
+ export declare const getGetUDFQuotesUrl: (params: GetUDFQuotesParams) => string;
1305
+ export declare const getUDFQuotes: (params: GetUDFQuotesParams, options?: RequestInit) => Promise<getUDFQuotesResponse>;
1306
+ /**
1307
+ * Returns marks (annotations) for bars in a time range.
1308
+ Only called by TradingView when `supports_marks: true` in /udf/config.
1309
+ Currently returns empty arrays (stub).
1310
+
1311
+ * @summary Bar marks
1312
+ */
1313
+ export type getUDFMarksResponse200 = {
1314
+ data: UDFMarksResponse;
1315
+ status: 200;
1316
+ };
1317
+ export type getUDFMarksResponse400 = {
1318
+ data: BadRequestResponse;
1319
+ status: 400;
1320
+ };
1321
+ export type getUDFMarksResponse429 = {
1322
+ data: RateLimitedResponse;
1323
+ status: 429;
1324
+ };
1325
+ export type getUDFMarksResponseSuccess = getUDFMarksResponse200 & {
1326
+ headers: Headers;
1327
+ };
1328
+ export type getUDFMarksResponseError = (getUDFMarksResponse400 | getUDFMarksResponse429) & {
1329
+ headers: Headers;
1330
+ };
1331
+ export type getUDFMarksResponse = getUDFMarksResponseSuccess | getUDFMarksResponseError;
1332
+ export declare const getGetUDFMarksUrl: (params: GetUDFMarksParams) => string;
1333
+ export declare const getUDFMarks: (params: GetUDFMarksParams, options?: RequestInit) => Promise<getUDFMarksResponse>;
1334
+ /**
1335
+ * Returns marks displayed on the time axis.
1336
+ Only called by TradingView when `supports_timescale_marks: true` in /udf/config.
1337
+ Currently returns an empty array (stub).
1338
+
1339
+ * @summary Timescale marks
1340
+ */
1341
+ export type getUDFTimescaleMarksResponse200 = {
1342
+ data: UDFTimescaleMark[];
1343
+ status: 200;
1344
+ };
1345
+ export type getUDFTimescaleMarksResponse400 = {
1346
+ data: BadRequestResponse;
1347
+ status: 400;
1348
+ };
1349
+ export type getUDFTimescaleMarksResponse429 = {
1350
+ data: RateLimitedResponse;
1351
+ status: 429;
1352
+ };
1353
+ export type getUDFTimescaleMarksResponseSuccess = getUDFTimescaleMarksResponse200 & {
1354
+ headers: Headers;
1355
+ };
1356
+ export type getUDFTimescaleMarksResponseError = (getUDFTimescaleMarksResponse400 | getUDFTimescaleMarksResponse429) & {
1357
+ headers: Headers;
1358
+ };
1359
+ export type getUDFTimescaleMarksResponse = getUDFTimescaleMarksResponseSuccess | getUDFTimescaleMarksResponseError;
1360
+ export declare const getGetUDFTimescaleMarksUrl: (params: GetUDFTimescaleMarksParams) => string;
1361
+ export declare const getUDFTimescaleMarks: (params: GetUDFTimescaleMarksParams, options?: RequestInit) => Promise<getUDFTimescaleMarksResponse>;
1362
+ /**
1363
+ * @summary OpenAPI specification
1364
+ */
1365
+ export type getOpenAPISpecResponse200 = {
1366
+ data: string;
1367
+ status: 200;
1368
+ };
1369
+ export type getOpenAPISpecResponse429 = {
1370
+ data: RateLimitedResponse;
1371
+ status: 429;
1372
+ };
1373
+ export type getOpenAPISpecResponseSuccess = getOpenAPISpecResponse200 & {
1374
+ headers: Headers;
1375
+ };
1376
+ export type getOpenAPISpecResponseError = getOpenAPISpecResponse429 & {
1377
+ headers: Headers;
1378
+ };
1379
+ export type getOpenAPISpecResponse = getOpenAPISpecResponseSuccess | getOpenAPISpecResponseError;
1380
+ export declare const getGetOpenAPISpecUrl: () => string;
1381
+ export declare const getOpenAPISpec: (options?: RequestInit) => Promise<getOpenAPISpecResponse>;