@roarkanalytics/sdk 5.5.0 → 5.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.
@@ -8,20 +8,19 @@ import { path } from '../internal/utils/path';
8
8
  export class MetricCollectionJob extends APIResource {
9
9
  /**
10
10
  * Creates a metric collection job for the specified calls or chats and metrics,
11
- * then triggers processing. Provide exactly one of callIds or chatIds.
11
+ * then triggers processing. Provide exactly one of callIds or chatIds. Pass
12
+ * policyId to score with a metric policy’s settings (for example to re-score past
13
+ * calls after changing which properties Property Verification checks); metrics
14
+ * then defaults to every metric that policy collects.
12
15
  *
13
16
  * @example
14
17
  * ```ts
15
18
  * const metricCollectionJob =
16
- * await client.metricCollectionJob.create({
17
- * metrics: [
18
- * { id: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e' },
19
- * ],
20
- * });
19
+ * await client.metricCollectionJob.create();
21
20
  * ```
22
21
  */
23
22
  create(
24
- body: MetricCollectionJobCreateParams,
23
+ body: MetricCollectionJobCreateParams | null | undefined = {},
25
24
  options?: RequestOptions,
26
25
  ): APIPromise<MetricCollectionJobCreateResponse> {
27
26
  return this._client.post('/v1/metric/collection-jobs', { body, ...options });
@@ -300,11 +299,6 @@ export namespace MetricCollectionJobGetByIDResponse {
300
299
  }
301
300
 
302
301
  export interface MetricCollectionJobCreateParams {
303
- /**
304
- * Metric definitions to collect. Max 20 per request.
305
- */
306
- metrics: Array<MetricCollectionJobCreateParams.Metric>;
307
-
308
302
  /**
309
303
  * Call IDs to collect metrics for. Mutually exclusive with chatIds. Max 500 per
310
304
  * request.
@@ -316,6 +310,23 @@ export interface MetricCollectionJobCreateParams {
316
310
  * request.
317
311
  */
318
312
  chatIds?: Array<string>;
313
+
314
+ /**
315
+ * Metric definitions to collect. Max 20 per request. Required unless policyId is
316
+ * given; with policyId, defaults to every metric that policy collects, and each
317
+ * one listed must be in it.
318
+ */
319
+ metrics?: Array<MetricCollectionJobCreateParams.Metric>;
320
+
321
+ /**
322
+ * Optional. A metric policy (collector) whose settings to score with: each metric
323
+ * runs at the version that policy runs it at, with its per-collector setting (such
324
+ * as the properties Property Verification checks), instead of the metric's
325
+ * default. A metric the policy runs at its default runs at its default here too.
326
+ * The policy's conditions are not applied: the listed conversations are scored as
327
+ * given. Use it to re-score past conversations after changing a policy's settings.
328
+ */
329
+ policyId?: string;
319
330
  }
320
331
 
321
332
  export namespace MetricCollectionJobCreateParams {
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '5.5.0'; // x-release-please-version
1
+ export const VERSION = '5.7.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "5.5.0";
1
+ export declare const VERSION = "5.7.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "5.5.0";
1
+ export declare const VERSION = "5.7.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '5.5.0'; // x-release-please-version
4
+ exports.VERSION = '5.7.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '5.5.0'; // x-release-please-version
1
+ export const VERSION = '5.7.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map