@roarkanalytics/sdk 5.2.0 → 5.4.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 (48) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/client.d.mts +6 -0
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +6 -0
  5. package/client.d.ts.map +1 -1
  6. package/client.js +6 -0
  7. package/client.js.map +1 -1
  8. package/client.mjs +6 -0
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/config.d.mts +416 -8
  12. package/resources/config.d.mts.map +1 -1
  13. package/resources/config.d.ts +416 -8
  14. package/resources/config.d.ts.map +1 -1
  15. package/resources/index.d.mts +2 -0
  16. package/resources/index.d.mts.map +1 -1
  17. package/resources/index.d.ts +2 -0
  18. package/resources/index.d.ts.map +1 -1
  19. package/resources/index.js +5 -1
  20. package/resources/index.js.map +1 -1
  21. package/resources/index.mjs +2 -0
  22. package/resources/index.mjs.map +1 -1
  23. package/resources/simulation-group.d.mts +777 -0
  24. package/resources/simulation-group.d.mts.map +1 -0
  25. package/resources/simulation-group.d.ts +777 -0
  26. package/resources/simulation-group.d.ts.map +1 -0
  27. package/resources/simulation-group.js +116 -0
  28. package/resources/simulation-group.js.map +1 -0
  29. package/resources/simulation-group.mjs +112 -0
  30. package/resources/simulation-group.mjs.map +1 -0
  31. package/resources/simulation-run-group.d.mts +890 -0
  32. package/resources/simulation-run-group.d.mts.map +1 -0
  33. package/resources/simulation-run-group.d.ts +890 -0
  34. package/resources/simulation-run-group.d.ts.map +1 -0
  35. package/resources/simulation-run-group.js +91 -0
  36. package/resources/simulation-run-group.js.map +1 -0
  37. package/resources/simulation-run-group.mjs +87 -0
  38. package/resources/simulation-run-group.mjs.map +1 -0
  39. package/src/client.ts +50 -0
  40. package/src/resources/config.ts +759 -31
  41. package/src/resources/index.ts +22 -0
  42. package/src/resources/simulation-group.ts +1105 -0
  43. package/src/resources/simulation-run-group.ts +1489 -0
  44. package/src/version.ts +1 -1
  45. package/version.d.mts +1 -1
  46. package/version.d.ts +1 -1
  47. package/version.js +1 -1
  48. package/version.mjs +1 -1
@@ -0,0 +1,777 @@
1
+ import { APIResource } from "../core/resource.mjs";
2
+ import { APIPromise } from "../core/api-promise.mjs";
3
+ import { RequestOptions } from "../internal/request-options.mjs";
4
+ export declare class SimulationGroup extends APIResource {
5
+ /**
6
+ * Saves a named set of plans to run together, again and again. Nothing runs yet:
7
+ * POST /v1/simulation/group/{groupId}/run starts one run of every plan and groups
8
+ * them into a run group with one combined report.
9
+ *
10
+ * Slack channels need Slack connected to the project. Email is on by default.
11
+ *
12
+ * @example
13
+ * ```ts
14
+ * const simulationGroup = await client.simulationGroup.create(
15
+ * {
16
+ * name: 'Release regression',
17
+ * simulationRunPlanIds: [
18
+ * '3c1d2e4f-5a6b-4c7d-8e9f-0a1b2c3d4e5f',
19
+ * '6d7e8f9a-0b1c-4d2e-9f3a-4b5c6d7e8f9a',
20
+ * ],
21
+ * },
22
+ * );
23
+ * ```
24
+ */
25
+ create(body: SimulationGroupCreateParams, options?: RequestOptions): APIPromise<SimulationGroupCreateResponse>;
26
+ /**
27
+ * Edits a saved simulation group. Omitted fields keep their current value;
28
+ * `notifications`, when sent, replaces the settings as a whole. Run groups it
29
+ * already started keep theirs.
30
+ *
31
+ * A group managed by config as code (`configManaged: true`) returns 409: change it
32
+ * in the config file.
33
+ *
34
+ * @example
35
+ * ```ts
36
+ * const simulationGroup = await client.simulationGroup.update(
37
+ * '2a3b4c5d-6e7f-4a8b-9c0d-1e2f3a4b5c6d',
38
+ * );
39
+ * ```
40
+ */
41
+ update(groupID: string, body?: SimulationGroupUpdateParams | null | undefined, options?: RequestOptions): APIPromise<SimulationGroupUpdateResponse>;
42
+ /**
43
+ * Returns the saved simulation groups in the project, most recently edited first,
44
+ * each with its plans in run order and notification settings.
45
+ *
46
+ * @example
47
+ * ```ts
48
+ * const simulationGroups =
49
+ * await client.simulationGroup.list();
50
+ * ```
51
+ */
52
+ list(query?: SimulationGroupListParams | null | undefined, options?: RequestOptions): APIPromise<SimulationGroupListResponse>;
53
+ /**
54
+ * Deletes a saved simulation group and any schedules that run it. Run groups it
55
+ * already started, and their reports, stay. A group managed by config as code
56
+ * returns 409.
57
+ *
58
+ * @example
59
+ * ```ts
60
+ * const simulationGroup = await client.simulationGroup.delete(
61
+ * '2a3b4c5d-6e7f-4a8b-9c0d-1e2f3a4b5c6d',
62
+ * );
63
+ * ```
64
+ */
65
+ delete(groupID: string, options?: RequestOptions): APIPromise<SimulationGroupDeleteResponse>;
66
+ /**
67
+ * Returns a saved simulation group with its plans in run order and notification
68
+ * settings.
69
+ *
70
+ * @example
71
+ * ```ts
72
+ * const response = await client.simulationGroup.getByID(
73
+ * '2a3b4c5d-6e7f-4a8b-9c0d-1e2f3a4b5c6d',
74
+ * );
75
+ * ```
76
+ */
77
+ getByID(groupID: string, options?: RequestOptions): APIPromise<SimulationGroupGetByIDResponse>;
78
+ /**
79
+ * Starts one run of every plan in the group, exactly as POST
80
+ * /v1/simulation/plan/{planId}/job would for each, and groups the runs into a run
81
+ * group whose combined report is announced through the group's notification
82
+ * settings once it is ready. This places real calls. Config-managed groups can be
83
+ * run here too.
84
+ *
85
+ * Returns the run group. Poll GET /v1/simulation/run-group/{groupId} until
86
+ * `latestReport.status` is READY.
87
+ *
88
+ * If a plan cannot start after others did, the runs that started are still grouped
89
+ * and the 400 names the run group id.
90
+ *
91
+ * @example
92
+ * ```ts
93
+ * const response = await client.simulationGroup.run(
94
+ * '2a3b4c5d-6e7f-4a8b-9c0d-1e2f3a4b5c6d',
95
+ * );
96
+ * ```
97
+ */
98
+ run(groupID: string, options?: RequestOptions): APIPromise<SimulationGroupRunResponse>;
99
+ }
100
+ export interface SimulationGroupCreateResponse {
101
+ /**
102
+ * A saved, repeatable set of plans that run together. Each run starts one run of
103
+ * every plan and groups them into a run group with one combined report.
104
+ */
105
+ data: SimulationGroupCreateResponse.Data;
106
+ }
107
+ export declare namespace SimulationGroupCreateResponse {
108
+ /**
109
+ * A saved, repeatable set of plans that run together. Each run starts one run of
110
+ * every plan and groups them into a run group with one combined report.
111
+ */
112
+ interface Data {
113
+ id: string;
114
+ /**
115
+ * Whether this group is managed by config as code. A managed group can be run
116
+ * here, but PUT and DELETE on it return 409: change it in the config file.
117
+ */
118
+ configManaged: boolean;
119
+ /**
120
+ * ISO 8601
121
+ */
122
+ createdAt: string;
123
+ description: string | null;
124
+ /**
125
+ * ISO 8601. Null when it has never run.
126
+ */
127
+ lastRunAt: string | null;
128
+ /**
129
+ * The most recent run group it started, readable at GET
130
+ * /v1/simulation/run-group/{groupId}. Null when it has never run.
131
+ */
132
+ latestRunGroupId: string | null;
133
+ name: string;
134
+ /**
135
+ * Where each run's group report announces itself once it is ready.
136
+ */
137
+ notifications: Data.Notifications;
138
+ /**
139
+ * The plans in run order. A plan deleted since it was added is left out.
140
+ */
141
+ plans: Array<Data.Plan>;
142
+ /**
143
+ * ISO 8601
144
+ */
145
+ updatedAt: string;
146
+ }
147
+ namespace Data {
148
+ /**
149
+ * Where each run's group report announces itself once it is ready.
150
+ */
151
+ interface Notifications {
152
+ email: Notifications.Email;
153
+ slack: Array<Notifications.Slack>;
154
+ }
155
+ namespace Notifications {
156
+ interface Email {
157
+ enabled: boolean;
158
+ recipients: Array<string>;
159
+ }
160
+ interface Slack {
161
+ channelId: string;
162
+ channelName: string;
163
+ }
164
+ }
165
+ interface Plan {
166
+ /**
167
+ * The plan, readable at GET /v1/simulation/plan/{planId}
168
+ */
169
+ id: string;
170
+ name: string;
171
+ }
172
+ }
173
+ }
174
+ export interface SimulationGroupUpdateResponse {
175
+ /**
176
+ * A saved, repeatable set of plans that run together. Each run starts one run of
177
+ * every plan and groups them into a run group with one combined report.
178
+ */
179
+ data: SimulationGroupUpdateResponse.Data;
180
+ }
181
+ export declare namespace SimulationGroupUpdateResponse {
182
+ /**
183
+ * A saved, repeatable set of plans that run together. Each run starts one run of
184
+ * every plan and groups them into a run group with one combined report.
185
+ */
186
+ interface Data {
187
+ id: string;
188
+ /**
189
+ * Whether this group is managed by config as code. A managed group can be run
190
+ * here, but PUT and DELETE on it return 409: change it in the config file.
191
+ */
192
+ configManaged: boolean;
193
+ /**
194
+ * ISO 8601
195
+ */
196
+ createdAt: string;
197
+ description: string | null;
198
+ /**
199
+ * ISO 8601. Null when it has never run.
200
+ */
201
+ lastRunAt: string | null;
202
+ /**
203
+ * The most recent run group it started, readable at GET
204
+ * /v1/simulation/run-group/{groupId}. Null when it has never run.
205
+ */
206
+ latestRunGroupId: string | null;
207
+ name: string;
208
+ /**
209
+ * Where each run's group report announces itself once it is ready.
210
+ */
211
+ notifications: Data.Notifications;
212
+ /**
213
+ * The plans in run order. A plan deleted since it was added is left out.
214
+ */
215
+ plans: Array<Data.Plan>;
216
+ /**
217
+ * ISO 8601
218
+ */
219
+ updatedAt: string;
220
+ }
221
+ namespace Data {
222
+ /**
223
+ * Where each run's group report announces itself once it is ready.
224
+ */
225
+ interface Notifications {
226
+ email: Notifications.Email;
227
+ slack: Array<Notifications.Slack>;
228
+ }
229
+ namespace Notifications {
230
+ interface Email {
231
+ enabled: boolean;
232
+ recipients: Array<string>;
233
+ }
234
+ interface Slack {
235
+ channelId: string;
236
+ channelName: string;
237
+ }
238
+ }
239
+ interface Plan {
240
+ /**
241
+ * The plan, readable at GET /v1/simulation/plan/{planId}
242
+ */
243
+ id: string;
244
+ name: string;
245
+ }
246
+ }
247
+ }
248
+ export interface SimulationGroupListResponse {
249
+ data: Array<SimulationGroupListResponse.Data>;
250
+ pagination: SimulationGroupListResponse.Pagination;
251
+ }
252
+ export declare namespace SimulationGroupListResponse {
253
+ /**
254
+ * A saved, repeatable set of plans that run together. Each run starts one run of
255
+ * every plan and groups them into a run group with one combined report.
256
+ */
257
+ interface Data {
258
+ id: string;
259
+ /**
260
+ * Whether this group is managed by config as code. A managed group can be run
261
+ * here, but PUT and DELETE on it return 409: change it in the config file.
262
+ */
263
+ configManaged: boolean;
264
+ /**
265
+ * ISO 8601
266
+ */
267
+ createdAt: string;
268
+ description: string | null;
269
+ /**
270
+ * ISO 8601. Null when it has never run.
271
+ */
272
+ lastRunAt: string | null;
273
+ /**
274
+ * The most recent run group it started, readable at GET
275
+ * /v1/simulation/run-group/{groupId}. Null when it has never run.
276
+ */
277
+ latestRunGroupId: string | null;
278
+ name: string;
279
+ /**
280
+ * Where each run's group report announces itself once it is ready.
281
+ */
282
+ notifications: Data.Notifications;
283
+ /**
284
+ * The plans in run order. A plan deleted since it was added is left out.
285
+ */
286
+ plans: Array<Data.Plan>;
287
+ /**
288
+ * ISO 8601
289
+ */
290
+ updatedAt: string;
291
+ }
292
+ namespace Data {
293
+ /**
294
+ * Where each run's group report announces itself once it is ready.
295
+ */
296
+ interface Notifications {
297
+ email: Notifications.Email;
298
+ slack: Array<Notifications.Slack>;
299
+ }
300
+ namespace Notifications {
301
+ interface Email {
302
+ enabled: boolean;
303
+ recipients: Array<string>;
304
+ }
305
+ interface Slack {
306
+ channelId: string;
307
+ channelName: string;
308
+ }
309
+ }
310
+ interface Plan {
311
+ /**
312
+ * The plan, readable at GET /v1/simulation/plan/{planId}
313
+ */
314
+ id: string;
315
+ name: string;
316
+ }
317
+ }
318
+ interface Pagination {
319
+ hasMore: boolean;
320
+ limit: number;
321
+ offset: number;
322
+ /**
323
+ * Total groups in the project, ignoring this page.
324
+ */
325
+ total: number;
326
+ }
327
+ }
328
+ export interface SimulationGroupDeleteResponse {
329
+ data: SimulationGroupDeleteResponse.Data;
330
+ }
331
+ export declare namespace SimulationGroupDeleteResponse {
332
+ interface Data {
333
+ /**
334
+ * Whether the group was deleted
335
+ */
336
+ deleted: boolean;
337
+ }
338
+ }
339
+ export interface SimulationGroupGetByIDResponse {
340
+ /**
341
+ * A saved, repeatable set of plans that run together. Each run starts one run of
342
+ * every plan and groups them into a run group with one combined report.
343
+ */
344
+ data: SimulationGroupGetByIDResponse.Data;
345
+ }
346
+ export declare namespace SimulationGroupGetByIDResponse {
347
+ /**
348
+ * A saved, repeatable set of plans that run together. Each run starts one run of
349
+ * every plan and groups them into a run group with one combined report.
350
+ */
351
+ interface Data {
352
+ id: string;
353
+ /**
354
+ * Whether this group is managed by config as code. A managed group can be run
355
+ * here, but PUT and DELETE on it return 409: change it in the config file.
356
+ */
357
+ configManaged: boolean;
358
+ /**
359
+ * ISO 8601
360
+ */
361
+ createdAt: string;
362
+ description: string | null;
363
+ /**
364
+ * ISO 8601. Null when it has never run.
365
+ */
366
+ lastRunAt: string | null;
367
+ /**
368
+ * The most recent run group it started, readable at GET
369
+ * /v1/simulation/run-group/{groupId}. Null when it has never run.
370
+ */
371
+ latestRunGroupId: string | null;
372
+ name: string;
373
+ /**
374
+ * Where each run's group report announces itself once it is ready.
375
+ */
376
+ notifications: Data.Notifications;
377
+ /**
378
+ * The plans in run order. A plan deleted since it was added is left out.
379
+ */
380
+ plans: Array<Data.Plan>;
381
+ /**
382
+ * ISO 8601
383
+ */
384
+ updatedAt: string;
385
+ }
386
+ namespace Data {
387
+ /**
388
+ * Where each run's group report announces itself once it is ready.
389
+ */
390
+ interface Notifications {
391
+ email: Notifications.Email;
392
+ slack: Array<Notifications.Slack>;
393
+ }
394
+ namespace Notifications {
395
+ interface Email {
396
+ enabled: boolean;
397
+ recipients: Array<string>;
398
+ }
399
+ interface Slack {
400
+ channelId: string;
401
+ channelName: string;
402
+ }
403
+ }
404
+ interface Plan {
405
+ /**
406
+ * The plan, readable at GET /v1/simulation/plan/{planId}
407
+ */
408
+ id: string;
409
+ name: string;
410
+ }
411
+ }
412
+ }
413
+ export interface SimulationGroupRunResponse {
414
+ /**
415
+ * Several simulation runs read as one.
416
+ */
417
+ data: SimulationGroupRunResponse.Data;
418
+ }
419
+ export declare namespace SimulationGroupRunResponse {
420
+ /**
421
+ * Several simulation runs read as one.
422
+ */
423
+ interface Data {
424
+ id: string;
425
+ /**
426
+ * ISO 8601
427
+ */
428
+ createdAt: string;
429
+ /**
430
+ * One generation of the group report.
431
+ */
432
+ latestReport: Data.LatestReport | null;
433
+ name: string;
434
+ runCount: number;
435
+ runs: Array<Data.Run>;
436
+ }
437
+ namespace Data {
438
+ /**
439
+ * One generation of the group report.
440
+ */
441
+ interface LatestReport {
442
+ id: string;
443
+ /**
444
+ * ISO 8601. Null until the report settles.
445
+ */
446
+ completedAt: string | null;
447
+ /**
448
+ * ISO 8601
449
+ */
450
+ createdAt: string;
451
+ /**
452
+ * The group report: the runs it covers, a scorecard summed across them, what went
453
+ * well, and the issues found, each merged from the per-run debriefs with
454
+ * call-level evidence. Every figure is computed from the runs; the prose is
455
+ * AI-written around those facts.
456
+ */
457
+ document: LatestReport.Document | null;
458
+ errorMessage: string | null;
459
+ /**
460
+ * PENDING and GENERATING are in flight; READY carries the document; FAILED carries
461
+ * errorMessage.
462
+ */
463
+ status: 'PENDING' | 'GENERATING' | 'READY' | 'FAILED';
464
+ }
465
+ namespace LatestReport {
466
+ /**
467
+ * The group report: the runs it covers, a scorecard summed across them, what went
468
+ * well, and the issues found, each merged from the per-run debriefs with
469
+ * call-level evidence. Every figure is computed from the runs; the prose is
470
+ * AI-written around those facts.
471
+ */
472
+ interface Document {
473
+ aggregates: Array<Document.Aggregate>;
474
+ executiveSummary: Array<Document.ExecutiveSummary>;
475
+ generatedAtIso: string;
476
+ headline: Document.Headline;
477
+ issues: Array<Document.Issue>;
478
+ methodology: string;
479
+ model: string;
480
+ recommendations: Array<Document.Recommendation>;
481
+ runs: Array<Document.Run>;
482
+ scorecard: Array<Document.Scorecard>;
483
+ simulationRunGroupId: string;
484
+ smallerItems: Array<Document.SmallerItem>;
485
+ version: 1;
486
+ wentWell: Array<Document.WentWell>;
487
+ }
488
+ namespace Document {
489
+ interface Aggregate {
490
+ averageLabel: string | null;
491
+ evaluatedCount: number;
492
+ medianLabel: string | null;
493
+ metricName: string;
494
+ p95Label: string | null;
495
+ }
496
+ interface ExecutiveSummary {
497
+ body: string;
498
+ heading: string;
499
+ }
500
+ interface Headline {
501
+ callCount: number;
502
+ completedAtIso: string | null;
503
+ groupName: string;
504
+ passedRunCount: number;
505
+ reportedRunCount: number;
506
+ runCount: number;
507
+ statTiles: Array<Headline.StatTile>;
508
+ verdict: 'PASSED' | 'THRESHOLD_FAILED';
509
+ verdictProse: string;
510
+ }
511
+ namespace Headline {
512
+ interface StatTile {
513
+ deltaDirection: 'POSITIVE' | 'NEGATIVE' | 'NEUTRAL' | null;
514
+ label: string;
515
+ sub: string | null;
516
+ value: string;
517
+ }
518
+ }
519
+ interface Issue {
520
+ affectedCallCount: number;
521
+ body: string;
522
+ calls: Array<Issue.Call>;
523
+ checkNames: Array<string>;
524
+ evidence: Array<Issue.Evidence>;
525
+ order: number;
526
+ rootCauseChannel: 'PROMPT' | 'VOICE_CONFIG' | 'STT' | 'SPEECH_MODEL' | 'LLM_MODEL' | 'INFRA' | 'EXTERNAL' | null;
527
+ runLabels: Array<string>;
528
+ severity: 'HIGH' | 'MEDIUM' | 'LOW';
529
+ sourceThemes: Array<Issue.SourceTheme>;
530
+ title: string;
531
+ }
532
+ namespace Issue {
533
+ interface Call {
534
+ callId: string | null;
535
+ conversationId: string;
536
+ cueMs: number | null;
537
+ personaName: string | null;
538
+ simulationRunPlanJobId: string;
539
+ }
540
+ interface Evidence {
541
+ callId: string | null;
542
+ conversationId: string;
543
+ cueMs: number | null;
544
+ personaName: string | null;
545
+ simulationRunPlanJobId: string;
546
+ text: string;
547
+ }
548
+ interface SourceTheme {
549
+ simulationRunPlanJobId: string;
550
+ slug: string;
551
+ }
552
+ }
553
+ interface Recommendation {
554
+ body: string;
555
+ channel: 'PROMPT' | 'VOICE_CONFIG' | 'STT' | 'SPEECH_MODEL' | 'LLM_MODEL' | 'INFRA' | 'EXTERNAL' | null;
556
+ issueOrders: Array<number>;
557
+ order: number;
558
+ title: string;
559
+ }
560
+ interface Run {
561
+ callCount: number;
562
+ checksPassed: number;
563
+ checksTotal: number;
564
+ completedAtIso: string | null;
565
+ runLabel: string;
566
+ runNumber: number | null;
567
+ simulationRunPlanJobId: string;
568
+ status: 'PENDING' | 'QUEUED' | 'CREATING_SNAPSHOTS' | 'CREATING_SIMULATIONS' | 'PREPARING_CAPACITY' | 'RUNNING_SIMULATIONS' | 'COMPLETED' | 'FAILED' | 'TIMED_OUT' | 'CANCELLED' | 'CANCELLING' | 'ENDING_SIMULATIONS';
569
+ summary: string | null;
570
+ themeCount: number;
571
+ verdict: 'PASSED' | 'THRESHOLD_FAILED' | null;
572
+ }
573
+ interface Scorecard {
574
+ checkName: string;
575
+ evaluatedCount: number;
576
+ failedCount: number;
577
+ failedRunCount: number;
578
+ passRatePct: number | null;
579
+ runCount: number;
580
+ }
581
+ interface SmallerItem {
582
+ affectedCallCount: number;
583
+ body: string;
584
+ calls: Array<SmallerItem.Call>;
585
+ checkNames: Array<string>;
586
+ evidence: Array<SmallerItem.Evidence>;
587
+ order: number;
588
+ rootCauseChannel: 'PROMPT' | 'VOICE_CONFIG' | 'STT' | 'SPEECH_MODEL' | 'LLM_MODEL' | 'INFRA' | 'EXTERNAL' | null;
589
+ runLabels: Array<string>;
590
+ severity: 'HIGH' | 'MEDIUM' | 'LOW';
591
+ sourceThemes: Array<SmallerItem.SourceTheme>;
592
+ title: string;
593
+ }
594
+ namespace SmallerItem {
595
+ interface Call {
596
+ callId: string | null;
597
+ conversationId: string;
598
+ cueMs: number | null;
599
+ personaName: string | null;
600
+ simulationRunPlanJobId: string;
601
+ }
602
+ interface Evidence {
603
+ callId: string | null;
604
+ conversationId: string;
605
+ cueMs: number | null;
606
+ personaName: string | null;
607
+ simulationRunPlanJobId: string;
608
+ text: string;
609
+ }
610
+ interface SourceTheme {
611
+ simulationRunPlanJobId: string;
612
+ slug: string;
613
+ }
614
+ }
615
+ interface WentWell {
616
+ body: string;
617
+ evidence: Array<WentWell.Evidence>;
618
+ title: string;
619
+ }
620
+ namespace WentWell {
621
+ interface Evidence {
622
+ callId: string | null;
623
+ conversationId: string;
624
+ cueMs: number | null;
625
+ personaName: string | null;
626
+ simulationRunPlanJobId: string;
627
+ text: string;
628
+ }
629
+ }
630
+ }
631
+ }
632
+ /**
633
+ * One run in the group, in group order.
634
+ */
635
+ interface Run {
636
+ /**
637
+ * ISO 8601
638
+ */
639
+ createdAt: string;
640
+ endedAt: string | null;
641
+ /**
642
+ * The name of the plan the run ran. Null when the plan was deleted.
643
+ */
644
+ planName: string | null;
645
+ /**
646
+ * Per-project run number, shown as SR-42 in the app.
647
+ */
648
+ runNumber: number | null;
649
+ simulationRunPlanId: string;
650
+ /**
651
+ * The run, readable at GET /v1/simulation/plan/job/{jobId}
652
+ */
653
+ simulationRunPlanJobId: string;
654
+ startedAt: string | null;
655
+ status: 'PENDING' | 'QUEUED' | 'CREATING_SNAPSHOTS' | 'CREATING_SIMULATIONS' | 'PREPARING_CAPACITY' | 'RUNNING_SIMULATIONS' | 'COMPLETED' | 'FAILED' | 'TIMED_OUT' | 'CANCELLED' | 'CANCELLING' | 'ENDING_SIMULATIONS';
656
+ }
657
+ }
658
+ }
659
+ export interface SimulationGroupCreateParams {
660
+ /**
661
+ * What to call the group.
662
+ */
663
+ name: string;
664
+ /**
665
+ * The plans to run together, in run order (2 to 20). Duplicates are dropped.
666
+ */
667
+ simulationRunPlanIds: Array<string>;
668
+ /**
669
+ * What the group is for.
670
+ */
671
+ description?: string | null;
672
+ /**
673
+ * Defaults to email on (to the default audience) and no Slack.
674
+ */
675
+ notifications?: SimulationGroupCreateParams.Notifications;
676
+ }
677
+ export declare namespace SimulationGroupCreateParams {
678
+ /**
679
+ * Defaults to email on (to the default audience) and no Slack.
680
+ */
681
+ interface Notifications {
682
+ email?: Notifications.Email;
683
+ /**
684
+ * Channels in the project's connected Slack workspace to post the report to (at
685
+ * most 10). Slack must be connected to the project first.
686
+ */
687
+ slack?: Array<Notifications.Slack>;
688
+ }
689
+ namespace Notifications {
690
+ interface Email {
691
+ /**
692
+ * Whether the group report of each run is emailed when it is ready.
693
+ */
694
+ enabled: boolean;
695
+ /**
696
+ * Addresses to email (at most 50), Roark users or not: the email attaches the
697
+ * report PDF. Empty emails every member of the project.
698
+ */
699
+ recipients?: Array<string>;
700
+ }
701
+ interface Slack {
702
+ /**
703
+ * The Slack channel id
704
+ */
705
+ channelId: string;
706
+ /**
707
+ * The channel name, shown in Roark
708
+ */
709
+ channelName: string;
710
+ }
711
+ }
712
+ }
713
+ export interface SimulationGroupUpdateParams {
714
+ /**
715
+ * Send null to clear it.
716
+ */
717
+ description?: string | null;
718
+ name?: string;
719
+ /**
720
+ * Replaces the notification settings as a whole.
721
+ */
722
+ notifications?: SimulationGroupUpdateParams.Notifications;
723
+ /**
724
+ * Replaces the plans, in run order.
725
+ */
726
+ simulationRunPlanIds?: Array<string>;
727
+ }
728
+ export declare namespace SimulationGroupUpdateParams {
729
+ /**
730
+ * Replaces the notification settings as a whole.
731
+ */
732
+ interface Notifications {
733
+ email?: Notifications.Email;
734
+ /**
735
+ * Channels in the project's connected Slack workspace to post the report to (at
736
+ * most 10). Slack must be connected to the project first.
737
+ */
738
+ slack?: Array<Notifications.Slack>;
739
+ }
740
+ namespace Notifications {
741
+ interface Email {
742
+ /**
743
+ * Whether the group report of each run is emailed when it is ready.
744
+ */
745
+ enabled: boolean;
746
+ /**
747
+ * Addresses to email (at most 50), Roark users or not: the email attaches the
748
+ * report PDF. Empty emails every member of the project.
749
+ */
750
+ recipients?: Array<string>;
751
+ }
752
+ interface Slack {
753
+ /**
754
+ * The Slack channel id
755
+ */
756
+ channelId: string;
757
+ /**
758
+ * The channel name, shown in Roark
759
+ */
760
+ channelName: string;
761
+ }
762
+ }
763
+ }
764
+ export interface SimulationGroupListParams {
765
+ /**
766
+ * Maximum number of groups to return (default: 20, max: 100)
767
+ */
768
+ limit?: number;
769
+ /**
770
+ * Pagination offset
771
+ */
772
+ offset?: number;
773
+ }
774
+ export declare namespace SimulationGroup {
775
+ export { type SimulationGroupCreateResponse as SimulationGroupCreateResponse, type SimulationGroupUpdateResponse as SimulationGroupUpdateResponse, type SimulationGroupListResponse as SimulationGroupListResponse, type SimulationGroupDeleteResponse as SimulationGroupDeleteResponse, type SimulationGroupGetByIDResponse as SimulationGroupGetByIDResponse, type SimulationGroupRunResponse as SimulationGroupRunResponse, type SimulationGroupCreateParams as SimulationGroupCreateParams, type SimulationGroupUpdateParams as SimulationGroupUpdateParams, type SimulationGroupListParams as SimulationGroupListParams, };
776
+ }
777
+ //# sourceMappingURL=simulation-group.d.mts.map