@nadohq/nuanze-client 0.43.1 → 0.45.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (69) hide show
  1. package/README.md +21 -0
  2. package/dist/{NuanzeClient-BrjXP2Sz.cjs → NuanzeClient-D_LPUkvb.cjs} +59 -45
  3. package/dist/NuanzeClient-D_LPUkvb.cjs.map +1 -0
  4. package/dist/NuanzeClient.cjs +1 -1
  5. package/dist/NuanzeClient.d.cts +49 -35
  6. package/dist/NuanzeClient.d.cts.map +1 -1
  7. package/dist/NuanzeClient.d.ts +49 -35
  8. package/dist/NuanzeClient.d.ts.map +1 -1
  9. package/dist/NuanzeClient.js +58 -44
  10. package/dist/NuanzeClient.js.map +1 -1
  11. package/dist/{NuanzeServerFailureError-DQp7Lca2.d.ts → NuanzeServerFailureError-D-C98gOE.d.ts} +2 -2
  12. package/dist/{NuanzeServerFailureError-DQp7Lca2.d.ts.map → NuanzeServerFailureError-D-C98gOE.d.ts.map} +1 -1
  13. package/dist/{NuanzeServerFailureError-DMdmlNpW.d.cts → NuanzeServerFailureError-cR0V5to1.d.cts} +2 -2
  14. package/dist/{NuanzeServerFailureError-DMdmlNpW.d.cts.map → NuanzeServerFailureError-cR0V5to1.d.cts.map} +1 -1
  15. package/dist/{clientModelTypes-CreYRHbE.d.ts → clientModelTypes-Bzf5pbVl.d.ts} +6 -1
  16. package/dist/{clientModelTypes-CreYRHbE.d.ts.map → clientModelTypes-Bzf5pbVl.d.ts.map} +1 -1
  17. package/dist/{clientModelTypes-DyNrbcyr.d.cts → clientModelTypes-DE60UN6J.d.cts} +6 -1
  18. package/dist/{clientModelTypes-DyNrbcyr.d.cts.map → clientModelTypes-DE60UN6J.d.cts.map} +1 -1
  19. package/dist/{clientTypes-DfQsJWmx.d.cts → clientTypes-BxpTClrz.d.ts} +63 -73
  20. package/dist/clientTypes-BxpTClrz.d.ts.map +1 -0
  21. package/dist/{clientTypes-BPlIXBRh.d.ts → clientTypes-DXquGZPe.d.cts} +63 -73
  22. package/dist/clientTypes-DXquGZPe.d.cts.map +1 -0
  23. package/dist/dataMappers.cjs +7 -14
  24. package/dist/dataMappers.cjs.map +1 -1
  25. package/dist/dataMappers.d.cts +4 -4
  26. package/dist/dataMappers.d.cts.map +1 -1
  27. package/dist/dataMappers.d.ts +4 -4
  28. package/dist/dataMappers.d.ts.map +1 -1
  29. package/dist/dataMappers.js +6 -13
  30. package/dist/dataMappers.js.map +1 -1
  31. package/dist/index.cjs +1 -1
  32. package/dist/index.d.cts +6 -6
  33. package/dist/index.d.ts +6 -6
  34. package/dist/{serverModelTypes-DL_58zos.d.ts → serverModelTypes-A_b-zjZO.d.ts} +3 -2
  35. package/dist/{serverModelTypes-DL_58zos.d.ts.map → serverModelTypes-A_b-zjZO.d.ts.map} +1 -1
  36. package/dist/{serverModelTypes-DUggGfPj.d.cts → serverModelTypes-Db5COWs3.d.cts} +3 -2
  37. package/dist/{serverModelTypes-DUggGfPj.d.cts.map → serverModelTypes-Db5COWs3.d.cts.map} +1 -1
  38. package/dist/{serverQueryTypes-D5-euf7o.d.ts → serverQueryTypes-CHYSYH97.d.ts} +11 -7
  39. package/dist/serverQueryTypes-CHYSYH97.d.ts.map +1 -0
  40. package/dist/{serverQueryTypes-d03JU0mr.d.cts → serverQueryTypes-QNx6f1km.d.cts} +11 -7
  41. package/dist/serverQueryTypes-QNx6f1km.d.cts.map +1 -0
  42. package/dist/types/NuanzeServerFailureError.d.cts +1 -1
  43. package/dist/types/NuanzeServerFailureError.d.ts +1 -1
  44. package/dist/types/clientModelTypes.cjs.map +1 -1
  45. package/dist/types/clientModelTypes.d.cts +1 -1
  46. package/dist/types/clientModelTypes.d.ts +1 -1
  47. package/dist/types/clientModelTypes.js.map +1 -1
  48. package/dist/types/clientTypes.d.cts +2 -2
  49. package/dist/types/clientTypes.d.ts +2 -2
  50. package/dist/types/index.d.cts +6 -6
  51. package/dist/types/index.d.ts +6 -6
  52. package/dist/types/serverModelTypes.d.cts +1 -1
  53. package/dist/types/serverModelTypes.d.ts +1 -1
  54. package/dist/types/serverQueryTypes.cjs.map +1 -1
  55. package/dist/types/serverQueryTypes.d.cts +1 -1
  56. package/dist/types/serverQueryTypes.d.ts +1 -1
  57. package/dist/types/serverQueryTypes.js.map +1 -1
  58. package/package.json +3 -3
  59. package/src/NuanzeClient.ts +76 -55
  60. package/src/dataMappers.ts +7 -17
  61. package/src/types/clientModelTypes.ts +5 -0
  62. package/src/types/clientTypes.ts +48 -35
  63. package/src/types/serverModelTypes.ts +1 -0
  64. package/src/types/serverQueryTypes.ts +8 -4
  65. package/dist/NuanzeClient-BrjXP2Sz.cjs.map +0 -1
  66. package/dist/clientTypes-BPlIXBRh.d.ts.map +0 -1
  67. package/dist/clientTypes-DfQsJWmx.d.cts.map +0 -1
  68. package/dist/serverQueryTypes-D5-euf7o.d.ts.map +0 -1
  69. package/dist/serverQueryTypes-d03JU0mr.d.cts.map +0 -1
@@ -1,4 +1,4 @@
1
- import { $ as NuanzeMarket, A as NuanzeCandleInterval, B as NuanzeFlowTimeframe, Ct as NuanzeOpenPositionSortDirection, Et as NuanzePnlWindow, F as NuanzeCoverage, I as NuanzeFlowBucket, It as NuanzeSubaccountLeaderboardItem, J as NuanzeFundingRate, Mt as NuanzeSeriesPoint, N as NuanzeCollateralFlow, P as NuanzeCollateralFlowPoint, Pt as NuanzeSourceInterval, R as NuanzeFlowEventTypeFilter, Rt as NuanzeWalletPosition, St as NuanzeOpenPosition, Tt as NuanzePlatformWindow, V as NuanzeFollowedLeaderboardItem, X as NuanzeLeaderboardItem, Z as NuanzeLeaderboardTimeframe, _t as NuanzeNewsSentiment, at as NuanzeMarketPositionSortDirection, ct as NuanzeMarketPositioningNotionalBucketResponse, dt as NuanzeMarketTradingStatus, ft as NuanzeMarketVenue, gt as NuanzeNewsEventType, it as NuanzeMarketPositionSortBy, jt as NuanzeSeriesMetric, k as NuanzeCandle, kt as NuanzePositioningGroupBy, lt as NuanzeMarketPositioningSideResponse, pt as NuanzeMinPositionUsd, rt as NuanzeMarketPosition, st as NuanzeMarketPositioningCohortResponse, tt as NuanzeMarketDetail, ut as NuanzeMarketTrade, vt as NuanzeNewsStory, wt as NuanzePlatformDeltas, zt as NuanzeWalletTrade } from "./clientModelTypes-DyNrbcyr.cjs";
1
+ import { $ as NuanzeMarket, A as NuanzeCandleInterval, B as NuanzeFlowTimeframe, Ct as NuanzeOpenPositionSortDirection, Et as NuanzePnlWindow, F as NuanzeCoverage, I as NuanzeFlowBucket, It as NuanzeSubaccountLeaderboardItem, J as NuanzeFundingRate, Mt as NuanzeSeriesPoint, N as NuanzeCollateralFlow, P as NuanzeCollateralFlowPoint, Pt as NuanzeSourceInterval, R as NuanzeFlowEventTypeFilter, Rt as NuanzeWalletPosition, St as NuanzeOpenPosition, Tt as NuanzePlatformWindow, V as NuanzeFollowedLeaderboardItem, X as NuanzeLeaderboardItem, Z as NuanzeLeaderboardTimeframe, _t as NuanzeNewsSentiment, at as NuanzeMarketPositionSortDirection, ct as NuanzeMarketPositioningNotionalBucketResponse, dt as NuanzeMarketTradingStatus, ft as NuanzeMarketVenue, gt as NuanzeNewsEventType, it as NuanzeMarketPositionSortBy, jt as NuanzeSeriesMetric, k as NuanzeCandle, kt as NuanzePositioningGroupBy, lt as NuanzeMarketPositioningSideResponse, pt as NuanzeMinPositionUsd, rt as NuanzeMarketPosition, st as NuanzeMarketPositioningCohortResponse, tt as NuanzeMarketDetail, ut as NuanzeMarketTrade, vt as NuanzeNewsStory, wt as NuanzePlatformDeltas, zt as NuanzeWalletTrade } from "./clientModelTypes-Bzf5pbVl.js";
2
2
  import BigNumber from "bignumber.js";
3
3
 
4
4
  //#region src/types/clientTypes.d.ts
@@ -33,6 +33,13 @@ interface GetNuanzeMarketsResponse {
33
33
  interface GetNuanzeNewsParams {
34
34
  /** Page size, 1-100, default 30. */
35
35
  limit?: number;
36
+ /**
37
+ * Exact canonical ticker, matched case-insensitively across every product for the asset. Spot
38
+ * and perpetual markets are not distinguished. When productId is also supplied, both must match.
39
+ */
40
+ ticker?: string;
41
+ /** Exact public product ID. When ticker is also supplied, both filters must match. */
42
+ productId?: number;
36
43
  /** Restrict to one sentiment. */
37
44
  sentiment?: NuanzeNewsSentiment;
38
45
  /** Restrict to one event type. */
@@ -54,23 +61,37 @@ interface GetNuanzeNewsResponse {
54
61
  asOf: string;
55
62
  }
56
63
  /**
57
- * Params for `NuanzeClient.getMarketByTicker`.
64
+ * Selects a market for scoped GET operations under `/markets/{ticker}`. The `{ticker}` path
65
+ * segment accepts a canonical ticker, legacy source symbol, or numeric product ID. At least one
66
+ * of `ticker` or `productId` is required. When both are supplied, `productId` is encoded as the
67
+ * path segment and `ticker` is ignored (neither field is sent as a query parameter).
58
68
  */
59
- interface GetNuanzeMarketByTickerParams {
60
- /** Case-insensitive canonical ticker or accepted legacy source symbol. */
69
+ type NuanzeMarketSelector = {
70
+ /**
71
+ * Canonical ticker or legacy source symbol. Case-insensitive. Used as the path segment when
72
+ * `productId` is omitted; ignored when `productId` is supplied.
73
+ */
61
74
  ticker: string;
62
- /** Restrict to one venue. Omit to use the asset's primary venue. */
63
- venue?: NuanzeMarketVenue;
64
- /** Pin an exact product; must match ticker and venue. */
75
+ /**
76
+ * Public product ID. When supplied, used as the path segment and `ticker` is ignored.
77
+ */
65
78
  productId?: number;
79
+ } | {
80
+ ticker?: string; /** Public product ID used as the path segment. */
81
+ productId: number;
82
+ };
83
+ /**
84
+ * Params for `NuanzeClient.getMarketByTicker`. Requires {@link NuanzeMarketSelector}.
85
+ */
86
+ type GetNuanzeMarketByTickerParams = NuanzeMarketSelector & {
87
+ /** Restrict to one venue. Omit to use the asset's primary venue. */venue?: NuanzeMarketVenue;
66
88
  /**
67
89
  * When true and `venue` is omitted, reject a multi-venue canonical ticker with
68
90
  * `AMBIGUOUS_MARKET`. Default false.
69
91
  */
70
- strictVenue?: boolean;
71
- /** Max published stories to include, 1-30, default 12. */
92
+ strictVenue?: boolean; /** Max published stories to include, 1-30, default 12. */
72
93
  newsLimit?: number;
73
- }
94
+ };
74
95
  /**
75
96
  * Response of `NuanzeClient.getMarketByTicker`.
76
97
  */
@@ -297,29 +318,20 @@ interface GetNuanzeWalletPositionsResponse {
297
318
  asOf: string;
298
319
  }
299
320
  /**
300
- * Params for `NuanzeClient.getMarketTrades`.
321
+ * Params for `NuanzeClient.getMarketTrades`. Requires {@link NuanzeMarketSelector}.
301
322
  */
302
- interface GetNuanzeMarketTradesParams {
303
- /** Case-insensitive canonical ticker or accepted legacy source symbol. */
304
- ticker: string;
305
- /** Restrict to one venue. Omit to use the asset's primary venue. */
306
- venue?: NuanzeMarketVenue;
307
- /** Pin an exact product; must match ticker and venue. */
308
- productId?: number;
323
+ type GetNuanzeMarketTradesParams = NuanzeMarketSelector & {
324
+ /** Restrict to one venue. Omit to use the asset's primary venue. */venue?: NuanzeMarketVenue;
309
325
  /**
310
326
  * When true and `venue` is omitted, reject a multi-venue canonical ticker with
311
327
  * `AMBIGUOUS_MARKET`. Default false.
312
328
  */
313
- strictVenue?: boolean;
314
- /** Page size, 1-200, default 50. */
315
- limit?: number;
316
- /** Inclusive start as a UTC ISO 8601 string. */
317
- from?: string;
318
- /** Exclusive end as a UTC ISO 8601 string. */
319
- to?: string;
320
- /** Opaque exclusive cursor bound to the normalized filters. */
329
+ strictVenue?: boolean; /** Page size, 1-200, default 50. */
330
+ limit?: number; /** Inclusive start as a UTC ISO 8601 string. */
331
+ from?: string; /** Exclusive end as a UTC ISO 8601 string. */
332
+ to?: string; /** Opaque exclusive cursor bound to the normalized filters. */
321
333
  cursor?: string;
322
- }
334
+ };
323
335
  /**
324
336
  * Response of `NuanzeClient.getMarketTrades`.
325
337
  */
@@ -340,29 +352,20 @@ interface GetNuanzeMarketTradesResponse {
340
352
  asOf: string;
341
353
  }
342
354
  /**
343
- * Params for `NuanzeClient.getMarketCandles`.
355
+ * Params for `NuanzeClient.getMarketCandles`. Requires {@link NuanzeMarketSelector}.
344
356
  */
345
- interface GetNuanzeMarketCandlesParams {
346
- /** Case-insensitive canonical ticker or accepted legacy source symbol. */
347
- ticker: string;
348
- /** Restrict to one venue. Omit to use the asset's primary venue. */
349
- venue?: NuanzeMarketVenue;
350
- /** Pin an exact product; must match ticker and venue. */
351
- productId?: number;
357
+ type GetNuanzeMarketCandlesParams = NuanzeMarketSelector & {
358
+ /** Restrict to one venue. Omit to use the asset's primary venue. */venue?: NuanzeMarketVenue;
352
359
  /**
353
360
  * When true and `venue` is omitted, reject a multi-venue canonical ticker with
354
361
  * `AMBIGUOUS_MARKET`. Default false.
355
362
  */
356
- strictVenue?: boolean;
357
- /** Bar interval, default `1h`. */
358
- interval?: NuanzeCandleInterval;
359
- /** Inclusive start as a UTC ISO 8601 string. */
360
- from?: string;
361
- /** Exclusive end as a UTC ISO 8601 string. */
362
- to?: string;
363
- /** Newest matching bars to return, 1-750, default 200. Returned oldest-to-newest. */
363
+ strictVenue?: boolean; /** Bar interval, default `1h`. */
364
+ interval?: NuanzeCandleInterval; /** Inclusive start as a UTC ISO 8601 string. */
365
+ from?: string; /** Exclusive end as a UTC ISO 8601 string. */
366
+ to?: string; /** Newest matching bars to return, 1-750, default 200. Returned oldest-to-newest. */
364
367
  limit?: number;
365
- }
368
+ };
366
369
  /**
367
370
  * Response of `NuanzeClient.getMarketCandles`.
368
371
  */
@@ -587,51 +590,38 @@ interface GetNuanzeCollateralFlowSeriesResponse {
587
590
  asOf: string;
588
591
  }
589
592
  /**
590
- * Params for `NuanzeClient.getMarketPositioning`. Resolves only an active perpetual.
593
+ * Params for `NuanzeClient.getMarketPositioning`. Requires {@link NuanzeMarketSelector}. Resolves
594
+ * only an active perpetual.
591
595
  */
592
- interface GetNuanzeMarketPositioningParams {
593
- /** Case-insensitive canonical ticker or accepted legacy source symbol. */
594
- ticker: string;
595
- /** If supplied, only `perp` is valid. */
596
- venue?: 'perp';
597
- /** Pin an exact product; must match ticker and venue. */
598
- productId?: number;
596
+ type GetNuanzeMarketPositioningParams = NuanzeMarketSelector & {
597
+ /** If supplied, only `perp` is valid. */venue?: 'perp';
599
598
  /**
600
599
  * When true and `venue` is omitted, reject a multi-venue canonical ticker with
601
600
  * `AMBIGUOUS_MARKET`. Default false.
602
601
  */
603
- strictVenue?: boolean;
604
- /** Cell grouping, default `side`. */
605
- groupBy?: NuanzePositioningGroupBy;
606
- /** Inclusion threshold as a USD string, default `'10'`. */
602
+ strictVenue?: boolean; /** Cell grouping, default `side`. */
603
+ groupBy?: NuanzePositioningGroupBy; /** Inclusion threshold as a USD string, default `'10'`. */
607
604
  minPositionUsd?: NuanzeMinPositionUsd;
608
- }
605
+ };
609
606
  /**
610
607
  * Response of `NuanzeClient.getMarketPositioning`. Discriminated by `groupBy`.
611
608
  */
612
609
  type GetNuanzeMarketPositioningResponse = NuanzeMarketPositioningSideResponse | NuanzeMarketPositioningCohortResponse | NuanzeMarketPositioningNotionalBucketResponse;
613
610
  /**
614
- * Params for `NuanzeClient.getMarketPositions`. Resolves only an active perpetual.
611
+ * Params for `NuanzeClient.getMarketPositions`. Requires {@link NuanzeMarketSelector}. Resolves
612
+ * only an active perpetual.
615
613
  */
616
- interface GetNuanzeMarketPositionsParams {
617
- /** Case-insensitive canonical ticker or accepted legacy source symbol. */
618
- ticker: string;
619
- /** If supplied, only `perp` is valid. */
620
- venue?: 'perp';
621
- /** Pin an exact product; must match ticker and venue. */
622
- productId?: number;
623
- /** Page size, 1-200, default 50. */
614
+ type GetNuanzeMarketPositionsParams = NuanzeMarketSelector & {
615
+ /** If supplied, only `perp` is valid. */venue?: 'perp'; /** Page size, 1-200, default 50. */
624
616
  limit?: number;
625
617
  /**
626
618
  * Primary ordering field, default `notional`. Notional and amount use absolute values; PnL remains
627
619
  * signed.
628
620
  */
629
- sortBy?: NuanzeMarketPositionSortBy;
630
- /** Primary ordering direction, default `desc`. */
631
- sortDirection?: NuanzeMarketPositionSortDirection;
632
- /** Opaque exclusive cursor bound to the resolved product. */
621
+ sortBy?: NuanzeMarketPositionSortBy; /** Primary ordering direction, default `desc`. */
622
+ sortDirection?: NuanzeMarketPositionSortDirection; /** Opaque exclusive cursor bound to the resolved product. */
633
623
  cursor?: string;
634
- }
624
+ };
635
625
  /**
636
626
  * Response of `NuanzeClient.getMarketPositions`.
637
627
  */
@@ -681,5 +671,5 @@ interface GetNuanzeOpenPositionsResponse {
681
671
  asOf: string;
682
672
  }
683
673
  //#endregion
684
- export { GetNuanzePlatformSummaryResponse as A, GetNuanzeWalletSummaryResponse as B, GetNuanzeMarketsParams as C, GetNuanzeOpenPositionsParams as D, GetNuanzeNewsResponse as E, GetNuanzeWalletPnlSeriesParams as F, GetNuanzeWalletTradesResponse as H, GetNuanzeWalletPnlSeriesResponse as I, GetNuanzeWalletPositionsParams as L, GetNuanzeSubaccountLeaderboardResponse as M, GetNuanzeWalletPnlParams as N, GetNuanzeOpenPositionsResponse as O, GetNuanzeWalletPnlResponse as P, GetNuanzeWalletPositionsResponse as R, GetNuanzeMarketTradesResponse as S, GetNuanzeNewsParams as T, GetNuanzeWalletTradesParams as V, GetNuanzeMarketPositioningParams as _, GetNuanzeCollateralFlowsParams as a, GetNuanzeMarketPositionsResponse as b, GetNuanzeFollowedLeaderboardResponse as c, GetNuanzeLeaderboardParams as d, GetNuanzeLeaderboardResponse as f, GetNuanzeMarketCandlesResponse as g, GetNuanzeMarketCandlesParams as h, GetNuanzeCollateralFlowSummaryResponse as i, GetNuanzeSubaccountLeaderboardParams as j, GetNuanzePlatformSummaryParams as k, GetNuanzeFundingRatesParams as l, GetNuanzeMarketByTickerResponse as m, GetNuanzeCollateralFlowSeriesResponse as n, GetNuanzeCollateralFlowsResponse as o, GetNuanzeMarketByTickerParams as p, GetNuanzeCollateralFlowSummaryParams as r, GetNuanzeFollowedLeaderboardParams as s, GetNuanzeCollateralFlowSeriesParams as t, GetNuanzeFundingRatesResponse as u, GetNuanzeMarketPositioningResponse as v, GetNuanzeMarketsResponse as w, GetNuanzeMarketTradesParams as x, GetNuanzeMarketPositionsParams as y, GetNuanzeWalletSummaryParams as z };
685
- //# sourceMappingURL=clientTypes-DfQsJWmx.d.cts.map
674
+ export { GetNuanzePlatformSummaryResponse as A, GetNuanzeWalletSummaryResponse as B, GetNuanzeMarketsParams as C, GetNuanzeOpenPositionsParams as D, GetNuanzeNewsResponse as E, GetNuanzeWalletPnlSeriesParams as F, GetNuanzeWalletTradesResponse as H, GetNuanzeWalletPnlSeriesResponse as I, GetNuanzeWalletPositionsParams as L, GetNuanzeSubaccountLeaderboardResponse as M, GetNuanzeWalletPnlParams as N, GetNuanzeOpenPositionsResponse as O, GetNuanzeWalletPnlResponse as P, GetNuanzeWalletPositionsResponse as R, GetNuanzeMarketTradesResponse as S, GetNuanzeNewsParams as T, NuanzeMarketSelector as U, GetNuanzeWalletTradesParams as V, GetNuanzeMarketPositioningParams as _, GetNuanzeCollateralFlowsParams as a, GetNuanzeMarketPositionsResponse as b, GetNuanzeFollowedLeaderboardResponse as c, GetNuanzeLeaderboardParams as d, GetNuanzeLeaderboardResponse as f, GetNuanzeMarketCandlesResponse as g, GetNuanzeMarketCandlesParams as h, GetNuanzeCollateralFlowSummaryResponse as i, GetNuanzeSubaccountLeaderboardParams as j, GetNuanzePlatformSummaryParams as k, GetNuanzeFundingRatesParams as l, GetNuanzeMarketByTickerResponse as m, GetNuanzeCollateralFlowSeriesResponse as n, GetNuanzeCollateralFlowsResponse as o, GetNuanzeMarketByTickerParams as p, GetNuanzeCollateralFlowSummaryParams as r, GetNuanzeFollowedLeaderboardParams as s, GetNuanzeCollateralFlowSeriesParams as t, GetNuanzeFundingRatesResponse as u, GetNuanzeMarketPositioningResponse as v, GetNuanzeMarketsResponse as w, GetNuanzeMarketTradesParams as x, GetNuanzeMarketPositionsParams as y, GetNuanzeWalletSummaryParams as z };
675
+ //# sourceMappingURL=clientTypes-BxpTClrz.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"clientTypes-BxpTClrz.d.ts","names":[],"sources":["../src/types/src/types/clientTypes.ts"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,GACA,qCAAA,GACA,6CAAA;;;;;KAMQ,8BAAA,GAAiC,oBAAA;2CAE3C,KAAA;EAEA,KAAA;;;;;EAKA,MAAA,GAAS,0BAAA;EAET,aAAA,GAAgB,iCAAA;EAEhB,MAAA;AAAA;;;;UAMe,gCAAA;;EAEf,SAAA;;EAEA,MAAA;;EAEA,MAAA;;EAEA,KAAA,EAAO,iBAAA;;EAEP,SAAA,EAAW,oBAAoB;;EAE/B,UAAA;;EAEA,aAAA;;EAEA,IAAA;AAAA;;;;;UAOe,4BAAA;;EAEf,KAAA;;EAEA,aAAA,GAAgB,+BAA+B;;EAE/C,cAAA;;EAEA,MAAA;AAAA;;;;UAMe,8BAAA;;EAEf,SAAA,EAAW,kBAAkB;;EAE7B,UAAA;;EAEA,aAAA;;EAEA,IAAA;AAAA"}
@@ -1,4 +1,4 @@
1
- import { $ as NuanzeMarket, A as NuanzeCandleInterval, B as NuanzeFlowTimeframe, Ct as NuanzeOpenPositionSortDirection, Et as NuanzePnlWindow, F as NuanzeCoverage, I as NuanzeFlowBucket, It as NuanzeSubaccountLeaderboardItem, J as NuanzeFundingRate, Mt as NuanzeSeriesPoint, N as NuanzeCollateralFlow, P as NuanzeCollateralFlowPoint, Pt as NuanzeSourceInterval, R as NuanzeFlowEventTypeFilter, Rt as NuanzeWalletPosition, St as NuanzeOpenPosition, Tt as NuanzePlatformWindow, V as NuanzeFollowedLeaderboardItem, X as NuanzeLeaderboardItem, Z as NuanzeLeaderboardTimeframe, _t as NuanzeNewsSentiment, at as NuanzeMarketPositionSortDirection, ct as NuanzeMarketPositioningNotionalBucketResponse, dt as NuanzeMarketTradingStatus, ft as NuanzeMarketVenue, gt as NuanzeNewsEventType, it as NuanzeMarketPositionSortBy, jt as NuanzeSeriesMetric, k as NuanzeCandle, kt as NuanzePositioningGroupBy, lt as NuanzeMarketPositioningSideResponse, pt as NuanzeMinPositionUsd, rt as NuanzeMarketPosition, st as NuanzeMarketPositioningCohortResponse, tt as NuanzeMarketDetail, ut as NuanzeMarketTrade, vt as NuanzeNewsStory, wt as NuanzePlatformDeltas, zt as NuanzeWalletTrade } from "./clientModelTypes-CreYRHbE.js";
1
+ import { $ as NuanzeMarket, A as NuanzeCandleInterval, B as NuanzeFlowTimeframe, Ct as NuanzeOpenPositionSortDirection, Et as NuanzePnlWindow, F as NuanzeCoverage, I as NuanzeFlowBucket, It as NuanzeSubaccountLeaderboardItem, J as NuanzeFundingRate, Mt as NuanzeSeriesPoint, N as NuanzeCollateralFlow, P as NuanzeCollateralFlowPoint, Pt as NuanzeSourceInterval, R as NuanzeFlowEventTypeFilter, Rt as NuanzeWalletPosition, St as NuanzeOpenPosition, Tt as NuanzePlatformWindow, V as NuanzeFollowedLeaderboardItem, X as NuanzeLeaderboardItem, Z as NuanzeLeaderboardTimeframe, _t as NuanzeNewsSentiment, at as NuanzeMarketPositionSortDirection, ct as NuanzeMarketPositioningNotionalBucketResponse, dt as NuanzeMarketTradingStatus, ft as NuanzeMarketVenue, gt as NuanzeNewsEventType, it as NuanzeMarketPositionSortBy, jt as NuanzeSeriesMetric, k as NuanzeCandle, kt as NuanzePositioningGroupBy, lt as NuanzeMarketPositioningSideResponse, pt as NuanzeMinPositionUsd, rt as NuanzeMarketPosition, st as NuanzeMarketPositioningCohortResponse, tt as NuanzeMarketDetail, ut as NuanzeMarketTrade, vt as NuanzeNewsStory, wt as NuanzePlatformDeltas, zt as NuanzeWalletTrade } from "./clientModelTypes-DE60UN6J.cjs";
2
2
  import BigNumber from "bignumber.js";
3
3
 
4
4
  //#region src/types/clientTypes.d.ts
@@ -33,6 +33,13 @@ interface GetNuanzeMarketsResponse {
33
33
  interface GetNuanzeNewsParams {
34
34
  /** Page size, 1-100, default 30. */
35
35
  limit?: number;
36
+ /**
37
+ * Exact canonical ticker, matched case-insensitively across every product for the asset. Spot
38
+ * and perpetual markets are not distinguished. When productId is also supplied, both must match.
39
+ */
40
+ ticker?: string;
41
+ /** Exact public product ID. When ticker is also supplied, both filters must match. */
42
+ productId?: number;
36
43
  /** Restrict to one sentiment. */
37
44
  sentiment?: NuanzeNewsSentiment;
38
45
  /** Restrict to one event type. */
@@ -54,23 +61,37 @@ interface GetNuanzeNewsResponse {
54
61
  asOf: string;
55
62
  }
56
63
  /**
57
- * Params for `NuanzeClient.getMarketByTicker`.
64
+ * Selects a market for scoped GET operations under `/markets/{ticker}`. The `{ticker}` path
65
+ * segment accepts a canonical ticker, legacy source symbol, or numeric product ID. At least one
66
+ * of `ticker` or `productId` is required. When both are supplied, `productId` is encoded as the
67
+ * path segment and `ticker` is ignored (neither field is sent as a query parameter).
58
68
  */
59
- interface GetNuanzeMarketByTickerParams {
60
- /** Case-insensitive canonical ticker or accepted legacy source symbol. */
69
+ type NuanzeMarketSelector = {
70
+ /**
71
+ * Canonical ticker or legacy source symbol. Case-insensitive. Used as the path segment when
72
+ * `productId` is omitted; ignored when `productId` is supplied.
73
+ */
61
74
  ticker: string;
62
- /** Restrict to one venue. Omit to use the asset's primary venue. */
63
- venue?: NuanzeMarketVenue;
64
- /** Pin an exact product; must match ticker and venue. */
75
+ /**
76
+ * Public product ID. When supplied, used as the path segment and `ticker` is ignored.
77
+ */
65
78
  productId?: number;
79
+ } | {
80
+ ticker?: string; /** Public product ID used as the path segment. */
81
+ productId: number;
82
+ };
83
+ /**
84
+ * Params for `NuanzeClient.getMarketByTicker`. Requires {@link NuanzeMarketSelector}.
85
+ */
86
+ type GetNuanzeMarketByTickerParams = NuanzeMarketSelector & {
87
+ /** Restrict to one venue. Omit to use the asset's primary venue. */venue?: NuanzeMarketVenue;
66
88
  /**
67
89
  * When true and `venue` is omitted, reject a multi-venue canonical ticker with
68
90
  * `AMBIGUOUS_MARKET`. Default false.
69
91
  */
70
- strictVenue?: boolean;
71
- /** Max published stories to include, 1-30, default 12. */
92
+ strictVenue?: boolean; /** Max published stories to include, 1-30, default 12. */
72
93
  newsLimit?: number;
73
- }
94
+ };
74
95
  /**
75
96
  * Response of `NuanzeClient.getMarketByTicker`.
76
97
  */
@@ -297,29 +318,20 @@ interface GetNuanzeWalletPositionsResponse {
297
318
  asOf: string;
298
319
  }
299
320
  /**
300
- * Params for `NuanzeClient.getMarketTrades`.
321
+ * Params for `NuanzeClient.getMarketTrades`. Requires {@link NuanzeMarketSelector}.
301
322
  */
302
- interface GetNuanzeMarketTradesParams {
303
- /** Case-insensitive canonical ticker or accepted legacy source symbol. */
304
- ticker: string;
305
- /** Restrict to one venue. Omit to use the asset's primary venue. */
306
- venue?: NuanzeMarketVenue;
307
- /** Pin an exact product; must match ticker and venue. */
308
- productId?: number;
323
+ type GetNuanzeMarketTradesParams = NuanzeMarketSelector & {
324
+ /** Restrict to one venue. Omit to use the asset's primary venue. */venue?: NuanzeMarketVenue;
309
325
  /**
310
326
  * When true and `venue` is omitted, reject a multi-venue canonical ticker with
311
327
  * `AMBIGUOUS_MARKET`. Default false.
312
328
  */
313
- strictVenue?: boolean;
314
- /** Page size, 1-200, default 50. */
315
- limit?: number;
316
- /** Inclusive start as a UTC ISO 8601 string. */
317
- from?: string;
318
- /** Exclusive end as a UTC ISO 8601 string. */
319
- to?: string;
320
- /** Opaque exclusive cursor bound to the normalized filters. */
329
+ strictVenue?: boolean; /** Page size, 1-200, default 50. */
330
+ limit?: number; /** Inclusive start as a UTC ISO 8601 string. */
331
+ from?: string; /** Exclusive end as a UTC ISO 8601 string. */
332
+ to?: string; /** Opaque exclusive cursor bound to the normalized filters. */
321
333
  cursor?: string;
322
- }
334
+ };
323
335
  /**
324
336
  * Response of `NuanzeClient.getMarketTrades`.
325
337
  */
@@ -340,29 +352,20 @@ interface GetNuanzeMarketTradesResponse {
340
352
  asOf: string;
341
353
  }
342
354
  /**
343
- * Params for `NuanzeClient.getMarketCandles`.
355
+ * Params for `NuanzeClient.getMarketCandles`. Requires {@link NuanzeMarketSelector}.
344
356
  */
345
- interface GetNuanzeMarketCandlesParams {
346
- /** Case-insensitive canonical ticker or accepted legacy source symbol. */
347
- ticker: string;
348
- /** Restrict to one venue. Omit to use the asset's primary venue. */
349
- venue?: NuanzeMarketVenue;
350
- /** Pin an exact product; must match ticker and venue. */
351
- productId?: number;
357
+ type GetNuanzeMarketCandlesParams = NuanzeMarketSelector & {
358
+ /** Restrict to one venue. Omit to use the asset's primary venue. */venue?: NuanzeMarketVenue;
352
359
  /**
353
360
  * When true and `venue` is omitted, reject a multi-venue canonical ticker with
354
361
  * `AMBIGUOUS_MARKET`. Default false.
355
362
  */
356
- strictVenue?: boolean;
357
- /** Bar interval, default `1h`. */
358
- interval?: NuanzeCandleInterval;
359
- /** Inclusive start as a UTC ISO 8601 string. */
360
- from?: string;
361
- /** Exclusive end as a UTC ISO 8601 string. */
362
- to?: string;
363
- /** Newest matching bars to return, 1-750, default 200. Returned oldest-to-newest. */
363
+ strictVenue?: boolean; /** Bar interval, default `1h`. */
364
+ interval?: NuanzeCandleInterval; /** Inclusive start as a UTC ISO 8601 string. */
365
+ from?: string; /** Exclusive end as a UTC ISO 8601 string. */
366
+ to?: string; /** Newest matching bars to return, 1-750, default 200. Returned oldest-to-newest. */
364
367
  limit?: number;
365
- }
368
+ };
366
369
  /**
367
370
  * Response of `NuanzeClient.getMarketCandles`.
368
371
  */
@@ -587,51 +590,38 @@ interface GetNuanzeCollateralFlowSeriesResponse {
587
590
  asOf: string;
588
591
  }
589
592
  /**
590
- * Params for `NuanzeClient.getMarketPositioning`. Resolves only an active perpetual.
593
+ * Params for `NuanzeClient.getMarketPositioning`. Requires {@link NuanzeMarketSelector}. Resolves
594
+ * only an active perpetual.
591
595
  */
592
- interface GetNuanzeMarketPositioningParams {
593
- /** Case-insensitive canonical ticker or accepted legacy source symbol. */
594
- ticker: string;
595
- /** If supplied, only `perp` is valid. */
596
- venue?: 'perp';
597
- /** Pin an exact product; must match ticker and venue. */
598
- productId?: number;
596
+ type GetNuanzeMarketPositioningParams = NuanzeMarketSelector & {
597
+ /** If supplied, only `perp` is valid. */venue?: 'perp';
599
598
  /**
600
599
  * When true and `venue` is omitted, reject a multi-venue canonical ticker with
601
600
  * `AMBIGUOUS_MARKET`. Default false.
602
601
  */
603
- strictVenue?: boolean;
604
- /** Cell grouping, default `side`. */
605
- groupBy?: NuanzePositioningGroupBy;
606
- /** Inclusion threshold as a USD string, default `'10'`. */
602
+ strictVenue?: boolean; /** Cell grouping, default `side`. */
603
+ groupBy?: NuanzePositioningGroupBy; /** Inclusion threshold as a USD string, default `'10'`. */
607
604
  minPositionUsd?: NuanzeMinPositionUsd;
608
- }
605
+ };
609
606
  /**
610
607
  * Response of `NuanzeClient.getMarketPositioning`. Discriminated by `groupBy`.
611
608
  */
612
609
  type GetNuanzeMarketPositioningResponse = NuanzeMarketPositioningSideResponse | NuanzeMarketPositioningCohortResponse | NuanzeMarketPositioningNotionalBucketResponse;
613
610
  /**
614
- * Params for `NuanzeClient.getMarketPositions`. Resolves only an active perpetual.
611
+ * Params for `NuanzeClient.getMarketPositions`. Requires {@link NuanzeMarketSelector}. Resolves
612
+ * only an active perpetual.
615
613
  */
616
- interface GetNuanzeMarketPositionsParams {
617
- /** Case-insensitive canonical ticker or accepted legacy source symbol. */
618
- ticker: string;
619
- /** If supplied, only `perp` is valid. */
620
- venue?: 'perp';
621
- /** Pin an exact product; must match ticker and venue. */
622
- productId?: number;
623
- /** Page size, 1-200, default 50. */
614
+ type GetNuanzeMarketPositionsParams = NuanzeMarketSelector & {
615
+ /** If supplied, only `perp` is valid. */venue?: 'perp'; /** Page size, 1-200, default 50. */
624
616
  limit?: number;
625
617
  /**
626
618
  * Primary ordering field, default `notional`. Notional and amount use absolute values; PnL remains
627
619
  * signed.
628
620
  */
629
- sortBy?: NuanzeMarketPositionSortBy;
630
- /** Primary ordering direction, default `desc`. */
631
- sortDirection?: NuanzeMarketPositionSortDirection;
632
- /** Opaque exclusive cursor bound to the resolved product. */
621
+ sortBy?: NuanzeMarketPositionSortBy; /** Primary ordering direction, default `desc`. */
622
+ sortDirection?: NuanzeMarketPositionSortDirection; /** Opaque exclusive cursor bound to the resolved product. */
633
623
  cursor?: string;
634
- }
624
+ };
635
625
  /**
636
626
  * Response of `NuanzeClient.getMarketPositions`.
637
627
  */
@@ -681,5 +671,5 @@ interface GetNuanzeOpenPositionsResponse {
681
671
  asOf: string;
682
672
  }
683
673
  //#endregion
684
- export { GetNuanzePlatformSummaryResponse as A, GetNuanzeWalletSummaryResponse as B, GetNuanzeMarketsParams as C, GetNuanzeOpenPositionsParams as D, GetNuanzeNewsResponse as E, GetNuanzeWalletPnlSeriesParams as F, GetNuanzeWalletTradesResponse as H, GetNuanzeWalletPnlSeriesResponse as I, GetNuanzeWalletPositionsParams as L, GetNuanzeSubaccountLeaderboardResponse as M, GetNuanzeWalletPnlParams as N, GetNuanzeOpenPositionsResponse as O, GetNuanzeWalletPnlResponse as P, GetNuanzeWalletPositionsResponse as R, GetNuanzeMarketTradesResponse as S, GetNuanzeNewsParams as T, GetNuanzeWalletTradesParams as V, GetNuanzeMarketPositioningParams as _, GetNuanzeCollateralFlowsParams as a, GetNuanzeMarketPositionsResponse as b, GetNuanzeFollowedLeaderboardResponse as c, GetNuanzeLeaderboardParams as d, GetNuanzeLeaderboardResponse as f, GetNuanzeMarketCandlesResponse as g, GetNuanzeMarketCandlesParams as h, GetNuanzeCollateralFlowSummaryResponse as i, GetNuanzeSubaccountLeaderboardParams as j, GetNuanzePlatformSummaryParams as k, GetNuanzeFundingRatesParams as l, GetNuanzeMarketByTickerResponse as m, GetNuanzeCollateralFlowSeriesResponse as n, GetNuanzeCollateralFlowsResponse as o, GetNuanzeMarketByTickerParams as p, GetNuanzeCollateralFlowSummaryParams as r, GetNuanzeFollowedLeaderboardParams as s, GetNuanzeCollateralFlowSeriesParams as t, GetNuanzeFundingRatesResponse as u, GetNuanzeMarketPositioningResponse as v, GetNuanzeMarketsResponse as w, GetNuanzeMarketTradesParams as x, GetNuanzeMarketPositionsParams as y, GetNuanzeWalletSummaryParams as z };
685
- //# sourceMappingURL=clientTypes-BPlIXBRh.d.ts.map
674
+ export { GetNuanzePlatformSummaryResponse as A, GetNuanzeWalletSummaryResponse as B, GetNuanzeMarketsParams as C, GetNuanzeOpenPositionsParams as D, GetNuanzeNewsResponse as E, GetNuanzeWalletPnlSeriesParams as F, GetNuanzeWalletTradesResponse as H, GetNuanzeWalletPnlSeriesResponse as I, GetNuanzeWalletPositionsParams as L, GetNuanzeSubaccountLeaderboardResponse as M, GetNuanzeWalletPnlParams as N, GetNuanzeOpenPositionsResponse as O, GetNuanzeWalletPnlResponse as P, GetNuanzeWalletPositionsResponse as R, GetNuanzeMarketTradesResponse as S, GetNuanzeNewsParams as T, NuanzeMarketSelector as U, GetNuanzeWalletTradesParams as V, GetNuanzeMarketPositioningParams as _, GetNuanzeCollateralFlowsParams as a, GetNuanzeMarketPositionsResponse as b, GetNuanzeFollowedLeaderboardResponse as c, GetNuanzeLeaderboardParams as d, GetNuanzeLeaderboardResponse as f, GetNuanzeMarketCandlesResponse as g, GetNuanzeMarketCandlesParams as h, GetNuanzeCollateralFlowSummaryResponse as i, GetNuanzeSubaccountLeaderboardParams as j, GetNuanzePlatformSummaryParams as k, GetNuanzeFundingRatesParams as l, GetNuanzeMarketByTickerResponse as m, GetNuanzeCollateralFlowSeriesResponse as n, GetNuanzeCollateralFlowsResponse as o, GetNuanzeMarketByTickerParams as p, GetNuanzeCollateralFlowSummaryParams as r, GetNuanzeFollowedLeaderboardParams as s, GetNuanzeCollateralFlowSeriesParams as t, GetNuanzeFundingRatesResponse as u, GetNuanzeMarketPositioningResponse as v, GetNuanzeMarketsResponse as w, GetNuanzeMarketTradesParams as x, GetNuanzeMarketPositionsParams as y, GetNuanzeWalletSummaryParams as z };
675
+ //# sourceMappingURL=clientTypes-DXquGZPe.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"clientTypes-DXquGZPe.d.cts","names":[],"sources":["../src/types/src/types/clientTypes.ts"],"mappings":";;;;;;AA8CA;UAAiB,sBAAA;;EAEf,KAAA,GAAQ,iBAAA;EAAR;EAEA,aAAA,GAAgB,yBAAyB;E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AA,GAAS,0BAAA;EAET,aAAA,GAAgB,iCAAA;EAEhB,MAAA;AAAA;;;;UAMe,gCAAA;;EAEf,SAAA;;EAEA,MAAA;;EAEA,MAAA;;EAEA,KAAA,EAAO,iBAAA;;EAEP,SAAA,EAAW,oBAAoB;;EAE/B,UAAA;;EAEA,aAAA;;EAEA,IAAA;AAAA;;;;;UAOe,4BAAA;;EAEf,KAAA;;EAEA,aAAA,GAAgB,+BAA+B;;EAE/C,cAAA;;EAEA,MAAA;AAAA;;;;UAMe,8BAAA;;EAEf,SAAA,EAAW,kBAAkB;;EAE7B,UAAA;;EAEA,aAAA;;EAEA,IAAA;AAAA"}
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- require("./NuanzeClient-BrjXP2Sz.cjs");
2
+ require("./NuanzeClient-D_LPUkvb.cjs");
3
3
  let _nadohq_shared = require("@nadohq/shared");
4
4
  //#region src/dataMappers.ts
5
5
  function mapNuanzeDecimal(value) {
@@ -626,12 +626,14 @@ function mapNuanzeMarketPositioningResponse(server) {
626
626
  };
627
627
  }
628
628
  /**
629
- * Maps fields shared by per-market and globally ranked position legs.
629
+ * Maps a server-side market position leg, including its synced identity.
630
630
  */
631
- function mapNuanzePositionBase(server) {
631
+ function mapNuanzeMarketPosition(server) {
632
632
  return {
633
633
  subaccountOwner: server.subaccountOwner,
634
634
  subaccountName: server.subaccountName,
635
+ username: server.username,
636
+ displayName: server.displayName,
635
637
  symbol: server.symbol,
636
638
  marginKind: server.marginKind,
637
639
  side: server.side,
@@ -639,17 +641,8 @@ function mapNuanzePositionBase(server) {
639
641
  notional: (0, _nadohq_shared.toBigNumber)(server.notional),
640
642
  upnl: (0, _nadohq_shared.toBigNumber)(server.upnl),
641
643
  margin: mapNuanzeDecimal(server.margin),
642
- entryPrice: mapNuanzeDecimal(server.entryPrice)
643
- };
644
- }
645
- /**
646
- * Maps a server-side market position leg, including its synced identity.
647
- */
648
- function mapNuanzeMarketPosition(server) {
649
- return {
650
- ...mapNuanzePositionBase(server),
651
- username: server.username,
652
- displayName: server.displayName
644
+ entryPrice: mapNuanzeDecimal(server.entryPrice),
645
+ leverage: mapNuanzeDecimal(server.leverage)
653
646
  };
654
647
  }
655
648
  /**