@nadohq/indexer-client 0.1.0-alpha.2 → 0.1.0-alpha.21

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 (66) hide show
  1. package/dist/IndexerBaseClient.cjs +83 -57
  2. package/dist/IndexerBaseClient.cjs.map +1 -1
  3. package/dist/IndexerBaseClient.d.cts +13 -4
  4. package/dist/IndexerBaseClient.d.ts +13 -4
  5. package/dist/IndexerBaseClient.js +36 -9
  6. package/dist/IndexerBaseClient.js.map +1 -1
  7. package/dist/IndexerClient.cjs +17 -16
  8. package/dist/IndexerClient.cjs.map +1 -1
  9. package/dist/IndexerClient.d.cts +2 -3
  10. package/dist/IndexerClient.d.ts +2 -3
  11. package/dist/IndexerClient.js +6 -3
  12. package/dist/IndexerClient.js.map +1 -1
  13. package/dist/dataMappers.cjs +119 -109
  14. package/dist/dataMappers.cjs.map +1 -1
  15. package/dist/dataMappers.d.cts +5 -5
  16. package/dist/dataMappers.d.ts +5 -5
  17. package/dist/dataMappers.js +26 -18
  18. package/dist/dataMappers.js.map +1 -1
  19. package/dist/endpoints.cjs +2 -2
  20. package/dist/endpoints.cjs.map +1 -1
  21. package/dist/endpoints.d.cts +1 -1
  22. package/dist/endpoints.d.ts +1 -1
  23. package/dist/endpoints.js +2 -2
  24. package/dist/endpoints.js.map +1 -1
  25. package/dist/index.cjs +6 -4
  26. package/dist/index.cjs.map +1 -1
  27. package/dist/index.d.cts +10 -11
  28. package/dist/index.d.ts +10 -11
  29. package/dist/index.js +3 -2
  30. package/dist/index.js.map +1 -1
  31. package/dist/types/clientTypes.cjs.map +1 -1
  32. package/dist/types/clientTypes.d.cts +64 -11
  33. package/dist/types/clientTypes.d.ts +64 -11
  34. package/dist/types/index.cjs +11 -11
  35. package/dist/types/index.cjs.map +1 -1
  36. package/dist/types/index.d.cts +6 -7
  37. package/dist/types/index.d.ts +6 -7
  38. package/dist/types/index.js +5 -5
  39. package/dist/types/index.js.map +1 -1
  40. package/dist/types/paginatedEventsTypes.cjs.map +1 -1
  41. package/dist/types/paginatedEventsTypes.d.cts +6 -7
  42. package/dist/types/paginatedEventsTypes.d.ts +6 -7
  43. package/dist/types/serverModelTypes.cjs.map +1 -1
  44. package/dist/types/serverModelTypes.d.cts +8 -4
  45. package/dist/types/serverModelTypes.d.ts +8 -4
  46. package/dist/types/serverTypes.cjs.map +1 -1
  47. package/dist/types/serverTypes.d.cts +36 -5
  48. package/dist/types/serverTypes.d.ts +36 -5
  49. package/dist/utils/index.d.cts +2 -3
  50. package/dist/utils/index.d.ts +2 -3
  51. package/dist/utils/indexerBalanceValue.cjs.map +1 -1
  52. package/dist/utils/indexerBalanceValue.d.cts +2 -3
  53. package/dist/utils/indexerBalanceValue.d.ts +2 -3
  54. package/dist/utils/indexerBalanceValue.js.map +1 -1
  55. package/package.json +4 -5
  56. package/src/IndexerBaseClient.ts +55 -13
  57. package/src/IndexerClient.ts +9 -6
  58. package/src/dataMappers.ts +33 -21
  59. package/src/endpoints.ts +2 -2
  60. package/src/index.ts +3 -2
  61. package/src/types/clientTypes.ts +77 -12
  62. package/src/types/index.ts +5 -5
  63. package/src/types/paginatedEventsTypes.ts +2 -3
  64. package/src/types/serverModelTypes.ts +8 -4
  65. package/src/types/serverTypes.ts +48 -5
  66. package/src/utils/indexerBalanceValue.ts +1 -1
@@ -1,11 +1,10 @@
1
- import { Subaccount, ProductEngineType, SpotBalance, SpotMarket, PerpBalance, PerpMarket, Market, OrderExpirationType, EIP712OrderValues } from '@nadohq/contracts';
2
- import { BigDecimal } from '@nadohq/utils';
3
- import { Hex } from 'viem';
1
+ import { Subaccount, BigDecimal, ProductEngineType, SpotBalance, SpotMarket, PerpBalance, PerpMarket, Market, OrderAppendix, EIP712OrderValues } from '@nadohq/shared';
2
+ import { Hex, Address } from 'viem';
4
3
  import { CandlestickPeriod } from './CandlestickPeriod.js';
5
4
  import { IndexerEventType } from './IndexerEventType.js';
6
5
  import { IndexerLeaderboardRankType } from './IndexerLeaderboardType.js';
7
- import { IndexerServerListSubaccountsParams, IndexerServerFastWithdrawalSignatureParams } from './serverTypes.js';
8
6
  import { NadoTx, NadoWithdrawCollateralTx } from './NadoTx.js';
7
+ import { IndexerServerListSubaccountsParams, IndexerServerTriggerTypeFilter, IndexerServerFastWithdrawalSignatureParams } from './serverTypes.js';
9
8
  import './serverModelTypes.js';
10
9
  import '@nadohq/engine-client';
11
10
 
@@ -34,6 +33,7 @@ interface IndexerBalanceTrackedVars {
34
33
  netFundingCumulative: BigDecimal;
35
34
  netEntryUnrealized: BigDecimal;
36
35
  netEntryCumulative: BigDecimal;
36
+ quoteVolumeCumulative: BigDecimal;
37
37
  }
38
38
  interface IndexerEvent<TStateType extends IndexerEventBalanceStateSnapshot = IndexerEventBalanceStateSnapshot> {
39
39
  subaccount: string;
@@ -226,21 +226,19 @@ interface GetIndexerOrdersParams {
226
226
  maxTimestampInclusive?: number;
227
227
  limit?: number;
228
228
  productIds?: number[];
229
+ triggerTypes?: IndexerServerTriggerTypeFilter[];
229
230
  isolated?: boolean;
230
231
  digests?: string[];
231
232
  }
232
233
  interface IndexerOrder {
233
234
  digest: string;
234
235
  subaccount: string;
235
- isolated: boolean;
236
236
  productId: number;
237
237
  submissionIndex: string;
238
238
  amount: BigDecimal;
239
239
  price: BigDecimal;
240
- rawExpiration: BigDecimal;
241
- isReduceOnly: boolean;
242
- orderType: OrderExpirationType;
243
240
  expiration: number;
241
+ appendix: OrderAppendix;
244
242
  nonce: BigDecimal;
245
243
  recvTimeSeconds: number;
246
244
  baseFilled: BigDecimal;
@@ -445,8 +443,8 @@ interface IndexerNlpSnapshot {
445
443
  timestamp: BigDecimal;
446
444
  cumulativeVolume: BigDecimal;
447
445
  cumulativeTrades: BigDecimal;
448
- cumulativeMintAmountUsdc: BigDecimal;
449
- cumulativeBurnAmountUsdc: BigDecimal;
446
+ cumulativeMintAmountQuote: BigDecimal;
447
+ cumulativeBurnAmountQuote: BigDecimal;
450
448
  cumulativePnl: BigDecimal;
451
449
  tvl: BigDecimal;
452
450
  oraclePrice: BigDecimal;
@@ -463,5 +461,60 @@ interface GetIndexerBacklogResponse {
463
461
  backlogEtaInSeconds: BigDecimal | null;
464
462
  txsPerSecond: BigDecimal | null;
465
463
  }
464
+ interface GetIndexerSubaccountDDAParams {
465
+ subaccount: Subaccount;
466
+ }
467
+ interface GetIndexerSubaccountDDAResponse {
468
+ address: Address;
469
+ }
470
+ /**
471
+ * V2 Tickers
472
+ */
473
+ /**
474
+ * Market type for ticker filtering
475
+ */
476
+ type TickerMarketType = 'spot' | 'perp';
477
+ /**
478
+ * Parameters for querying v2 tickers endpoint
479
+ */
480
+ interface GetIndexerV2TickersParams {
481
+ /**
482
+ * Filter tickers by market type (spot or perp)
483
+ * @example 'spot'
484
+ * @example 'perp'
485
+ */
486
+ market?: TickerMarketType;
487
+ /**
488
+ * Whether to include edge products
489
+ * @default false
490
+ */
491
+ edge?: boolean;
492
+ }
493
+ /**
494
+ * Individual ticker data from v2 endpoint
495
+ */
496
+ interface IndexerV2TickerResponse {
497
+ /** Unique product identifier */
498
+ productId: number;
499
+ /** Unique ticker identifier */
500
+ tickerId: string;
501
+ /** Base currency symbol */
502
+ baseCurrency: string;
503
+ /** Quote currency symbol */
504
+ quoteCurrency: string;
505
+ /** Last traded price */
506
+ lastPrice: number;
507
+ /** 24h trading volume in base currency */
508
+ baseVolume: number;
509
+ /** 24h trading volume in quote currency */
510
+ quoteVolume: number;
511
+ /** 24h price change percentage */
512
+ priceChangePercent24h: number;
513
+ }
514
+ /**
515
+ * Response from v2 tickers endpoint
516
+ * Maps ticker IDs to their respective ticker data
517
+ */
518
+ type GetIndexerV2TickersResponse = Record<string, IndexerV2TickerResponse>;
466
519
 
467
- export type { Candlestick, GetIndexerBacklogResponse, GetIndexerCandlesticksParams, GetIndexerCandlesticksResponse, GetIndexerEdgeCandlesticksParams, GetIndexerEdgeCandlesticksResponse, GetIndexerEdgeMarketSnapshotResponse, GetIndexerEdgeMarketSnapshotsParams, GetIndexerEventsLimitType, GetIndexerEventsParams, GetIndexerEventsResponse, GetIndexerFastWithdrawalSignatureParams, GetIndexerFastWithdrawalSignatureResponse, GetIndexerFundingRateParams, GetIndexerFundingRateResponse, GetIndexerInterestFundingPaymentsParams, GetIndexerInterestFundingPaymentsResponse, GetIndexerLeaderboardContestsParams, GetIndexerLeaderboardContestsResponse, GetIndexerLeaderboardParams, GetIndexerLeaderboardParticipantParams, GetIndexerLeaderboardParticipantResponse, GetIndexerLeaderboardRegistrationParams, GetIndexerLeaderboardRegistrationResponse, GetIndexerLeaderboardResponse, GetIndexerLinkedSignerParams, GetIndexerLinkedSignerResponse, GetIndexerMakerStatisticsParams, GetIndexerMakerStatisticsResponse, GetIndexerMarketSnapshotsParams, GetIndexerMarketSnapshotsResponse, GetIndexerMatchEventsParams, GetIndexerMatchEventsResponse, GetIndexerMultiProductFundingRatesParams, GetIndexerMultiProductFundingRatesResponse, GetIndexerMultiProductPerpPricesParams, GetIndexerMultiProductPerpPricesResponse, GetIndexerMultiProductSnapshotsParams, GetIndexerMultiProductSnapshotsResponse, GetIndexerMultiSubaccountSnapshotsParams, GetIndexerMultiSubaccountSnapshotsResponse, GetIndexerNlpSnapshotsParams, GetIndexerNlpSnapshotsResponse, GetIndexerOraclePricesParams, GetIndexerOraclePricesResponse, GetIndexerOrdersParams, GetIndexerOrdersResponse, GetIndexerPerpPricesParams, GetIndexerPerpPricesResponse, GetIndexerProductSnapshotsParams, GetIndexerProductSnapshotsResponse, GetIndexerQuotePriceResponse, GetIndexerReferralCodeParams, GetIndexerReferralCodeResponse, IndexerBalanceTrackedVars, IndexerEvent, IndexerEventBalanceStateSnapshot, IndexerEventPerpStateSnapshot, IndexerEventSpotStateSnapshot, IndexerEventWithTx, IndexerFundingRate, IndexerLeaderboardContest, IndexerLeaderboardParticipant, IndexerLeaderboardRegistration, IndexerMaker, IndexerMakerSnapshot, IndexerMarketSnapshot, IndexerMatchEvent, IndexerMatchEventBalances, IndexerNlpSnapshot, IndexerOraclePrice, IndexerOrder, IndexerPerpBalance, IndexerPerpPrices, IndexerProductPayment, IndexerProductSnapshot, IndexerSnapshotBalance, IndexerSnapshotsIntervalParams, IndexerSpotBalance, IndexerSubaccountSnapshot, ListIndexerSubaccountsParams, ListIndexerSubaccountsResponse, UpdateIndexerLeaderboardRegistrationParams, UpdateIndexerLeaderboardRegistrationResponse };
520
+ export type { Candlestick, GetIndexerBacklogResponse, GetIndexerCandlesticksParams, GetIndexerCandlesticksResponse, GetIndexerEdgeCandlesticksParams, GetIndexerEdgeCandlesticksResponse, GetIndexerEdgeMarketSnapshotResponse, GetIndexerEdgeMarketSnapshotsParams, GetIndexerEventsLimitType, GetIndexerEventsParams, GetIndexerEventsResponse, GetIndexerFastWithdrawalSignatureParams, GetIndexerFastWithdrawalSignatureResponse, GetIndexerFundingRateParams, GetIndexerFundingRateResponse, GetIndexerInterestFundingPaymentsParams, GetIndexerInterestFundingPaymentsResponse, GetIndexerLeaderboardContestsParams, GetIndexerLeaderboardContestsResponse, GetIndexerLeaderboardParams, GetIndexerLeaderboardParticipantParams, GetIndexerLeaderboardParticipantResponse, GetIndexerLeaderboardRegistrationParams, GetIndexerLeaderboardRegistrationResponse, GetIndexerLeaderboardResponse, GetIndexerLinkedSignerParams, GetIndexerLinkedSignerResponse, GetIndexerMakerStatisticsParams, GetIndexerMakerStatisticsResponse, GetIndexerMarketSnapshotsParams, GetIndexerMarketSnapshotsResponse, GetIndexerMatchEventsParams, GetIndexerMatchEventsResponse, GetIndexerMultiProductFundingRatesParams, GetIndexerMultiProductFundingRatesResponse, GetIndexerMultiProductPerpPricesParams, GetIndexerMultiProductPerpPricesResponse, GetIndexerMultiProductSnapshotsParams, GetIndexerMultiProductSnapshotsResponse, GetIndexerMultiSubaccountSnapshotsParams, GetIndexerMultiSubaccountSnapshotsResponse, GetIndexerNlpSnapshotsParams, GetIndexerNlpSnapshotsResponse, GetIndexerOraclePricesParams, GetIndexerOraclePricesResponse, GetIndexerOrdersParams, GetIndexerOrdersResponse, GetIndexerPerpPricesParams, GetIndexerPerpPricesResponse, GetIndexerProductSnapshotsParams, GetIndexerProductSnapshotsResponse, GetIndexerQuotePriceResponse, GetIndexerReferralCodeParams, GetIndexerReferralCodeResponse, GetIndexerSubaccountDDAParams, GetIndexerSubaccountDDAResponse, GetIndexerV2TickersParams, GetIndexerV2TickersResponse, IndexerBalanceTrackedVars, IndexerEvent, IndexerEventBalanceStateSnapshot, IndexerEventPerpStateSnapshot, IndexerEventSpotStateSnapshot, IndexerEventWithTx, IndexerFundingRate, IndexerLeaderboardContest, IndexerLeaderboardParticipant, IndexerLeaderboardRegistration, IndexerMaker, IndexerMakerSnapshot, IndexerMarketSnapshot, IndexerMatchEvent, IndexerMatchEventBalances, IndexerNlpSnapshot, IndexerOraclePrice, IndexerOrder, IndexerPerpBalance, IndexerPerpPrices, IndexerProductPayment, IndexerProductSnapshot, IndexerSnapshotBalance, IndexerSnapshotsIntervalParams, IndexerSpotBalance, IndexerSubaccountSnapshot, IndexerV2TickerResponse, ListIndexerSubaccountsParams, ListIndexerSubaccountsResponse, TickerMarketType, UpdateIndexerLeaderboardRegistrationParams, UpdateIndexerLeaderboardRegistrationResponse };
@@ -17,25 +17,25 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
17
17
  // src/types/index.ts
18
18
  var types_exports = {};
19
19
  module.exports = __toCommonJS(types_exports);
20
- __reExport(types_exports, require("./clientTypes.cjs"), module.exports);
21
- __reExport(types_exports, require("./paginatedEventsTypes.cjs"), module.exports);
22
- __reExport(types_exports, require("./serverTypes.cjs"), module.exports);
23
- __reExport(types_exports, require("./serverModelTypes.cjs"), module.exports);
24
20
  __reExport(types_exports, require("./CandlestickPeriod.cjs"), module.exports);
21
+ __reExport(types_exports, require("./clientTypes.cjs"), module.exports);
22
+ __reExport(types_exports, require("./collateralEventType.cjs"), module.exports);
25
23
  __reExport(types_exports, require("./IndexerEventType.cjs"), module.exports);
26
24
  __reExport(types_exports, require("./IndexerLeaderboardType.cjs"), module.exports);
27
- __reExport(types_exports, require("./collateralEventType.cjs"), module.exports);
28
25
  __reExport(types_exports, require("./NadoTx.cjs"), module.exports);
26
+ __reExport(types_exports, require("./paginatedEventsTypes.cjs"), module.exports);
27
+ __reExport(types_exports, require("./serverModelTypes.cjs"), module.exports);
28
+ __reExport(types_exports, require("./serverTypes.cjs"), module.exports);
29
29
  // Annotate the CommonJS export names for ESM import in node:
30
30
  0 && (module.exports = {
31
- ...require("./clientTypes.cjs"),
32
- ...require("./paginatedEventsTypes.cjs"),
33
- ...require("./serverTypes.cjs"),
34
- ...require("./serverModelTypes.cjs"),
35
31
  ...require("./CandlestickPeriod.cjs"),
32
+ ...require("./clientTypes.cjs"),
33
+ ...require("./collateralEventType.cjs"),
36
34
  ...require("./IndexerEventType.cjs"),
37
35
  ...require("./IndexerLeaderboardType.cjs"),
38
- ...require("./collateralEventType.cjs"),
39
- ...require("./NadoTx.cjs")
36
+ ...require("./NadoTx.cjs"),
37
+ ...require("./paginatedEventsTypes.cjs"),
38
+ ...require("./serverModelTypes.cjs"),
39
+ ...require("./serverTypes.cjs")
40
40
  });
41
41
  //# sourceMappingURL=index.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/types/index.ts"],"sourcesContent":["export * from './clientTypes';\nexport * from './paginatedEventsTypes';\nexport * from './serverTypes';\nexport * from './serverModelTypes';\nexport * from './CandlestickPeriod';\nexport * from './IndexerEventType';\nexport * from './IndexerLeaderboardType';\nexport * from './collateralEventType';\nexport * from './NadoTx';\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,0BAAc,8BAAd;AACA,0BAAc,uCADd;AAEA,0BAAc,8BAFd;AAGA,0BAAc,mCAHd;AAIA,0BAAc,oCAJd;AAKA,0BAAc,mCALd;AAMA,0BAAc,yCANd;AAOA,0BAAc,sCAPd;AAQA,0BAAc,yBARd;","names":[]}
1
+ {"version":3,"sources":["../../src/types/index.ts"],"sourcesContent":["export * from './CandlestickPeriod';\nexport * from './clientTypes';\nexport * from './collateralEventType';\nexport * from './IndexerEventType';\nexport * from './IndexerLeaderboardType';\nexport * from './NadoTx';\nexport * from './paginatedEventsTypes';\nexport * from './serverModelTypes';\nexport * from './serverTypes';\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,0BAAc,oCAAd;AACA,0BAAc,8BADd;AAEA,0BAAc,sCAFd;AAGA,0BAAc,mCAHd;AAIA,0BAAc,yCAJd;AAKA,0BAAc,yBALd;AAMA,0BAAc,uCANd;AAOA,0BAAc,mCAPd;AAQA,0BAAc,8BARd;","names":[]}
@@ -1,13 +1,12 @@
1
- export { Candlestick, GetIndexerBacklogResponse, GetIndexerCandlesticksParams, GetIndexerCandlesticksResponse, GetIndexerEdgeCandlesticksParams, GetIndexerEdgeCandlesticksResponse, GetIndexerEdgeMarketSnapshotResponse, GetIndexerEdgeMarketSnapshotsParams, GetIndexerEventsLimitType, GetIndexerEventsParams, GetIndexerEventsResponse, GetIndexerFastWithdrawalSignatureParams, GetIndexerFastWithdrawalSignatureResponse, GetIndexerFundingRateParams, GetIndexerFundingRateResponse, GetIndexerInterestFundingPaymentsParams, GetIndexerInterestFundingPaymentsResponse, GetIndexerLeaderboardContestsParams, GetIndexerLeaderboardContestsResponse, GetIndexerLeaderboardParams, GetIndexerLeaderboardParticipantParams, GetIndexerLeaderboardParticipantResponse, GetIndexerLeaderboardRegistrationParams, GetIndexerLeaderboardRegistrationResponse, GetIndexerLeaderboardResponse, GetIndexerLinkedSignerParams, GetIndexerLinkedSignerResponse, GetIndexerMakerStatisticsParams, GetIndexerMakerStatisticsResponse, GetIndexerMarketSnapshotsParams, GetIndexerMarketSnapshotsResponse, GetIndexerMatchEventsParams, GetIndexerMatchEventsResponse, GetIndexerMultiProductFundingRatesParams, GetIndexerMultiProductFundingRatesResponse, GetIndexerMultiProductPerpPricesParams, GetIndexerMultiProductPerpPricesResponse, GetIndexerMultiProductSnapshotsParams, GetIndexerMultiProductSnapshotsResponse, GetIndexerMultiSubaccountSnapshotsParams, GetIndexerMultiSubaccountSnapshotsResponse, GetIndexerNlpSnapshotsParams, GetIndexerNlpSnapshotsResponse, GetIndexerOraclePricesParams, GetIndexerOraclePricesResponse, GetIndexerOrdersParams, GetIndexerOrdersResponse, GetIndexerPerpPricesParams, GetIndexerPerpPricesResponse, GetIndexerProductSnapshotsParams, GetIndexerProductSnapshotsResponse, GetIndexerQuotePriceResponse, GetIndexerReferralCodeParams, GetIndexerReferralCodeResponse, IndexerBalanceTrackedVars, IndexerEvent, IndexerEventBalanceStateSnapshot, IndexerEventPerpStateSnapshot, IndexerEventSpotStateSnapshot, IndexerEventWithTx, IndexerFundingRate, IndexerLeaderboardContest, IndexerLeaderboardParticipant, IndexerLeaderboardRegistration, IndexerMaker, IndexerMakerSnapshot, IndexerMarketSnapshot, IndexerMatchEvent, IndexerMatchEventBalances, IndexerNlpSnapshot, IndexerOraclePrice, IndexerOrder, IndexerPerpBalance, IndexerPerpPrices, IndexerProductPayment, IndexerProductSnapshot, IndexerSnapshotBalance, IndexerSnapshotsIntervalParams, IndexerSpotBalance, IndexerSubaccountSnapshot, ListIndexerSubaccountsParams, ListIndexerSubaccountsResponse, UpdateIndexerLeaderboardRegistrationParams, UpdateIndexerLeaderboardRegistrationResponse } from './clientTypes.cjs';
2
- export { BaseIndexerPaginatedEvent, GetIndexerPaginatedInterestFundingPaymentsResponse, GetIndexerPaginatedLeaderboardParams, GetIndexerPaginatedLeaderboardResponse, GetIndexerPaginatedOrdersParams, GetIndexerPaginatedOrdersResponse, GetIndexerSubaccountCollateralEventsParams, GetIndexerSubaccountCollateralEventsResponse, GetIndexerSubaccountInterestFundingPaymentsParams, GetIndexerSubaccountLiquidationEventsParams, GetIndexerSubaccountLiquidationEventsResponse, GetIndexerSubaccountMatchEventParams, GetIndexerSubaccountMatchEventsResponse, GetIndexerSubaccountNlpEventsParams, GetIndexerSubaccountNlpEventsResponse, GetIndexerSubaccountSettlementEventsParams, GetIndexerSubaccountSettlementEventsResponse, IndexerCollateralEvent, IndexerLiquidationEvent, IndexerNlpEvent, IndexerPaginationMeta, IndexerPaginationParams, IndexerSettlementEvent, PaginatedIndexerEventsResponse, WithPaginationMeta } from './paginatedEventsTypes.cjs';
3
- export { IndexerEdgeServerCandlesticksParams, IndexerEdgeServerCandlesticksResponse, IndexerEdgeServerMarketSnapshotsParams, IndexerEdgeServerMarketSnapshotsResponse, IndexerServerBacklogResponse, IndexerServerCandlesticksParams, IndexerServerCandlesticksResponse, IndexerServerEventsParams, IndexerServerEventsResponse, IndexerServerFastWithdrawalSignatureParams, IndexerServerFastWithdrawalSignatureResponse, IndexerServerFundingRate, IndexerServerFundingRateParams, IndexerServerFundingRateResponse, IndexerServerFundingRatesParams, IndexerServerFundingRatesResponse, IndexerServerInterestFundingParams, IndexerServerInterestFundingResponse, IndexerServerLeaderboardContestsParams, IndexerServerLeaderboardContestsResponse, IndexerServerLeaderboardParams, IndexerServerLeaderboardRankParams, IndexerServerLeaderboardRankResponse, IndexerServerLeaderboardRegistrationParams, IndexerServerLeaderboardRegistrationResponse, IndexerServerLeaderboardResponse, IndexerServerLinkedSignerParams, IndexerServerLinkedSignerResponse, IndexerServerListSubaccountsParams, IndexerServerListSubaccountsResponse, IndexerServerMakerStatisticsParams, IndexerServerMakerStatisticsResponse, IndexerServerMarketSnapshotsParams, IndexerServerMarketSnapshotsResponse, IndexerServerMatchEventsParams, IndexerServerMatchEventsResponse, IndexerServerMultiProductsParams, IndexerServerMultiProductsResponse, IndexerServerMultiSubaccountSnapshotsParams, IndexerServerMultiSubaccountSnapshotsResponse, IndexerServerNlpSnapshotsParams, IndexerServerNlpSnapshotsResponse, IndexerServerOraclePricesParams, IndexerServerOraclePricesResponse, IndexerServerOrdersParams, IndexerServerOrdersResponse, IndexerServerPerpPrices, IndexerServerPerpPricesParams, IndexerServerPerpPricesResponse, IndexerServerPriceParams, IndexerServerPriceResponse, IndexerServerProductsParams, IndexerServerProductsResponse, IndexerServerQueryRequestByType, IndexerServerQueryRequestType, IndexerServerQueryResponseByType, IndexerServerReferralCodeParams, IndexerServerReferralCodeResponse, IndexerServerUsdcPriceResponse } from './serverTypes.cjs';
4
- export { IndexerServerBalance, IndexerServerCandlestick, IndexerServerEvent, IndexerServerLeaderboardContest, IndexerServerLeaderboardPosition, IndexerServerLeaderboardRegistration, IndexerServerMaker, IndexerServerMakerData, IndexerServerMarketSnapshot, IndexerServerMarketSnapshotInterval, IndexerServerMatchEvent, IndexerServerMatchEventBalances, IndexerServerNlpSnapshot, IndexerServerOraclePrice, IndexerServerOrder, IndexerServerProduct, IndexerServerProductPayment, IndexerServerProductSnapshot, IndexerServerSnapshotsInterval, IndexerServerTx } from './serverModelTypes.cjs';
5
1
  export { CandlestickPeriod } from './CandlestickPeriod.cjs';
2
+ export { Candlestick, GetIndexerBacklogResponse, GetIndexerCandlesticksParams, GetIndexerCandlesticksResponse, GetIndexerEdgeCandlesticksParams, GetIndexerEdgeCandlesticksResponse, GetIndexerEdgeMarketSnapshotResponse, GetIndexerEdgeMarketSnapshotsParams, GetIndexerEventsLimitType, GetIndexerEventsParams, GetIndexerEventsResponse, GetIndexerFastWithdrawalSignatureParams, GetIndexerFastWithdrawalSignatureResponse, GetIndexerFundingRateParams, GetIndexerFundingRateResponse, GetIndexerInterestFundingPaymentsParams, GetIndexerInterestFundingPaymentsResponse, GetIndexerLeaderboardContestsParams, GetIndexerLeaderboardContestsResponse, GetIndexerLeaderboardParams, GetIndexerLeaderboardParticipantParams, GetIndexerLeaderboardParticipantResponse, GetIndexerLeaderboardRegistrationParams, GetIndexerLeaderboardRegistrationResponse, GetIndexerLeaderboardResponse, GetIndexerLinkedSignerParams, GetIndexerLinkedSignerResponse, GetIndexerMakerStatisticsParams, GetIndexerMakerStatisticsResponse, GetIndexerMarketSnapshotsParams, GetIndexerMarketSnapshotsResponse, GetIndexerMatchEventsParams, GetIndexerMatchEventsResponse, GetIndexerMultiProductFundingRatesParams, GetIndexerMultiProductFundingRatesResponse, GetIndexerMultiProductPerpPricesParams, GetIndexerMultiProductPerpPricesResponse, GetIndexerMultiProductSnapshotsParams, GetIndexerMultiProductSnapshotsResponse, GetIndexerMultiSubaccountSnapshotsParams, GetIndexerMultiSubaccountSnapshotsResponse, GetIndexerNlpSnapshotsParams, GetIndexerNlpSnapshotsResponse, GetIndexerOraclePricesParams, GetIndexerOraclePricesResponse, GetIndexerOrdersParams, GetIndexerOrdersResponse, GetIndexerPerpPricesParams, GetIndexerPerpPricesResponse, GetIndexerProductSnapshotsParams, GetIndexerProductSnapshotsResponse, GetIndexerQuotePriceResponse, GetIndexerReferralCodeParams, GetIndexerReferralCodeResponse, GetIndexerSubaccountDDAParams, GetIndexerSubaccountDDAResponse, GetIndexerV2TickersParams, GetIndexerV2TickersResponse, IndexerBalanceTrackedVars, IndexerEvent, IndexerEventBalanceStateSnapshot, IndexerEventPerpStateSnapshot, IndexerEventSpotStateSnapshot, IndexerEventWithTx, IndexerFundingRate, IndexerLeaderboardContest, IndexerLeaderboardParticipant, IndexerLeaderboardRegistration, IndexerMaker, IndexerMakerSnapshot, IndexerMarketSnapshot, IndexerMatchEvent, IndexerMatchEventBalances, IndexerNlpSnapshot, IndexerOraclePrice, IndexerOrder, IndexerPerpBalance, IndexerPerpPrices, IndexerProductPayment, IndexerProductSnapshot, IndexerSnapshotBalance, IndexerSnapshotsIntervalParams, IndexerSpotBalance, IndexerSubaccountSnapshot, IndexerV2TickerResponse, ListIndexerSubaccountsParams, ListIndexerSubaccountsResponse, TickerMarketType, UpdateIndexerLeaderboardRegistrationParams, UpdateIndexerLeaderboardRegistrationResponse } from './clientTypes.cjs';
3
+ export { CollateralEventType } from './collateralEventType.cjs';
6
4
  export { IndexerEventType } from './IndexerEventType.cjs';
7
5
  export { IndexerLeaderboardRankType } from './IndexerLeaderboardType.cjs';
8
- export { CollateralEventType } from './collateralEventType.cjs';
9
6
  export { NadoDepositCollateralTx, NadoLiquidateSubaccountTx, NadoMatchOrdersRfqTx, NadoMatchOrdersTx, NadoTransferQuoteTx, NadoTx, NadoWithdrawCollateralTx } from './NadoTx.cjs';
10
- import '@nadohq/contracts';
11
- import '@nadohq/utils';
7
+ export { BaseIndexerPaginatedEvent, GetIndexerPaginatedInterestFundingPaymentsResponse, GetIndexerPaginatedLeaderboardParams, GetIndexerPaginatedLeaderboardResponse, GetIndexerPaginatedOrdersParams, GetIndexerPaginatedOrdersResponse, GetIndexerSubaccountCollateralEventsParams, GetIndexerSubaccountCollateralEventsResponse, GetIndexerSubaccountInterestFundingPaymentsParams, GetIndexerSubaccountLiquidationEventsParams, GetIndexerSubaccountLiquidationEventsResponse, GetIndexerSubaccountMatchEventParams, GetIndexerSubaccountMatchEventsResponse, GetIndexerSubaccountNlpEventsParams, GetIndexerSubaccountNlpEventsResponse, GetIndexerSubaccountSettlementEventsParams, GetIndexerSubaccountSettlementEventsResponse, IndexerCollateralEvent, IndexerLiquidationEvent, IndexerNlpEvent, IndexerPaginationMeta, IndexerPaginationParams, IndexerSettlementEvent, PaginatedIndexerEventsResponse, WithPaginationMeta } from './paginatedEventsTypes.cjs';
8
+ export { IndexerServerBalance, IndexerServerCandlestick, IndexerServerEvent, IndexerServerLeaderboardContest, IndexerServerLeaderboardPosition, IndexerServerLeaderboardRegistration, IndexerServerMaker, IndexerServerMakerData, IndexerServerMarketSnapshot, IndexerServerMarketSnapshotInterval, IndexerServerMatchEvent, IndexerServerMatchEventBalances, IndexerServerNlpSnapshot, IndexerServerOraclePrice, IndexerServerOrder, IndexerServerProduct, IndexerServerProductPayment, IndexerServerProductSnapshot, IndexerServerSnapshotsInterval, IndexerServerTx } from './serverModelTypes.cjs';
9
+ export { IndexerEdgeServerCandlesticksParams, IndexerEdgeServerCandlesticksResponse, IndexerEdgeServerMarketSnapshotsParams, IndexerEdgeServerMarketSnapshotsResponse, IndexerServerBacklogResponse, IndexerServerCandlesticksParams, IndexerServerCandlesticksResponse, IndexerServerDDAQueryParams, IndexerServerDDAResponse, IndexerServerEventsParams, IndexerServerEventsResponse, IndexerServerFastWithdrawalSignatureParams, IndexerServerFastWithdrawalSignatureResponse, IndexerServerFundingRate, IndexerServerFundingRateParams, IndexerServerFundingRateResponse, IndexerServerFundingRatesParams, IndexerServerFundingRatesResponse, IndexerServerInterestFundingParams, IndexerServerInterestFundingResponse, IndexerServerLeaderboardContestsParams, IndexerServerLeaderboardContestsResponse, IndexerServerLeaderboardParams, IndexerServerLeaderboardRankParams, IndexerServerLeaderboardRankResponse, IndexerServerLeaderboardRegistrationParams, IndexerServerLeaderboardRegistrationResponse, IndexerServerLeaderboardResponse, IndexerServerLinkedSignerParams, IndexerServerLinkedSignerResponse, IndexerServerListSubaccountsParams, IndexerServerListSubaccountsResponse, IndexerServerMakerStatisticsParams, IndexerServerMakerStatisticsResponse, IndexerServerMarketSnapshotsParams, IndexerServerMarketSnapshotsResponse, IndexerServerMatchEventsParams, IndexerServerMatchEventsResponse, IndexerServerMultiProductsParams, IndexerServerMultiProductsResponse, IndexerServerMultiSubaccountSnapshotsParams, IndexerServerMultiSubaccountSnapshotsResponse, IndexerServerNlpSnapshotsParams, IndexerServerNlpSnapshotsResponse, IndexerServerOraclePricesParams, IndexerServerOraclePricesResponse, IndexerServerOrdersParams, IndexerServerOrdersResponse, IndexerServerPerpPrices, IndexerServerPerpPricesParams, IndexerServerPerpPricesResponse, IndexerServerPriceParams, IndexerServerPriceResponse, IndexerServerProductsParams, IndexerServerProductsResponse, IndexerServerQueryRequestByType, IndexerServerQueryRequestType, IndexerServerQueryResponseByType, IndexerServerQuotePriceResponse, IndexerServerReferralCodeParams, IndexerServerReferralCodeResponse, IndexerServerTriggerTypeFilter, IndexerServerV2TickerResponse, IndexerServerV2TickersResponse } from './serverTypes.cjs';
10
+ import '@nadohq/shared';
12
11
  import 'viem';
13
12
  import '@nadohq/engine-client';
@@ -1,13 +1,12 @@
1
- export { Candlestick, GetIndexerBacklogResponse, GetIndexerCandlesticksParams, GetIndexerCandlesticksResponse, GetIndexerEdgeCandlesticksParams, GetIndexerEdgeCandlesticksResponse, GetIndexerEdgeMarketSnapshotResponse, GetIndexerEdgeMarketSnapshotsParams, GetIndexerEventsLimitType, GetIndexerEventsParams, GetIndexerEventsResponse, GetIndexerFastWithdrawalSignatureParams, GetIndexerFastWithdrawalSignatureResponse, GetIndexerFundingRateParams, GetIndexerFundingRateResponse, GetIndexerInterestFundingPaymentsParams, GetIndexerInterestFundingPaymentsResponse, GetIndexerLeaderboardContestsParams, GetIndexerLeaderboardContestsResponse, GetIndexerLeaderboardParams, GetIndexerLeaderboardParticipantParams, GetIndexerLeaderboardParticipantResponse, GetIndexerLeaderboardRegistrationParams, GetIndexerLeaderboardRegistrationResponse, GetIndexerLeaderboardResponse, GetIndexerLinkedSignerParams, GetIndexerLinkedSignerResponse, GetIndexerMakerStatisticsParams, GetIndexerMakerStatisticsResponse, GetIndexerMarketSnapshotsParams, GetIndexerMarketSnapshotsResponse, GetIndexerMatchEventsParams, GetIndexerMatchEventsResponse, GetIndexerMultiProductFundingRatesParams, GetIndexerMultiProductFundingRatesResponse, GetIndexerMultiProductPerpPricesParams, GetIndexerMultiProductPerpPricesResponse, GetIndexerMultiProductSnapshotsParams, GetIndexerMultiProductSnapshotsResponse, GetIndexerMultiSubaccountSnapshotsParams, GetIndexerMultiSubaccountSnapshotsResponse, GetIndexerNlpSnapshotsParams, GetIndexerNlpSnapshotsResponse, GetIndexerOraclePricesParams, GetIndexerOraclePricesResponse, GetIndexerOrdersParams, GetIndexerOrdersResponse, GetIndexerPerpPricesParams, GetIndexerPerpPricesResponse, GetIndexerProductSnapshotsParams, GetIndexerProductSnapshotsResponse, GetIndexerQuotePriceResponse, GetIndexerReferralCodeParams, GetIndexerReferralCodeResponse, IndexerBalanceTrackedVars, IndexerEvent, IndexerEventBalanceStateSnapshot, IndexerEventPerpStateSnapshot, IndexerEventSpotStateSnapshot, IndexerEventWithTx, IndexerFundingRate, IndexerLeaderboardContest, IndexerLeaderboardParticipant, IndexerLeaderboardRegistration, IndexerMaker, IndexerMakerSnapshot, IndexerMarketSnapshot, IndexerMatchEvent, IndexerMatchEventBalances, IndexerNlpSnapshot, IndexerOraclePrice, IndexerOrder, IndexerPerpBalance, IndexerPerpPrices, IndexerProductPayment, IndexerProductSnapshot, IndexerSnapshotBalance, IndexerSnapshotsIntervalParams, IndexerSpotBalance, IndexerSubaccountSnapshot, ListIndexerSubaccountsParams, ListIndexerSubaccountsResponse, UpdateIndexerLeaderboardRegistrationParams, UpdateIndexerLeaderboardRegistrationResponse } from './clientTypes.js';
2
- export { BaseIndexerPaginatedEvent, GetIndexerPaginatedInterestFundingPaymentsResponse, GetIndexerPaginatedLeaderboardParams, GetIndexerPaginatedLeaderboardResponse, GetIndexerPaginatedOrdersParams, GetIndexerPaginatedOrdersResponse, GetIndexerSubaccountCollateralEventsParams, GetIndexerSubaccountCollateralEventsResponse, GetIndexerSubaccountInterestFundingPaymentsParams, GetIndexerSubaccountLiquidationEventsParams, GetIndexerSubaccountLiquidationEventsResponse, GetIndexerSubaccountMatchEventParams, GetIndexerSubaccountMatchEventsResponse, GetIndexerSubaccountNlpEventsParams, GetIndexerSubaccountNlpEventsResponse, GetIndexerSubaccountSettlementEventsParams, GetIndexerSubaccountSettlementEventsResponse, IndexerCollateralEvent, IndexerLiquidationEvent, IndexerNlpEvent, IndexerPaginationMeta, IndexerPaginationParams, IndexerSettlementEvent, PaginatedIndexerEventsResponse, WithPaginationMeta } from './paginatedEventsTypes.js';
3
- export { IndexerEdgeServerCandlesticksParams, IndexerEdgeServerCandlesticksResponse, IndexerEdgeServerMarketSnapshotsParams, IndexerEdgeServerMarketSnapshotsResponse, IndexerServerBacklogResponse, IndexerServerCandlesticksParams, IndexerServerCandlesticksResponse, IndexerServerEventsParams, IndexerServerEventsResponse, IndexerServerFastWithdrawalSignatureParams, IndexerServerFastWithdrawalSignatureResponse, IndexerServerFundingRate, IndexerServerFundingRateParams, IndexerServerFundingRateResponse, IndexerServerFundingRatesParams, IndexerServerFundingRatesResponse, IndexerServerInterestFundingParams, IndexerServerInterestFundingResponse, IndexerServerLeaderboardContestsParams, IndexerServerLeaderboardContestsResponse, IndexerServerLeaderboardParams, IndexerServerLeaderboardRankParams, IndexerServerLeaderboardRankResponse, IndexerServerLeaderboardRegistrationParams, IndexerServerLeaderboardRegistrationResponse, IndexerServerLeaderboardResponse, IndexerServerLinkedSignerParams, IndexerServerLinkedSignerResponse, IndexerServerListSubaccountsParams, IndexerServerListSubaccountsResponse, IndexerServerMakerStatisticsParams, IndexerServerMakerStatisticsResponse, IndexerServerMarketSnapshotsParams, IndexerServerMarketSnapshotsResponse, IndexerServerMatchEventsParams, IndexerServerMatchEventsResponse, IndexerServerMultiProductsParams, IndexerServerMultiProductsResponse, IndexerServerMultiSubaccountSnapshotsParams, IndexerServerMultiSubaccountSnapshotsResponse, IndexerServerNlpSnapshotsParams, IndexerServerNlpSnapshotsResponse, IndexerServerOraclePricesParams, IndexerServerOraclePricesResponse, IndexerServerOrdersParams, IndexerServerOrdersResponse, IndexerServerPerpPrices, IndexerServerPerpPricesParams, IndexerServerPerpPricesResponse, IndexerServerPriceParams, IndexerServerPriceResponse, IndexerServerProductsParams, IndexerServerProductsResponse, IndexerServerQueryRequestByType, IndexerServerQueryRequestType, IndexerServerQueryResponseByType, IndexerServerReferralCodeParams, IndexerServerReferralCodeResponse, IndexerServerUsdcPriceResponse } from './serverTypes.js';
4
- export { IndexerServerBalance, IndexerServerCandlestick, IndexerServerEvent, IndexerServerLeaderboardContest, IndexerServerLeaderboardPosition, IndexerServerLeaderboardRegistration, IndexerServerMaker, IndexerServerMakerData, IndexerServerMarketSnapshot, IndexerServerMarketSnapshotInterval, IndexerServerMatchEvent, IndexerServerMatchEventBalances, IndexerServerNlpSnapshot, IndexerServerOraclePrice, IndexerServerOrder, IndexerServerProduct, IndexerServerProductPayment, IndexerServerProductSnapshot, IndexerServerSnapshotsInterval, IndexerServerTx } from './serverModelTypes.js';
5
1
  export { CandlestickPeriod } from './CandlestickPeriod.js';
2
+ export { Candlestick, GetIndexerBacklogResponse, GetIndexerCandlesticksParams, GetIndexerCandlesticksResponse, GetIndexerEdgeCandlesticksParams, GetIndexerEdgeCandlesticksResponse, GetIndexerEdgeMarketSnapshotResponse, GetIndexerEdgeMarketSnapshotsParams, GetIndexerEventsLimitType, GetIndexerEventsParams, GetIndexerEventsResponse, GetIndexerFastWithdrawalSignatureParams, GetIndexerFastWithdrawalSignatureResponse, GetIndexerFundingRateParams, GetIndexerFundingRateResponse, GetIndexerInterestFundingPaymentsParams, GetIndexerInterestFundingPaymentsResponse, GetIndexerLeaderboardContestsParams, GetIndexerLeaderboardContestsResponse, GetIndexerLeaderboardParams, GetIndexerLeaderboardParticipantParams, GetIndexerLeaderboardParticipantResponse, GetIndexerLeaderboardRegistrationParams, GetIndexerLeaderboardRegistrationResponse, GetIndexerLeaderboardResponse, GetIndexerLinkedSignerParams, GetIndexerLinkedSignerResponse, GetIndexerMakerStatisticsParams, GetIndexerMakerStatisticsResponse, GetIndexerMarketSnapshotsParams, GetIndexerMarketSnapshotsResponse, GetIndexerMatchEventsParams, GetIndexerMatchEventsResponse, GetIndexerMultiProductFundingRatesParams, GetIndexerMultiProductFundingRatesResponse, GetIndexerMultiProductPerpPricesParams, GetIndexerMultiProductPerpPricesResponse, GetIndexerMultiProductSnapshotsParams, GetIndexerMultiProductSnapshotsResponse, GetIndexerMultiSubaccountSnapshotsParams, GetIndexerMultiSubaccountSnapshotsResponse, GetIndexerNlpSnapshotsParams, GetIndexerNlpSnapshotsResponse, GetIndexerOraclePricesParams, GetIndexerOraclePricesResponse, GetIndexerOrdersParams, GetIndexerOrdersResponse, GetIndexerPerpPricesParams, GetIndexerPerpPricesResponse, GetIndexerProductSnapshotsParams, GetIndexerProductSnapshotsResponse, GetIndexerQuotePriceResponse, GetIndexerReferralCodeParams, GetIndexerReferralCodeResponse, GetIndexerSubaccountDDAParams, GetIndexerSubaccountDDAResponse, GetIndexerV2TickersParams, GetIndexerV2TickersResponse, IndexerBalanceTrackedVars, IndexerEvent, IndexerEventBalanceStateSnapshot, IndexerEventPerpStateSnapshot, IndexerEventSpotStateSnapshot, IndexerEventWithTx, IndexerFundingRate, IndexerLeaderboardContest, IndexerLeaderboardParticipant, IndexerLeaderboardRegistration, IndexerMaker, IndexerMakerSnapshot, IndexerMarketSnapshot, IndexerMatchEvent, IndexerMatchEventBalances, IndexerNlpSnapshot, IndexerOraclePrice, IndexerOrder, IndexerPerpBalance, IndexerPerpPrices, IndexerProductPayment, IndexerProductSnapshot, IndexerSnapshotBalance, IndexerSnapshotsIntervalParams, IndexerSpotBalance, IndexerSubaccountSnapshot, IndexerV2TickerResponse, ListIndexerSubaccountsParams, ListIndexerSubaccountsResponse, TickerMarketType, UpdateIndexerLeaderboardRegistrationParams, UpdateIndexerLeaderboardRegistrationResponse } from './clientTypes.js';
3
+ export { CollateralEventType } from './collateralEventType.js';
6
4
  export { IndexerEventType } from './IndexerEventType.js';
7
5
  export { IndexerLeaderboardRankType } from './IndexerLeaderboardType.js';
8
- export { CollateralEventType } from './collateralEventType.js';
9
6
  export { NadoDepositCollateralTx, NadoLiquidateSubaccountTx, NadoMatchOrdersRfqTx, NadoMatchOrdersTx, NadoTransferQuoteTx, NadoTx, NadoWithdrawCollateralTx } from './NadoTx.js';
10
- import '@nadohq/contracts';
11
- import '@nadohq/utils';
7
+ export { BaseIndexerPaginatedEvent, GetIndexerPaginatedInterestFundingPaymentsResponse, GetIndexerPaginatedLeaderboardParams, GetIndexerPaginatedLeaderboardResponse, GetIndexerPaginatedOrdersParams, GetIndexerPaginatedOrdersResponse, GetIndexerSubaccountCollateralEventsParams, GetIndexerSubaccountCollateralEventsResponse, GetIndexerSubaccountInterestFundingPaymentsParams, GetIndexerSubaccountLiquidationEventsParams, GetIndexerSubaccountLiquidationEventsResponse, GetIndexerSubaccountMatchEventParams, GetIndexerSubaccountMatchEventsResponse, GetIndexerSubaccountNlpEventsParams, GetIndexerSubaccountNlpEventsResponse, GetIndexerSubaccountSettlementEventsParams, GetIndexerSubaccountSettlementEventsResponse, IndexerCollateralEvent, IndexerLiquidationEvent, IndexerNlpEvent, IndexerPaginationMeta, IndexerPaginationParams, IndexerSettlementEvent, PaginatedIndexerEventsResponse, WithPaginationMeta } from './paginatedEventsTypes.js';
8
+ export { IndexerServerBalance, IndexerServerCandlestick, IndexerServerEvent, IndexerServerLeaderboardContest, IndexerServerLeaderboardPosition, IndexerServerLeaderboardRegistration, IndexerServerMaker, IndexerServerMakerData, IndexerServerMarketSnapshot, IndexerServerMarketSnapshotInterval, IndexerServerMatchEvent, IndexerServerMatchEventBalances, IndexerServerNlpSnapshot, IndexerServerOraclePrice, IndexerServerOrder, IndexerServerProduct, IndexerServerProductPayment, IndexerServerProductSnapshot, IndexerServerSnapshotsInterval, IndexerServerTx } from './serverModelTypes.js';
9
+ export { IndexerEdgeServerCandlesticksParams, IndexerEdgeServerCandlesticksResponse, IndexerEdgeServerMarketSnapshotsParams, IndexerEdgeServerMarketSnapshotsResponse, IndexerServerBacklogResponse, IndexerServerCandlesticksParams, IndexerServerCandlesticksResponse, IndexerServerDDAQueryParams, IndexerServerDDAResponse, IndexerServerEventsParams, IndexerServerEventsResponse, IndexerServerFastWithdrawalSignatureParams, IndexerServerFastWithdrawalSignatureResponse, IndexerServerFundingRate, IndexerServerFundingRateParams, IndexerServerFundingRateResponse, IndexerServerFundingRatesParams, IndexerServerFundingRatesResponse, IndexerServerInterestFundingParams, IndexerServerInterestFundingResponse, IndexerServerLeaderboardContestsParams, IndexerServerLeaderboardContestsResponse, IndexerServerLeaderboardParams, IndexerServerLeaderboardRankParams, IndexerServerLeaderboardRankResponse, IndexerServerLeaderboardRegistrationParams, IndexerServerLeaderboardRegistrationResponse, IndexerServerLeaderboardResponse, IndexerServerLinkedSignerParams, IndexerServerLinkedSignerResponse, IndexerServerListSubaccountsParams, IndexerServerListSubaccountsResponse, IndexerServerMakerStatisticsParams, IndexerServerMakerStatisticsResponse, IndexerServerMarketSnapshotsParams, IndexerServerMarketSnapshotsResponse, IndexerServerMatchEventsParams, IndexerServerMatchEventsResponse, IndexerServerMultiProductsParams, IndexerServerMultiProductsResponse, IndexerServerMultiSubaccountSnapshotsParams, IndexerServerMultiSubaccountSnapshotsResponse, IndexerServerNlpSnapshotsParams, IndexerServerNlpSnapshotsResponse, IndexerServerOraclePricesParams, IndexerServerOraclePricesResponse, IndexerServerOrdersParams, IndexerServerOrdersResponse, IndexerServerPerpPrices, IndexerServerPerpPricesParams, IndexerServerPerpPricesResponse, IndexerServerPriceParams, IndexerServerPriceResponse, IndexerServerProductsParams, IndexerServerProductsResponse, IndexerServerQueryRequestByType, IndexerServerQueryRequestType, IndexerServerQueryResponseByType, IndexerServerQuotePriceResponse, IndexerServerReferralCodeParams, IndexerServerReferralCodeResponse, IndexerServerTriggerTypeFilter, IndexerServerV2TickerResponse, IndexerServerV2TickersResponse } from './serverTypes.js';
10
+ import '@nadohq/shared';
12
11
  import 'viem';
13
12
  import '@nadohq/engine-client';
@@ -1,11 +1,11 @@
1
1
  // src/types/index.ts
2
- export * from "./clientTypes.js";
3
- export * from "./paginatedEventsTypes.js";
4
- export * from "./serverTypes.js";
5
- export * from "./serverModelTypes.js";
6
2
  export * from "./CandlestickPeriod.js";
3
+ export * from "./clientTypes.js";
4
+ export * from "./collateralEventType.js";
7
5
  export * from "./IndexerEventType.js";
8
6
  export * from "./IndexerLeaderboardType.js";
9
- export * from "./collateralEventType.js";
10
7
  export * from "./NadoTx.js";
8
+ export * from "./paginatedEventsTypes.js";
9
+ export * from "./serverModelTypes.js";
10
+ export * from "./serverTypes.js";
11
11
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/types/index.ts"],"sourcesContent":["export * from './clientTypes';\nexport * from './paginatedEventsTypes';\nexport * from './serverTypes';\nexport * from './serverModelTypes';\nexport * from './CandlestickPeriod';\nexport * from './IndexerEventType';\nexport * from './IndexerLeaderboardType';\nexport * from './collateralEventType';\nexport * from './NadoTx';\n"],"mappings":";AAAA,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;","names":[]}
1
+ {"version":3,"sources":["../../src/types/index.ts"],"sourcesContent":["export * from './CandlestickPeriod';\nexport * from './clientTypes';\nexport * from './collateralEventType';\nexport * from './IndexerEventType';\nexport * from './IndexerLeaderboardType';\nexport * from './NadoTx';\nexport * from './paginatedEventsTypes';\nexport * from './serverModelTypes';\nexport * from './serverTypes';\n"],"mappings":";AAAA,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;","names":[]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/types/paginatedEventsTypes.ts"],"sourcesContent":["import { Subaccount } from '@nadohq/contracts';\nimport { BigDecimal } from '@nadohq/utils';\nimport {\n GetIndexerInterestFundingPaymentsParams,\n GetIndexerInterestFundingPaymentsResponse,\n GetIndexerLeaderboardParams,\n GetIndexerLeaderboardResponse,\n GetIndexerMatchEventsParams,\n GetIndexerOrdersParams,\n IndexerEventBalanceStateSnapshot,\n IndexerEventPerpStateSnapshot,\n IndexerEventSpotStateSnapshot,\n IndexerEventWithTx,\n IndexerMatchEvent,\n IndexerOrder,\n} from './clientTypes';\nimport { CollateralEventType } from './collateralEventType';\nimport { NadoTx } from './NadoTx';\n\nexport interface IndexerPaginationParams {\n limit: number;\n // Retrieves events inclusive of this start cursor\n startCursor?: string;\n}\n\nexport interface IndexerPaginationMeta {\n hasMore: boolean;\n nextCursor?: string;\n}\n\nexport type WithPaginationMeta = { meta: IndexerPaginationMeta };\n\ntype BaseSubaccountPaginationParams = Subaccount &\n IndexerPaginationParams & {\n /**\n * If provided, only events with a timestamp in seconds <= this value will be returned\n * Specifying `startCursor` will supercede this value\n */\n maxTimestampInclusive?: number;\n };\n\nexport interface BaseIndexerPaginatedEvent extends Subaccount {\n timestamp: BigDecimal;\n submissionIndex: string;\n tx: NadoTx;\n}\n\nexport interface PaginatedIndexerEventsResponse<\n T extends BaseIndexerPaginatedEvent,\n> extends WithPaginationMeta {\n events: T[];\n}\n\n/**\n * Collateral\n */\n\nexport interface GetIndexerSubaccountCollateralEventsParams\n extends BaseSubaccountPaginationParams {\n eventTypes?: CollateralEventType[];\n // If not given, will return both isolated & non-iso events\n isolated?: boolean;\n}\n\nexport interface IndexerCollateralEvent extends BaseIndexerPaginatedEvent {\n eventType: CollateralEventType;\n // Positive for deposits, negative for withdrawals\n amount: BigDecimal;\n // The collateral balance after the event\n newAmount: BigDecimal;\n snapshot: IndexerEventSpotStateSnapshot;\n}\n\nexport type GetIndexerSubaccountCollateralEventsResponse =\n PaginatedIndexerEventsResponse<IndexerCollateralEvent>;\n\n/**\n * NLP\n */\nexport type GetIndexerSubaccountNlpEventsParams =\n BaseSubaccountPaginationParams;\n\nexport interface IndexerNlpEvent extends BaseIndexerPaginatedEvent {\n nlpDelta: BigDecimal;\n primaryQuoteDelta: BigDecimal;\n}\n\nexport type GetIndexerSubaccountNlpEventsResponse =\n PaginatedIndexerEventsResponse<IndexerNlpEvent>;\n\n/**\n * Match events\n */\n\nexport type GetIndexerSubaccountMatchEventParams =\n BaseSubaccountPaginationParams &\n Pick<GetIndexerMatchEventsParams, 'productIds' | 'isolated'>;\n\nexport type GetIndexerSubaccountMatchEventsResponse =\n PaginatedIndexerEventsResponse<IndexerMatchEvent>;\n\n/**\n * Orders\n */\n\nexport type GetIndexerPaginatedOrdersParams = BaseSubaccountPaginationParams &\n Pick<GetIndexerOrdersParams, 'productIds' | 'isolated'>;\n\nexport interface GetIndexerPaginatedOrdersResponse {\n orders: IndexerOrder[];\n meta: IndexerPaginationMeta;\n}\n\n/**\n * Liquidations\n */\n\nexport type GetIndexerSubaccountLiquidationEventsParams =\n BaseSubaccountPaginationParams;\n\ntype WithIndexerEvent<\n TData,\n TStateType extends IndexerEventBalanceStateSnapshot,\n> = TData & {\n indexerEvent: IndexerEventWithTx<TStateType>;\n};\n\nexport interface IndexerLiquidationEvent extends BaseIndexerPaginatedEvent {\n // Either spot or perp will then be liquidated if the subaccount maint. health is below 0\n // Both spot & perp can be liquidated in the same event from a spread liquidation\n spot?: WithIndexerEvent<\n {\n // The original balance that was liquidated\n // ex. if it was originally a short, amount is negative, but the net delta from the liquidation is positive\n amountLiquidated: BigDecimal;\n },\n IndexerEventSpotStateSnapshot\n >;\n perp?: WithIndexerEvent<\n {\n // The original balance that was liquidated\n // ex. if it was originally a short, amount is negative, but the net delta from the liquidation is positive\n amountLiquidated: BigDecimal;\n },\n IndexerEventPerpStateSnapshot\n >;\n // Quote delta for the subaccount\n // Only the SPOT QUOTE payment made for the liquidation. Does not include the perp vQuote balance change\n quote: WithIndexerEvent<\n {\n balanceDelta: BigDecimal;\n },\n IndexerEventSpotStateSnapshot\n >;\n}\n\nexport type GetIndexerSubaccountLiquidationEventsResponse =\n PaginatedIndexerEventsResponse<IndexerLiquidationEvent>;\n\n/**\n * Settlement\n */\n\nexport type GetIndexerSubaccountSettlementEventsParams =\n BaseSubaccountPaginationParams;\n\nexport interface IndexerSettlementEvent extends BaseIndexerPaginatedEvent {\n // Quote delta for the subaccount being settled\n quoteDelta: BigDecimal;\n snapshot: IndexerEventPerpStateSnapshot;\n isolated: boolean;\n}\n\nexport type GetIndexerSubaccountSettlementEventsResponse =\n PaginatedIndexerEventsResponse<IndexerSettlementEvent>;\n\n/**\n * Interest / Funding\n */\n\nexport type GetIndexerSubaccountInterestFundingPaymentsParams =\n BaseSubaccountPaginationParams &\n Pick<GetIndexerInterestFundingPaymentsParams, 'productIds' | 'startCursor'>;\n\nexport interface GetIndexerPaginatedInterestFundingPaymentsResponse\n extends GetIndexerInterestFundingPaymentsResponse {\n meta: IndexerPaginationMeta;\n}\n\nexport type GetIndexerPaginatedLeaderboardParams = IndexerPaginationParams &\n Pick<GetIndexerLeaderboardParams, 'contestId' | 'rankType'>;\n\nexport type GetIndexerPaginatedLeaderboardResponse = WithPaginationMeta &\n GetIndexerLeaderboardResponse;\n"],"mappings":";;;;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
1
+ {"version":3,"sources":["../../src/types/paginatedEventsTypes.ts"],"sourcesContent":["import { BigDecimal, Subaccount } from '@nadohq/shared';\nimport {\n GetIndexerInterestFundingPaymentsParams,\n GetIndexerInterestFundingPaymentsResponse,\n GetIndexerLeaderboardParams,\n GetIndexerLeaderboardResponse,\n GetIndexerMatchEventsParams,\n GetIndexerOrdersParams,\n IndexerEventBalanceStateSnapshot,\n IndexerEventPerpStateSnapshot,\n IndexerEventSpotStateSnapshot,\n IndexerEventWithTx,\n IndexerMatchEvent,\n IndexerOrder,\n} from './clientTypes';\nimport { CollateralEventType } from './collateralEventType';\nimport { NadoTx } from './NadoTx';\n\nexport interface IndexerPaginationParams {\n limit: number;\n // Retrieves events inclusive of this start cursor\n startCursor?: string;\n}\n\nexport interface IndexerPaginationMeta {\n hasMore: boolean;\n nextCursor?: string;\n}\n\nexport type WithPaginationMeta = { meta: IndexerPaginationMeta };\n\ntype BaseSubaccountPaginationParams = Subaccount &\n IndexerPaginationParams & {\n /**\n * If provided, only events with a timestamp in seconds <= this value will be returned\n * Specifying `startCursor` will supercede this value\n */\n maxTimestampInclusive?: number;\n };\n\nexport interface BaseIndexerPaginatedEvent extends Subaccount {\n timestamp: BigDecimal;\n submissionIndex: string;\n tx: NadoTx;\n}\n\nexport interface PaginatedIndexerEventsResponse<\n T extends BaseIndexerPaginatedEvent,\n> extends WithPaginationMeta {\n events: T[];\n}\n\n/**\n * Collateral\n */\n\nexport interface GetIndexerSubaccountCollateralEventsParams\n extends BaseSubaccountPaginationParams {\n eventTypes?: CollateralEventType[];\n // If not given, will return both isolated & non-iso events\n isolated?: boolean;\n}\n\nexport interface IndexerCollateralEvent extends BaseIndexerPaginatedEvent {\n eventType: CollateralEventType;\n // Positive for deposits, negative for withdrawals\n amount: BigDecimal;\n // The collateral balance after the event\n newAmount: BigDecimal;\n snapshot: IndexerEventSpotStateSnapshot;\n}\n\nexport type GetIndexerSubaccountCollateralEventsResponse =\n PaginatedIndexerEventsResponse<IndexerCollateralEvent>;\n\n/**\n * NLP\n */\nexport type GetIndexerSubaccountNlpEventsParams =\n BaseSubaccountPaginationParams;\n\nexport interface IndexerNlpEvent extends BaseIndexerPaginatedEvent {\n nlpDelta: BigDecimal;\n primaryQuoteDelta: BigDecimal;\n}\n\nexport type GetIndexerSubaccountNlpEventsResponse =\n PaginatedIndexerEventsResponse<IndexerNlpEvent>;\n\n/**\n * Match events\n */\n\nexport type GetIndexerSubaccountMatchEventParams =\n BaseSubaccountPaginationParams &\n Pick<GetIndexerMatchEventsParams, 'productIds' | 'isolated'>;\n\nexport type GetIndexerSubaccountMatchEventsResponse =\n PaginatedIndexerEventsResponse<IndexerMatchEvent>;\n\n/**\n * Orders\n */\n\nexport type GetIndexerPaginatedOrdersParams = BaseSubaccountPaginationParams &\n Pick<GetIndexerOrdersParams, 'productIds' | 'triggerTypes' | 'isolated'>;\n\nexport interface GetIndexerPaginatedOrdersResponse {\n orders: IndexerOrder[];\n meta: IndexerPaginationMeta;\n}\n\n/**\n * Liquidations\n */\n\nexport type GetIndexerSubaccountLiquidationEventsParams =\n BaseSubaccountPaginationParams;\n\ntype WithIndexerEvent<\n TData,\n TStateType extends IndexerEventBalanceStateSnapshot,\n> = TData & {\n indexerEvent: IndexerEventWithTx<TStateType>;\n};\n\nexport interface IndexerLiquidationEvent extends BaseIndexerPaginatedEvent {\n // Either spot or perp will then be liquidated if the subaccount maint. health is below 0\n // Both spot & perp can be liquidated in the same event from a spread liquidation\n spot?: WithIndexerEvent<\n {\n // The original balance that was liquidated\n // ex. if it was originally a short, amount is negative, but the net delta from the liquidation is positive\n amountLiquidated: BigDecimal;\n },\n IndexerEventSpotStateSnapshot\n >;\n perp?: WithIndexerEvent<\n {\n // The original balance that was liquidated\n // ex. if it was originally a short, amount is negative, but the net delta from the liquidation is positive\n amountLiquidated: BigDecimal;\n },\n IndexerEventPerpStateSnapshot\n >;\n // Quote delta for the subaccount\n // Only the SPOT QUOTE payment made for the liquidation. Does not include the perp vQuote balance change\n quote: WithIndexerEvent<\n {\n balanceDelta: BigDecimal;\n },\n IndexerEventSpotStateSnapshot\n >;\n}\n\nexport type GetIndexerSubaccountLiquidationEventsResponse =\n PaginatedIndexerEventsResponse<IndexerLiquidationEvent>;\n\n/**\n * Settlement\n */\n\nexport type GetIndexerSubaccountSettlementEventsParams =\n BaseSubaccountPaginationParams;\n\nexport interface IndexerSettlementEvent extends BaseIndexerPaginatedEvent {\n // Quote delta for the subaccount being settled\n quoteDelta: BigDecimal;\n snapshot: IndexerEventPerpStateSnapshot;\n isolated: boolean;\n}\n\nexport type GetIndexerSubaccountSettlementEventsResponse =\n PaginatedIndexerEventsResponse<IndexerSettlementEvent>;\n\n/**\n * Interest / Funding\n */\n\nexport type GetIndexerSubaccountInterestFundingPaymentsParams =\n BaseSubaccountPaginationParams &\n Pick<GetIndexerInterestFundingPaymentsParams, 'productIds' | 'startCursor'>;\n\nexport interface GetIndexerPaginatedInterestFundingPaymentsResponse\n extends GetIndexerInterestFundingPaymentsResponse {\n meta: IndexerPaginationMeta;\n}\n\nexport type GetIndexerPaginatedLeaderboardParams = IndexerPaginationParams &\n Pick<GetIndexerLeaderboardParams, 'contestId' | 'rankType'>;\n\nexport type GetIndexerPaginatedLeaderboardResponse = WithPaginationMeta &\n GetIndexerLeaderboardResponse;\n"],"mappings":";;;;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
@@ -1,13 +1,12 @@
1
+ import './CandlestickPeriod.cjs';
1
2
  import { GetIndexerMatchEventsParams, IndexerMatchEvent, IndexerEventSpotStateSnapshot, GetIndexerOrdersParams, IndexerOrder, IndexerEventPerpStateSnapshot, IndexerEventBalanceStateSnapshot, IndexerEventWithTx, GetIndexerInterestFundingPaymentsParams, GetIndexerInterestFundingPaymentsResponse, GetIndexerLeaderboardParams, GetIndexerLeaderboardResponse } from './clientTypes.cjs';
2
- import { Subaccount } from '@nadohq/contracts';
3
- import { BigDecimal } from '@nadohq/utils';
4
3
  import { CollateralEventType } from './collateralEventType.cjs';
5
- import { NadoTx } from './NadoTx.cjs';
6
- import './serverTypes.cjs';
7
- import './serverModelTypes.cjs';
8
- import './CandlestickPeriod.cjs';
9
4
  import './IndexerEventType.cjs';
10
5
  import './IndexerLeaderboardType.cjs';
6
+ import { NadoTx } from './NadoTx.cjs';
7
+ import { Subaccount, BigDecimal } from '@nadohq/shared';
8
+ import './serverModelTypes.cjs';
9
+ import './serverTypes.cjs';
11
10
  import 'viem';
12
11
  import '@nadohq/engine-client';
13
12
 
@@ -68,7 +67,7 @@ type GetIndexerSubaccountMatchEventsResponse = PaginatedIndexerEventsResponse<In
68
67
  /**
69
68
  * Orders
70
69
  */
71
- type GetIndexerPaginatedOrdersParams = BaseSubaccountPaginationParams & Pick<GetIndexerOrdersParams, 'productIds' | 'isolated'>;
70
+ type GetIndexerPaginatedOrdersParams = BaseSubaccountPaginationParams & Pick<GetIndexerOrdersParams, 'productIds' | 'triggerTypes' | 'isolated'>;
72
71
  interface GetIndexerPaginatedOrdersResponse {
73
72
  orders: IndexerOrder[];
74
73
  meta: IndexerPaginationMeta;
@@ -1,13 +1,12 @@
1
+ import './CandlestickPeriod.js';
1
2
  import { GetIndexerMatchEventsParams, IndexerMatchEvent, IndexerEventSpotStateSnapshot, GetIndexerOrdersParams, IndexerOrder, IndexerEventPerpStateSnapshot, IndexerEventBalanceStateSnapshot, IndexerEventWithTx, GetIndexerInterestFundingPaymentsParams, GetIndexerInterestFundingPaymentsResponse, GetIndexerLeaderboardParams, GetIndexerLeaderboardResponse } from './clientTypes.js';
2
- import { Subaccount } from '@nadohq/contracts';
3
- import { BigDecimal } from '@nadohq/utils';
4
3
  import { CollateralEventType } from './collateralEventType.js';
5
- import { NadoTx } from './NadoTx.js';
6
- import './serverTypes.js';
7
- import './serverModelTypes.js';
8
- import './CandlestickPeriod.js';
9
4
  import './IndexerEventType.js';
10
5
  import './IndexerLeaderboardType.js';
6
+ import { NadoTx } from './NadoTx.js';
7
+ import { Subaccount, BigDecimal } from '@nadohq/shared';
8
+ import './serverModelTypes.js';
9
+ import './serverTypes.js';
11
10
  import 'viem';
12
11
  import '@nadohq/engine-client';
13
12
 
@@ -68,7 +67,7 @@ type GetIndexerSubaccountMatchEventsResponse = PaginatedIndexerEventsResponse<In
68
67
  /**
69
68
  * Orders
70
69
  */
71
- type GetIndexerPaginatedOrdersParams = BaseSubaccountPaginationParams & Pick<GetIndexerOrdersParams, 'productIds' | 'isolated'>;
70
+ type GetIndexerPaginatedOrdersParams = BaseSubaccountPaginationParams & Pick<GetIndexerOrdersParams, 'productIds' | 'triggerTypes' | 'isolated'>;
72
71
  interface GetIndexerPaginatedOrdersResponse {
73
72
  orders: IndexerOrder[];
74
73
  meta: IndexerPaginationMeta;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/types/serverModelTypes.ts"],"sourcesContent":["import { EIP712OrderValues } from '@nadohq/contracts';\nimport {\n EngineServerPerpBalance,\n EngineServerPerpProduct,\n EngineServerSpotBalance,\n EngineServerSpotProduct,\n} from '@nadohq/engine-client';\nimport { IndexerEventType } from './IndexerEventType';\nimport { NadoTx } from './NadoTx';\n\nexport interface IndexerServerSnapshotsInterval {\n count: number;\n // Currently accepts any granularity, time distance (in seconds) between data points\n granularity: number;\n max_time?: string;\n}\n\nexport type IndexerServerProduct =\n | {\n spot: EngineServerSpotProduct;\n }\n | {\n perp: EngineServerPerpProduct;\n };\n\nexport type IndexerServerBalance =\n | {\n spot: EngineServerSpotBalance;\n }\n | {\n perp: EngineServerPerpBalance;\n };\n\n/**\n * Candlesticks\n */\n\nexport interface IndexerServerCandlestick {\n product_id: number;\n granularity: string;\n submission_idx: string;\n timestamp: string;\n open_x18: string;\n high_x18: string;\n low_x18: string;\n close_x18: string;\n volume: string;\n}\n\n/**\n * Product snapshots\n */\n\nexport interface IndexerServerProductSnapshot {\n product_id: number;\n submission_idx: string;\n product: IndexerServerProduct;\n}\n\n/**\n * Base Events\n */\n\nexport interface IndexerServerEvent {\n subaccount: string;\n isolated: boolean;\n // The product ID associated with the isolated perp market. This is only used when product_id === QUOTE_PRODUCT_ID and isolated === true\n isolated_product_id: number | null;\n product_id: number;\n submission_idx: string;\n event_type: IndexerEventType;\n pre_balance: IndexerServerBalance;\n post_balance: IndexerServerBalance;\n product: IndexerServerProduct;\n net_interest_unrealized: string;\n net_interest_cumulative: string;\n net_funding_unrealized: string;\n net_funding_cumulative: string;\n net_entry_unrealized: string;\n net_entry_cumulative: string;\n}\n\nexport interface IndexerServerTx {\n submission_idx: string;\n timestamp: string;\n tx: NadoTx;\n}\n\n/**\n * Orders\n */\n\nexport interface IndexerServerOrder {\n digest: string;\n isolated: boolean;\n subaccount: string;\n product_id: number;\n submission_idx: string;\n amount: string;\n price_x18: string;\n expiration: string;\n nonce: string;\n base_filled: string;\n // Includes fee\n quote_filled: string;\n // Includes sequencer fee\n fee: string;\n}\n\n/**\n * Match events\n */\n\nexport interface IndexerServerMatchEvent {\n digest: string;\n isolated: boolean;\n order: EIP712OrderValues;\n base_filled: string;\n // Includes fee\n quote_filled: string;\n // Includes sequencer fee\n fee: string;\n sequencer_fee: string;\n cumulative_fee: string;\n cumulative_base_filled: string;\n cumulative_quote_filled: string;\n submission_idx: string;\n net_entry_unrealized: string;\n net_entry_cumulative: string;\n pre_balance: IndexerServerMatchEventBalances;\n post_balance: IndexerServerMatchEventBalances;\n}\n\nexport interface IndexerServerMatchEventBalances {\n base: IndexerServerBalance;\n // Quote is defined if 0 is included in `product_ids` and the match event is a spot event\n quote?: IndexerServerBalance;\n}\n\n/**\n * Oracle price\n */\n\nexport interface IndexerServerOraclePrice {\n product_id: number;\n oracle_price_x18: string;\n update_time: number;\n}\n\n/**\n * Market snapshots\n */\n\nexport interface IndexerServerMarketSnapshotInterval {\n count: number;\n // Currently accepts any granularity, time distance (in seconds) between data points\n granularity: number;\n max_time?: string;\n}\n\nexport interface IndexerServerMarketSnapshot {\n timestamp: string;\n cumulative_users: string;\n daily_active_users: string;\n tvl: string;\n // Keyed by product ID -> decimal value in string (i.e. no decimal adjustment) necessary\n // Backend serializes hashmaps with string keys\n cumulative_volumes: Record<string, string>;\n cumulative_taker_fees: Record<string, string>;\n cumulative_sequencer_fees: Record<string, string>;\n cumulative_maker_fees: Record<string, string>;\n cumulative_trades: Record<string, string>;\n cumulative_liquidation_amounts: Record<string, string>;\n open_interests: Record<string, string>;\n total_deposits: Record<string, string>;\n total_borrows: Record<string, string>;\n funding_rates: Record<string, string>;\n deposit_rates: Record<string, string>;\n borrow_rates: Record<string, string>;\n cumulative_trade_sizes: Record<string, string>;\n cumulative_inflows: Record<string, string>;\n cumulative_outflows: Record<string, string>;\n oracle_prices: Record<string, string>;\n}\n\n/**\n * Interest / funding\n */\n\nexport interface IndexerServerProductPayment {\n product_id: number;\n idx: string;\n timestamp: string;\n amount: string;\n balance_amount: string;\n rate_x18: string;\n oracle_price_x18: string;\n isolated: boolean;\n isolated_product_id: number | null;\n}\n\n/**\n * Maker stats\n */\n\nexport interface IndexerServerMakerData {\n timestamp: string;\n maker_fee: string;\n uptime: string;\n sum_q_min: string;\n q_score: string;\n maker_share: string;\n expected_maker_reward: string;\n}\n\nexport interface IndexerServerMaker {\n address: string;\n data: IndexerServerMakerData[];\n}\n\n/**\n * Leaderboard\n */\n\nexport interface IndexerServerLeaderboardPosition {\n subaccount: string;\n contest_id: number;\n pnl: string;\n pnl_rank: string;\n roi: string;\n roi_rank: string;\n account_value: string;\n volume?: string;\n update_time: string;\n}\n\nexport interface IndexerServerLeaderboardContest {\n contest_id: number;\n start_time: string;\n end_time: string;\n timeframe: string;\n count: string;\n threshold: string;\n volume_threshold: string;\n product_ids: number[];\n last_updated: string;\n active: boolean;\n}\n\nexport interface IndexerServerLeaderboardRegistration {\n subaccount: string;\n contest_id: number;\n update_time: string;\n}\n\n/**\n * NLP\n */\n\nexport interface IndexerServerNlpSnapshot {\n cumulative_burn_usdc: string;\n cumulative_mint_usdc: string;\n cumulative_pnl: string;\n cumulative_trades: string;\n cumulative_volume: string;\n depositors: string;\n oracle_price_x18: string;\n submission_idx: string;\n timestamp: string;\n tvl: string;\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
1
+ {"version":3,"sources":["../../src/types/serverModelTypes.ts"],"sourcesContent":["import {\n EngineServerPerpBalance,\n EngineServerPerpProduct,\n EngineServerSpotBalance,\n EngineServerSpotProduct,\n} from '@nadohq/engine-client';\nimport { EIP712OrderValues } from '@nadohq/shared';\nimport { IndexerEventType } from './IndexerEventType';\nimport { NadoTx } from './NadoTx';\n\nexport interface IndexerServerSnapshotsInterval {\n count: number;\n // Currently accepts any granularity, time distance (in seconds) between data points\n granularity: number;\n max_time?: string;\n}\n\nexport type IndexerServerProduct =\n | {\n spot: EngineServerSpotProduct;\n }\n | {\n perp: EngineServerPerpProduct;\n };\n\nexport type IndexerServerBalance =\n | {\n spot: EngineServerSpotBalance;\n }\n | {\n perp: EngineServerPerpBalance;\n };\n\n/**\n * Candlesticks\n */\n\nexport interface IndexerServerCandlestick {\n product_id: number;\n granularity: string;\n submission_idx: string;\n timestamp: string;\n open_x18: string;\n high_x18: string;\n low_x18: string;\n close_x18: string;\n volume: string;\n}\n\n/**\n * Product snapshots\n */\n\nexport interface IndexerServerProductSnapshot {\n product_id: number;\n submission_idx: string;\n product: IndexerServerProduct;\n}\n\n/**\n * Base Events\n */\n\nexport interface IndexerServerEvent {\n subaccount: string;\n isolated: boolean;\n // The product ID associated with the isolated perp market. This is only used when product_id === QUOTE_PRODUCT_ID and isolated === true\n isolated_product_id: number | null;\n product_id: number;\n submission_idx: string;\n event_type: IndexerEventType;\n pre_balance: IndexerServerBalance;\n post_balance: IndexerServerBalance;\n product: IndexerServerProduct;\n net_interest_unrealized: string;\n net_interest_cumulative: string;\n net_funding_unrealized: string;\n net_funding_cumulative: string;\n net_entry_unrealized: string;\n net_entry_cumulative: string;\n /**\n * Total traded volume in terms of the primary quote (i.e in terms of USDT) for this product\n */\n quote_volume_cumulative: string;\n}\n\nexport interface IndexerServerTx {\n submission_idx: string;\n timestamp: string;\n tx: NadoTx;\n}\n\n/**\n * Orders\n */\n\nexport interface IndexerServerOrder {\n digest: string;\n subaccount: string;\n product_id: number;\n submission_idx: string;\n amount: string;\n price_x18: string;\n expiration: string;\n appendix: string;\n nonce: string;\n base_filled: string;\n // Includes fee\n quote_filled: string;\n // Includes sequencer fee\n fee: string;\n}\n\n/**\n * Match events\n */\n\nexport interface IndexerServerMatchEvent {\n digest: string;\n isolated: boolean;\n order: EIP712OrderValues;\n base_filled: string;\n // Includes fee\n quote_filled: string;\n // Includes sequencer fee\n fee: string;\n sequencer_fee: string;\n cumulative_fee: string;\n cumulative_base_filled: string;\n cumulative_quote_filled: string;\n submission_idx: string;\n net_entry_unrealized: string;\n net_entry_cumulative: string;\n pre_balance: IndexerServerMatchEventBalances;\n post_balance: IndexerServerMatchEventBalances;\n}\n\nexport interface IndexerServerMatchEventBalances {\n base: IndexerServerBalance;\n // Quote is defined if 0 is included in `product_ids` and the match event is a spot event\n quote?: IndexerServerBalance;\n}\n\n/**\n * Oracle price\n */\n\nexport interface IndexerServerOraclePrice {\n product_id: number;\n oracle_price_x18: string;\n update_time: number;\n}\n\n/**\n * Market snapshots\n */\n\nexport interface IndexerServerMarketSnapshotInterval {\n count: number;\n // Currently accepts any granularity, time distance (in seconds) between data points\n granularity: number;\n max_time?: string;\n}\n\nexport interface IndexerServerMarketSnapshot {\n timestamp: string;\n cumulative_users: string;\n daily_active_users: string;\n tvl: string;\n // Keyed by product ID -> decimal value in string (i.e. no decimal adjustment) necessary\n // Backend serializes hashmaps with string keys\n cumulative_volumes: Record<string, string>;\n cumulative_taker_fees: Record<string, string>;\n cumulative_sequencer_fees: Record<string, string>;\n cumulative_maker_fees: Record<string, string>;\n cumulative_trades: Record<string, string>;\n cumulative_liquidation_amounts: Record<string, string>;\n open_interests: Record<string, string>;\n total_deposits: Record<string, string>;\n total_borrows: Record<string, string>;\n funding_rates: Record<string, string>;\n deposit_rates: Record<string, string>;\n borrow_rates: Record<string, string>;\n cumulative_trade_sizes: Record<string, string>;\n cumulative_inflows: Record<string, string>;\n cumulative_outflows: Record<string, string>;\n oracle_prices: Record<string, string>;\n}\n\n/**\n * Interest / funding\n */\n\nexport interface IndexerServerProductPayment {\n product_id: number;\n idx: string;\n timestamp: string;\n amount: string;\n balance_amount: string;\n rate_x18: string;\n oracle_price_x18: string;\n isolated: boolean;\n isolated_product_id: number | null;\n}\n\n/**\n * Maker stats\n */\n\nexport interface IndexerServerMakerData {\n timestamp: string;\n maker_fee: string;\n uptime: string;\n sum_q_min: string;\n q_score: string;\n maker_share: string;\n expected_maker_reward: string;\n}\n\nexport interface IndexerServerMaker {\n address: string;\n data: IndexerServerMakerData[];\n}\n\n/**\n * Leaderboard\n */\n\nexport interface IndexerServerLeaderboardPosition {\n subaccount: string;\n contest_id: number;\n pnl: string;\n pnl_rank: string;\n roi: string;\n roi_rank: string;\n account_value: string;\n volume?: string;\n update_time: string;\n}\n\nexport interface IndexerServerLeaderboardContest {\n contest_id: number;\n start_time: string;\n end_time: string;\n timeframe: string;\n count: string;\n threshold: string;\n volume_threshold: string;\n product_ids: number[];\n last_updated: string;\n active: boolean;\n}\n\nexport interface IndexerServerLeaderboardRegistration {\n subaccount: string;\n contest_id: number;\n update_time: string;\n}\n\n/**\n * NLP\n */\n\nexport interface IndexerServerNlpSnapshot {\n cumulative_burn_quote: string;\n cumulative_mint_quote: string;\n cumulative_pnl: string;\n cumulative_trades: string;\n cumulative_volume: string;\n depositors: string;\n oracle_price_x18: string;\n submission_idx: string;\n timestamp: string;\n tvl: string;\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
@@ -1,5 +1,5 @@
1
- import { EIP712OrderValues } from '@nadohq/contracts';
2
1
  import { EngineServerSpotBalance, EngineServerPerpBalance, EngineServerSpotProduct, EngineServerPerpProduct } from '@nadohq/engine-client';
2
+ import { EIP712OrderValues } from '@nadohq/shared';
3
3
  import { IndexerEventType } from './IndexerEventType.cjs';
4
4
  import { NadoTx } from './NadoTx.cjs';
5
5
 
@@ -59,6 +59,10 @@ interface IndexerServerEvent {
59
59
  net_funding_cumulative: string;
60
60
  net_entry_unrealized: string;
61
61
  net_entry_cumulative: string;
62
+ /**
63
+ * Total traded volume in terms of the primary quote (i.e in terms of USDT) for this product
64
+ */
65
+ quote_volume_cumulative: string;
62
66
  }
63
67
  interface IndexerServerTx {
64
68
  submission_idx: string;
@@ -70,13 +74,13 @@ interface IndexerServerTx {
70
74
  */
71
75
  interface IndexerServerOrder {
72
76
  digest: string;
73
- isolated: boolean;
74
77
  subaccount: string;
75
78
  product_id: number;
76
79
  submission_idx: string;
77
80
  amount: string;
78
81
  price_x18: string;
79
82
  expiration: string;
83
+ appendix: string;
80
84
  nonce: string;
81
85
  base_filled: string;
82
86
  quote_filled: string;
@@ -209,8 +213,8 @@ interface IndexerServerLeaderboardRegistration {
209
213
  * NLP
210
214
  */
211
215
  interface IndexerServerNlpSnapshot {
212
- cumulative_burn_usdc: string;
213
- cumulative_mint_usdc: string;
216
+ cumulative_burn_quote: string;
217
+ cumulative_mint_quote: string;
214
218
  cumulative_pnl: string;
215
219
  cumulative_trades: string;
216
220
  cumulative_volume: string;
@@ -1,5 +1,5 @@
1
- import { EIP712OrderValues } from '@nadohq/contracts';
2
1
  import { EngineServerSpotBalance, EngineServerPerpBalance, EngineServerSpotProduct, EngineServerPerpProduct } from '@nadohq/engine-client';
2
+ import { EIP712OrderValues } from '@nadohq/shared';
3
3
  import { IndexerEventType } from './IndexerEventType.js';
4
4
  import { NadoTx } from './NadoTx.js';
5
5
 
@@ -59,6 +59,10 @@ interface IndexerServerEvent {
59
59
  net_funding_cumulative: string;
60
60
  net_entry_unrealized: string;
61
61
  net_entry_cumulative: string;
62
+ /**
63
+ * Total traded volume in terms of the primary quote (i.e in terms of USDT) for this product
64
+ */
65
+ quote_volume_cumulative: string;
62
66
  }
63
67
  interface IndexerServerTx {
64
68
  submission_idx: string;
@@ -70,13 +74,13 @@ interface IndexerServerTx {
70
74
  */
71
75
  interface IndexerServerOrder {
72
76
  digest: string;
73
- isolated: boolean;
74
77
  subaccount: string;
75
78
  product_id: number;
76
79
  submission_idx: string;
77
80
  amount: string;
78
81
  price_x18: string;
79
82
  expiration: string;
83
+ appendix: string;
80
84
  nonce: string;
81
85
  base_filled: string;
82
86
  quote_filled: string;
@@ -209,8 +213,8 @@ interface IndexerServerLeaderboardRegistration {
209
213
  * NLP
210
214
  */
211
215
  interface IndexerServerNlpSnapshot {
212
- cumulative_burn_usdc: string;
213
- cumulative_mint_usdc: string;
216
+ cumulative_burn_quote: string;
217
+ cumulative_mint_quote: string;
214
218
  cumulative_pnl: string;
215
219
  cumulative_trades: string;
216
220
  cumulative_volume: string;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/types/serverTypes.ts"],"sourcesContent":["import {\n EIP712LeaderboardAuthenticationValues,\n SignedTx,\n} from '@nadohq/contracts';\nimport { IndexerEventType } from './IndexerEventType';\nimport { IndexerLeaderboardRankType } from './IndexerLeaderboardType';\nimport { NadoWithdrawCollateralTx } from './NadoTx';\nimport {\n IndexerServerCandlestick,\n IndexerServerEvent,\n IndexerServerLeaderboardContest,\n IndexerServerLeaderboardPosition,\n IndexerServerLeaderboardRegistration,\n IndexerServerMaker,\n IndexerServerMarketSnapshot,\n IndexerServerMarketSnapshotInterval,\n IndexerServerMatchEvent,\n IndexerServerOraclePrice,\n IndexerServerOrder,\n IndexerServerProductPayment,\n IndexerServerProductSnapshot,\n IndexerServerSnapshotsInterval,\n IndexerServerTx,\n IndexerServerNlpSnapshot,\n} from './serverModelTypes';\n\n/**\n * Params\n */\n\nexport interface IndexerServerListSubaccountsParams {\n // Inclusive, defaults to 0\n start?: number;\n // Defaults to 100\n limit?: number;\n address?: string;\n}\n\nexport interface IndexerServerMultiSubaccountSnapshotsParams {\n // Subaccount hex identifiers\n subaccounts: string[];\n timestamps: number[];\n // If not given, will return both isolated & non-iso balances\n isolated?: boolean;\n}\n\nexport interface IndexerServerReferralCodeParams {\n subaccount: string;\n}\n\nexport interface IndexerServerFundingRateParams {\n product_id: number;\n}\n\nexport interface IndexerServerFundingRatesParams {\n product_ids: number[];\n}\n\nexport interface IndexerServerPriceParams {\n product_id: number;\n}\n\nexport interface IndexerServerPerpPricesParams {\n product_ids: number[];\n}\n\nexport interface IndexerServerOraclePricesParams {\n product_ids: number[];\n}\n\nexport interface IndexerServerCandlesticksParams {\n product_id: number;\n granularity: number;\n // Seconds\n max_time?: number;\n limit: number;\n}\n\nexport type IndexerEdgeServerCandlesticksParams =\n IndexerServerCandlesticksParams;\n\nexport interface IndexerServerProductsParams {\n product_id: number;\n max_time?: number;\n limit: number;\n // submission_idx for pagination, inclusive\n idx?: string;\n}\n\nexport interface IndexerServerMultiProductsParams {\n product_ids: number[];\n max_time: number[];\n}\n\nexport interface IndexerServerEventsParams {\n subaccount?: string;\n product_ids?: number[];\n // If not given, will return both isolated & non-iso events\n isolated?: boolean;\n event_types?: IndexerEventType[];\n // Descending order for idx (time), defaults to true\n desc?: boolean;\n // submission_idx for pagination, inclusive\n idx?: string;\n max_time?: number;\n limit?:\n | {\n raw: number;\n }\n | {\n txs: number;\n };\n}\n\nexport interface IndexerServerOrdersParams {\n subaccount?: string;\n product_ids?: number[];\n digests?: string[];\n max_time?: number;\n limit?: number;\n // If not given, will return both isolated & non-iso orders\n isolated?: boolean;\n // submission_idx for pagination, inclusive\n idx?: string;\n}\n\nexport interface IndexerServerMatchEventsParams {\n subaccount?: string;\n product_ids?: number[];\n // If not given, will return both isolated & non-iso events\n isolated?: boolean;\n max_time?: number;\n limit: number;\n // submission_idx for pagination, inclusive\n idx?: string;\n}\n\nexport interface IndexerServerLinkedSignerParams {\n subaccount: string;\n}\n\nexport interface IndexerServerMarketSnapshotsParams {\n interval: IndexerServerMarketSnapshotInterval;\n // Defaults to all\n product_ids?: number[];\n}\n\nexport interface IndexerEdgeServerMarketSnapshotsParams {\n interval: IndexerServerMarketSnapshotInterval;\n}\n\nexport interface IndexerServerInterestFundingParams {\n subaccount: string;\n product_ids: number[];\n // If not given, defaults to latest\n max_idx?: string;\n max_time?: number;\n limit: number;\n}\n\nexport interface IndexerServerMakerStatisticsParams {\n product_id: number;\n epoch: number;\n interval: number;\n}\n\nexport interface IndexerServerLeaderboardParams {\n contest_id: number;\n rank_type: IndexerLeaderboardRankType;\n start?: number | string;\n limit?: number | string;\n}\n\nexport interface IndexerServerLeaderboardRankParams {\n subaccount: string;\n contest_ids: number[];\n}\n\nexport interface IndexerServerLeaderboardContestsParams {\n contest_ids: number[];\n}\n\nexport interface IndexerServerLeaderboardRegistrationParams {\n subaccount: string;\n contest_id: number;\n update_registration: SignedTx<EIP712LeaderboardAuthenticationValues> | null;\n}\n\nexport interface IndexerServerFastWithdrawalSignatureParams {\n /**\n * The submission index of the WithdrawCollateral tx to be used for fast withdraw.\n */\n idx: number | string;\n}\n\nexport interface IndexerServerNlpSnapshotsParams {\n interval: IndexerServerSnapshotsInterval;\n}\n\n// Request\nexport interface IndexerServerQueryRequestByType {\n account_snapshots: IndexerServerMultiSubaccountSnapshotsParams;\n backlog: Record<string, never>;\n candlesticks: IndexerServerCandlesticksParams;\n edge_candlesticks: IndexerEdgeServerCandlesticksParams;\n edge_market_snapshots: IndexerEdgeServerMarketSnapshotsParams;\n events: IndexerServerEventsParams;\n fast_withdrawal_signature: IndexerServerFastWithdrawalSignatureParams;\n funding_rate: IndexerServerFundingRateParams;\n funding_rates: IndexerServerFundingRatesParams;\n interest_and_funding: IndexerServerInterestFundingParams;\n leaderboard: IndexerServerLeaderboardParams;\n leaderboard_contests: IndexerServerLeaderboardContestsParams;\n leaderboard_rank: IndexerServerLeaderboardRankParams;\n leaderboard_registration: IndexerServerLeaderboardRegistrationParams;\n linked_signer_rate_limit: IndexerServerLinkedSignerParams;\n maker_statistics: IndexerServerMakerStatisticsParams;\n market_snapshots: IndexerServerMarketSnapshotsParams;\n matches: IndexerServerMatchEventsParams;\n oracle_price: IndexerServerOraclePricesParams;\n orders: IndexerServerOrdersParams;\n perp_prices: IndexerServerPerpPricesParams;\n price: IndexerServerPriceParams;\n product_snapshots: IndexerServerMultiProductsParams;\n products: IndexerServerProductsParams;\n referral_code: IndexerServerReferralCodeParams;\n subaccounts: IndexerServerListSubaccountsParams;\n usdc_price: Record<string, never>;\n nlp_snapshots: IndexerServerNlpSnapshotsParams;\n}\n\nexport type IndexerServerQueryRequestType =\n keyof IndexerServerQueryRequestByType;\n\n/**\n * Responses\n */\n\nexport interface IndexerServerListSubaccountsResponse {\n subaccounts: {\n id: string;\n // Hex of subaccount bytes\n subaccount: string;\n }[];\n}\n\nexport interface IndexerServerMultiSubaccountSnapshotsResponse {\n // Map of subaccount hex -> timestamp requested -> latest events corresponding to each product\n snapshots: Record<string, Record<string, IndexerServerEvent[]>>;\n}\n\nexport interface IndexerServerReferralCodeResponse {\n referral_code: string | null;\n}\n\nexport interface IndexerServerFundingRate {\n product_id: number;\n funding_rate_x18: string;\n update_time: number;\n}\n\nexport type IndexerServerFundingRateResponse = IndexerServerFundingRate;\n\n// Map of productId -> IndexerServerFundingRate\nexport type IndexerServerFundingRatesResponse = Record<\n string,\n IndexerServerFundingRate\n>;\n\nexport interface IndexerServerPerpPrices {\n product_id: number;\n index_price_x18: string;\n mark_price_x18: string;\n update_time: number;\n}\n\nexport type IndexerServerPriceResponse = IndexerServerPerpPrices;\n\n// Map of productId -> IndexerServerPerpPrices\nexport type IndexerServerPerpPricesResponse = Record<\n string,\n IndexerServerPerpPrices\n>;\n\nexport interface IndexerServerOraclePricesResponse {\n prices: IndexerServerOraclePrice[];\n}\n\nexport interface IndexerServerCandlesticksResponse {\n candlesticks: IndexerServerCandlestick[];\n}\n\nexport type IndexerEdgeServerCandlesticksResponse =\n IndexerServerCandlesticksResponse;\n\nexport interface IndexerServerProductsResponse {\n products: IndexerServerProductSnapshot[];\n txs: IndexerServerTx[];\n}\n\n// Map of timestamp -> (productID -> IndexerServerProductSnapshot)\nexport type IndexerServerMultiProductsResponse = Record<\n string,\n Record<string, IndexerServerProductSnapshot>\n>;\n\nexport interface IndexerServerEventsResponse {\n events: IndexerServerEvent[];\n txs: IndexerServerTx[];\n}\n\nexport interface IndexerServerOrdersResponse {\n orders: IndexerServerOrder[];\n}\n\nexport interface IndexerServerMatchEventsResponse {\n matches: IndexerServerMatchEvent[];\n txs: IndexerServerTx[];\n}\n\nexport interface IndexerServerUsdcPriceResponse {\n price_x18: string;\n}\n\nexport interface IndexerServerLinkedSignerResponse {\n total_tx_limit: string;\n remaining_tx: string;\n wait_time: string;\n signer: string;\n}\n\nexport interface IndexerServerMarketSnapshotsResponse {\n snapshots: IndexerServerMarketSnapshot[];\n}\n\nexport interface IndexerEdgeServerMarketSnapshotsResponse {\n snapshots: Record<number, IndexerServerMarketSnapshot[]>;\n}\n\nexport interface IndexerServerInterestFundingResponse {\n interest_payments: IndexerServerProductPayment[];\n funding_payments: IndexerServerProductPayment[];\n next_idx: string;\n}\n\nexport interface IndexerServerMakerStatisticsResponse {\n reward_coefficient: string;\n makers: IndexerServerMaker[];\n}\n\nexport interface IndexerServerLeaderboardResponse {\n positions: IndexerServerLeaderboardPosition[];\n}\n\nexport interface IndexerServerLeaderboardRegistrationResponse {\n // For non-tiered contests, null if the user is not registered for the provided contestId.\n // For tiered contests (i.e., related contests), null if the user is not registered for any of the contests in the tier group.\n registration: IndexerServerLeaderboardRegistration | null;\n}\n\nexport interface IndexerServerLeaderboardRankResponse {\n // If the subaccount is not eligible for a given contest, it would not be included in the response.\n // contestId -> IndexerServerLeaderboardPosition\n positions: Record<string, IndexerServerLeaderboardPosition>;\n}\n\nexport interface IndexerServerLeaderboardContestsResponse {\n contests: IndexerServerLeaderboardContest[];\n}\n\nexport interface IndexerServerFastWithdrawalSignatureResponse {\n idx: string;\n tx: NadoWithdrawCollateralTx['withdraw_collateral'];\n tx_bytes: string;\n signatures: string[];\n}\n\nexport interface IndexerServerNlpSnapshotsResponse {\n snapshots: IndexerServerNlpSnapshot[];\n}\n\nexport interface IndexerServerBacklogResponse {\n // Total number of transactions stored in the indexer DB\n total_txs: string;\n // Current nSubmissions value from the chain (i.e., number of processed txs)\n total_submissions: string;\n // Number of unprocessed transactions (total_txs - total_submissions)\n backlog_size: string;\n // UNIX timestamp (in seconds) of when the data was last updated\n updated_at: string;\n // Estimated time in seconds (float) to clear the entire backlog (null if unavailable)\n backlog_eta_in_seconds: string | null;\n // Current submission rate in transactions per second (float) (null if unavailable)\n txs_per_second: string | null;\n}\n\n// Response\nexport interface IndexerServerQueryResponseByType {\n account_snapshots: IndexerServerMultiSubaccountSnapshotsResponse;\n backlog: IndexerServerBacklogResponse;\n candlesticks: IndexerServerCandlesticksResponse;\n edge_candlesticks: IndexerEdgeServerCandlesticksResponse;\n edge_market_snapshots: IndexerEdgeServerMarketSnapshotsResponse;\n events: IndexerServerEventsResponse;\n fast_withdrawal_signature: IndexerServerFastWithdrawalSignatureResponse;\n funding_rate: IndexerServerFundingRateResponse;\n funding_rates: IndexerServerFundingRatesResponse;\n interest_and_funding: IndexerServerInterestFundingResponse;\n leaderboard: IndexerServerLeaderboardResponse;\n leaderboard_contests: IndexerServerLeaderboardContestsResponse;\n leaderboard_rank: IndexerServerLeaderboardRankResponse;\n leaderboard_registration: IndexerServerLeaderboardRegistrationResponse;\n linked_signer_rate_limit: IndexerServerLinkedSignerResponse;\n maker_statistics: IndexerServerMakerStatisticsResponse;\n market_snapshots: IndexerServerMarketSnapshotsResponse;\n matches: IndexerServerMatchEventsResponse;\n oracle_price: IndexerServerOraclePricesResponse;\n orders: IndexerServerOrdersResponse;\n perp_prices: IndexerServerPerpPricesResponse;\n price: IndexerServerPriceResponse;\n product_snapshots: IndexerServerMultiProductsResponse;\n products: IndexerServerProductsResponse;\n referral_code: IndexerServerReferralCodeResponse;\n subaccounts: IndexerServerListSubaccountsResponse;\n usdc_price: IndexerServerUsdcPriceResponse;\n nlp_snapshots: IndexerServerNlpSnapshotsResponse;\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
1
+ {"version":3,"sources":["../../src/types/serverTypes.ts"],"sourcesContent":["import {\n EIP712LeaderboardAuthenticationValues,\n SignedTx,\n} from '@nadohq/shared';\nimport { IndexerEventType } from './IndexerEventType';\nimport { IndexerLeaderboardRankType } from './IndexerLeaderboardType';\nimport { NadoWithdrawCollateralTx } from './NadoTx';\nimport {\n IndexerServerCandlestick,\n IndexerServerEvent,\n IndexerServerLeaderboardContest,\n IndexerServerLeaderboardPosition,\n IndexerServerLeaderboardRegistration,\n IndexerServerMaker,\n IndexerServerMarketSnapshot,\n IndexerServerMarketSnapshotInterval,\n IndexerServerMatchEvent,\n IndexerServerNlpSnapshot,\n IndexerServerOraclePrice,\n IndexerServerOrder,\n IndexerServerProductPayment,\n IndexerServerProductSnapshot,\n IndexerServerSnapshotsInterval,\n IndexerServerTx,\n} from './serverModelTypes';\n\n/**\n * Params\n */\n\nexport interface IndexerServerListSubaccountsParams {\n // Inclusive, defaults to 0\n start?: number;\n // Defaults to 100\n limit?: number;\n address?: string;\n}\n\nexport interface IndexerServerMultiSubaccountSnapshotsParams {\n // Subaccount hex identifiers\n subaccounts: string[];\n timestamps: number[];\n // If not given, will return both isolated & non-iso balances\n isolated?: boolean;\n}\n\nexport interface IndexerServerReferralCodeParams {\n subaccount: string;\n}\n\nexport interface IndexerServerFundingRateParams {\n product_id: number;\n}\n\nexport interface IndexerServerFundingRatesParams {\n product_ids: number[];\n}\n\nexport interface IndexerServerPriceParams {\n product_id: number;\n}\n\nexport interface IndexerServerPerpPricesParams {\n product_ids: number[];\n}\n\nexport interface IndexerServerOraclePricesParams {\n product_ids: number[];\n}\n\nexport interface IndexerServerCandlesticksParams {\n product_id: number;\n granularity: number;\n // Seconds\n max_time?: number;\n limit: number;\n}\n\nexport type IndexerEdgeServerCandlesticksParams =\n IndexerServerCandlesticksParams;\n\nexport interface IndexerServerProductsParams {\n product_id: number;\n max_time?: number;\n limit: number;\n // submission_idx for pagination, inclusive\n idx?: string;\n}\n\nexport interface IndexerServerMultiProductsParams {\n product_ids: number[];\n max_time: number[];\n}\n\nexport interface IndexerServerEventsParams {\n subaccount?: string;\n product_ids?: number[];\n // If not given, will return both isolated & non-iso events\n isolated?: boolean;\n event_types?: IndexerEventType[];\n // Descending order for idx (time), defaults to true\n desc?: boolean;\n // submission_idx for pagination, inclusive\n idx?: string;\n max_time?: number;\n limit?:\n | {\n raw: number;\n }\n | {\n txs: number;\n };\n}\n\nexport type IndexerServerTriggerTypeFilter =\n | 'none'\n | 'price_trigger'\n | 'time_trigger';\n\nexport interface IndexerServerOrdersParams {\n subaccount?: string;\n product_ids?: number[];\n trigger_types?: IndexerServerTriggerTypeFilter[];\n digests?: string[];\n max_time?: number;\n limit?: number;\n // If not given, will return both isolated & non-iso orders\n isolated?: boolean;\n // submission_idx for pagination, inclusive\n idx?: string;\n}\n\nexport interface IndexerServerMatchEventsParams {\n subaccount?: string;\n product_ids?: number[];\n // If not given, will return both isolated & non-iso events\n isolated?: boolean;\n max_time?: number;\n limit: number;\n // submission_idx for pagination, inclusive\n idx?: string;\n}\n\nexport interface IndexerServerLinkedSignerParams {\n subaccount: string;\n}\n\nexport interface IndexerServerMarketSnapshotsParams {\n interval: IndexerServerMarketSnapshotInterval;\n // Defaults to all\n product_ids?: number[];\n}\n\nexport interface IndexerEdgeServerMarketSnapshotsParams {\n interval: IndexerServerMarketSnapshotInterval;\n}\n\nexport interface IndexerServerInterestFundingParams {\n subaccount: string;\n product_ids: number[];\n // If not given, defaults to latest\n max_idx?: string;\n max_time?: number;\n limit: number;\n}\n\nexport interface IndexerServerMakerStatisticsParams {\n product_id: number;\n epoch: number;\n interval: number;\n}\n\nexport interface IndexerServerLeaderboardParams {\n contest_id: number;\n rank_type: IndexerLeaderboardRankType;\n start?: number | string;\n limit?: number | string;\n}\n\nexport interface IndexerServerLeaderboardRankParams {\n subaccount: string;\n contest_ids: number[];\n}\n\nexport interface IndexerServerLeaderboardContestsParams {\n contest_ids: number[];\n}\n\nexport interface IndexerServerLeaderboardRegistrationParams {\n subaccount: string;\n contest_id: number;\n update_registration: SignedTx<EIP712LeaderboardAuthenticationValues> | null;\n}\n\nexport interface IndexerServerFastWithdrawalSignatureParams {\n /**\n * The submission index of the WithdrawCollateral tx to be used for fast withdraw.\n */\n idx: number | string;\n}\n\nexport interface IndexerServerNlpSnapshotsParams {\n interval: IndexerServerSnapshotsInterval;\n}\n\nexport interface IndexerServerDDAQueryParams {\n subaccount: string;\n}\n\n// Request\nexport interface IndexerServerQueryRequestByType {\n account_snapshots: IndexerServerMultiSubaccountSnapshotsParams;\n backlog: Record<string, never>;\n candlesticks: IndexerServerCandlesticksParams;\n direct_deposit_address: IndexerServerDDAQueryParams;\n edge_candlesticks: IndexerEdgeServerCandlesticksParams;\n edge_market_snapshots: IndexerEdgeServerMarketSnapshotsParams;\n events: IndexerServerEventsParams;\n fast_withdrawal_signature: IndexerServerFastWithdrawalSignatureParams;\n funding_rate: IndexerServerFundingRateParams;\n funding_rates: IndexerServerFundingRatesParams;\n interest_and_funding: IndexerServerInterestFundingParams;\n leaderboard: IndexerServerLeaderboardParams;\n leaderboard_contests: IndexerServerLeaderboardContestsParams;\n leaderboard_rank: IndexerServerLeaderboardRankParams;\n leaderboard_registration: IndexerServerLeaderboardRegistrationParams;\n linked_signer_rate_limit: IndexerServerLinkedSignerParams;\n maker_statistics: IndexerServerMakerStatisticsParams;\n market_snapshots: IndexerServerMarketSnapshotsParams;\n matches: IndexerServerMatchEventsParams;\n oracle_price: IndexerServerOraclePricesParams;\n orders: IndexerServerOrdersParams;\n perp_prices: IndexerServerPerpPricesParams;\n price: IndexerServerPriceParams;\n product_snapshots: IndexerServerMultiProductsParams;\n products: IndexerServerProductsParams;\n referral_code: IndexerServerReferralCodeParams;\n subaccounts: IndexerServerListSubaccountsParams;\n quote_price: Record<string, never>;\n nlp_snapshots: IndexerServerNlpSnapshotsParams;\n}\n\nexport type IndexerServerQueryRequestType =\n keyof IndexerServerQueryRequestByType;\n\n/**\n * Responses\n */\n\nexport interface IndexerServerListSubaccountsResponse {\n subaccounts: {\n id: string;\n // Hex of subaccount bytes\n subaccount: string;\n }[];\n}\n\nexport interface IndexerServerMultiSubaccountSnapshotsResponse {\n // Map of subaccount hex -> timestamp requested -> latest events corresponding to each product\n snapshots: Record<string, Record<string, IndexerServerEvent[]>>;\n}\n\nexport interface IndexerServerReferralCodeResponse {\n referral_code: string | null;\n}\n\nexport interface IndexerServerFundingRate {\n product_id: number;\n funding_rate_x18: string;\n update_time: number;\n}\n\nexport type IndexerServerFundingRateResponse = IndexerServerFundingRate;\n\n// Map of productId -> IndexerServerFundingRate\nexport type IndexerServerFundingRatesResponse = Record<\n string,\n IndexerServerFundingRate\n>;\n\nexport interface IndexerServerPerpPrices {\n product_id: number;\n index_price_x18: string;\n mark_price_x18: string;\n update_time: number;\n}\n\nexport type IndexerServerPriceResponse = IndexerServerPerpPrices;\n\n// Map of productId -> IndexerServerPerpPrices\nexport type IndexerServerPerpPricesResponse = Record<\n string,\n IndexerServerPerpPrices\n>;\n\nexport interface IndexerServerOraclePricesResponse {\n prices: IndexerServerOraclePrice[];\n}\n\nexport interface IndexerServerCandlesticksResponse {\n candlesticks: IndexerServerCandlestick[];\n}\n\nexport type IndexerEdgeServerCandlesticksResponse =\n IndexerServerCandlesticksResponse;\n\nexport interface IndexerServerProductsResponse {\n products: IndexerServerProductSnapshot[];\n txs: IndexerServerTx[];\n}\n\n// Map of timestamp -> (productID -> IndexerServerProductSnapshot)\nexport type IndexerServerMultiProductsResponse = Record<\n string,\n Record<string, IndexerServerProductSnapshot>\n>;\n\nexport interface IndexerServerEventsResponse {\n events: IndexerServerEvent[];\n txs: IndexerServerTx[];\n}\n\nexport interface IndexerServerOrdersResponse {\n orders: IndexerServerOrder[];\n}\n\nexport interface IndexerServerMatchEventsResponse {\n matches: IndexerServerMatchEvent[];\n txs: IndexerServerTx[];\n}\n\nexport interface IndexerServerQuotePriceResponse {\n price_x18: string;\n}\n\nexport interface IndexerServerLinkedSignerResponse {\n total_tx_limit: string;\n remaining_tx: string;\n wait_time: string;\n signer: string;\n}\n\nexport interface IndexerServerMarketSnapshotsResponse {\n snapshots: IndexerServerMarketSnapshot[];\n}\n\nexport interface IndexerEdgeServerMarketSnapshotsResponse {\n snapshots: Record<number, IndexerServerMarketSnapshot[]>;\n}\n\nexport interface IndexerServerInterestFundingResponse {\n interest_payments: IndexerServerProductPayment[];\n funding_payments: IndexerServerProductPayment[];\n next_idx: string;\n}\n\nexport interface IndexerServerMakerStatisticsResponse {\n reward_coefficient: string;\n makers: IndexerServerMaker[];\n}\n\nexport interface IndexerServerLeaderboardResponse {\n positions: IndexerServerLeaderboardPosition[];\n}\n\nexport interface IndexerServerLeaderboardRegistrationResponse {\n // For non-tiered contests, null if the user is not registered for the provided contestId.\n // For tiered contests (i.e., related contests), null if the user is not registered for any of the contests in the tier group.\n registration: IndexerServerLeaderboardRegistration | null;\n}\n\nexport interface IndexerServerLeaderboardRankResponse {\n // If the subaccount is not eligible for a given contest, it would not be included in the response.\n // contestId -> IndexerServerLeaderboardPosition\n positions: Record<string, IndexerServerLeaderboardPosition>;\n}\n\nexport interface IndexerServerLeaderboardContestsResponse {\n contests: IndexerServerLeaderboardContest[];\n}\n\nexport interface IndexerServerFastWithdrawalSignatureResponse {\n idx: string;\n tx: NadoWithdrawCollateralTx['withdraw_collateral'];\n tx_bytes: string;\n signatures: string[];\n}\n\nexport interface IndexerServerNlpSnapshotsResponse {\n snapshots: IndexerServerNlpSnapshot[];\n}\n\nexport interface IndexerServerDDAResponse {\n v1_address: string;\n}\n\nexport interface IndexerServerBacklogResponse {\n // Total number of transactions stored in the indexer DB\n total_txs: string;\n // Current nSubmissions value from the chain (i.e., number of processed txs)\n total_submissions: string;\n // Number of unprocessed transactions (total_txs - total_submissions)\n backlog_size: string;\n // UNIX timestamp (in seconds) of when the data was last updated\n updated_at: string;\n // Estimated time in seconds (float) to clear the entire backlog (null if unavailable)\n backlog_eta_in_seconds: string | null;\n // Current submission rate in transactions per second (float) (null if unavailable)\n txs_per_second: string | null;\n}\n\n// Response\nexport interface IndexerServerQueryResponseByType {\n account_snapshots: IndexerServerMultiSubaccountSnapshotsResponse;\n backlog: IndexerServerBacklogResponse;\n candlesticks: IndexerServerCandlesticksResponse;\n direct_deposit_address: IndexerServerDDAResponse;\n edge_candlesticks: IndexerEdgeServerCandlesticksResponse;\n edge_market_snapshots: IndexerEdgeServerMarketSnapshotsResponse;\n events: IndexerServerEventsResponse;\n fast_withdrawal_signature: IndexerServerFastWithdrawalSignatureResponse;\n funding_rate: IndexerServerFundingRateResponse;\n funding_rates: IndexerServerFundingRatesResponse;\n interest_and_funding: IndexerServerInterestFundingResponse;\n leaderboard: IndexerServerLeaderboardResponse;\n leaderboard_contests: IndexerServerLeaderboardContestsResponse;\n leaderboard_rank: IndexerServerLeaderboardRankResponse;\n leaderboard_registration: IndexerServerLeaderboardRegistrationResponse;\n linked_signer_rate_limit: IndexerServerLinkedSignerResponse;\n maker_statistics: IndexerServerMakerStatisticsResponse;\n market_snapshots: IndexerServerMarketSnapshotsResponse;\n matches: IndexerServerMatchEventsResponse;\n oracle_price: IndexerServerOraclePricesResponse;\n orders: IndexerServerOrdersResponse;\n perp_prices: IndexerServerPerpPricesResponse;\n price: IndexerServerPriceResponse;\n product_snapshots: IndexerServerMultiProductsResponse;\n products: IndexerServerProductsResponse;\n referral_code: IndexerServerReferralCodeResponse;\n subaccounts: IndexerServerListSubaccountsResponse;\n quote_price: IndexerServerQuotePriceResponse;\n nlp_snapshots: IndexerServerNlpSnapshotsResponse;\n}\n\n/**\n * V2 API Types\n */\n\n/**\n * Individual ticker data from v2 indexer endpoint (server format)\n */\nexport interface IndexerServerV2TickerResponse {\n product_id: number;\n ticker_id: string;\n base_currency: string;\n quote_currency: string;\n last_price: number;\n base_volume: number;\n quote_volume: number;\n price_change_percent_24h: number;\n}\n\n/**\n * Response from v2 tickers endpoint (server format)\n * Maps ticker IDs to their respective ticker data\n */\nexport type IndexerServerV2TickersResponse = Record<\n string,\n IndexerServerV2TickerResponse\n>;\n"],"mappings":";;;;;;;;;;;;;;;;AAAA;AAAA;","names":[]}