@nadohq/indexer-client 0.15.0 → 0.17.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.
Files changed (155) hide show
  1. package/dist/CandlestickPeriod-1DtcEiOb.d.ts +15 -0
  2. package/dist/CandlestickPeriod-1DtcEiOb.d.ts.map +1 -0
  3. package/dist/CandlestickPeriod-D3_IoSev.d.cts +15 -0
  4. package/dist/CandlestickPeriod-D3_IoSev.d.cts.map +1 -0
  5. package/dist/IndexerBaseClient-3KfzA2ph.cjs +639 -0
  6. package/dist/IndexerBaseClient-3KfzA2ph.cjs.map +1 -0
  7. package/dist/IndexerBaseClient.cjs +3 -788
  8. package/dist/IndexerBaseClient.d.cts +223 -229
  9. package/dist/IndexerBaseClient.d.cts.map +1 -0
  10. package/dist/IndexerBaseClient.d.ts +223 -229
  11. package/dist/IndexerBaseClient.d.ts.map +1 -0
  12. package/dist/IndexerBaseClient.js +601 -783
  13. package/dist/IndexerBaseClient.js.map +1 -1
  14. package/dist/IndexerClient.cjs +275 -381
  15. package/dist/IndexerClient.cjs.map +1 -1
  16. package/dist/IndexerClient.d.cts +32 -43
  17. package/dist/IndexerClient.d.cts.map +1 -0
  18. package/dist/IndexerClient.d.ts +32 -43
  19. package/dist/IndexerClient.d.ts.map +1 -0
  20. package/dist/IndexerClient.js +273 -362
  21. package/dist/IndexerClient.js.map +1 -1
  22. package/dist/IndexerEventType-B-uXsf-a.d.cts +5 -0
  23. package/dist/IndexerEventType-B-uXsf-a.d.cts.map +1 -0
  24. package/dist/IndexerEventType-DCLkSlgR.d.ts +5 -0
  25. package/dist/IndexerEventType-DCLkSlgR.d.ts.map +1 -0
  26. package/dist/IndexerLeaderboardType-Ck12QVWR.d.cts +13 -0
  27. package/dist/IndexerLeaderboardType-Ck12QVWR.d.cts.map +1 -0
  28. package/dist/IndexerLeaderboardType-DAKw2tfI.d.ts +13 -0
  29. package/dist/IndexerLeaderboardType-DAKw2tfI.d.ts.map +1 -0
  30. package/dist/NadoTx-CWCklgY4.d.ts +50 -0
  31. package/dist/NadoTx-CWCklgY4.d.ts.map +1 -0
  32. package/dist/NadoTx-MYNIlXyq.d.cts +50 -0
  33. package/dist/NadoTx-MYNIlXyq.d.cts.map +1 -0
  34. package/dist/clientTypes-BpxOUu1q.d.ts +709 -0
  35. package/dist/clientTypes-BpxOUu1q.d.ts.map +1 -0
  36. package/dist/clientTypes-BsJ2yIC4.d.cts +709 -0
  37. package/dist/clientTypes-BsJ2yIC4.d.cts.map +1 -0
  38. package/dist/collateralEventType-CzH_2iTV.d.ts +5 -0
  39. package/dist/collateralEventType-CzH_2iTV.d.ts.map +1 -0
  40. package/dist/collateralEventType-DIm6Te7F.d.cts +5 -0
  41. package/dist/collateralEventType-DIm6Te7F.d.cts.map +1 -0
  42. package/dist/dataMappers.cjs +269 -346
  43. package/dist/dataMappers.cjs.map +1 -1
  44. package/dist/dataMappers.d.cts +7 -12
  45. package/dist/dataMappers.d.cts.map +1 -0
  46. package/dist/dataMappers.d.ts +7 -12
  47. package/dist/dataMappers.d.ts.map +1 -0
  48. package/dist/dataMappers.js +248 -314
  49. package/dist/dataMappers.js.map +1 -1
  50. package/dist/endpoints.cjs +8 -32
  51. package/dist/endpoints.cjs.map +1 -1
  52. package/dist/endpoints.d.cts +4 -2
  53. package/dist/endpoints.d.cts.map +1 -0
  54. package/dist/endpoints.d.ts +4 -2
  55. package/dist/endpoints.d.ts.map +1 -0
  56. package/dist/endpoints.js +8 -8
  57. package/dist/endpoints.js.map +1 -1
  58. package/dist/index-D6CnpA_r.d.cts +1 -0
  59. package/dist/index-DhI2LvVQ.d.ts +1 -0
  60. package/dist/index.cjs +15 -33
  61. package/dist/index.d.cts +14 -18
  62. package/dist/index.d.ts +14 -18
  63. package/dist/index.js +8 -7
  64. package/dist/indexerBalanceValue-4AuNuTAc.d.cts +32 -0
  65. package/dist/indexerBalanceValue-4AuNuTAc.d.cts.map +1 -0
  66. package/dist/indexerBalanceValue-B0OggI67.d.ts +32 -0
  67. package/dist/indexerBalanceValue-B0OggI67.d.ts.map +1 -0
  68. package/dist/paginatedEventsTypes-DtGDU-kI.d.cts +110 -0
  69. package/dist/paginatedEventsTypes-DtGDU-kI.d.cts.map +1 -0
  70. package/dist/paginatedEventsTypes-RwXoQrEa.d.ts +110 -0
  71. package/dist/paginatedEventsTypes-RwXoQrEa.d.ts.map +1 -0
  72. package/dist/serverModelTypes-CM2g040o.d.cts +262 -0
  73. package/dist/serverModelTypes-CM2g040o.d.cts.map +1 -0
  74. package/dist/serverModelTypes-DPHMUSZe.d.ts +262 -0
  75. package/dist/serverModelTypes-DPHMUSZe.d.ts.map +1 -0
  76. package/dist/serverTypes-BMSNh2GK.d.cts +452 -0
  77. package/dist/serverTypes-BMSNh2GK.d.cts.map +1 -0
  78. package/dist/serverTypes-c8IABU73.d.ts +452 -0
  79. package/dist/serverTypes-c8IABU73.d.ts.map +1 -0
  80. package/dist/types/CandlestickPeriod.cjs +16 -40
  81. package/dist/types/CandlestickPeriod.cjs.map +1 -1
  82. package/dist/types/CandlestickPeriod.d.cts +2 -13
  83. package/dist/types/CandlestickPeriod.d.ts +2 -13
  84. package/dist/types/CandlestickPeriod.js +16 -16
  85. package/dist/types/CandlestickPeriod.js.map +1 -1
  86. package/dist/types/IndexerEventType.cjs +0 -19
  87. package/dist/types/IndexerEventType.d.cts +2 -3
  88. package/dist/types/IndexerEventType.d.ts +2 -3
  89. package/dist/types/IndexerEventType.js +1 -1
  90. package/dist/types/IndexerLeaderboardType.cjs +0 -19
  91. package/dist/types/IndexerLeaderboardType.d.cts +2 -11
  92. package/dist/types/IndexerLeaderboardType.d.ts +2 -11
  93. package/dist/types/IndexerLeaderboardType.js +1 -1
  94. package/dist/types/NadoTx.cjs +0 -19
  95. package/dist/types/NadoTx.d.cts +2 -48
  96. package/dist/types/NadoTx.d.ts +2 -48
  97. package/dist/types/NadoTx.js +1 -1
  98. package/dist/types/clientTypes.cjs +0 -19
  99. package/dist/types/clientTypes.d.cts +2 -709
  100. package/dist/types/clientTypes.d.ts +2 -709
  101. package/dist/types/clientTypes.js +1 -1
  102. package/dist/types/collateralEventType.cjs +0 -19
  103. package/dist/types/collateralEventType.d.cts +2 -3
  104. package/dist/types/collateralEventType.d.ts +2 -3
  105. package/dist/types/collateralEventType.js +1 -1
  106. package/dist/types/index.cjs +3 -41
  107. package/dist/types/index.d.cts +10 -13
  108. package/dist/types/index.d.ts +10 -13
  109. package/dist/types/index.js +2 -11
  110. package/dist/types/paginatedEventsTypes.cjs +0 -19
  111. package/dist/types/paginatedEventsTypes.d.cts +2 -115
  112. package/dist/types/paginatedEventsTypes.d.ts +2 -115
  113. package/dist/types/paginatedEventsTypes.js +1 -1
  114. package/dist/types/serverModelTypes.cjs +0 -19
  115. package/dist/types/serverModelTypes.d.cts +2 -260
  116. package/dist/types/serverModelTypes.d.ts +2 -260
  117. package/dist/types/serverModelTypes.js +1 -1
  118. package/dist/types/serverTypes.cjs +0 -19
  119. package/dist/types/serverTypes.d.cts +2 -451
  120. package/dist/types/serverTypes.d.ts +2 -451
  121. package/dist/types/serverTypes.js +1 -1
  122. package/dist/utils/index.cjs +5 -25
  123. package/dist/utils/index.d.cts +2 -12
  124. package/dist/utils/index.d.ts +2 -12
  125. package/dist/utils/index.js +2 -3
  126. package/dist/utils/indexerBalanceValue.cjs +32 -36
  127. package/dist/utils/indexerBalanceValue.cjs.map +1 -1
  128. package/dist/utils/indexerBalanceValue.d.cts +2 -39
  129. package/dist/utils/indexerBalanceValue.d.ts +2 -39
  130. package/dist/utils/indexerBalanceValue.js +29 -9
  131. package/dist/utils/indexerBalanceValue.js.map +1 -1
  132. package/package.json +10 -10
  133. package/dist/IndexerBaseClient.cjs.map +0 -1
  134. package/dist/index.cjs.map +0 -1
  135. package/dist/index.js.map +0 -1
  136. package/dist/types/IndexerEventType.cjs.map +0 -1
  137. package/dist/types/IndexerEventType.js.map +0 -1
  138. package/dist/types/IndexerLeaderboardType.cjs.map +0 -1
  139. package/dist/types/IndexerLeaderboardType.js.map +0 -1
  140. package/dist/types/NadoTx.cjs.map +0 -1
  141. package/dist/types/NadoTx.js.map +0 -1
  142. package/dist/types/clientTypes.cjs.map +0 -1
  143. package/dist/types/clientTypes.js.map +0 -1
  144. package/dist/types/collateralEventType.cjs.map +0 -1
  145. package/dist/types/collateralEventType.js.map +0 -1
  146. package/dist/types/index.cjs.map +0 -1
  147. package/dist/types/index.js.map +0 -1
  148. package/dist/types/paginatedEventsTypes.cjs.map +0 -1
  149. package/dist/types/paginatedEventsTypes.js.map +0 -1
  150. package/dist/types/serverModelTypes.cjs.map +0 -1
  151. package/dist/types/serverModelTypes.js.map +0 -1
  152. package/dist/types/serverTypes.cjs.map +0 -1
  153. package/dist/types/serverTypes.js.map +0 -1
  154. package/dist/utils/index.cjs.map +0 -1
  155. package/dist/utils/index.js.map +0 -1
@@ -1,237 +1,231 @@
1
- import { WalletClientWithAccount, SignableRequestType, SignableRequestTypeToParams } from '@nadohq/shared';
2
- import { AxiosInstance } from 'axios';
3
- import { ListIndexerSubaccountsParams, ListIndexerSubaccountsResponse, GetIndexerMultiSubaccountSnapshotsParams, GetIndexerMultiSubaccountSnapshotsResponse, GetIndexerReferralCodeParams, GetIndexerReferralCodeResponse, GetIndexerFundingRateParams, GetIndexerFundingRateResponse, GetIndexerMultiProductFundingRatesParams, GetIndexerMultiProductFundingRatesResponse, GetIndexerPerpPricesParams, GetIndexerPerpPricesResponse, GetIndexerMultiProductPerpPricesParams, GetIndexerMultiProductPerpPricesResponse, GetIndexerOraclePricesParams, GetIndexerOraclePricesResponse, GetIndexerCandlesticksParams, GetIndexerCandlesticksResponse, GetIndexerEdgeCandlesticksParams, GetIndexerEdgeCandlesticksResponse, GetIndexerProductSnapshotsParams, GetIndexerProductSnapshotsResponse, GetIndexerMultiProductSnapshotsParams, GetIndexerMultiProductSnapshotsResponse, GetIndexerEventsParams, GetIndexerEventsResponse, GetIndexerOrdersParams, GetIndexerOrdersResponse, GetIndexerMatchEventsParams, GetIndexerMatchEventsResponse, GetIndexerInterestFundingPaymentsParams, GetIndexerInterestFundingPaymentsResponse, GetIndexerQuotePriceResponse, GetIndexerLinkedSignerParams, GetIndexerLinkedSignerResponse, GetIndexerMarketSnapshotsParams, GetIndexerMarketSnapshotsResponse, GetIndexerEdgeMarketSnapshotsParams, GetIndexerEdgeMarketSnapshotResponse, GetIndexerMakerStatisticsParams, GetIndexerMakerStatisticsResponse, GetIndexerLeaderboardParams, GetIndexerLeaderboardResponse, GetIndexerLeaderboardParticipantParams, GetIndexerLeaderboardParticipantResponse, RegisterLeaderboardParams, RegisterLeaderboardResponse, GetIndexerLeaderboardRegistrationsParams, GetIndexerLeaderboardRegistrationsResponse, GetIndexerLeaderboardContestsParams, GetIndexerLeaderboardContestsResponse, GetIndexerFastWithdrawalSignatureParams, GetIndexerFastWithdrawalSignatureResponse, GetIndexerNlpSnapshotsParams, GetIndexerNlpSnapshotsResponse, GetIndexerSubaccountDDAParams, GetIndexerSubaccountDDAResponse, GetIndexerBacklogResponse, GetIndexerPrivateAlphaChoiceParams, GetIndexerPrivateAlphaChoiceResponse, GetIndexerPointsParams, GetIndexerPointsResponse, ConnectSocialAccountParams, ConnectSocialAccountResponse, ListIndexerSocialAccountsParams, ListIndexerSocialAccountsResponse, RevokeSocialAccountParams, RevokeSocialAccountResponse, GetIndexerV2TickersParams, GetIndexerV2TickersResponse, GetIndexerV2SymbolsParams, GetIndexerV2SymbolsResponse } from './types/clientTypes.cjs';
4
- import { IndexerServerQueryRequestType, IndexerServerQueryRequestByType, IndexerServerQueryResponseByType } from './types/serverTypes.cjs';
5
- import 'bignumber.js';
6
- import 'viem';
7
- import './types/CandlestickPeriod.cjs';
8
- import './types/IndexerEventType.cjs';
9
- import './types/IndexerLeaderboardType.cjs';
10
- import './types/NadoTx.cjs';
11
- import './types/serverModelTypes.cjs';
12
- import '@nadohq/engine-client';
1
+ import { dt as IndexerServerQueryRequestByType, ft as IndexerServerQueryRequestType, pt as IndexerServerQueryResponseByType } from "./serverTypes-BMSNh2GK.cjs";
2
+ import { $ as GetIndexerPointsResponse, $t as RegisterLeaderboardResponse, A as GetIndexerMakerStatisticsParams, B as GetIndexerMultiProductSnapshotsParams, C as GetIndexerLeaderboardParticipantParams, D as GetIndexerLeaderboardResponse, E as GetIndexerLeaderboardRegistrationsResponse, F as GetIndexerMatchEventsResponse, G as GetIndexerNlpSnapshotsResponse, H as GetIndexerMultiSubaccountSnapshotsParams, I as GetIndexerMultiProductFundingRatesParams, J as GetIndexerOrdersParams, Jt as ListIndexerSocialAccountsParams, K as GetIndexerOraclePricesParams, L as GetIndexerMultiProductFundingRatesResponse, M as GetIndexerMarketSnapshotsParams, N as GetIndexerMarketSnapshotsResponse, O as GetIndexerLinkedSignerParams, P as GetIndexerMatchEventsParams, Q as GetIndexerPointsParams, Qt as RegisterLeaderboardParams, R as GetIndexerMultiProductPerpPricesParams, S as GetIndexerLeaderboardParams, T as GetIndexerLeaderboardRegistrationsParams, U as GetIndexerMultiSubaccountSnapshotsResponse, V as GetIndexerMultiProductSnapshotsResponse, W as GetIndexerNlpSnapshotsParams, X as GetIndexerPerpPricesParams, Xt as ListIndexerSubaccountsParams, Y as GetIndexerOrdersResponse, Yt as ListIndexerSocialAccountsResponse, Z as GetIndexerPerpPricesResponse, Zt as ListIndexerSubaccountsResponse, _ as GetIndexerFundingRateResponse, a as GetIndexerCandlesticksParams, at as GetIndexerReferralCodeParams, b as GetIndexerLeaderboardContestsParams, c as GetIndexerEdgeCandlesticksResponse, ct as GetIndexerSubaccountDDAResponse, dt as GetIndexerV2TickersParams, en as RevokeSocialAccountParams, et as GetIndexerPrivateAlphaChoiceParams, f as GetIndexerEventsParams, ft as GetIndexerV2TickersResponse, g as GetIndexerFundingRateParams, h as GetIndexerFastWithdrawalSignatureResponse, i as GetIndexerBacklogResponse, it as GetIndexerQuotePriceResponse, j as GetIndexerMakerStatisticsResponse, k as GetIndexerLinkedSignerResponse, l as GetIndexerEdgeMarketSnapshotResponse, lt as GetIndexerV2SymbolsParams, m as GetIndexerFastWithdrawalSignatureParams, n as ConnectSocialAccountParams, nt as GetIndexerProductSnapshotsParams, o as GetIndexerCandlesticksResponse, ot as GetIndexerReferralCodeResponse, p as GetIndexerEventsResponse, q as GetIndexerOraclePricesResponse, r as ConnectSocialAccountResponse, rt as GetIndexerProductSnapshotsResponse, s as GetIndexerEdgeCandlesticksParams, st as GetIndexerSubaccountDDAParams, tn as RevokeSocialAccountResponse, tt as GetIndexerPrivateAlphaChoiceResponse, u as GetIndexerEdgeMarketSnapshotsParams, ut as GetIndexerV2SymbolsResponse, v as GetIndexerInterestFundingPaymentsParams, w as GetIndexerLeaderboardParticipantResponse, x as GetIndexerLeaderboardContestsResponse, y as GetIndexerInterestFundingPaymentsResponse, z as GetIndexerMultiProductPerpPricesResponse } from "./clientTypes-BsJ2yIC4.cjs";
3
+ import { SignableRequestType, SignableRequestTypeToParams, WalletClientWithAccount } from "@nadohq/shared";
4
+ import { AxiosInstance } from "axios";
13
5
 
6
+ //#region src/IndexerBaseClient.d.ts
14
7
  interface IndexerClientOpts {
15
- url: string;
16
- v2Url?: string;
17
- walletClient?: WalletClientWithAccount;
18
- linkedSignerWalletClient?: WalletClientWithAccount;
8
+ url: string;
9
+ v2Url?: string;
10
+ walletClient?: WalletClientWithAccount;
11
+ linkedSignerWalletClient?: WalletClientWithAccount;
19
12
  }
20
13
  /**
21
14
  * Base client for all indexer requests
22
15
  */
23
16
  declare class IndexerBaseClient {
24
- readonly opts: IndexerClientOpts;
25
- readonly v2Url: string;
26
- readonly axiosInstance: AxiosInstance;
27
- constructor(opts: IndexerClientOpts);
28
- /**
29
- * Sets the linked signer for execute requests
30
- *
31
- * @param linkedSignerWalletClient The linkedSigner to use for all signatures. Set to null to revert to the chain signer
32
- */
33
- setLinkedSigner(linkedSignerWalletClient: WalletClientWithAccount | null): void;
34
- /**
35
- * List all subaccounts
36
- *
37
- * @param params
38
- */
39
- listSubaccounts(params: ListIndexerSubaccountsParams): Promise<ListIndexerSubaccountsResponse>;
40
- /**
41
- * Retrieve snapshots of multiple subaccounts at multiple points in time.
42
- * Each snapshot is a view of the subaccount's balances at this point in time, with tracked variables for interest, funding, etc.
43
- *
44
- * @param params
45
- */
46
- getMultiSubaccountSnapshots(params: GetIndexerMultiSubaccountSnapshotsParams): Promise<GetIndexerMultiSubaccountSnapshotsResponse>;
47
- /**
48
- * Retrieves referral code for an address
49
- *
50
- * @param params
51
- */
52
- getReferralCode(params: GetIndexerReferralCodeParams): Promise<GetIndexerReferralCodeResponse>;
53
- /**
54
- * Retrieves funding rate for a product, where 1 = 100%
55
- * @param params
56
- */
57
- getFundingRate(params: GetIndexerFundingRateParams): Promise<GetIndexerFundingRateResponse>;
58
- /**
59
- * Retrieves funding rate for multiple products, where 1 = 100%
60
- * @param params
61
- */
62
- getMultiProductFundingRates(params: GetIndexerMultiProductFundingRatesParams): Promise<GetIndexerMultiProductFundingRatesResponse>;
63
- /**
64
- * Retrieves latest mark/index price for a perp product
65
- * @param params
66
- */
67
- getPerpPrices(params: GetIndexerPerpPricesParams): Promise<GetIndexerPerpPricesResponse>;
68
- /**
69
- * Retrieves latest mark/index price for multiple perp products
70
- * @param params
71
- */
72
- getMultiProductPerpPrices(params: GetIndexerMultiProductPerpPricesParams): Promise<GetIndexerMultiProductPerpPricesResponse>;
73
- /**
74
- * Retrieves latest oracle prices for provided products
75
- * @param params
76
- */
77
- getOraclePrices(params: GetIndexerOraclePricesParams): Promise<GetIndexerOraclePricesResponse>;
78
- /**
79
- * Retrieves candlesticks for a product
80
- * @param params
81
- */
82
- getCandlesticks(params: GetIndexerCandlesticksParams): Promise<GetIndexerCandlesticksResponse>;
83
- /**
84
- * Retrieves candlesticks for a product from Edge
85
- * @param params
86
- */
87
- getEdgeCandlesticks(params: GetIndexerEdgeCandlesticksParams): Promise<GetIndexerEdgeCandlesticksResponse>;
88
- /**
89
- * Retrieves historical snapshots for a product
90
- * @param params
91
- */
92
- getProductSnapshots(params: GetIndexerProductSnapshotsParams): Promise<GetIndexerProductSnapshotsResponse>;
93
- /**
94
- * Retrieves historical snapshots for multiple products
95
- * @param params
96
- */
97
- getMultiProductSnapshots(params: GetIndexerMultiProductSnapshotsParams): Promise<GetIndexerMultiProductSnapshotsResponse>;
98
- /**
99
- * Retrieves historical events
100
- *
101
- * @param params
102
- */
103
- getEvents(params: GetIndexerEventsParams): Promise<GetIndexerEventsResponse>;
104
- /**
105
- * Retrieves historical orders
106
- * @param params
107
- */
108
- getOrders(params: GetIndexerOrdersParams): Promise<GetIndexerOrdersResponse>;
109
- /**
110
- * Gets match order events, this will return the same events as the events query, but with additional information
111
- * to identify the order that was matched
112
- *
113
- * @param params
114
- */
115
- getMatchEvents(params: GetIndexerMatchEventsParams): Promise<GetIndexerMatchEventsResponse>;
116
- /**
117
- * Retrieves historical funding & interest payments.
118
- * NOTE: `limit` is an upperbound. If a user changes position size such that his position is 0 during each funding/interest tick,
119
- * then the indexer will return fewer than `limit` results per page. However, more events can be present. This means that
120
- * there isn't a reliable way to determine whether there is a next page. We just need to keep paginating until the next cursor is null.
121
- *
122
- * @param params
123
- */
124
- getInterestFundingPayments(params: GetIndexerInterestFundingPaymentsParams): Promise<GetIndexerInterestFundingPaymentsResponse>;
125
- /**
126
- * Gets quote (USDT) price in terms of USD
127
- */
128
- getQuotePrice(): Promise<GetIndexerQuotePriceResponse>;
129
- /**
130
- * Fetches currently registered linked signer with the remaining txs allowed for the subaccount
131
- */
132
- getLinkedSignerWithRateLimit(params: GetIndexerLinkedSignerParams): Promise<GetIndexerLinkedSignerResponse>;
133
- /**
134
- * Retrieve historical market snapshots
135
- * @param params
136
- */
137
- getMarketSnapshots(params: GetIndexerMarketSnapshotsParams): Promise<GetIndexerMarketSnapshotsResponse>;
138
- /**
139
- * Retrieve historical market snapshots from Edge
140
- * @param params
141
- */
142
- getEdgeMarketSnapshots(params: GetIndexerEdgeMarketSnapshotsParams): Promise<GetIndexerEdgeMarketSnapshotResponse>;
143
- /**
144
- * Retrieve maker statistics for a given epoch
145
- *
146
- * @param params
147
- */
148
- getMakerStatistics(params: GetIndexerMakerStatisticsParams): Promise<GetIndexerMakerStatisticsResponse>;
149
- /**
150
- * Retrieve leaderboard stats for a given contest
151
- *
152
- * @param params
153
- */
154
- getLeaderboard(params: GetIndexerLeaderboardParams): Promise<GetIndexerLeaderboardResponse>;
155
- /**
156
- * Retrieve leaderboard ranking of a subaccount on a given contest
157
- *
158
- * @param params
159
- */
160
- getLeaderboardParticipant(params: GetIndexerLeaderboardParticipantParams): Promise<GetIndexerLeaderboardParticipantResponse>;
161
- /**
162
- * Registers a subaccount for one or more contests. Requires EIP-712 signing.
163
- *
164
- * @param params - Registration parameters including contest IDs and signing config.
165
- */
166
- registerLeaderboard(params: RegisterLeaderboardParams): Promise<RegisterLeaderboardResponse>;
167
- /**
168
- * Retrieves contest registrations for a subaccount. Supports batch lookup
169
- * across multiple contests with an optional active filter.
170
- *
171
- * @param params - Query parameters including subaccount and contest IDs.
172
- */
173
- getLeaderboardRegistrations(params: GetIndexerLeaderboardRegistrationsParams): Promise<GetIndexerLeaderboardRegistrationsResponse>;
174
- /**
175
- * Retrieve metadata of provided leaderboard contests
176
- *
177
- * @param params
178
- */
179
- getLeaderboardContests(params: GetIndexerLeaderboardContestsParams): Promise<GetIndexerLeaderboardContestsResponse>;
180
- /**
181
- * Retrieve signature and tx to submit a fast withdrawal
182
- *
183
- * @param params
184
- */
185
- getFastWithdrawalSignature(params: GetIndexerFastWithdrawalSignatureParams): Promise<GetIndexerFastWithdrawalSignatureResponse>;
186
- getNlpSnapshots(params: GetIndexerNlpSnapshotsParams): Promise<GetIndexerNlpSnapshotsResponse>;
187
- /**
188
- * Retrieves the subaccount's DDA (Direct Deposit Address)
189
- * @param params
190
- */
191
- getSubaccountDDA(params: GetIndexerSubaccountDDAParams): Promise<GetIndexerSubaccountDDAResponse>;
192
- getSequencerBacklog(): Promise<GetIndexerBacklogResponse>;
193
- /**
194
- * Retrieves private alpha choice information for a given address
195
- * @param params
196
- */
197
- getPrivateAlphaChoice(params: GetIndexerPrivateAlphaChoiceParams): Promise<GetIndexerPrivateAlphaChoiceResponse>;
198
- /**
199
- * Retrieves points information for a given address, including points per epoch and all-time points
200
- * @param params
201
- */
202
- getPoints(params: GetIndexerPointsParams): Promise<GetIndexerPointsResponse>;
203
- /**
204
- * Initiates a social account connection flow. Returns a URL the user must visit to complete the OAuth flow.
205
- * Requires EIP-712 signing.
206
- *
207
- * @param params - Connection parameters including provider and signing config.
208
- */
209
- connectSocialAccount(params: ConnectSocialAccountParams): Promise<ConnectSocialAccountResponse>;
210
- /**
211
- * Lists linked social accounts for a given address.
212
- *
213
- * @param params - Query parameters including the wallet address.
214
- */
215
- listSocialAccounts(params: ListIndexerSocialAccountsParams): Promise<ListIndexerSocialAccountsResponse>;
216
- /**
217
- * Revokes a linked social account. Requires EIP-712 signing.
218
- *
219
- * @param params - Revocation parameters including provider and signing config.
220
- */
221
- revokeSocialAccount(params: RevokeSocialAccountParams): Promise<RevokeSocialAccountResponse>;
222
- /**
223
- * Get tickers from the v2 indexer endpoint
224
- * @param params
225
- */
226
- getV2Tickers(params: GetIndexerV2TickersParams): Promise<GetIndexerV2TickersResponse>;
227
- /**
228
- * Get symbols with market hours from the v2 indexer endpoint
229
- * @param params
230
- */
231
- getV2Symbols(params?: GetIndexerV2SymbolsParams): Promise<GetIndexerV2SymbolsResponse>;
232
- protected query<TRequestType extends IndexerServerQueryRequestType>(requestType: TRequestType, params: IndexerServerQueryRequestByType[TRequestType]): Promise<IndexerServerQueryResponseByType[TRequestType]>;
233
- protected sign<T extends SignableRequestType>(requestType: T, verifyingContract: string, chainId: number, params: SignableRequestTypeToParams[T]): Promise<`0x${string}`>;
234
- private checkResponseStatus;
17
+ readonly opts: IndexerClientOpts;
18
+ readonly v2Url: string;
19
+ readonly axiosInstance: AxiosInstance;
20
+ constructor(opts: IndexerClientOpts);
21
+ /**
22
+ * Sets the linked signer for execute requests
23
+ *
24
+ * @param linkedSignerWalletClient The linkedSigner to use for all signatures. Set to null to revert to the chain signer
25
+ */
26
+ setLinkedSigner(linkedSignerWalletClient: WalletClientWithAccount | null): void;
27
+ /**
28
+ * List all subaccounts
29
+ *
30
+ * @param params
31
+ */
32
+ listSubaccounts(params: ListIndexerSubaccountsParams): Promise<ListIndexerSubaccountsResponse>;
33
+ /**
34
+ * Retrieve snapshots of multiple subaccounts at multiple points in time.
35
+ * Each snapshot is a view of the subaccount's balances at this point in time, with tracked variables for interest, funding, etc.
36
+ *
37
+ * @param params
38
+ */
39
+ getMultiSubaccountSnapshots(params: GetIndexerMultiSubaccountSnapshotsParams): Promise<GetIndexerMultiSubaccountSnapshotsResponse>;
40
+ /**
41
+ * Retrieves referral code for an address
42
+ *
43
+ * @param params
44
+ */
45
+ getReferralCode(params: GetIndexerReferralCodeParams): Promise<GetIndexerReferralCodeResponse>;
46
+ /**
47
+ * Retrieves funding rate for a product, where 1 = 100%
48
+ * @param params
49
+ */
50
+ getFundingRate(params: GetIndexerFundingRateParams): Promise<GetIndexerFundingRateResponse>;
51
+ /**
52
+ * Retrieves funding rate for multiple products, where 1 = 100%
53
+ * @param params
54
+ */
55
+ getMultiProductFundingRates(params: GetIndexerMultiProductFundingRatesParams): Promise<GetIndexerMultiProductFundingRatesResponse>;
56
+ /**
57
+ * Retrieves latest mark/index price for a perp product
58
+ * @param params
59
+ */
60
+ getPerpPrices(params: GetIndexerPerpPricesParams): Promise<GetIndexerPerpPricesResponse>;
61
+ /**
62
+ * Retrieves latest mark/index price for multiple perp products
63
+ * @param params
64
+ */
65
+ getMultiProductPerpPrices(params: GetIndexerMultiProductPerpPricesParams): Promise<GetIndexerMultiProductPerpPricesResponse>;
66
+ /**
67
+ * Retrieves latest oracle prices for provided products
68
+ * @param params
69
+ */
70
+ getOraclePrices(params: GetIndexerOraclePricesParams): Promise<GetIndexerOraclePricesResponse>;
71
+ /**
72
+ * Retrieves candlesticks for a product
73
+ * @param params
74
+ */
75
+ getCandlesticks(params: GetIndexerCandlesticksParams): Promise<GetIndexerCandlesticksResponse>;
76
+ /**
77
+ * Retrieves candlesticks for a product from Edge
78
+ * @param params
79
+ */
80
+ getEdgeCandlesticks(params: GetIndexerEdgeCandlesticksParams): Promise<GetIndexerEdgeCandlesticksResponse>;
81
+ /**
82
+ * Retrieves historical snapshots for a product
83
+ * @param params
84
+ */
85
+ getProductSnapshots(params: GetIndexerProductSnapshotsParams): Promise<GetIndexerProductSnapshotsResponse>;
86
+ /**
87
+ * Retrieves historical snapshots for multiple products
88
+ * @param params
89
+ */
90
+ getMultiProductSnapshots(params: GetIndexerMultiProductSnapshotsParams): Promise<GetIndexerMultiProductSnapshotsResponse>;
91
+ /**
92
+ * Retrieves historical events
93
+ *
94
+ * @param params
95
+ */
96
+ getEvents(params: GetIndexerEventsParams): Promise<GetIndexerEventsResponse>;
97
+ /**
98
+ * Retrieves historical orders
99
+ * @param params
100
+ */
101
+ getOrders(params: GetIndexerOrdersParams): Promise<GetIndexerOrdersResponse>;
102
+ /**
103
+ * Gets match order events, this will return the same events as the events query, but with additional information
104
+ * to identify the order that was matched
105
+ *
106
+ * @param params
107
+ */
108
+ getMatchEvents(params: GetIndexerMatchEventsParams): Promise<GetIndexerMatchEventsResponse>;
109
+ /**
110
+ * Retrieves historical funding & interest payments.
111
+ * NOTE: `limit` is an upperbound. If a user changes position size such that his position is 0 during each funding/interest tick,
112
+ * then the indexer will return fewer than `limit` results per page. However, more events can be present. This means that
113
+ * there isn't a reliable way to determine whether there is a next page. We just need to keep paginating until the next cursor is null.
114
+ *
115
+ * @param params
116
+ */
117
+ getInterestFundingPayments(params: GetIndexerInterestFundingPaymentsParams): Promise<GetIndexerInterestFundingPaymentsResponse>;
118
+ /**
119
+ * Gets quote (USDT) price in terms of USD
120
+ */
121
+ getQuotePrice(): Promise<GetIndexerQuotePriceResponse>;
122
+ /**
123
+ * Fetches currently registered linked signer with the remaining txs allowed for the subaccount
124
+ */
125
+ getLinkedSignerWithRateLimit(params: GetIndexerLinkedSignerParams): Promise<GetIndexerLinkedSignerResponse>;
126
+ /**
127
+ * Retrieve historical market snapshots
128
+ * @param params
129
+ */
130
+ getMarketSnapshots(params: GetIndexerMarketSnapshotsParams): Promise<GetIndexerMarketSnapshotsResponse>;
131
+ /**
132
+ * Retrieve historical market snapshots from Edge
133
+ * @param params
134
+ */
135
+ getEdgeMarketSnapshots(params: GetIndexerEdgeMarketSnapshotsParams): Promise<GetIndexerEdgeMarketSnapshotResponse>;
136
+ /**
137
+ * Retrieve maker statistics for a given epoch
138
+ *
139
+ * @param params
140
+ */
141
+ getMakerStatistics(params: GetIndexerMakerStatisticsParams): Promise<GetIndexerMakerStatisticsResponse>;
142
+ /**
143
+ * Retrieve leaderboard stats for a given contest
144
+ *
145
+ * @param params
146
+ */
147
+ getLeaderboard(params: GetIndexerLeaderboardParams): Promise<GetIndexerLeaderboardResponse>;
148
+ /**
149
+ * Retrieve leaderboard ranking of a subaccount on a given contest
150
+ *
151
+ * @param params
152
+ */
153
+ getLeaderboardParticipant(params: GetIndexerLeaderboardParticipantParams): Promise<GetIndexerLeaderboardParticipantResponse>;
154
+ /**
155
+ * Registers a subaccount for one or more contests. Requires EIP-712 signing.
156
+ *
157
+ * @param params - Registration parameters including contest IDs and signing config.
158
+ */
159
+ registerLeaderboard(params: RegisterLeaderboardParams): Promise<RegisterLeaderboardResponse>;
160
+ /**
161
+ * Retrieves contest registrations for a subaccount. Supports batch lookup
162
+ * across multiple contests with an optional active filter.
163
+ *
164
+ * @param params - Query parameters including subaccount and contest IDs.
165
+ */
166
+ getLeaderboardRegistrations(params: GetIndexerLeaderboardRegistrationsParams): Promise<GetIndexerLeaderboardRegistrationsResponse>;
167
+ /**
168
+ * Retrieve metadata of provided leaderboard contests
169
+ *
170
+ * @param params
171
+ */
172
+ getLeaderboardContests(params: GetIndexerLeaderboardContestsParams): Promise<GetIndexerLeaderboardContestsResponse>;
173
+ /**
174
+ * Retrieve signature and tx to submit a fast withdrawal
175
+ *
176
+ * @param params
177
+ */
178
+ getFastWithdrawalSignature(params: GetIndexerFastWithdrawalSignatureParams): Promise<GetIndexerFastWithdrawalSignatureResponse>;
179
+ getNlpSnapshots(params: GetIndexerNlpSnapshotsParams): Promise<GetIndexerNlpSnapshotsResponse>;
180
+ /**
181
+ * Retrieves the subaccount's DDA (Direct Deposit Address)
182
+ * @param params
183
+ */
184
+ getSubaccountDDA(params: GetIndexerSubaccountDDAParams): Promise<GetIndexerSubaccountDDAResponse>;
185
+ getSequencerBacklog(): Promise<GetIndexerBacklogResponse>;
186
+ /**
187
+ * Retrieves private alpha choice information for a given address
188
+ * @param params
189
+ */
190
+ getPrivateAlphaChoice(params: GetIndexerPrivateAlphaChoiceParams): Promise<GetIndexerPrivateAlphaChoiceResponse>;
191
+ /**
192
+ * Retrieves points information for a given address, including points per epoch and all-time points
193
+ * @param params
194
+ */
195
+ getPoints(params: GetIndexerPointsParams): Promise<GetIndexerPointsResponse>;
196
+ /**
197
+ * Initiates a social account connection flow. Returns a URL the user must visit to complete the OAuth flow.
198
+ * Requires EIP-712 signing.
199
+ *
200
+ * @param params - Connection parameters including provider and signing config.
201
+ */
202
+ connectSocialAccount(params: ConnectSocialAccountParams): Promise<ConnectSocialAccountResponse>;
203
+ /**
204
+ * Lists linked social accounts for a given address.
205
+ *
206
+ * @param params - Query parameters including the wallet address.
207
+ */
208
+ listSocialAccounts(params: ListIndexerSocialAccountsParams): Promise<ListIndexerSocialAccountsResponse>;
209
+ /**
210
+ * Revokes a linked social account. Requires EIP-712 signing.
211
+ *
212
+ * @param params - Revocation parameters including provider and signing config.
213
+ */
214
+ revokeSocialAccount(params: RevokeSocialAccountParams): Promise<RevokeSocialAccountResponse>;
215
+ /**
216
+ * Get tickers from the v2 indexer endpoint
217
+ * @param params
218
+ */
219
+ getV2Tickers(params: GetIndexerV2TickersParams): Promise<GetIndexerV2TickersResponse>;
220
+ /**
221
+ * Get symbols with market hours from the v2 indexer endpoint
222
+ * @param params
223
+ */
224
+ getV2Symbols(params?: GetIndexerV2SymbolsParams): Promise<GetIndexerV2SymbolsResponse>;
225
+ protected query<TRequestType extends IndexerServerQueryRequestType>(requestType: TRequestType, params: IndexerServerQueryRequestByType[TRequestType]): Promise<IndexerServerQueryResponseByType[TRequestType]>;
226
+ protected sign<T extends SignableRequestType>(requestType: T, verifyingContract: string, chainId: number, params: SignableRequestTypeToParams[T]): Promise<`0x${string}`>;
227
+ private checkResponseStatus;
235
228
  }
236
-
237
- export { IndexerBaseClient, type IndexerClientOpts };
229
+ //#endregion
230
+ export { IndexerBaseClient, IndexerClientOpts };
231
+ //# sourceMappingURL=IndexerBaseClient.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IndexerBaseClient.d.cts","names":[],"sources":["../src/src/IndexerBaseClient.ts"],"mappings":";;;;;;UAkIiB,iBAAA;EAEf,GAAA;EACA,KAAA;EAEA,YAAA,GAAe,uBAAA;EAEf,wBAAA,GAA2B,uBAAuB;AAAA;;;;cAQvC,iBAAA;EAAA,SACF,IAAA,EAAM,iBAAA;EAAA,SACN,KAAA;EAAA,SACA,aAAA,EAAe,aAAA;cAEZ,IAAA,EAAM,iBAAA;EAbgC;AAAA;AAQpD;;;EAoBS,eAAA,CACL,wBAAA,EAA0B,uBAAA;EAlBJ;;;;;EA4BlB,eAAA,CACJ,MAAA,EAAQ,4BAAA,GACP,OAAA,CAAQ,8BAAA;EAqBD;;;;;;EADJ,2BAAA,CACJ,MAAA,EAAQ,wCAAA,GACP,OAAA,CAAQ,0CAAA;EAmEA;;;;;EArBL,eAAA,CACJ,MAAA,EAAQ,4BAAA,GACP,OAAA,CAAQ,8BAAA;EA+CA;;;;EA9BL,cAAA,CACJ,MAAA,EAAQ,2BAAA,GACP,OAAA,CAAQ,6BAAA;EAuDD;;;;EA3CJ,2BAAA,CACJ,MAAA,EAAQ,wCAAA,GACP,OAAA,CAAQ,0CAAA;EA8DR;;;;EAlDG,aAAA,CACJ,MAAA,EAAQ,0BAAA,GACP,O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