@agg-build/sdk 4.6.0 → 4.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -4371,6 +4371,13 @@ declare class AggClient {
4371
4371
  /** Get a single venue event by ID. Requires appId or admin auth. */
4372
4372
  getVenueEventById(id: string, options?: {
4373
4373
  signal?: AbortSignal;
4374
+ /**
4375
+ * Scope `marketCount` and the rolled-up `volume` to the whole matched
4376
+ * cluster (default, `true`) or to this one venue event (`false`). Pair it
4377
+ * with the same value on {@link getVenueMarkets} so the count matches the
4378
+ * market list you render.
4379
+ */
4380
+ cluster?: boolean;
4374
4381
  }): Promise<VenueEvent>;
4375
4382
  /** Get normalized live score state for sports events. Requires appId or admin auth. */
4376
4383
  getSportsLive(eventIds: string[], options?: {
@@ -4386,6 +4393,13 @@ declare class AggClient {
4386
4393
  getVenueMarkets(options?: {
4387
4394
  venue?: Venue;
4388
4395
  venueEventId?: string;
4396
+ /**
4397
+ * Scope `venueEventId` to the whole matched cluster (default, `true`) or to
4398
+ * that one venue event (`false`). Under the default, naming any member of a
4399
+ * cluster returns every venue's markets for that real-world event with
4400
+ * matched siblings folded into their anchor. Ignored without `venueEventId`.
4401
+ */
4402
+ cluster?: boolean;
4389
4403
  search?: string;
4390
4404
  matchStatus?: MatchStatus;
4391
4405
  status?: MarketStatus;
package/dist/index.d.ts CHANGED
@@ -4371,6 +4371,13 @@ declare class AggClient {
4371
4371
  /** Get a single venue event by ID. Requires appId or admin auth. */
4372
4372
  getVenueEventById(id: string, options?: {
4373
4373
  signal?: AbortSignal;
4374
+ /**
4375
+ * Scope `marketCount` and the rolled-up `volume` to the whole matched
4376
+ * cluster (default, `true`) or to this one venue event (`false`). Pair it
4377
+ * with the same value on {@link getVenueMarkets} so the count matches the
4378
+ * market list you render.
4379
+ */
4380
+ cluster?: boolean;
4374
4381
  }): Promise<VenueEvent>;
4375
4382
  /** Get normalized live score state for sports events. Requires appId or admin auth. */
4376
4383
  getSportsLive(eventIds: string[], options?: {
@@ -4386,6 +4393,13 @@ declare class AggClient {
4386
4393
  getVenueMarkets(options?: {
4387
4394
  venue?: Venue;
4388
4395
  venueEventId?: string;
4396
+ /**
4397
+ * Scope `venueEventId` to the whole matched cluster (default, `true`) or to
4398
+ * that one venue event (`false`). Under the default, naming any member of a
4399
+ * cluster returns every venue's markets for that real-world event with
4400
+ * matched siblings folded into their anchor. Ignored without `venueEventId`.
4401
+ */
4402
+ cluster?: boolean;
4389
4403
  search?: string;
4390
4404
  matchStatus?: MatchStatus;
4391
4405
  status?: MarketStatus;
package/dist/index.js CHANGED
@@ -2719,7 +2719,7 @@ Issued At: ${issuedAt}`;
2719
2719
  // Opt into the lean response (no embedded `venueMarkets`) — markets are
2720
2720
  // fetched separately via GET /venue-markets. Empty `expand` (no `markets`
2721
2721
  // token) tells the API to omit the deprecated embedded array.
2722
- query: { expand: "" },
2722
+ query: __spreadValues({ expand: "" }, (options == null ? void 0 : options.cluster) === false ? { cluster: "false" } : {}),
2723
2723
  signal: options == null ? void 0 : options.signal
2724
2724
  });
2725
2725
  });
@@ -2847,6 +2847,7 @@ Issued At: ${issuedAt}`;
2847
2847
  const query = {};
2848
2848
  if (options == null ? void 0 : options.venue) query.venue = options.venue;
2849
2849
  if (options == null ? void 0 : options.venueEventId) query.venueEventId = options.venueEventId;
2850
+ if ((options == null ? void 0 : options.cluster) === false) query.cluster = "false";
2850
2851
  if ((_a = options == null ? void 0 : options.search) == null ? void 0 : _a.trim()) query.search = options.search.trim();
2851
2852
  if (options == null ? void 0 : options.matchStatus) query.matchStatus = options.matchStatus;
2852
2853
  if (options == null ? void 0 : options.status) query.status = options.status;
package/dist/index.mjs CHANGED
@@ -2588,7 +2588,7 @@ Issued At: ${issuedAt}`;
2588
2588
  // Opt into the lean response (no embedded `venueMarkets`) — markets are
2589
2589
  // fetched separately via GET /venue-markets. Empty `expand` (no `markets`
2590
2590
  // token) tells the API to omit the deprecated embedded array.
2591
- query: { expand: "" },
2591
+ query: __spreadValues({ expand: "" }, (options == null ? void 0 : options.cluster) === false ? { cluster: "false" } : {}),
2592
2592
  signal: options == null ? void 0 : options.signal
2593
2593
  });
2594
2594
  });
@@ -2716,6 +2716,7 @@ Issued At: ${issuedAt}`;
2716
2716
  const query = {};
2717
2717
  if (options == null ? void 0 : options.venue) query.venue = options.venue;
2718
2718
  if (options == null ? void 0 : options.venueEventId) query.venueEventId = options.venueEventId;
2719
+ if ((options == null ? void 0 : options.cluster) === false) query.cluster = "false";
2719
2720
  if ((_a = options == null ? void 0 : options.search) == null ? void 0 : _a.trim()) query.search = options.search.trim();
2720
2721
  if (options == null ? void 0 : options.matchStatus) query.matchStatus = options.matchStatus;
2721
2722
  if (options == null ? void 0 : options.status) query.status = options.status;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agg-build/sdk",
3
- "version": "4.6.0",
3
+ "version": "4.7.0",
4
4
  "description": "Vanilla TypeScript client for the AGG prediction market aggregator (auth, markets, orderbooks, charts, trading, managed execution, WebSockets). Works in browsers, Node.js, and React Native.",
5
5
  "sideEffects": false,
6
6
  "license": "MIT",