@converge.ai/a13n 0.0.90 → 0.0.95
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/README.md +87 -61
- package/THIRD_PARTY_NOTICES.txt +83 -0
- package/dist/client.d.ts +1 -1
- package/dist/client.js +2 -2
- package/dist/client.js.map +1 -1
- package/dist/dispatch.d.ts +6 -0
- package/dist/dispatch.d.ts.map +1 -0
- package/dist/dispatch.js +19 -0
- package/dist/dispatch.js.map +1 -0
- package/dist/errors.d.ts +23 -1
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +38 -5
- package/dist/errors.js.map +1 -1
- package/dist/index.d.ts +7 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/resources/base.d.ts.map +1 -1
- package/dist/resources/base.js +5 -2
- package/dist/resources/base.js.map +1 -1
- package/dist/resources/generated.d.ts +3441 -1180
- package/dist/resources/generated.d.ts.map +1 -1
- package/dist/resources/generated.js +2188 -461
- package/dist/resources/generated.js.map +1 -1
- package/dist/resources/interaction.d.ts +1 -7
- package/dist/resources/interaction.d.ts.map +1 -1
- package/dist/resources/interaction.js +2 -30
- package/dist/resources/interaction.js.map +1 -1
- package/dist/schema.d.ts +14939 -6070
- package/dist/schema.d.ts.map +1 -1
- package/dist/semantic.d.ts +102 -117
- package/dist/semantic.d.ts.map +1 -1
- package/dist/semantic.js +461 -168
- package/dist/semantic.js.map +1 -1
- package/dist/session-stream-schema.d.ts +1773 -0
- package/dist/session-stream-schema.d.ts.map +1 -0
- package/dist/session-stream-schema.js +2 -0
- package/dist/session-stream-schema.js.map +1 -0
- package/dist/session-stream-validation.d.ts +128 -0
- package/dist/session-stream-validation.d.ts.map +1 -0
- package/dist/session-stream-validation.js +29384 -0
- package/dist/session-stream-validation.js.map +1 -0
- package/dist/streams/session-stream.d.ts +12 -0
- package/dist/streams/session-stream.d.ts.map +1 -0
- package/dist/streams/session-stream.js +36 -0
- package/dist/streams/session-stream.js.map +1 -0
- package/dist/streams/sse.d.ts +5 -1
- package/dist/streams/sse.d.ts.map +1 -1
- package/dist/streams/sse.js +11 -4
- package/dist/streams/sse.js.map +1 -1
- package/dist/streams/thread-stream.d.ts +21 -2
- package/dist/streams/thread-stream.d.ts.map +1 -1
- package/dist/streams/thread-stream.js +34 -4
- package/dist/streams/thread-stream.js.map +1 -1
- package/dist/transport.d.ts.map +1 -1
- package/dist/transport.js +3 -0
- package/dist/transport.js.map +1 -1
- package/dist/workflow.d.ts +117 -0
- package/dist/workflow.d.ts.map +1 -0
- package/dist/workflow.js +90 -0
- package/dist/workflow.js.map +1 -0
- package/dist/workspace-scope.d.ts.map +1 -1
- package/dist/workspace-scope.js +125 -0
- package/dist/workspace-scope.js.map +1 -1
- package/openapi.json +34024 -10870
- package/package.json +5 -1
|
@@ -19,12 +19,24 @@ export class ServiceResources {
|
|
|
19
19
|
get auth() {
|
|
20
20
|
return new AuthResource(this.transport, "/api/v1/auth");
|
|
21
21
|
}
|
|
22
|
+
get builtinSkills() {
|
|
23
|
+
return new BuiltinSkillsResource(this.transport, "/api/v1/builtin-skills");
|
|
24
|
+
}
|
|
22
25
|
get connections() {
|
|
23
26
|
return new ConnectionsResource(this.transport, "/api/v1/connections");
|
|
24
27
|
}
|
|
25
28
|
get connectorProviders() {
|
|
26
29
|
return new ConnectorProvidersResource(this.transport, "/api/v1/connector-providers");
|
|
27
30
|
}
|
|
31
|
+
get desktopAssistance() {
|
|
32
|
+
return new DesktopAssistanceResource(this.transport, "/api/v1/desktop-assistance");
|
|
33
|
+
}
|
|
34
|
+
get devices() {
|
|
35
|
+
return new DevicesResource(this.transport, "/api/v1/devices");
|
|
36
|
+
}
|
|
37
|
+
get environmentProviderOptions() {
|
|
38
|
+
return new EnvironmentProviderOptionsResource(this.transport, "/api/v1/environment-provider-options");
|
|
39
|
+
}
|
|
28
40
|
get environmentProviders() {
|
|
29
41
|
return new EnvironmentProvidersResource(this.transport, "/api/v1/environment-providers");
|
|
30
42
|
}
|
|
@@ -34,6 +46,18 @@ export class ServiceResources {
|
|
|
34
46
|
get environments() {
|
|
35
47
|
return new EnvironmentsResource(this.transport, "/api/v1/environments");
|
|
36
48
|
}
|
|
49
|
+
/** POST /api/v1/finding-agent. Preserves response metadata; mutations are not replayed. */
|
|
50
|
+
findingAgent(options = {}) {
|
|
51
|
+
return jsonRequest(this.transport, "POST", "/api/v1/finding-agent", undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
52
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
53
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
54
|
+
}
|
|
55
|
+
get findingAnalyses() {
|
|
56
|
+
return new FindingAnalysesResource(this.transport, "/api/v1/finding-analyses");
|
|
57
|
+
}
|
|
58
|
+
get findings() {
|
|
59
|
+
return new FindingsResource(this.transport, "/api/v1/findings");
|
|
60
|
+
}
|
|
37
61
|
get invitations() {
|
|
38
62
|
return new InvitationsResource(this.transport, "/api/v1/invitations");
|
|
39
63
|
}
|
|
@@ -49,6 +73,15 @@ export class ServiceResources {
|
|
|
49
73
|
get memoryProviders() {
|
|
50
74
|
return new MemoryProvidersResource(this.transport, "/api/v1/memory-providers");
|
|
51
75
|
}
|
|
76
|
+
get memorySpaces() {
|
|
77
|
+
return new MemorySpacesResource(this.transport, "/api/v1/memory-spaces");
|
|
78
|
+
}
|
|
79
|
+
get metricsDashboards() {
|
|
80
|
+
return new MetricsDashboardsResource(this.transport, "/api/v1/metrics-dashboards");
|
|
81
|
+
}
|
|
82
|
+
get metricsDataSources() {
|
|
83
|
+
return new MetricsDataSourcesResource(this.transport, "/api/v1/metrics-data-sources");
|
|
84
|
+
}
|
|
52
85
|
get modelCatalog() {
|
|
53
86
|
return new ModelCatalogResource(this.transport, "/api/v1/model-catalog");
|
|
54
87
|
}
|
|
@@ -61,12 +94,18 @@ export class ServiceResources {
|
|
|
61
94
|
get organizations() {
|
|
62
95
|
return new OrganizationsResource(this.transport, "/api/v1/organizations");
|
|
63
96
|
}
|
|
97
|
+
get plugins() {
|
|
98
|
+
return new PluginsResource(this.transport, "/api/v1/plugins");
|
|
99
|
+
}
|
|
64
100
|
get providerTypes() {
|
|
65
101
|
return new ProviderTypesResource(this.transport, "/api/v1/provider-types");
|
|
66
102
|
}
|
|
67
103
|
get runs() {
|
|
68
104
|
return new RunsResource(this.transport, "/api/v1/runs");
|
|
69
105
|
}
|
|
106
|
+
get schedules() {
|
|
107
|
+
return new SchedulesResource(this.transport, "/api/v1/schedules");
|
|
108
|
+
}
|
|
70
109
|
get sessions() {
|
|
71
110
|
return new SessionsResource(this.transport, "/api/v1/sessions");
|
|
72
111
|
}
|
|
@@ -242,7 +281,6 @@ export class AgentsAgentIdRevisionsResource {
|
|
|
242
281
|
this.transport = transport;
|
|
243
282
|
this.path = path;
|
|
244
283
|
}
|
|
245
|
-
/** GET /api/v1/agents/{agent_id}/revisions. Preserves response metadata; mutations are not replayed. */
|
|
246
284
|
list(options = {}) {
|
|
247
285
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
248
286
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -275,11 +313,13 @@ export class AgentsAgentIdRevisionsRevisionIdResource {
|
|
|
275
313
|
this.transport = transport;
|
|
276
314
|
this.path = path;
|
|
277
315
|
}
|
|
278
|
-
/** GET /api/v1/agents/{agent_id}/revisions/{revision_id}. Preserves response metadata; mutations are not replayed. */
|
|
279
316
|
get(options = {}) {
|
|
280
317
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
281
318
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
282
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
319
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
320
|
+
}
|
|
321
|
+
get compare() {
|
|
322
|
+
return new AgentsAgentIdRevisionsRevisionIdCompareResource(this.transport, this.path + "/compare");
|
|
283
323
|
}
|
|
284
324
|
/** POST /api/v1/agents/{agent_id}/revisions/{revision_id}/set-default. Preserves response metadata; mutations are not replayed. */
|
|
285
325
|
setDefault(options) {
|
|
@@ -291,6 +331,20 @@ export class AgentsAgentIdRevisionsRevisionIdResource {
|
|
|
291
331
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
292
332
|
}
|
|
293
333
|
}
|
|
334
|
+
export class AgentsAgentIdRevisionsRevisionIdCompareResource {
|
|
335
|
+
transport;
|
|
336
|
+
path;
|
|
337
|
+
constructor(transport, path) {
|
|
338
|
+
this.transport = transport;
|
|
339
|
+
this.path = path;
|
|
340
|
+
}
|
|
341
|
+
/** GET /api/v1/agents/{agent_id}/revisions/{revision_id}/compare. Preserves response metadata; mutations are not replayed. */
|
|
342
|
+
get(options) {
|
|
343
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
344
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
345
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
346
|
+
}
|
|
347
|
+
}
|
|
294
348
|
export class AssetsResource {
|
|
295
349
|
transport;
|
|
296
350
|
path;
|
|
@@ -455,6 +509,58 @@ export class AuthSessionResource {
|
|
|
455
509
|
});
|
|
456
510
|
}
|
|
457
511
|
}
|
|
512
|
+
export class BuiltinSkillsResource {
|
|
513
|
+
transport;
|
|
514
|
+
path;
|
|
515
|
+
constructor(transport, path) {
|
|
516
|
+
this.transport = transport;
|
|
517
|
+
this.path = path;
|
|
518
|
+
}
|
|
519
|
+
/** GET /api/v1/builtin-skills. Preserves response metadata; mutations are not replayed. */
|
|
520
|
+
list(options = {}) {
|
|
521
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
522
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
523
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
524
|
+
}
|
|
525
|
+
ref(value) {
|
|
526
|
+
return new BuiltinSkillsNameResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
527
|
+
}
|
|
528
|
+
}
|
|
529
|
+
export class BuiltinSkillsNameResource {
|
|
530
|
+
transport;
|
|
531
|
+
path;
|
|
532
|
+
constructor(transport, path) {
|
|
533
|
+
this.transport = transport;
|
|
534
|
+
this.path = path;
|
|
535
|
+
}
|
|
536
|
+
/** GET /api/v1/builtin-skills/{name}. Preserves response metadata; mutations are not replayed. */
|
|
537
|
+
get(options = {}) {
|
|
538
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
539
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
540
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
541
|
+
}
|
|
542
|
+
get content() {
|
|
543
|
+
return new BuiltinSkillsNameContentResource(this.transport, this.path + "/content");
|
|
544
|
+
}
|
|
545
|
+
}
|
|
546
|
+
export class BuiltinSkillsNameContentResource {
|
|
547
|
+
transport;
|
|
548
|
+
path;
|
|
549
|
+
constructor(transport, path) {
|
|
550
|
+
this.transport = transport;
|
|
551
|
+
this.path = path;
|
|
552
|
+
}
|
|
553
|
+
/** GET /api/v1/builtin-skills/{name}/content. Caller owns and closes the unbuffered body. */
|
|
554
|
+
get(options = {}) {
|
|
555
|
+
return binaryRequest(this.transport, this.path, {
|
|
556
|
+
...{ signal: options.signal, query: options.query },
|
|
557
|
+
headers: Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
558
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
559
|
+
.map(([key, value]) => [key, String(value)])),
|
|
560
|
+
accept: "application/zip",
|
|
561
|
+
});
|
|
562
|
+
}
|
|
563
|
+
}
|
|
458
564
|
export class ConnectionsResource {
|
|
459
565
|
transport;
|
|
460
566
|
path;
|
|
@@ -583,6 +689,47 @@ export class ConnectionsConnectionIdToolsResource {
|
|
|
583
689
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
584
690
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
585
691
|
}
|
|
692
|
+
get definitions() {
|
|
693
|
+
return new ConnectionsConnectionIdToolsDefinitionsResource(this.transport, this.path + "/definitions");
|
|
694
|
+
}
|
|
695
|
+
get index() {
|
|
696
|
+
return new ConnectionsConnectionIdToolsIndexResource(this.transport, this.path + "/index");
|
|
697
|
+
}
|
|
698
|
+
}
|
|
699
|
+
export class ConnectionsConnectionIdToolsDefinitionsResource {
|
|
700
|
+
transport;
|
|
701
|
+
path;
|
|
702
|
+
constructor(transport, path) {
|
|
703
|
+
this.transport = transport;
|
|
704
|
+
this.path = path;
|
|
705
|
+
}
|
|
706
|
+
/** GET /api/v1/connections/{connection_id}/tools/definitions. Preserves response metadata; mutations are not replayed. */
|
|
707
|
+
list(options) {
|
|
708
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
709
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
710
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
711
|
+
}
|
|
712
|
+
}
|
|
713
|
+
export class ConnectionsConnectionIdToolsIndexResource {
|
|
714
|
+
transport;
|
|
715
|
+
path;
|
|
716
|
+
constructor(transport, path) {
|
|
717
|
+
this.transport = transport;
|
|
718
|
+
this.path = path;
|
|
719
|
+
}
|
|
720
|
+
/** GET /api/v1/connections/{connection_id}/tools/index. Preserves response metadata; mutations are not replayed. */
|
|
721
|
+
list(options = {}) {
|
|
722
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
723
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
724
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
725
|
+
}
|
|
726
|
+
pages(options = {}) {
|
|
727
|
+
const query = snapshot(options.query ?? {});
|
|
728
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
729
|
+
}
|
|
730
|
+
items(options = {}) {
|
|
731
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
732
|
+
}
|
|
586
733
|
}
|
|
587
734
|
export class ConnectorProvidersResource {
|
|
588
735
|
transport;
|
|
@@ -621,6 +768,15 @@ export class ConnectorProvidersProviderIdResource {
|
|
|
621
768
|
this.transport = transport;
|
|
622
769
|
this.path = path;
|
|
623
770
|
}
|
|
771
|
+
/** DELETE /api/v1/connector-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
772
|
+
delete(options) {
|
|
773
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
774
|
+
"If-Match": options.ifMatch,
|
|
775
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
776
|
+
})
|
|
777
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
778
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
779
|
+
}
|
|
624
780
|
/** GET /api/v1/connector-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
625
781
|
get(options = {}) {
|
|
626
782
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
@@ -700,15 +856,35 @@ export class ConnectorProvidersProviderIdAppsAppActionsResource {
|
|
|
700
856
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
701
857
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
702
858
|
}
|
|
859
|
+
get definitions() {
|
|
860
|
+
return new ConnectorProvidersProviderIdAppsAppActionsDefinitionsResource(this.transport, this.path + "/definitions");
|
|
861
|
+
}
|
|
862
|
+
get index() {
|
|
863
|
+
return new ConnectorProvidersProviderIdAppsAppActionsIndexResource(this.transport, this.path + "/index");
|
|
864
|
+
}
|
|
703
865
|
}
|
|
704
|
-
export class
|
|
866
|
+
export class ConnectorProvidersProviderIdAppsAppActionsDefinitionsResource {
|
|
705
867
|
transport;
|
|
706
868
|
path;
|
|
707
869
|
constructor(transport, path) {
|
|
708
870
|
this.transport = transport;
|
|
709
871
|
this.path = path;
|
|
710
872
|
}
|
|
711
|
-
/** GET /api/v1/
|
|
873
|
+
/** GET /api/v1/connector-providers/{provider_id}/apps/{app}/actions/definitions. Preserves response metadata; mutations are not replayed. */
|
|
874
|
+
list(options) {
|
|
875
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
876
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
877
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
878
|
+
}
|
|
879
|
+
}
|
|
880
|
+
export class ConnectorProvidersProviderIdAppsAppActionsIndexResource {
|
|
881
|
+
transport;
|
|
882
|
+
path;
|
|
883
|
+
constructor(transport, path) {
|
|
884
|
+
this.transport = transport;
|
|
885
|
+
this.path = path;
|
|
886
|
+
}
|
|
887
|
+
/** GET /api/v1/connector-providers/{provider_id}/apps/{app}/actions/index. Preserves response metadata; mutations are not replayed. */
|
|
712
888
|
list(options = {}) {
|
|
713
889
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
714
890
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -721,53 +897,64 @@ export class EnvironmentProvidersResource {
|
|
|
721
897
|
items(options = {}) {
|
|
722
898
|
return flattenPages(this.pages(options), (value) => value);
|
|
723
899
|
}
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
900
|
+
}
|
|
901
|
+
export class DesktopAssistanceResource {
|
|
902
|
+
transport;
|
|
903
|
+
path;
|
|
904
|
+
constructor(transport, path) {
|
|
905
|
+
this.transport = transport;
|
|
906
|
+
this.path = path;
|
|
729
907
|
}
|
|
730
908
|
ref(value) {
|
|
731
|
-
return new
|
|
909
|
+
return new DesktopAssistanceAssistanceIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
732
910
|
}
|
|
733
911
|
}
|
|
734
|
-
export class
|
|
912
|
+
export class DesktopAssistanceAssistanceIdResource {
|
|
735
913
|
transport;
|
|
736
914
|
path;
|
|
737
915
|
constructor(transport, path) {
|
|
738
916
|
this.transport = transport;
|
|
739
917
|
this.path = path;
|
|
740
918
|
}
|
|
741
|
-
/**
|
|
742
|
-
|
|
743
|
-
return jsonRequest(this.transport, "
|
|
919
|
+
/** POST /api/v1/desktop-assistance/{assistance_id}/complete. Preserves response metadata; mutations are not replayed. */
|
|
920
|
+
complete(body, options = {}) {
|
|
921
|
+
return jsonRequest(this.transport, "POST", this.path + "/complete", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
744
922
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
745
923
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
746
924
|
}
|
|
747
|
-
/**
|
|
748
|
-
|
|
749
|
-
return jsonRequest(this.transport, "
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
925
|
+
/** POST /api/v1/desktop-assistance/{assistance_id}/control. Preserves response metadata; mutations are not replayed. */
|
|
926
|
+
control(body, options = {}) {
|
|
927
|
+
return jsonRequest(this.transport, "POST", this.path + "/control", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
928
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
929
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
930
|
+
}
|
|
931
|
+
/** POST /api/v1/desktop-assistance/{assistance_id}/disconnect. Preserves response metadata; mutations are not replayed. */
|
|
932
|
+
disconnect(body, options = {}) {
|
|
933
|
+
return jsonRequest(this.transport, "POST", this.path + "/disconnect", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
753
934
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
754
935
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
755
936
|
}
|
|
756
|
-
/** POST /api/v1/
|
|
757
|
-
|
|
758
|
-
return jsonRequest(this.transport, "POST", this.path + "/
|
|
937
|
+
/** POST /api/v1/desktop-assistance/{assistance_id}/request-control. Preserves response metadata; mutations are not replayed. */
|
|
938
|
+
requestControl(options = {}) {
|
|
939
|
+
return jsonRequest(this.transport, "POST", this.path + "/request-control", undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
759
940
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
760
941
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
761
942
|
}
|
|
943
|
+
/** POST /api/v1/desktop-assistance/{assistance_id}/view. Preserves response metadata; mutations are not replayed. */
|
|
944
|
+
view(body, options = {}) {
|
|
945
|
+
return jsonRequest(this.transport, "POST", this.path + "/view", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
946
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
947
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
948
|
+
}
|
|
762
949
|
}
|
|
763
|
-
export class
|
|
950
|
+
export class DevicesResource {
|
|
764
951
|
transport;
|
|
765
952
|
path;
|
|
766
953
|
constructor(transport, path) {
|
|
767
954
|
this.transport = transport;
|
|
768
955
|
this.path = path;
|
|
769
956
|
}
|
|
770
|
-
/** GET /api/v1/
|
|
957
|
+
/** GET /api/v1/devices. Preserves response metadata; mutations are not replayed. */
|
|
771
958
|
list(options = {}) {
|
|
772
959
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
773
960
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -780,30 +967,39 @@ export class EnvironmentTemplatesResource {
|
|
|
780
967
|
items(options = {}) {
|
|
781
968
|
return flattenPages(this.pages(options), (value) => value);
|
|
782
969
|
}
|
|
783
|
-
/** POST /api/v1/
|
|
970
|
+
/** POST /api/v1/devices. Preserves response metadata; mutations are not replayed. */
|
|
784
971
|
create(body, options = {}) {
|
|
785
972
|
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
786
973
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
787
974
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
788
975
|
}
|
|
789
976
|
ref(value) {
|
|
790
|
-
return new
|
|
977
|
+
return new DevicesDeviceIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
791
978
|
}
|
|
792
979
|
}
|
|
793
|
-
export class
|
|
980
|
+
export class DevicesDeviceIdResource {
|
|
794
981
|
transport;
|
|
795
982
|
path;
|
|
796
983
|
constructor(transport, path) {
|
|
797
984
|
this.transport = transport;
|
|
798
985
|
this.path = path;
|
|
799
986
|
}
|
|
800
|
-
/**
|
|
987
|
+
/** DELETE /api/v1/devices/{device_id}. Preserves response metadata; mutations are not replayed. */
|
|
988
|
+
delete(options) {
|
|
989
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
990
|
+
"If-Match": options.ifMatch,
|
|
991
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
992
|
+
})
|
|
993
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
994
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
995
|
+
}
|
|
996
|
+
/** GET /api/v1/devices/{device_id}. Preserves response metadata; mutations are not replayed. */
|
|
801
997
|
get(options = {}) {
|
|
802
998
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
803
999
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
804
1000
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
805
1001
|
}
|
|
806
|
-
/** PATCH /api/v1/
|
|
1002
|
+
/** PATCH /api/v1/devices/{device_id}. Preserves response metadata; mutations are not replayed. */
|
|
807
1003
|
update(body, options) {
|
|
808
1004
|
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
809
1005
|
"If-Match": options.ifMatch,
|
|
@@ -812,15 +1008,55 @@ export class EnvironmentTemplatesTemplateIdResource {
|
|
|
812
1008
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
813
1009
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
814
1010
|
}
|
|
1011
|
+
get metrics() {
|
|
1012
|
+
return new DevicesDeviceIdMetricsResource(this.transport, this.path + "/metrics");
|
|
1013
|
+
}
|
|
1014
|
+
/** POST /api/v1/devices/{device_id}/rotate-credential. Preserves response metadata; mutations are not replayed. */
|
|
1015
|
+
rotateCredential(options) {
|
|
1016
|
+
return jsonRequest(this.transport, "POST", this.path + "/rotate-credential", undefined, Object.fromEntries(Object.entries({
|
|
1017
|
+
"If-Match": options.ifMatch,
|
|
1018
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
1019
|
+
})
|
|
1020
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1021
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1022
|
+
}
|
|
815
1023
|
}
|
|
816
|
-
export class
|
|
1024
|
+
export class DevicesDeviceIdMetricsResource {
|
|
817
1025
|
transport;
|
|
818
1026
|
path;
|
|
819
1027
|
constructor(transport, path) {
|
|
820
1028
|
this.transport = transport;
|
|
821
1029
|
this.path = path;
|
|
822
1030
|
}
|
|
823
|
-
/**
|
|
1031
|
+
/** POST /api/v1/devices/{device_id}/metrics/query. Preserves response metadata; mutations are not replayed. */
|
|
1032
|
+
query(body, options = {}) {
|
|
1033
|
+
return jsonRequest(this.transport, "POST", this.path + "/query", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1034
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1035
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1036
|
+
}
|
|
1037
|
+
}
|
|
1038
|
+
export class EnvironmentProviderOptionsResource {
|
|
1039
|
+
transport;
|
|
1040
|
+
path;
|
|
1041
|
+
constructor(transport, path) {
|
|
1042
|
+
this.transport = transport;
|
|
1043
|
+
this.path = path;
|
|
1044
|
+
}
|
|
1045
|
+
/** POST /api/v1/environment-provider-options/vercel. Preserves response metadata; mutations are not replayed. */
|
|
1046
|
+
vercel(body, options = {}) {
|
|
1047
|
+
return jsonRequest(this.transport, "POST", this.path + "/vercel", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1048
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1049
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1050
|
+
}
|
|
1051
|
+
}
|
|
1052
|
+
export class EnvironmentProvidersResource {
|
|
1053
|
+
transport;
|
|
1054
|
+
path;
|
|
1055
|
+
constructor(transport, path) {
|
|
1056
|
+
this.transport = transport;
|
|
1057
|
+
this.path = path;
|
|
1058
|
+
}
|
|
1059
|
+
/** GET /api/v1/environment-providers. Preserves response metadata; mutations are not replayed. */
|
|
824
1060
|
list(options = {}) {
|
|
825
1061
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
826
1062
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -833,24 +1069,24 @@ export class EnvironmentsResource {
|
|
|
833
1069
|
items(options = {}) {
|
|
834
1070
|
return flattenPages(this.pages(options), (value) => value);
|
|
835
1071
|
}
|
|
836
|
-
/** POST /api/v1/
|
|
1072
|
+
/** POST /api/v1/environment-providers. Preserves response metadata; mutations are not replayed. */
|
|
837
1073
|
create(body, options = {}) {
|
|
838
1074
|
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
839
1075
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
840
1076
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
841
1077
|
}
|
|
842
1078
|
ref(value) {
|
|
843
|
-
return new
|
|
1079
|
+
return new EnvironmentProvidersProviderIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
844
1080
|
}
|
|
845
1081
|
}
|
|
846
|
-
export class
|
|
1082
|
+
export class EnvironmentProvidersProviderIdResource {
|
|
847
1083
|
transport;
|
|
848
1084
|
path;
|
|
849
1085
|
constructor(transport, path) {
|
|
850
1086
|
this.transport = transport;
|
|
851
1087
|
this.path = path;
|
|
852
1088
|
}
|
|
853
|
-
/** DELETE /api/v1/
|
|
1089
|
+
/** DELETE /api/v1/environment-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
854
1090
|
delete(options) {
|
|
855
1091
|
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
856
1092
|
"If-Match": options.ifMatch,
|
|
@@ -859,13 +1095,13 @@ export class EnvironmentsEnvironmentIdResource {
|
|
|
859
1095
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
860
1096
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
861
1097
|
}
|
|
862
|
-
/** GET /api/v1/
|
|
1098
|
+
/** GET /api/v1/environment-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
863
1099
|
get(options = {}) {
|
|
864
1100
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
865
1101
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
866
1102
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
867
1103
|
}
|
|
868
|
-
/** PATCH /api/v1/
|
|
1104
|
+
/** PATCH /api/v1/environment-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
869
1105
|
update(body, options) {
|
|
870
1106
|
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
871
1107
|
"If-Match": options.ifMatch,
|
|
@@ -874,77 +1110,76 @@ export class EnvironmentsEnvironmentIdResource {
|
|
|
874
1110
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
875
1111
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
876
1112
|
}
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
})
|
|
1113
|
+
get references() {
|
|
1114
|
+
return new EnvironmentProvidersProviderIdReferencesResource(this.transport, this.path + "/references");
|
|
1115
|
+
}
|
|
1116
|
+
/** POST /api/v1/environment-providers/{provider_id}/test. Preserves response metadata; mutations are not replayed. */
|
|
1117
|
+
test(options = {}) {
|
|
1118
|
+
return jsonRequest(this.transport, "POST", this.path + "/test", undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
883
1119
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
884
1120
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
885
1121
|
}
|
|
886
1122
|
}
|
|
887
|
-
export class
|
|
1123
|
+
export class EnvironmentProvidersProviderIdReferencesResource {
|
|
888
1124
|
transport;
|
|
889
1125
|
path;
|
|
890
1126
|
constructor(transport, path) {
|
|
891
1127
|
this.transport = transport;
|
|
892
1128
|
this.path = path;
|
|
893
1129
|
}
|
|
894
|
-
|
|
895
|
-
|
|
1130
|
+
/** GET /api/v1/environment-providers/{provider_id}/references. Preserves response metadata; mutations are not replayed. */
|
|
1131
|
+
get(options = {}) {
|
|
1132
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1133
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1134
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
896
1135
|
}
|
|
897
1136
|
}
|
|
898
|
-
export class
|
|
1137
|
+
export class EnvironmentTemplatesResource {
|
|
899
1138
|
transport;
|
|
900
1139
|
path;
|
|
901
1140
|
constructor(transport, path) {
|
|
902
1141
|
this.transport = transport;
|
|
903
1142
|
this.path = path;
|
|
904
1143
|
}
|
|
905
|
-
/**
|
|
906
|
-
|
|
907
|
-
return jsonRequest(this.transport, "
|
|
1144
|
+
/** GET /api/v1/environment-templates. Preserves response metadata; mutations are not replayed. */
|
|
1145
|
+
list(options = {}) {
|
|
1146
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1147
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1148
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
908
1149
|
}
|
|
909
|
-
}
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
path;
|
|
913
|
-
constructor(transport, path) {
|
|
914
|
-
this.transport = transport;
|
|
915
|
-
this.path = path;
|
|
916
|
-
}
|
|
917
|
-
/** GET /api/v1/mcp-servers. Preserves response metadata; mutations are not replayed. */
|
|
918
|
-
list(options = {}) {
|
|
919
|
-
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
920
|
-
signal: options.signal,
|
|
921
|
-
query: options.query,
|
|
922
|
-
});
|
|
923
|
-
}
|
|
924
|
-
pages(options = {}) {
|
|
925
|
-
const query = snapshot(options.query ?? {});
|
|
926
|
-
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
1150
|
+
pages(options = {}) {
|
|
1151
|
+
const query = snapshot(options.query ?? {});
|
|
1152
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
927
1153
|
}
|
|
928
1154
|
items(options = {}) {
|
|
929
1155
|
return flattenPages(this.pages(options), (value) => value);
|
|
930
1156
|
}
|
|
1157
|
+
/** POST /api/v1/environment-templates. Preserves response metadata; mutations are not replayed. */
|
|
1158
|
+
create(body, options = {}) {
|
|
1159
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1160
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1161
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1162
|
+
}
|
|
1163
|
+
ref(value) {
|
|
1164
|
+
return new EnvironmentTemplatesTemplateIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1165
|
+
}
|
|
931
1166
|
}
|
|
932
|
-
export class
|
|
1167
|
+
export class EnvironmentTemplatesTemplateIdResource {
|
|
933
1168
|
transport;
|
|
934
1169
|
path;
|
|
935
1170
|
constructor(transport, path) {
|
|
936
1171
|
this.transport = transport;
|
|
937
1172
|
this.path = path;
|
|
938
1173
|
}
|
|
939
|
-
/** GET /api/v1/
|
|
1174
|
+
/** GET /api/v1/environment-templates/{template_id}. Preserves response metadata; mutations are not replayed. */
|
|
940
1175
|
get(options = {}) {
|
|
941
1176
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
942
1177
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
943
1178
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
944
1179
|
}
|
|
945
|
-
/**
|
|
946
|
-
|
|
947
|
-
return jsonRequest(this.transport, "
|
|
1180
|
+
/** PATCH /api/v1/environment-templates/{template_id}. Preserves response metadata; mutations are not replayed. */
|
|
1181
|
+
update(body, options) {
|
|
1182
|
+
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
948
1183
|
"If-Match": options.ifMatch,
|
|
949
1184
|
"X-Workspace-ID": options.xWorkspaceId,
|
|
950
1185
|
})
|
|
@@ -952,14 +1187,14 @@ export class MediaUnderstandingDefaultsResource {
|
|
|
952
1187
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
953
1188
|
}
|
|
954
1189
|
}
|
|
955
|
-
export class
|
|
1190
|
+
export class EnvironmentsResource {
|
|
956
1191
|
transport;
|
|
957
1192
|
path;
|
|
958
1193
|
constructor(transport, path) {
|
|
959
1194
|
this.transport = transport;
|
|
960
1195
|
this.path = path;
|
|
961
1196
|
}
|
|
962
|
-
/** GET /api/v1/
|
|
1197
|
+
/** GET /api/v1/environments. Preserves response metadata; mutations are not replayed. */
|
|
963
1198
|
list(options = {}) {
|
|
964
1199
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
965
1200
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -972,24 +1207,24 @@ export class MemoriesResource {
|
|
|
972
1207
|
items(options = {}) {
|
|
973
1208
|
return flattenPages(this.pages(options), (value) => value);
|
|
974
1209
|
}
|
|
975
|
-
/** POST /api/v1/
|
|
1210
|
+
/** POST /api/v1/environments. Preserves response metadata; mutations are not replayed. */
|
|
976
1211
|
create(body, options = {}) {
|
|
977
1212
|
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
978
1213
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
979
1214
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
980
1215
|
}
|
|
981
1216
|
ref(value) {
|
|
982
|
-
return new
|
|
1217
|
+
return new EnvironmentsEnvironmentIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
983
1218
|
}
|
|
984
1219
|
}
|
|
985
|
-
export class
|
|
1220
|
+
export class EnvironmentsEnvironmentIdResource {
|
|
986
1221
|
transport;
|
|
987
1222
|
path;
|
|
988
1223
|
constructor(transport, path) {
|
|
989
1224
|
this.transport = transport;
|
|
990
1225
|
this.path = path;
|
|
991
1226
|
}
|
|
992
|
-
/** DELETE /api/v1/
|
|
1227
|
+
/** DELETE /api/v1/environments/{environment_id}. Preserves response metadata; mutations are not replayed. */
|
|
993
1228
|
delete(options) {
|
|
994
1229
|
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
995
1230
|
"If-Match": options.ifMatch,
|
|
@@ -998,13 +1233,13 @@ export class MemoriesMemoryIdResource {
|
|
|
998
1233
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
999
1234
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1000
1235
|
}
|
|
1001
|
-
/** GET /api/v1/
|
|
1236
|
+
/** GET /api/v1/environments/{environment_id}. Preserves response metadata; mutations are not replayed. */
|
|
1002
1237
|
get(options = {}) {
|
|
1003
1238
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1004
1239
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1005
1240
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1006
1241
|
}
|
|
1007
|
-
/** PATCH /api/v1/
|
|
1242
|
+
/** PATCH /api/v1/environments/{environment_id}. Preserves response metadata; mutations are not replayed. */
|
|
1008
1243
|
update(body, options) {
|
|
1009
1244
|
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
1010
1245
|
"If-Match": options.ifMatch,
|
|
@@ -1013,78 +1248,94 @@ export class MemoriesMemoryIdResource {
|
|
|
1013
1248
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1014
1249
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1015
1250
|
}
|
|
1016
|
-
get
|
|
1017
|
-
return new
|
|
1018
|
-
}
|
|
1019
|
-
get records() {
|
|
1020
|
-
return new MemoriesMemoryIdRecordsResource(this.transport, this.path + "/records");
|
|
1021
|
-
}
|
|
1022
|
-
get revisions() {
|
|
1023
|
-
return new MemoriesMemoryIdRevisionsResource(this.transport, this.path + "/revisions");
|
|
1251
|
+
get computer() {
|
|
1252
|
+
return new EnvironmentsEnvironmentIdComputerResource(this.transport, this.path + "/computer");
|
|
1024
1253
|
}
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
transport;
|
|
1028
|
-
path;
|
|
1029
|
-
constructor(transport, path) {
|
|
1030
|
-
this.transport = transport;
|
|
1031
|
-
this.path = path;
|
|
1254
|
+
get creation() {
|
|
1255
|
+
return new EnvironmentsEnvironmentIdCreationResource(this.transport, this.path + "/creation");
|
|
1032
1256
|
}
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1036
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
1037
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1257
|
+
get desktopPreview() {
|
|
1258
|
+
return new EnvironmentsEnvironmentIdDesktopPreviewResource(this.transport, this.path + "/desktop-preview");
|
|
1038
1259
|
}
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
1260
|
+
get metricsBinding() {
|
|
1261
|
+
return new EnvironmentsEnvironmentIdMetricsBindingResource(this.transport, this.path + "/metrics-binding");
|
|
1042
1262
|
}
|
|
1043
|
-
|
|
1044
|
-
return
|
|
1263
|
+
get metrics() {
|
|
1264
|
+
return new EnvironmentsEnvironmentIdMetricsResource(this.transport, this.path + "/metrics");
|
|
1045
1265
|
}
|
|
1046
|
-
/** POST /api/v1/
|
|
1047
|
-
|
|
1048
|
-
return jsonRequest(this.transport, "POST", this.path,
|
|
1266
|
+
/** POST /api/v1/environments/{environment_id}/retry-creation. Preserves response metadata; mutations are not replayed. */
|
|
1267
|
+
retryCreation(options) {
|
|
1268
|
+
return jsonRequest(this.transport, "POST", this.path + "/retry-creation", undefined, Object.fromEntries(Object.entries({
|
|
1269
|
+
"If-Match": options.ifMatch,
|
|
1270
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
1271
|
+
})
|
|
1049
1272
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1050
1273
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1051
1274
|
}
|
|
1052
|
-
/** POST /api/v1/
|
|
1053
|
-
|
|
1054
|
-
return jsonRequest(this.transport, "POST", this.path + "/
|
|
1275
|
+
/** POST /api/v1/environments/{environment_id}/stop. Preserves response metadata; mutations are not replayed. */
|
|
1276
|
+
stop(options) {
|
|
1277
|
+
return jsonRequest(this.transport, "POST", this.path + "/stop", undefined, Object.fromEntries(Object.entries({
|
|
1055
1278
|
"If-Match": options.ifMatch,
|
|
1056
1279
|
"X-Workspace-ID": options.xWorkspaceId,
|
|
1057
1280
|
})
|
|
1058
1281
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1059
1282
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1060
1283
|
}
|
|
1061
|
-
ref(value) {
|
|
1062
|
-
return new MemoriesMemoryIdFilesPathResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1063
|
-
}
|
|
1064
1284
|
}
|
|
1065
|
-
export class
|
|
1285
|
+
export class EnvironmentsEnvironmentIdComputerResource {
|
|
1066
1286
|
transport;
|
|
1067
1287
|
path;
|
|
1068
1288
|
constructor(transport, path) {
|
|
1069
1289
|
this.transport = transport;
|
|
1070
1290
|
this.path = path;
|
|
1071
1291
|
}
|
|
1072
|
-
/**
|
|
1073
|
-
|
|
1074
|
-
return jsonRequest(this.transport, "
|
|
1075
|
-
"If-Match": options.ifMatch,
|
|
1076
|
-
"X-Workspace-ID": options.xWorkspaceId,
|
|
1077
|
-
})
|
|
1292
|
+
/** POST /api/v1/environments/{environment_id}/computer/check. Preserves response metadata; mutations are not replayed. */
|
|
1293
|
+
check(options = {}) {
|
|
1294
|
+
return jsonRequest(this.transport, "POST", this.path + "/check", undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1078
1295
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1079
1296
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1080
1297
|
}
|
|
1081
|
-
|
|
1298
|
+
}
|
|
1299
|
+
export class EnvironmentsEnvironmentIdCreationResource {
|
|
1300
|
+
transport;
|
|
1301
|
+
path;
|
|
1302
|
+
constructor(transport, path) {
|
|
1303
|
+
this.transport = transport;
|
|
1304
|
+
this.path = path;
|
|
1305
|
+
}
|
|
1306
|
+
/** GET /api/v1/environments/{environment_id}/creation. Preserves response metadata; mutations are not replayed. */
|
|
1082
1307
|
get(options = {}) {
|
|
1083
1308
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1084
1309
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1085
1310
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1086
1311
|
}
|
|
1087
|
-
|
|
1312
|
+
}
|
|
1313
|
+
export class EnvironmentsEnvironmentIdDesktopPreviewResource {
|
|
1314
|
+
transport;
|
|
1315
|
+
path;
|
|
1316
|
+
constructor(transport, path) {
|
|
1317
|
+
this.transport = transport;
|
|
1318
|
+
this.path = path;
|
|
1319
|
+
}
|
|
1320
|
+
/** GET /api/v1/environments/{environment_id}/desktop-preview. Caller owns and closes the unbuffered body. */
|
|
1321
|
+
get(options = {}) {
|
|
1322
|
+
return binaryRequest(this.transport, this.path, {
|
|
1323
|
+
...{ signal: options.signal },
|
|
1324
|
+
headers: Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1325
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1326
|
+
.map(([key, value]) => [key, String(value)])),
|
|
1327
|
+
accept: "image/jpeg, image/png",
|
|
1328
|
+
});
|
|
1329
|
+
}
|
|
1330
|
+
}
|
|
1331
|
+
export class EnvironmentsEnvironmentIdMetricsBindingResource {
|
|
1332
|
+
transport;
|
|
1333
|
+
path;
|
|
1334
|
+
constructor(transport, path) {
|
|
1335
|
+
this.transport = transport;
|
|
1336
|
+
this.path = path;
|
|
1337
|
+
}
|
|
1338
|
+
/** PUT /api/v1/environments/{environment_id}/metrics-binding. Preserves response metadata; mutations are not replayed. */
|
|
1088
1339
|
replace(body, options) {
|
|
1089
1340
|
return jsonRequest(this.transport, "PUT", this.path, body, Object.fromEntries(Object.entries({
|
|
1090
1341
|
"If-Match": options.ifMatch,
|
|
@@ -1094,76 +1345,45 @@ export class MemoriesMemoryIdFilesPathResource {
|
|
|
1094
1345
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1095
1346
|
}
|
|
1096
1347
|
}
|
|
1097
|
-
export class
|
|
1348
|
+
export class EnvironmentsEnvironmentIdMetricsResource {
|
|
1098
1349
|
transport;
|
|
1099
1350
|
path;
|
|
1100
1351
|
constructor(transport, path) {
|
|
1101
1352
|
this.transport = transport;
|
|
1102
1353
|
this.path = path;
|
|
1103
1354
|
}
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1107
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
1108
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1109
|
-
}
|
|
1110
|
-
pages(options = {}) {
|
|
1111
|
-
const query = snapshot(options.query ?? {});
|
|
1112
|
-
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
1113
|
-
}
|
|
1114
|
-
items(options = {}) {
|
|
1115
|
-
return flattenPages(this.pages(options), (value) => value);
|
|
1116
|
-
}
|
|
1117
|
-
/** POST /api/v1/memories/{memory_id}/records. Preserves response metadata; mutations are not replayed. */
|
|
1118
|
-
create(body, options = {}) {
|
|
1119
|
-
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1120
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
1121
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1355
|
+
get collector() {
|
|
1356
|
+
return new EnvironmentsEnvironmentIdMetricsCollectorResource(this.transport, this.path + "/collector");
|
|
1122
1357
|
}
|
|
1123
|
-
/** POST /api/v1/
|
|
1124
|
-
|
|
1125
|
-
return jsonRequest(this.transport, "POST", this.path + "/
|
|
1358
|
+
/** POST /api/v1/environments/{environment_id}/metrics/query. Preserves response metadata; mutations are not replayed. */
|
|
1359
|
+
query(body, options = {}) {
|
|
1360
|
+
return jsonRequest(this.transport, "POST", this.path + "/query", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1126
1361
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1127
1362
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1128
1363
|
}
|
|
1129
|
-
ref(value) {
|
|
1130
|
-
return new MemoriesMemoryIdRecordsRecordIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1131
|
-
}
|
|
1132
1364
|
}
|
|
1133
|
-
export class
|
|
1365
|
+
export class EnvironmentsEnvironmentIdMetricsCollectorResource {
|
|
1134
1366
|
transport;
|
|
1135
1367
|
path;
|
|
1136
1368
|
constructor(transport, path) {
|
|
1137
1369
|
this.transport = transport;
|
|
1138
1370
|
this.path = path;
|
|
1139
1371
|
}
|
|
1140
|
-
/**
|
|
1141
|
-
|
|
1142
|
-
return jsonRequest(this.transport, "
|
|
1143
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
1144
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1145
|
-
}
|
|
1146
|
-
/** PUT /api/v1/memories/{memory_id}/records/{record_id}. Preserves response metadata; mutations are not replayed. */
|
|
1147
|
-
replace(body, options = {}) {
|
|
1148
|
-
return jsonRequest(this.transport, "PUT", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1372
|
+
/** GET /api/v1/environments/{environment_id}/metrics/collector. Preserves response metadata; mutations are not replayed. */
|
|
1373
|
+
get(options = {}) {
|
|
1374
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1149
1375
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1150
1376
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1151
1377
|
}
|
|
1152
1378
|
}
|
|
1153
|
-
export class
|
|
1379
|
+
export class FindingAnalysesResource {
|
|
1154
1380
|
transport;
|
|
1155
1381
|
path;
|
|
1156
1382
|
constructor(transport, path) {
|
|
1157
1383
|
this.transport = transport;
|
|
1158
1384
|
this.path = path;
|
|
1159
1385
|
}
|
|
1160
|
-
/**
|
|
1161
|
-
delete(options) {
|
|
1162
|
-
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1163
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
1164
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1165
|
-
}
|
|
1166
|
-
/** GET /api/v1/memories/{memory_id}/revisions. Preserves response metadata; mutations are not replayed. */
|
|
1386
|
+
/** GET /api/v1/finding-analyses. Preserves response metadata; mutations are not replayed. */
|
|
1167
1387
|
list(options = {}) {
|
|
1168
1388
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1169
1389
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -1176,41 +1396,24 @@ export class MemoriesMemoryIdRevisionsResource {
|
|
|
1176
1396
|
items(options = {}) {
|
|
1177
1397
|
return flattenPages(this.pages(options), (value) => value);
|
|
1178
1398
|
}
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
export class MemoriesMemoryIdRevisionsSeqResource {
|
|
1184
|
-
transport;
|
|
1185
|
-
path;
|
|
1186
|
-
constructor(transport, path) {
|
|
1187
|
-
this.transport = transport;
|
|
1188
|
-
this.path = path;
|
|
1189
|
-
}
|
|
1190
|
-
/** GET /api/v1/memories/{memory_id}/revisions/{seq}. Preserves response metadata; mutations are not replayed. */
|
|
1191
|
-
get(options = {}) {
|
|
1192
|
-
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1193
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
1194
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1195
|
-
}
|
|
1196
|
-
/** POST /api/v1/memories/{memory_id}/revisions/{seq}/restore. Preserves response metadata; mutations are not replayed. */
|
|
1197
|
-
restore(options = {}) {
|
|
1198
|
-
return jsonRequest(this.transport, "POST", this.path + "/restore", undefined, Object.fromEntries(Object.entries({
|
|
1199
|
-
"If-Match": options.ifMatch,
|
|
1399
|
+
/** POST /api/v1/finding-analyses. Preserves response metadata; mutations are not replayed. */
|
|
1400
|
+
create(body, options) {
|
|
1401
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({
|
|
1402
|
+
"Idempotency-Key": options.idempotencyKey,
|
|
1200
1403
|
"X-Workspace-ID": options.xWorkspaceId,
|
|
1201
1404
|
})
|
|
1202
1405
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1203
1406
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1204
1407
|
}
|
|
1205
1408
|
}
|
|
1206
|
-
export class
|
|
1409
|
+
export class FindingsResource {
|
|
1207
1410
|
transport;
|
|
1208
1411
|
path;
|
|
1209
1412
|
constructor(transport, path) {
|
|
1210
1413
|
this.transport = transport;
|
|
1211
1414
|
this.path = path;
|
|
1212
1415
|
}
|
|
1213
|
-
/** GET /api/v1/
|
|
1416
|
+
/** GET /api/v1/findings. Preserves response metadata; mutations are not replayed. */
|
|
1214
1417
|
list(options = {}) {
|
|
1215
1418
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1216
1419
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -1223,30 +1426,30 @@ export class MemoryProvidersResource {
|
|
|
1223
1426
|
items(options = {}) {
|
|
1224
1427
|
return flattenPages(this.pages(options), (value) => value);
|
|
1225
1428
|
}
|
|
1226
|
-
/** POST /api/v1/
|
|
1429
|
+
/** POST /api/v1/findings. Preserves response metadata; mutations are not replayed. */
|
|
1227
1430
|
create(body, options = {}) {
|
|
1228
1431
|
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1229
1432
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1230
1433
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1231
1434
|
}
|
|
1232
1435
|
ref(value) {
|
|
1233
|
-
return new
|
|
1436
|
+
return new FindingsFindingIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1234
1437
|
}
|
|
1235
1438
|
}
|
|
1236
|
-
export class
|
|
1439
|
+
export class FindingsFindingIdResource {
|
|
1237
1440
|
transport;
|
|
1238
1441
|
path;
|
|
1239
1442
|
constructor(transport, path) {
|
|
1240
1443
|
this.transport = transport;
|
|
1241
1444
|
this.path = path;
|
|
1242
1445
|
}
|
|
1243
|
-
/** GET /api/v1/
|
|
1446
|
+
/** GET /api/v1/findings/{finding_id}. Preserves response metadata; mutations are not replayed. */
|
|
1244
1447
|
get(options = {}) {
|
|
1245
1448
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1246
1449
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1247
1450
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1248
1451
|
}
|
|
1249
|
-
/** PATCH /api/v1/
|
|
1452
|
+
/** PATCH /api/v1/findings/{finding_id}. Preserves response metadata; mutations are not replayed. */
|
|
1250
1453
|
update(body, options) {
|
|
1251
1454
|
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
1252
1455
|
"If-Match": options.ifMatch,
|
|
@@ -1255,39 +1458,43 @@ export class MemoryProvidersProviderIdResource {
|
|
|
1255
1458
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1256
1459
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1257
1460
|
}
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1461
|
+
}
|
|
1462
|
+
export class InvitationsResource {
|
|
1463
|
+
transport;
|
|
1464
|
+
path;
|
|
1465
|
+
constructor(transport, path) {
|
|
1466
|
+
this.transport = transport;
|
|
1467
|
+
this.path = path;
|
|
1468
|
+
}
|
|
1469
|
+
ref(value) {
|
|
1470
|
+
return new InvitationsInvitationIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1263
1471
|
}
|
|
1264
1472
|
}
|
|
1265
|
-
export class
|
|
1473
|
+
export class InvitationsInvitationIdResource {
|
|
1266
1474
|
transport;
|
|
1267
1475
|
path;
|
|
1268
1476
|
constructor(transport, path) {
|
|
1269
1477
|
this.transport = transport;
|
|
1270
1478
|
this.path = path;
|
|
1271
1479
|
}
|
|
1272
|
-
/**
|
|
1273
|
-
|
|
1274
|
-
return jsonRequest(this.transport, "
|
|
1275
|
-
signal: options.signal,
|
|
1276
|
-
});
|
|
1480
|
+
/** POST /api/v1/invitations/{invitation_id}/accept. Preserves response metadata; mutations are not replayed. */
|
|
1481
|
+
accept(body, options = {}) {
|
|
1482
|
+
return jsonRequest(this.transport, "POST", this.path + "/accept", body, undefined, { signal: options.signal });
|
|
1277
1483
|
}
|
|
1278
1484
|
}
|
|
1279
|
-
export class
|
|
1485
|
+
export class McpServersResource {
|
|
1280
1486
|
transport;
|
|
1281
1487
|
path;
|
|
1282
1488
|
constructor(transport, path) {
|
|
1283
1489
|
this.transport = transport;
|
|
1284
1490
|
this.path = path;
|
|
1285
1491
|
}
|
|
1286
|
-
/** GET /api/v1/
|
|
1492
|
+
/** GET /api/v1/mcp-servers. Preserves response metadata; mutations are not replayed. */
|
|
1287
1493
|
list(options = {}) {
|
|
1288
|
-
return jsonRequest(this.transport, "GET", this.path, undefined,
|
|
1289
|
-
.
|
|
1290
|
-
|
|
1494
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
1495
|
+
signal: options.signal,
|
|
1496
|
+
query: options.query,
|
|
1497
|
+
});
|
|
1291
1498
|
}
|
|
1292
1499
|
pages(options = {}) {
|
|
1293
1500
|
const query = snapshot(options.query ?? {});
|
|
@@ -1296,53 +1503,38 @@ export class ModelProvidersResource {
|
|
|
1296
1503
|
items(options = {}) {
|
|
1297
1504
|
return flattenPages(this.pages(options), (value) => value);
|
|
1298
1505
|
}
|
|
1299
|
-
/** POST /api/v1/model-providers. Preserves response metadata; mutations are not replayed. */
|
|
1300
|
-
create(body, options = {}) {
|
|
1301
|
-
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1302
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
1303
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1304
|
-
}
|
|
1305
|
-
ref(value) {
|
|
1306
|
-
return new ModelProvidersProviderIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1307
|
-
}
|
|
1308
1506
|
}
|
|
1309
|
-
export class
|
|
1507
|
+
export class MediaUnderstandingDefaultsResource {
|
|
1310
1508
|
transport;
|
|
1311
1509
|
path;
|
|
1312
1510
|
constructor(transport, path) {
|
|
1313
1511
|
this.transport = transport;
|
|
1314
1512
|
this.path = path;
|
|
1315
1513
|
}
|
|
1316
|
-
/** GET /api/v1/
|
|
1514
|
+
/** GET /api/v1/media-understanding-defaults. Preserves response metadata; mutations are not replayed. */
|
|
1317
1515
|
get(options = {}) {
|
|
1318
1516
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1319
1517
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1320
1518
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1321
1519
|
}
|
|
1322
|
-
/**
|
|
1323
|
-
|
|
1324
|
-
return jsonRequest(this.transport, "
|
|
1520
|
+
/** PUT /api/v1/media-understanding-defaults. Preserves response metadata; mutations are not replayed. */
|
|
1521
|
+
replace(body, options) {
|
|
1522
|
+
return jsonRequest(this.transport, "PUT", this.path, body, Object.fromEntries(Object.entries({
|
|
1325
1523
|
"If-Match": options.ifMatch,
|
|
1326
1524
|
"X-Workspace-ID": options.xWorkspaceId,
|
|
1327
1525
|
})
|
|
1328
1526
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1329
1527
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1330
1528
|
}
|
|
1331
|
-
/** POST /api/v1/model-providers/{provider_id}/test. Preserves response metadata; mutations are not replayed. */
|
|
1332
|
-
test(options = {}) {
|
|
1333
|
-
return jsonRequest(this.transport, "POST", this.path + "/test", undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1334
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
1335
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1336
|
-
}
|
|
1337
1529
|
}
|
|
1338
|
-
export class
|
|
1530
|
+
export class MemoriesResource {
|
|
1339
1531
|
transport;
|
|
1340
1532
|
path;
|
|
1341
1533
|
constructor(transport, path) {
|
|
1342
1534
|
this.transport = transport;
|
|
1343
1535
|
this.path = path;
|
|
1344
1536
|
}
|
|
1345
|
-
/** GET /api/v1/
|
|
1537
|
+
/** GET /api/v1/memories. Preserves response metadata; mutations are not replayed. */
|
|
1346
1538
|
list(options = {}) {
|
|
1347
1539
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1348
1540
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -1355,30 +1547,39 @@ export class ModelsResource {
|
|
|
1355
1547
|
items(options = {}) {
|
|
1356
1548
|
return flattenPages(this.pages(options), (value) => value);
|
|
1357
1549
|
}
|
|
1358
|
-
/** POST /api/v1/
|
|
1550
|
+
/** POST /api/v1/memories. Preserves response metadata; mutations are not replayed. */
|
|
1359
1551
|
create(body, options = {}) {
|
|
1360
1552
|
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1361
1553
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1362
1554
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1363
1555
|
}
|
|
1364
1556
|
ref(value) {
|
|
1365
|
-
return new
|
|
1557
|
+
return new MemoriesMemoryIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1366
1558
|
}
|
|
1367
1559
|
}
|
|
1368
|
-
export class
|
|
1560
|
+
export class MemoriesMemoryIdResource {
|
|
1369
1561
|
transport;
|
|
1370
1562
|
path;
|
|
1371
1563
|
constructor(transport, path) {
|
|
1372
1564
|
this.transport = transport;
|
|
1373
1565
|
this.path = path;
|
|
1374
1566
|
}
|
|
1375
|
-
/**
|
|
1567
|
+
/** DELETE /api/v1/memories/{memory_id}. Preserves response metadata; mutations are not replayed. */
|
|
1568
|
+
delete(options) {
|
|
1569
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
1570
|
+
"If-Match": options.ifMatch,
|
|
1571
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
1572
|
+
})
|
|
1573
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1574
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1575
|
+
}
|
|
1576
|
+
/** GET /api/v1/memories/{memory_id}. Preserves response metadata; mutations are not replayed. */
|
|
1376
1577
|
get(options = {}) {
|
|
1377
1578
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1378
1579
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1379
1580
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1380
1581
|
}
|
|
1381
|
-
/** PATCH /api/v1/
|
|
1582
|
+
/** PATCH /api/v1/memories/{memory_id}. Preserves response metadata; mutations are not replayed. */
|
|
1382
1583
|
update(body, options) {
|
|
1383
1584
|
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
1384
1585
|
"If-Match": options.ifMatch,
|
|
@@ -1387,20 +1588,28 @@ export class ModelsKeyResource {
|
|
|
1387
1588
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1388
1589
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1389
1590
|
}
|
|
1591
|
+
get files() {
|
|
1592
|
+
return new MemoriesMemoryIdFilesResource(this.transport, this.path + "/files");
|
|
1593
|
+
}
|
|
1594
|
+
get records() {
|
|
1595
|
+
return new MemoriesMemoryIdRecordsResource(this.transport, this.path + "/records");
|
|
1596
|
+
}
|
|
1597
|
+
get revisions() {
|
|
1598
|
+
return new MemoriesMemoryIdRevisionsResource(this.transport, this.path + "/revisions");
|
|
1599
|
+
}
|
|
1390
1600
|
}
|
|
1391
|
-
export class
|
|
1601
|
+
export class MemoriesMemoryIdFilesResource {
|
|
1392
1602
|
transport;
|
|
1393
1603
|
path;
|
|
1394
1604
|
constructor(transport, path) {
|
|
1395
1605
|
this.transport = transport;
|
|
1396
1606
|
this.path = path;
|
|
1397
1607
|
}
|
|
1398
|
-
/** GET /api/v1/
|
|
1608
|
+
/** GET /api/v1/memories/{memory_id}/files. Preserves response metadata; mutations are not replayed. */
|
|
1399
1609
|
list(options = {}) {
|
|
1400
|
-
return jsonRequest(this.transport, "GET", this.path, undefined,
|
|
1401
|
-
|
|
1402
|
-
query: options.query
|
|
1403
|
-
});
|
|
1610
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1611
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1612
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1404
1613
|
}
|
|
1405
1614
|
pages(options = {}) {
|
|
1406
1615
|
const query = snapshot(options.query ?? {});
|
|
@@ -1409,61 +1618,131 @@ export class OrganizationsResource {
|
|
|
1409
1618
|
items(options = {}) {
|
|
1410
1619
|
return flattenPages(this.pages(options), (value) => value);
|
|
1411
1620
|
}
|
|
1621
|
+
/** POST /api/v1/memories/{memory_id}/files. Preserves response metadata; mutations are not replayed. */
|
|
1622
|
+
create(body, options = {}) {
|
|
1623
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1624
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1625
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1626
|
+
}
|
|
1627
|
+
/** POST /api/v1/memories/{memory_id}/files/move. Preserves response metadata; mutations are not replayed. */
|
|
1628
|
+
move(body, options) {
|
|
1629
|
+
return jsonRequest(this.transport, "POST", this.path + "/move", body, Object.fromEntries(Object.entries({
|
|
1630
|
+
"If-Match": options.ifMatch,
|
|
1631
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
1632
|
+
})
|
|
1633
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1634
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1635
|
+
}
|
|
1412
1636
|
ref(value) {
|
|
1413
|
-
return new
|
|
1637
|
+
return new MemoriesMemoryIdFilesPathResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1414
1638
|
}
|
|
1415
1639
|
}
|
|
1416
|
-
export class
|
|
1640
|
+
export class MemoriesMemoryIdFilesPathResource {
|
|
1417
1641
|
transport;
|
|
1418
1642
|
path;
|
|
1419
1643
|
constructor(transport, path) {
|
|
1420
1644
|
this.transport = transport;
|
|
1421
1645
|
this.path = path;
|
|
1422
1646
|
}
|
|
1423
|
-
/**
|
|
1647
|
+
/** DELETE /api/v1/memories/{memory_id}/files/{path}. Preserves response metadata; mutations are not replayed. */
|
|
1648
|
+
delete(options) {
|
|
1649
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
1650
|
+
"If-Match": options.ifMatch,
|
|
1651
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
1652
|
+
})
|
|
1653
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1654
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1655
|
+
}
|
|
1656
|
+
/** GET /api/v1/memories/{memory_id}/files/{path}. Preserves response metadata; mutations are not replayed. */
|
|
1424
1657
|
get(options = {}) {
|
|
1425
|
-
return jsonRequest(this.transport, "GET", this.path, undefined,
|
|
1426
|
-
|
|
1427
|
-
|
|
1658
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1659
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1660
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1428
1661
|
}
|
|
1429
|
-
/**
|
|
1430
|
-
|
|
1431
|
-
return jsonRequest(this.transport, "
|
|
1662
|
+
/** PUT /api/v1/memories/{memory_id}/files/{path}. Preserves response metadata; mutations are not replayed. */
|
|
1663
|
+
replace(body, options) {
|
|
1664
|
+
return jsonRequest(this.transport, "PUT", this.path, body, Object.fromEntries(Object.entries({
|
|
1665
|
+
"If-Match": options.ifMatch,
|
|
1666
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
1667
|
+
})
|
|
1432
1668
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1433
1669
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1434
1670
|
}
|
|
1435
|
-
|
|
1436
|
-
|
|
1671
|
+
}
|
|
1672
|
+
export class MemoriesMemoryIdRecordsResource {
|
|
1673
|
+
transport;
|
|
1674
|
+
path;
|
|
1675
|
+
constructor(transport, path) {
|
|
1676
|
+
this.transport = transport;
|
|
1677
|
+
this.path = path;
|
|
1437
1678
|
}
|
|
1438
|
-
|
|
1439
|
-
|
|
1679
|
+
/** GET /api/v1/memories/{memory_id}/records. Preserves response metadata; mutations are not replayed. */
|
|
1680
|
+
list(options = {}) {
|
|
1681
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1682
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1683
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1440
1684
|
}
|
|
1441
|
-
|
|
1442
|
-
|
|
1685
|
+
pages(options = {}) {
|
|
1686
|
+
const query = snapshot(options.query ?? {});
|
|
1687
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
1443
1688
|
}
|
|
1444
|
-
|
|
1445
|
-
return
|
|
1689
|
+
items(options = {}) {
|
|
1690
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
1446
1691
|
}
|
|
1447
|
-
|
|
1448
|
-
|
|
1692
|
+
/** POST /api/v1/memories/{memory_id}/records. Preserves response metadata; mutations are not replayed. */
|
|
1693
|
+
create(body, options = {}) {
|
|
1694
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1695
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1696
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1449
1697
|
}
|
|
1450
|
-
|
|
1451
|
-
|
|
1698
|
+
/** POST /api/v1/memories/{memory_id}/records/search. Preserves response metadata; mutations are not replayed. */
|
|
1699
|
+
search(body, options = {}) {
|
|
1700
|
+
return jsonRequest(this.transport, "POST", this.path + "/search", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1701
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1702
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1703
|
+
}
|
|
1704
|
+
ref(value) {
|
|
1705
|
+
return new MemoriesMemoryIdRecordsRecordIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1452
1706
|
}
|
|
1453
1707
|
}
|
|
1454
|
-
export class
|
|
1708
|
+
export class MemoriesMemoryIdRecordsRecordIdResource {
|
|
1455
1709
|
transport;
|
|
1456
1710
|
path;
|
|
1457
1711
|
constructor(transport, path) {
|
|
1458
1712
|
this.transport = transport;
|
|
1459
1713
|
this.path = path;
|
|
1460
1714
|
}
|
|
1461
|
-
/**
|
|
1715
|
+
/** DELETE /api/v1/memories/{memory_id}/records/{record_id}. Preserves response metadata; mutations are not replayed. */
|
|
1716
|
+
delete(options = {}) {
|
|
1717
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1718
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1719
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1720
|
+
}
|
|
1721
|
+
/** PUT /api/v1/memories/{memory_id}/records/{record_id}. Preserves response metadata; mutations are not replayed. */
|
|
1722
|
+
replace(body, options = {}) {
|
|
1723
|
+
return jsonRequest(this.transport, "PUT", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1724
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1725
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1726
|
+
}
|
|
1727
|
+
}
|
|
1728
|
+
export class MemoriesMemoryIdRevisionsResource {
|
|
1729
|
+
transport;
|
|
1730
|
+
path;
|
|
1731
|
+
constructor(transport, path) {
|
|
1732
|
+
this.transport = transport;
|
|
1733
|
+
this.path = path;
|
|
1734
|
+
}
|
|
1735
|
+
/** DELETE /api/v1/memories/{memory_id}/revisions. Preserves response metadata; mutations are not replayed. */
|
|
1736
|
+
delete(options) {
|
|
1737
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1738
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1739
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1740
|
+
}
|
|
1741
|
+
/** GET /api/v1/memories/{memory_id}/revisions. Preserves response metadata; mutations are not replayed. */
|
|
1462
1742
|
list(options = {}) {
|
|
1463
|
-
return jsonRequest(this.transport, "GET", this.path, undefined,
|
|
1464
|
-
|
|
1465
|
-
query: options.query
|
|
1466
|
-
});
|
|
1743
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1744
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1745
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1467
1746
|
}
|
|
1468
1747
|
pages(options = {}) {
|
|
1469
1748
|
const query = snapshot(options.query ?? {});
|
|
@@ -1472,20 +1751,45 @@ export class OrganizationsOrganizationIdAuditEventsResource {
|
|
|
1472
1751
|
items(options = {}) {
|
|
1473
1752
|
return flattenPages(this.pages(options), (value) => value);
|
|
1474
1753
|
}
|
|
1754
|
+
ref(value) {
|
|
1755
|
+
return new MemoriesMemoryIdRevisionsSeqResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1756
|
+
}
|
|
1475
1757
|
}
|
|
1476
|
-
export class
|
|
1758
|
+
export class MemoriesMemoryIdRevisionsSeqResource {
|
|
1477
1759
|
transport;
|
|
1478
1760
|
path;
|
|
1479
1761
|
constructor(transport, path) {
|
|
1480
1762
|
this.transport = transport;
|
|
1481
1763
|
this.path = path;
|
|
1482
1764
|
}
|
|
1483
|
-
/** GET /api/v1/
|
|
1765
|
+
/** GET /api/v1/memories/{memory_id}/revisions/{seq}. Preserves response metadata; mutations are not replayed. */
|
|
1766
|
+
get(options = {}) {
|
|
1767
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1768
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1769
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1770
|
+
}
|
|
1771
|
+
/** POST /api/v1/memories/{memory_id}/revisions/{seq}/restore. Preserves response metadata; mutations are not replayed. */
|
|
1772
|
+
restore(options = {}) {
|
|
1773
|
+
return jsonRequest(this.transport, "POST", this.path + "/restore", undefined, Object.fromEntries(Object.entries({
|
|
1774
|
+
"If-Match": options.ifMatch,
|
|
1775
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
1776
|
+
})
|
|
1777
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1778
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1779
|
+
}
|
|
1780
|
+
}
|
|
1781
|
+
export class MemoryProvidersResource {
|
|
1782
|
+
transport;
|
|
1783
|
+
path;
|
|
1784
|
+
constructor(transport, path) {
|
|
1785
|
+
this.transport = transport;
|
|
1786
|
+
this.path = path;
|
|
1787
|
+
}
|
|
1788
|
+
/** GET /api/v1/memory-providers. Preserves response metadata; mutations are not replayed. */
|
|
1484
1789
|
list(options = {}) {
|
|
1485
|
-
return jsonRequest(this.transport, "GET", this.path, undefined,
|
|
1486
|
-
|
|
1487
|
-
query: options.query
|
|
1488
|
-
});
|
|
1790
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1791
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1792
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1489
1793
|
}
|
|
1490
1794
|
pages(options = {}) {
|
|
1491
1795
|
const query = snapshot(options.query ?? {});
|
|
@@ -1494,126 +1798,1237 @@ export class OrganizationsOrganizationIdGrantsResource {
|
|
|
1494
1798
|
items(options = {}) {
|
|
1495
1799
|
return flattenPages(this.pages(options), (value) => value);
|
|
1496
1800
|
}
|
|
1497
|
-
/** POST /api/v1/
|
|
1801
|
+
/** POST /api/v1/memory-providers. Preserves response metadata; mutations are not replayed. */
|
|
1498
1802
|
create(body, options = {}) {
|
|
1499
|
-
return jsonRequest(this.transport, "POST", this.path, body,
|
|
1500
|
-
|
|
1501
|
-
|
|
1803
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1804
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1805
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1502
1806
|
}
|
|
1503
1807
|
ref(value) {
|
|
1504
|
-
return new
|
|
1808
|
+
return new MemoryProvidersProviderIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1505
1809
|
}
|
|
1506
1810
|
}
|
|
1507
|
-
export class
|
|
1811
|
+
export class MemoryProvidersProviderIdResource {
|
|
1508
1812
|
transport;
|
|
1509
1813
|
path;
|
|
1510
1814
|
constructor(transport, path) {
|
|
1511
1815
|
this.transport = transport;
|
|
1512
1816
|
this.path = path;
|
|
1513
1817
|
}
|
|
1514
|
-
/** DELETE /api/v1/
|
|
1515
|
-
delete(options
|
|
1516
|
-
return jsonRequest(this.transport, "DELETE", this.path, undefined,
|
|
1818
|
+
/** DELETE /api/v1/memory-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
1819
|
+
delete(options) {
|
|
1820
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
1821
|
+
"If-Match": options.ifMatch,
|
|
1822
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
1823
|
+
})
|
|
1824
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1825
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1517
1826
|
}
|
|
1518
|
-
/**
|
|
1519
|
-
|
|
1520
|
-
return jsonRequest(this.transport, "
|
|
1521
|
-
|
|
1522
|
-
|
|
1827
|
+
/** GET /api/v1/memory-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
1828
|
+
get(options = {}) {
|
|
1829
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1830
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1831
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1832
|
+
}
|
|
1833
|
+
/** PATCH /api/v1/memory-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
1834
|
+
update(body, options) {
|
|
1835
|
+
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
1836
|
+
"If-Match": options.ifMatch,
|
|
1837
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
1838
|
+
})
|
|
1839
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1840
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1841
|
+
}
|
|
1842
|
+
/** POST /api/v1/memory-providers/{provider_id}/test. Preserves response metadata; mutations are not replayed. */
|
|
1843
|
+
test(options = {}) {
|
|
1844
|
+
return jsonRequest(this.transport, "POST", this.path + "/test", undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1845
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1846
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1523
1847
|
}
|
|
1524
1848
|
}
|
|
1525
|
-
export class
|
|
1849
|
+
export class MemorySpacesResource {
|
|
1850
|
+
transport;
|
|
1851
|
+
path;
|
|
1852
|
+
constructor(transport, path) {
|
|
1853
|
+
this.transport = transport;
|
|
1854
|
+
this.path = path;
|
|
1855
|
+
}
|
|
1856
|
+
/** GET /api/v1/memory-spaces. Preserves response metadata; mutations are not replayed. */
|
|
1857
|
+
list(options = {}) {
|
|
1858
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1859
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1860
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1861
|
+
}
|
|
1862
|
+
pages(options = {}) {
|
|
1863
|
+
const query = snapshot(options.query ?? {});
|
|
1864
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
1865
|
+
}
|
|
1866
|
+
items(options = {}) {
|
|
1867
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
1868
|
+
}
|
|
1869
|
+
/** POST /api/v1/memory-spaces. Preserves response metadata; mutations are not replayed. */
|
|
1870
|
+
create(body, options = {}) {
|
|
1871
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1872
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1873
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1874
|
+
}
|
|
1875
|
+
ref(value) {
|
|
1876
|
+
return new MemorySpacesSpaceIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1877
|
+
}
|
|
1878
|
+
}
|
|
1879
|
+
export class MemorySpacesSpaceIdResource {
|
|
1880
|
+
transport;
|
|
1881
|
+
path;
|
|
1882
|
+
constructor(transport, path) {
|
|
1883
|
+
this.transport = transport;
|
|
1884
|
+
this.path = path;
|
|
1885
|
+
}
|
|
1886
|
+
/** DELETE /api/v1/memory-spaces/{space_id}. Preserves response metadata; mutations are not replayed. */
|
|
1887
|
+
delete(options) {
|
|
1888
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
1889
|
+
"If-Match": options.ifMatch,
|
|
1890
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
1891
|
+
})
|
|
1892
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1893
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1894
|
+
}
|
|
1895
|
+
/** GET /api/v1/memory-spaces/{space_id}. Preserves response metadata; mutations are not replayed. */
|
|
1896
|
+
get(options = {}) {
|
|
1897
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1898
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1899
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1900
|
+
}
|
|
1901
|
+
/** PATCH /api/v1/memory-spaces/{space_id}. Preserves response metadata; mutations are not replayed. */
|
|
1902
|
+
update(body, options) {
|
|
1903
|
+
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
1904
|
+
"If-Match": options.ifMatch,
|
|
1905
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
1906
|
+
})
|
|
1907
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1908
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1909
|
+
}
|
|
1910
|
+
get organization() {
|
|
1911
|
+
return new MemorySpacesSpaceIdOrganizationResource(this.transport, this.path + "/organization");
|
|
1912
|
+
}
|
|
1913
|
+
get organizations() {
|
|
1914
|
+
return new MemorySpacesSpaceIdOrganizationsResource(this.transport, this.path + "/organizations");
|
|
1915
|
+
}
|
|
1916
|
+
get sessions() {
|
|
1917
|
+
return new MemorySpacesSpaceIdSessionsResource(this.transport, this.path + "/sessions");
|
|
1918
|
+
}
|
|
1919
|
+
}
|
|
1920
|
+
export class MemorySpacesSpaceIdOrganizationResource {
|
|
1921
|
+
transport;
|
|
1922
|
+
path;
|
|
1923
|
+
constructor(transport, path) {
|
|
1924
|
+
this.transport = transport;
|
|
1925
|
+
this.path = path;
|
|
1926
|
+
}
|
|
1927
|
+
/** GET /api/v1/memory-spaces/{space_id}/organization. Preserves response metadata; mutations are not replayed. */
|
|
1928
|
+
get(options = {}) {
|
|
1929
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1930
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1931
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1932
|
+
}
|
|
1933
|
+
}
|
|
1934
|
+
export class MemorySpacesSpaceIdOrganizationsResource {
|
|
1935
|
+
transport;
|
|
1936
|
+
path;
|
|
1937
|
+
constructor(transport, path) {
|
|
1938
|
+
this.transport = transport;
|
|
1939
|
+
this.path = path;
|
|
1940
|
+
}
|
|
1941
|
+
/** GET /api/v1/memory-spaces/{space_id}/organizations. Preserves response metadata; mutations are not replayed. */
|
|
1942
|
+
list(options = {}) {
|
|
1943
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1944
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1945
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1946
|
+
}
|
|
1947
|
+
pages(options = {}) {
|
|
1948
|
+
const query = snapshot(options.query ?? {});
|
|
1949
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
1950
|
+
}
|
|
1951
|
+
items(options = {}) {
|
|
1952
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
1953
|
+
}
|
|
1954
|
+
/** POST /api/v1/memory-spaces/{space_id}/organizations. Preserves response metadata; mutations are not replayed. */
|
|
1955
|
+
create(options = {}) {
|
|
1956
|
+
return jsonRequest(this.transport, "POST", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1957
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1958
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1959
|
+
}
|
|
1960
|
+
}
|
|
1961
|
+
export class MemorySpacesSpaceIdSessionsResource {
|
|
1962
|
+
transport;
|
|
1963
|
+
path;
|
|
1964
|
+
constructor(transport, path) {
|
|
1965
|
+
this.transport = transport;
|
|
1966
|
+
this.path = path;
|
|
1967
|
+
}
|
|
1968
|
+
/** GET /api/v1/memory-spaces/{space_id}/sessions. Preserves response metadata; mutations are not replayed. */
|
|
1969
|
+
list(options = {}) {
|
|
1970
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1971
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1972
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1973
|
+
}
|
|
1974
|
+
pages(options = {}) {
|
|
1975
|
+
const query = snapshot(options.query ?? {});
|
|
1976
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
1977
|
+
}
|
|
1978
|
+
items(options = {}) {
|
|
1979
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
1980
|
+
}
|
|
1981
|
+
}
|
|
1982
|
+
export class MetricsDashboardsResource {
|
|
1983
|
+
transport;
|
|
1984
|
+
path;
|
|
1985
|
+
constructor(transport, path) {
|
|
1986
|
+
this.transport = transport;
|
|
1987
|
+
this.path = path;
|
|
1988
|
+
}
|
|
1989
|
+
/** GET /api/v1/metrics-dashboards. Preserves response metadata; mutations are not replayed. */
|
|
1990
|
+
list(options = {}) {
|
|
1991
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1992
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
1993
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1994
|
+
}
|
|
1995
|
+
pages(options = {}) {
|
|
1996
|
+
const query = snapshot(options.query ?? {});
|
|
1997
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
1998
|
+
}
|
|
1999
|
+
items(options = {}) {
|
|
2000
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2001
|
+
}
|
|
2002
|
+
/** POST /api/v1/metrics-dashboards. Preserves response metadata; mutations are not replayed. */
|
|
2003
|
+
create(body, options = {}) {
|
|
2004
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2005
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2006
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2007
|
+
}
|
|
2008
|
+
get preset() {
|
|
2009
|
+
return new MetricsDashboardsPresetResource(this.transport, this.path + "/preset");
|
|
2010
|
+
}
|
|
2011
|
+
ref(value) {
|
|
2012
|
+
return new MetricsDashboardsDashboardIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2013
|
+
}
|
|
2014
|
+
}
|
|
2015
|
+
export class MetricsDashboardsPresetResource {
|
|
2016
|
+
transport;
|
|
2017
|
+
path;
|
|
2018
|
+
constructor(transport, path) {
|
|
2019
|
+
this.transport = transport;
|
|
2020
|
+
this.path = path;
|
|
2021
|
+
}
|
|
2022
|
+
/** GET /api/v1/metrics-dashboards/preset. Preserves response metadata; mutations are not replayed. */
|
|
2023
|
+
get(options = {}) {
|
|
2024
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2025
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2026
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2027
|
+
}
|
|
2028
|
+
}
|
|
2029
|
+
export class MetricsDashboardsDashboardIdResource {
|
|
2030
|
+
transport;
|
|
2031
|
+
path;
|
|
2032
|
+
constructor(transport, path) {
|
|
2033
|
+
this.transport = transport;
|
|
2034
|
+
this.path = path;
|
|
2035
|
+
}
|
|
2036
|
+
/** DELETE /api/v1/metrics-dashboards/{dashboard_id}. Preserves response metadata; mutations are not replayed. */
|
|
2037
|
+
delete(options) {
|
|
2038
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
2039
|
+
"If-Match": options.ifMatch,
|
|
2040
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
2041
|
+
})
|
|
2042
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2043
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2044
|
+
}
|
|
2045
|
+
/** GET /api/v1/metrics-dashboards/{dashboard_id}. Preserves response metadata; mutations are not replayed. */
|
|
2046
|
+
get(options = {}) {
|
|
2047
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2048
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2049
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2050
|
+
}
|
|
2051
|
+
/** PATCH /api/v1/metrics-dashboards/{dashboard_id}. Preserves response metadata; mutations are not replayed. */
|
|
2052
|
+
update(body, options) {
|
|
2053
|
+
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
2054
|
+
"If-Match": options.ifMatch,
|
|
2055
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
2056
|
+
})
|
|
2057
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2058
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2059
|
+
}
|
|
2060
|
+
}
|
|
2061
|
+
export class MetricsDataSourcesResource {
|
|
2062
|
+
transport;
|
|
2063
|
+
path;
|
|
2064
|
+
constructor(transport, path) {
|
|
2065
|
+
this.transport = transport;
|
|
2066
|
+
this.path = path;
|
|
2067
|
+
}
|
|
2068
|
+
/** GET /api/v1/metrics-data-sources. Preserves response metadata; mutations are not replayed. */
|
|
2069
|
+
list(options = {}) {
|
|
2070
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2071
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2072
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
2073
|
+
}
|
|
2074
|
+
pages(options = {}) {
|
|
2075
|
+
const query = snapshot(options.query ?? {});
|
|
2076
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
2077
|
+
}
|
|
2078
|
+
items(options = {}) {
|
|
2079
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2080
|
+
}
|
|
2081
|
+
/** POST /api/v1/metrics-data-sources. Preserves response metadata; mutations are not replayed. */
|
|
2082
|
+
create(body, options = {}) {
|
|
2083
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2084
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2085
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2086
|
+
}
|
|
2087
|
+
get capabilities() {
|
|
2088
|
+
return new MetricsDataSourcesCapabilitiesResource(this.transport, this.path + "/capabilities");
|
|
2089
|
+
}
|
|
2090
|
+
get deploymentPreset() {
|
|
2091
|
+
return new MetricsDataSourcesDeploymentPresetResource(this.transport, this.path + "/deployment-preset");
|
|
2092
|
+
}
|
|
2093
|
+
ref(value) {
|
|
2094
|
+
return new MetricsDataSourcesSourceIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2095
|
+
}
|
|
2096
|
+
}
|
|
2097
|
+
export class MetricsDataSourcesCapabilitiesResource {
|
|
2098
|
+
transport;
|
|
2099
|
+
path;
|
|
2100
|
+
constructor(transport, path) {
|
|
2101
|
+
this.transport = transport;
|
|
2102
|
+
this.path = path;
|
|
2103
|
+
}
|
|
2104
|
+
/** GET /api/v1/metrics-data-sources/capabilities. Preserves response metadata; mutations are not replayed. */
|
|
2105
|
+
get(options = {}) {
|
|
2106
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2107
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2108
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2109
|
+
}
|
|
2110
|
+
}
|
|
2111
|
+
export class MetricsDataSourcesDeploymentPresetResource {
|
|
2112
|
+
transport;
|
|
2113
|
+
path;
|
|
2114
|
+
constructor(transport, path) {
|
|
2115
|
+
this.transport = transport;
|
|
2116
|
+
this.path = path;
|
|
2117
|
+
}
|
|
2118
|
+
/** GET /api/v1/metrics-data-sources/deployment-preset. Preserves response metadata; mutations are not replayed. */
|
|
2119
|
+
get(options = {}) {
|
|
2120
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2121
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2122
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2123
|
+
}
|
|
2124
|
+
}
|
|
2125
|
+
export class MetricsDataSourcesSourceIdResource {
|
|
2126
|
+
transport;
|
|
2127
|
+
path;
|
|
2128
|
+
constructor(transport, path) {
|
|
2129
|
+
this.transport = transport;
|
|
2130
|
+
this.path = path;
|
|
2131
|
+
}
|
|
2132
|
+
/** DELETE /api/v1/metrics-data-sources/{source_id}. Preserves response metadata; mutations are not replayed. */
|
|
2133
|
+
delete(options) {
|
|
2134
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
2135
|
+
"If-Match": options.ifMatch,
|
|
2136
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
2137
|
+
})
|
|
2138
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2139
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2140
|
+
}
|
|
2141
|
+
/** GET /api/v1/metrics-data-sources/{source_id}. Preserves response metadata; mutations are not replayed. */
|
|
2142
|
+
get(options = {}) {
|
|
2143
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2144
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2145
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2146
|
+
}
|
|
2147
|
+
/** PATCH /api/v1/metrics-data-sources/{source_id}. Preserves response metadata; mutations are not replayed. */
|
|
2148
|
+
update(body, options) {
|
|
2149
|
+
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
2150
|
+
"If-Match": options.ifMatch,
|
|
2151
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
2152
|
+
})
|
|
2153
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2154
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2155
|
+
}
|
|
2156
|
+
/** POST /api/v1/metrics-data-sources/{source_id}/query. Preserves response metadata; mutations are not replayed. */
|
|
2157
|
+
query(body, options = {}) {
|
|
2158
|
+
return jsonRequest(this.transport, "POST", this.path + "/query", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2159
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2160
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2161
|
+
}
|
|
2162
|
+
}
|
|
2163
|
+
export class ModelCatalogResource {
|
|
2164
|
+
transport;
|
|
2165
|
+
path;
|
|
2166
|
+
constructor(transport, path) {
|
|
2167
|
+
this.transport = transport;
|
|
2168
|
+
this.path = path;
|
|
2169
|
+
}
|
|
2170
|
+
list(options = {}) {
|
|
2171
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
2172
|
+
signal: options.signal,
|
|
2173
|
+
query: options.query,
|
|
2174
|
+
});
|
|
2175
|
+
}
|
|
2176
|
+
}
|
|
2177
|
+
export class ModelProvidersResource {
|
|
2178
|
+
transport;
|
|
2179
|
+
path;
|
|
2180
|
+
constructor(transport, path) {
|
|
2181
|
+
this.transport = transport;
|
|
2182
|
+
this.path = path;
|
|
2183
|
+
}
|
|
2184
|
+
/** GET /api/v1/model-providers. Preserves response metadata; mutations are not replayed. */
|
|
2185
|
+
list(options = {}) {
|
|
2186
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2187
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2188
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
2189
|
+
}
|
|
2190
|
+
pages(options = {}) {
|
|
2191
|
+
const query = snapshot(options.query ?? {});
|
|
2192
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
2193
|
+
}
|
|
2194
|
+
items(options = {}) {
|
|
2195
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2196
|
+
}
|
|
2197
|
+
/** POST /api/v1/model-providers. Preserves response metadata; mutations are not replayed. */
|
|
2198
|
+
create(body, options = {}) {
|
|
2199
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2200
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2201
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2202
|
+
}
|
|
2203
|
+
ref(value) {
|
|
2204
|
+
return new ModelProvidersProviderIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2205
|
+
}
|
|
2206
|
+
}
|
|
2207
|
+
export class ModelProvidersProviderIdResource {
|
|
2208
|
+
transport;
|
|
2209
|
+
path;
|
|
2210
|
+
constructor(transport, path) {
|
|
2211
|
+
this.transport = transport;
|
|
2212
|
+
this.path = path;
|
|
2213
|
+
}
|
|
2214
|
+
/** DELETE /api/v1/model-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
2215
|
+
delete(options) {
|
|
2216
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
2217
|
+
"If-Match": options.ifMatch,
|
|
2218
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
2219
|
+
})
|
|
2220
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2221
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2222
|
+
}
|
|
2223
|
+
/** GET /api/v1/model-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
2224
|
+
get(options = {}) {
|
|
2225
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2226
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2227
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2228
|
+
}
|
|
2229
|
+
/** PATCH /api/v1/model-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
2230
|
+
update(body, options) {
|
|
2231
|
+
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
2232
|
+
"If-Match": options.ifMatch,
|
|
2233
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
2234
|
+
})
|
|
2235
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2236
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2237
|
+
}
|
|
2238
|
+
get authorization() {
|
|
2239
|
+
return new ModelProvidersProviderIdAuthorizationResource(this.transport, this.path + "/authorization");
|
|
2240
|
+
}
|
|
2241
|
+
/** POST /api/v1/model-providers/{provider_id}/authorize. Preserves response metadata; mutations are not replayed. */
|
|
2242
|
+
authorize(body, options = {}) {
|
|
2243
|
+
return jsonRequest(this.transport, "POST", this.path + "/authorize", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2244
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2245
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2246
|
+
}
|
|
2247
|
+
get models() {
|
|
2248
|
+
return new ModelProvidersProviderIdModelsResource(this.transport, this.path + "/models");
|
|
2249
|
+
}
|
|
2250
|
+
/** POST /api/v1/model-providers/{provider_id}/test. Preserves response metadata; mutations are not replayed. */
|
|
2251
|
+
test(options = {}) {
|
|
2252
|
+
return jsonRequest(this.transport, "POST", this.path + "/test", undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2253
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2254
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2255
|
+
}
|
|
2256
|
+
}
|
|
2257
|
+
export class ModelProvidersProviderIdAuthorizationResource {
|
|
2258
|
+
transport;
|
|
2259
|
+
path;
|
|
2260
|
+
constructor(transport, path) {
|
|
2261
|
+
this.transport = transport;
|
|
2262
|
+
this.path = path;
|
|
2263
|
+
}
|
|
2264
|
+
/** DELETE /api/v1/model-providers/{provider_id}/authorization. Preserves response metadata; mutations are not replayed. */
|
|
2265
|
+
delete(options = {}) {
|
|
2266
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2267
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2268
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2269
|
+
}
|
|
2270
|
+
/** GET /api/v1/model-providers/{provider_id}/authorization. Preserves response metadata; mutations are not replayed. */
|
|
2271
|
+
get(options = {}) {
|
|
2272
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2273
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2274
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2275
|
+
}
|
|
2276
|
+
/** POST /api/v1/model-providers/{provider_id}/authorization/callback. Preserves response metadata; mutations are not replayed. */
|
|
2277
|
+
callback(body, options = {}) {
|
|
2278
|
+
return jsonRequest(this.transport, "POST", this.path + "/callback", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2279
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2280
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2281
|
+
}
|
|
2282
|
+
}
|
|
2283
|
+
export class ModelProvidersProviderIdModelsResource {
|
|
2284
|
+
transport;
|
|
2285
|
+
path;
|
|
2286
|
+
constructor(transport, path) {
|
|
2287
|
+
this.transport = transport;
|
|
2288
|
+
this.path = path;
|
|
2289
|
+
}
|
|
2290
|
+
/** GET /api/v1/model-providers/{provider_id}/models. Preserves response metadata; mutations are not replayed. */
|
|
2291
|
+
get(options = {}) {
|
|
2292
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2293
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2294
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2295
|
+
}
|
|
2296
|
+
}
|
|
2297
|
+
export class ModelsResource {
|
|
2298
|
+
transport;
|
|
2299
|
+
path;
|
|
2300
|
+
constructor(transport, path) {
|
|
2301
|
+
this.transport = transport;
|
|
2302
|
+
this.path = path;
|
|
2303
|
+
}
|
|
2304
|
+
/** GET /api/v1/models. Preserves response metadata; mutations are not replayed. */
|
|
2305
|
+
list(options = {}) {
|
|
2306
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2307
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2308
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
2309
|
+
}
|
|
2310
|
+
pages(options = {}) {
|
|
2311
|
+
const query = snapshot(options.query ?? {});
|
|
2312
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
2313
|
+
}
|
|
2314
|
+
items(options = {}) {
|
|
2315
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2316
|
+
}
|
|
2317
|
+
/** POST /api/v1/models. Preserves response metadata; mutations are not replayed. */
|
|
2318
|
+
create(body, options = {}) {
|
|
2319
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2320
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2321
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2322
|
+
}
|
|
2323
|
+
ref(value) {
|
|
2324
|
+
return new ModelsKeyResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2325
|
+
}
|
|
2326
|
+
}
|
|
2327
|
+
export class ModelsKeyResource {
|
|
2328
|
+
transport;
|
|
2329
|
+
path;
|
|
2330
|
+
constructor(transport, path) {
|
|
2331
|
+
this.transport = transport;
|
|
2332
|
+
this.path = path;
|
|
2333
|
+
}
|
|
2334
|
+
/** GET /api/v1/models/{key}. Preserves response metadata; mutations are not replayed. */
|
|
2335
|
+
get(options = {}) {
|
|
2336
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2337
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2338
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2339
|
+
}
|
|
2340
|
+
/** PATCH /api/v1/models/{key}. Preserves response metadata; mutations are not replayed. */
|
|
2341
|
+
update(body, options) {
|
|
2342
|
+
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
2343
|
+
"If-Match": options.ifMatch,
|
|
2344
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
2345
|
+
})
|
|
2346
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2347
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2348
|
+
}
|
|
2349
|
+
}
|
|
2350
|
+
export class OrganizationsResource {
|
|
2351
|
+
transport;
|
|
2352
|
+
path;
|
|
2353
|
+
constructor(transport, path) {
|
|
2354
|
+
this.transport = transport;
|
|
2355
|
+
this.path = path;
|
|
2356
|
+
}
|
|
2357
|
+
/** GET /api/v1/organizations. Preserves response metadata; mutations are not replayed. */
|
|
2358
|
+
list(options = {}) {
|
|
2359
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
2360
|
+
signal: options.signal,
|
|
2361
|
+
query: options.query,
|
|
2362
|
+
});
|
|
2363
|
+
}
|
|
2364
|
+
pages(options = {}) {
|
|
2365
|
+
const query = snapshot(options.query ?? {});
|
|
2366
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
2367
|
+
}
|
|
2368
|
+
items(options = {}) {
|
|
2369
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2370
|
+
}
|
|
2371
|
+
ref(value) {
|
|
2372
|
+
return new OrganizationsOrganizationIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2373
|
+
}
|
|
2374
|
+
}
|
|
2375
|
+
export class OrganizationsOrganizationIdResource {
|
|
2376
|
+
transport;
|
|
2377
|
+
path;
|
|
2378
|
+
constructor(transport, path) {
|
|
2379
|
+
this.transport = transport;
|
|
2380
|
+
this.path = path;
|
|
2381
|
+
}
|
|
2382
|
+
/** GET /api/v1/organizations/{organization_id}. Preserves response metadata; mutations are not replayed. */
|
|
2383
|
+
get(options = {}) {
|
|
2384
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
2385
|
+
signal: options.signal,
|
|
2386
|
+
});
|
|
2387
|
+
}
|
|
2388
|
+
/** PATCH /api/v1/organizations/{organization_id}. Preserves response metadata; mutations are not replayed. */
|
|
2389
|
+
update(body, options) {
|
|
2390
|
+
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({ "If-Match": options.ifMatch })
|
|
2391
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2392
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2393
|
+
}
|
|
2394
|
+
get auditEvents() {
|
|
2395
|
+
return new OrganizationsOrganizationIdAuditEventsResource(this.transport, this.path + "/audit-events");
|
|
2396
|
+
}
|
|
2397
|
+
get grants() {
|
|
2398
|
+
return new OrganizationsOrganizationIdGrantsResource(this.transport, this.path + "/grants");
|
|
2399
|
+
}
|
|
2400
|
+
get icon() {
|
|
2401
|
+
return new OrganizationsOrganizationIdIconResource(this.transport, this.path + "/icon");
|
|
2402
|
+
}
|
|
2403
|
+
get invitations() {
|
|
2404
|
+
return new OrganizationsOrganizationIdInvitationsResource(this.transport, this.path + "/invitations");
|
|
2405
|
+
}
|
|
2406
|
+
get members() {
|
|
2407
|
+
return new OrganizationsOrganizationIdMembersResource(this.transport, this.path + "/members");
|
|
2408
|
+
}
|
|
2409
|
+
get workspaces() {
|
|
2410
|
+
return new OrganizationsOrganizationIdWorkspacesResource(this.transport, this.path + "/workspaces");
|
|
2411
|
+
}
|
|
2412
|
+
}
|
|
2413
|
+
export class OrganizationsOrganizationIdAuditEventsResource {
|
|
2414
|
+
transport;
|
|
2415
|
+
path;
|
|
2416
|
+
constructor(transport, path) {
|
|
2417
|
+
this.transport = transport;
|
|
2418
|
+
this.path = path;
|
|
2419
|
+
}
|
|
2420
|
+
/** GET /api/v1/organizations/{organization_id}/audit-events. Preserves response metadata; mutations are not replayed. */
|
|
2421
|
+
list(options = {}) {
|
|
2422
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
2423
|
+
signal: options.signal,
|
|
2424
|
+
query: options.query,
|
|
2425
|
+
});
|
|
2426
|
+
}
|
|
2427
|
+
pages(options = {}) {
|
|
2428
|
+
const query = snapshot(options.query ?? {});
|
|
2429
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
2430
|
+
}
|
|
2431
|
+
items(options = {}) {
|
|
2432
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2433
|
+
}
|
|
2434
|
+
}
|
|
2435
|
+
export class OrganizationsOrganizationIdGrantsResource {
|
|
2436
|
+
transport;
|
|
2437
|
+
path;
|
|
2438
|
+
constructor(transport, path) {
|
|
2439
|
+
this.transport = transport;
|
|
2440
|
+
this.path = path;
|
|
2441
|
+
}
|
|
2442
|
+
/** GET /api/v1/organizations/{organization_id}/grants. Preserves response metadata; mutations are not replayed. */
|
|
2443
|
+
list(options = {}) {
|
|
2444
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
2445
|
+
signal: options.signal,
|
|
2446
|
+
query: options.query,
|
|
2447
|
+
});
|
|
2448
|
+
}
|
|
2449
|
+
pages(options = {}) {
|
|
2450
|
+
const query = snapshot(options.query ?? {});
|
|
2451
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
2452
|
+
}
|
|
2453
|
+
items(options = {}) {
|
|
2454
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2455
|
+
}
|
|
2456
|
+
/** POST /api/v1/organizations/{organization_id}/grants. Preserves response metadata; mutations are not replayed. */
|
|
2457
|
+
create(body, options = {}) {
|
|
2458
|
+
return jsonRequest(this.transport, "POST", this.path, body, undefined, {
|
|
2459
|
+
signal: options.signal,
|
|
2460
|
+
});
|
|
2461
|
+
}
|
|
2462
|
+
ref(value) {
|
|
2463
|
+
return new OrganizationsOrganizationIdGrantsGrantIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2464
|
+
}
|
|
2465
|
+
}
|
|
2466
|
+
export class OrganizationsOrganizationIdGrantsGrantIdResource {
|
|
2467
|
+
transport;
|
|
2468
|
+
path;
|
|
2469
|
+
constructor(transport, path) {
|
|
2470
|
+
this.transport = transport;
|
|
2471
|
+
this.path = path;
|
|
2472
|
+
}
|
|
2473
|
+
/** DELETE /api/v1/organizations/{organization_id}/grants/{grant_id}. Preserves response metadata; mutations are not replayed. */
|
|
2474
|
+
delete(options = {}) {
|
|
2475
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, undefined, { signal: options.signal });
|
|
2476
|
+
}
|
|
2477
|
+
/** PATCH /api/v1/organizations/{organization_id}/grants/{grant_id}. Preserves response metadata; mutations are not replayed. */
|
|
2478
|
+
update(body, options = {}) {
|
|
2479
|
+
return jsonRequest(this.transport, "PATCH", this.path, body, undefined, {
|
|
2480
|
+
signal: options.signal,
|
|
2481
|
+
});
|
|
2482
|
+
}
|
|
2483
|
+
}
|
|
2484
|
+
export class OrganizationsOrganizationIdIconResource {
|
|
2485
|
+
transport;
|
|
2486
|
+
path;
|
|
2487
|
+
constructor(transport, path) {
|
|
2488
|
+
this.transport = transport;
|
|
2489
|
+
this.path = path;
|
|
2490
|
+
}
|
|
2491
|
+
/** DELETE /api/v1/organizations/{organization_id}/icon. Preserves response metadata; mutations are not replayed. */
|
|
2492
|
+
delete(options) {
|
|
2493
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({ "If-Match": options.ifMatch })
|
|
2494
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2495
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2496
|
+
}
|
|
2497
|
+
/** GET /api/v1/organizations/{organization_id}/icon. Caller owns and closes the unbuffered body. */
|
|
2498
|
+
get(options = {}) {
|
|
2499
|
+
return binaryRequest(this.transport, this.path, {
|
|
2500
|
+
...{ signal: options.signal },
|
|
2501
|
+
headers: undefined,
|
|
2502
|
+
accept: "image/jpeg, image/png, image/webp",
|
|
2503
|
+
});
|
|
2504
|
+
}
|
|
2505
|
+
/** PUT /api/v1/organizations/{organization_id}/icon. Preserves response metadata; mutations are not replayed. */
|
|
2506
|
+
replace(body, options) {
|
|
2507
|
+
return uploadRequest(this.transport, "PUT", this.path, body, options.contentType, Object.fromEntries(Object.entries({ "If-Match": options.ifMatch })
|
|
2508
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2509
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2510
|
+
}
|
|
2511
|
+
}
|
|
2512
|
+
export class OrganizationsOrganizationIdInvitationsResource {
|
|
2513
|
+
transport;
|
|
2514
|
+
path;
|
|
2515
|
+
constructor(transport, path) {
|
|
2516
|
+
this.transport = transport;
|
|
2517
|
+
this.path = path;
|
|
2518
|
+
}
|
|
2519
|
+
/** GET /api/v1/organizations/{organization_id}/invitations. Preserves response metadata; mutations are not replayed. */
|
|
2520
|
+
list(options = {}) {
|
|
2521
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
2522
|
+
signal: options.signal,
|
|
2523
|
+
query: options.query,
|
|
2524
|
+
});
|
|
2525
|
+
}
|
|
2526
|
+
pages(options = {}) {
|
|
2527
|
+
const query = snapshot(options.query ?? {});
|
|
2528
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
2529
|
+
}
|
|
2530
|
+
items(options = {}) {
|
|
2531
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2532
|
+
}
|
|
2533
|
+
/** POST /api/v1/organizations/{organization_id}/invitations. Preserves response metadata; mutations are not replayed. */
|
|
2534
|
+
create(body, options = {}) {
|
|
2535
|
+
return jsonRequest(this.transport, "POST", this.path, body, undefined, {
|
|
2536
|
+
signal: options.signal,
|
|
2537
|
+
});
|
|
2538
|
+
}
|
|
2539
|
+
ref(value) {
|
|
2540
|
+
return new OrganizationsOrganizationIdInvitationsInvitationIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2541
|
+
}
|
|
2542
|
+
}
|
|
2543
|
+
export class OrganizationsOrganizationIdInvitationsInvitationIdResource {
|
|
2544
|
+
transport;
|
|
2545
|
+
path;
|
|
2546
|
+
constructor(transport, path) {
|
|
2547
|
+
this.transport = transport;
|
|
2548
|
+
this.path = path;
|
|
2549
|
+
}
|
|
2550
|
+
/** POST /api/v1/organizations/{organization_id}/invitations/{invitation_id}/resend. Preserves response metadata; mutations are not replayed. */
|
|
2551
|
+
resend(options) {
|
|
2552
|
+
return jsonRequest(this.transport, "POST", this.path + "/resend", undefined, Object.fromEntries(Object.entries({ "If-Match": options.ifMatch })
|
|
2553
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2554
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2555
|
+
}
|
|
2556
|
+
/** POST /api/v1/organizations/{organization_id}/invitations/{invitation_id}/revoke. Preserves response metadata; mutations are not replayed. */
|
|
2557
|
+
revoke(options) {
|
|
2558
|
+
return jsonRequest(this.transport, "POST", this.path + "/revoke", undefined, Object.fromEntries(Object.entries({ "If-Match": options.ifMatch })
|
|
2559
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2560
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2561
|
+
}
|
|
2562
|
+
}
|
|
2563
|
+
export class OrganizationsOrganizationIdMembersResource {
|
|
2564
|
+
transport;
|
|
2565
|
+
path;
|
|
2566
|
+
constructor(transport, path) {
|
|
2567
|
+
this.transport = transport;
|
|
2568
|
+
this.path = path;
|
|
2569
|
+
}
|
|
2570
|
+
/** GET /api/v1/organizations/{organization_id}/members. Preserves response metadata; mutations are not replayed. */
|
|
2571
|
+
list(options = {}) {
|
|
2572
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
2573
|
+
signal: options.signal,
|
|
2574
|
+
query: options.query,
|
|
2575
|
+
});
|
|
2576
|
+
}
|
|
2577
|
+
pages(options = {}) {
|
|
2578
|
+
const query = snapshot(options.query ?? {});
|
|
2579
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
2580
|
+
}
|
|
2581
|
+
items(options = {}) {
|
|
2582
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2583
|
+
}
|
|
2584
|
+
}
|
|
2585
|
+
export class OrganizationsOrganizationIdWorkspacesResource {
|
|
2586
|
+
transport;
|
|
2587
|
+
path;
|
|
2588
|
+
constructor(transport, path) {
|
|
2589
|
+
this.transport = transport;
|
|
2590
|
+
this.path = path;
|
|
2591
|
+
}
|
|
2592
|
+
/** GET /api/v1/organizations/{organization_id}/workspaces. Preserves response metadata; mutations are not replayed. */
|
|
2593
|
+
list(options = {}) {
|
|
2594
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
2595
|
+
signal: options.signal,
|
|
2596
|
+
query: options.query,
|
|
2597
|
+
});
|
|
2598
|
+
}
|
|
2599
|
+
pages(options = {}) {
|
|
2600
|
+
const query = snapshot(options.query ?? {});
|
|
2601
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
2602
|
+
}
|
|
2603
|
+
items(options = {}) {
|
|
2604
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2605
|
+
}
|
|
2606
|
+
/** POST /api/v1/organizations/{organization_id}/workspaces. Preserves response metadata; mutations are not replayed. */
|
|
2607
|
+
create(body, options = {}) {
|
|
2608
|
+
return jsonRequest(this.transport, "POST", this.path, body, undefined, {
|
|
2609
|
+
signal: options.signal,
|
|
2610
|
+
});
|
|
2611
|
+
}
|
|
2612
|
+
}
|
|
2613
|
+
export class PluginsResource {
|
|
2614
|
+
transport;
|
|
2615
|
+
path;
|
|
2616
|
+
constructor(transport, path) {
|
|
2617
|
+
this.transport = transport;
|
|
2618
|
+
this.path = path;
|
|
2619
|
+
}
|
|
2620
|
+
/** GET /api/v1/plugins. Preserves response metadata; mutations are not replayed. */
|
|
2621
|
+
list(options = {}) {
|
|
2622
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2623
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2624
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2625
|
+
}
|
|
2626
|
+
}
|
|
2627
|
+
export class ProviderTypesResource {
|
|
2628
|
+
transport;
|
|
2629
|
+
path;
|
|
2630
|
+
constructor(transport, path) {
|
|
2631
|
+
this.transport = transport;
|
|
2632
|
+
this.path = path;
|
|
2633
|
+
}
|
|
2634
|
+
ref(value) {
|
|
2635
|
+
return new ProviderTypesKindResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2636
|
+
}
|
|
2637
|
+
}
|
|
2638
|
+
export class ProviderTypesKindResource {
|
|
2639
|
+
transport;
|
|
2640
|
+
path;
|
|
2641
|
+
constructor(transport, path) {
|
|
2642
|
+
this.transport = transport;
|
|
2643
|
+
this.path = path;
|
|
2644
|
+
}
|
|
2645
|
+
/** GET /api/v1/provider-types/{kind}. Preserves response metadata; mutations are not replayed. */
|
|
2646
|
+
list(options = {}) {
|
|
2647
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
2648
|
+
signal: options.signal,
|
|
2649
|
+
});
|
|
2650
|
+
}
|
|
2651
|
+
}
|
|
2652
|
+
export class RunsResource {
|
|
2653
|
+
transport;
|
|
2654
|
+
path;
|
|
2655
|
+
constructor(transport, path) {
|
|
2656
|
+
this.transport = transport;
|
|
2657
|
+
this.path = path;
|
|
2658
|
+
}
|
|
2659
|
+
/** GET /api/v1/runs. Preserves response metadata; mutations are not replayed. */
|
|
2660
|
+
list(options = {}) {
|
|
2661
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2662
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2663
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
2664
|
+
}
|
|
2665
|
+
pages(options = {}) {
|
|
2666
|
+
const query = snapshot(options.query ?? {});
|
|
2667
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
2668
|
+
}
|
|
2669
|
+
items(options = {}) {
|
|
2670
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2671
|
+
}
|
|
2672
|
+
ref(value) {
|
|
2673
|
+
return new RunsRunIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2674
|
+
}
|
|
2675
|
+
}
|
|
2676
|
+
export class RunsRunIdResource {
|
|
2677
|
+
transport;
|
|
2678
|
+
path;
|
|
2679
|
+
constructor(transport, path) {
|
|
2680
|
+
this.transport = transport;
|
|
2681
|
+
this.path = path;
|
|
2682
|
+
}
|
|
2683
|
+
get(options = {}) {
|
|
2684
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2685
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2686
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
2687
|
+
}
|
|
2688
|
+
/** PATCH /api/v1/runs/{run_id}. Preserves response metadata; mutations are not replayed. */
|
|
2689
|
+
update(body, options) {
|
|
2690
|
+
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
2691
|
+
"If-Match": options.ifMatch,
|
|
2692
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
2693
|
+
})
|
|
2694
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2695
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2696
|
+
}
|
|
2697
|
+
get agent() {
|
|
2698
|
+
return new RunsRunIdAgentResource(this.transport, this.path + "/agent");
|
|
2699
|
+
}
|
|
2700
|
+
get apps() {
|
|
2701
|
+
return new RunsRunIdAppsResource(this.transport, this.path + "/apps");
|
|
2702
|
+
}
|
|
2703
|
+
get attempts() {
|
|
2704
|
+
return new RunsRunIdAttemptsResource(this.transport, this.path + "/attempts");
|
|
2705
|
+
}
|
|
2706
|
+
get contents() {
|
|
2707
|
+
return new RunsRunIdContentsResource(this.transport, this.path + "/contents");
|
|
2708
|
+
}
|
|
2709
|
+
get desktopAssistance() {
|
|
2710
|
+
return new RunsRunIdDesktopAssistanceResource(this.transport, this.path + "/desktop-assistance");
|
|
2711
|
+
}
|
|
2712
|
+
get desktopControl() {
|
|
2713
|
+
return new RunsRunIdDesktopControlResource(this.transport, this.path + "/desktop-control");
|
|
2714
|
+
}
|
|
2715
|
+
/** POST /api/v1/runs/{run_id}/fork. Preserves response metadata; mutations are not replayed. */
|
|
2716
|
+
fork(body, options) {
|
|
2717
|
+
return jsonRequest(this.transport, "POST", this.path + "/fork", body, Object.fromEntries(Object.entries({
|
|
2718
|
+
"Idempotency-Key": options.idempotencyKey,
|
|
2719
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
2720
|
+
})
|
|
2721
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2722
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2723
|
+
}
|
|
2724
|
+
get images() {
|
|
2725
|
+
return new RunsRunIdImagesResource(this.transport, this.path + "/images");
|
|
2726
|
+
}
|
|
2727
|
+
/** POST /api/v1/runs/{run_id}/interrupt. Preserves response metadata; mutations are not replayed. */
|
|
2728
|
+
interrupt(options = {}) {
|
|
2729
|
+
return jsonRequest(this.transport, "POST", this.path + "/interrupt", undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2730
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2731
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2732
|
+
}
|
|
2733
|
+
get items() {
|
|
2734
|
+
return new RunsRunIdItemsResource(this.transport, this.path + "/items");
|
|
2735
|
+
}
|
|
2736
|
+
get lineage() {
|
|
2737
|
+
return new RunsRunIdLineageResource(this.transport, this.path + "/lineage");
|
|
2738
|
+
}
|
|
2739
|
+
/** POST /api/v1/runs/{run_id}/resume. Preserves response metadata; mutations are not replayed. */
|
|
2740
|
+
resume(body, options) {
|
|
2741
|
+
return jsonRequest(this.transport, "POST", this.path + "/resume", body, Object.fromEntries(Object.entries({
|
|
2742
|
+
"Idempotency-Key": options.idempotencyKey,
|
|
2743
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
2744
|
+
})
|
|
2745
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2746
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2747
|
+
}
|
|
2748
|
+
}
|
|
2749
|
+
export class RunsRunIdAgentResource {
|
|
2750
|
+
transport;
|
|
2751
|
+
path;
|
|
2752
|
+
constructor(transport, path) {
|
|
2753
|
+
this.transport = transport;
|
|
2754
|
+
this.path = path;
|
|
2755
|
+
}
|
|
2756
|
+
get(options = {}) {
|
|
2757
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2758
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2759
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
2760
|
+
}
|
|
2761
|
+
}
|
|
2762
|
+
export class RunsRunIdAppsResource {
|
|
2763
|
+
transport;
|
|
2764
|
+
path;
|
|
2765
|
+
constructor(transport, path) {
|
|
2766
|
+
this.transport = transport;
|
|
2767
|
+
this.path = path;
|
|
2768
|
+
}
|
|
2769
|
+
ref(value) {
|
|
2770
|
+
return new RunsRunIdAppsAppIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2771
|
+
}
|
|
2772
|
+
}
|
|
2773
|
+
export class RunsRunIdAppsAppIdResource {
|
|
2774
|
+
transport;
|
|
2775
|
+
path;
|
|
2776
|
+
constructor(transport, path) {
|
|
2777
|
+
this.transport = transport;
|
|
2778
|
+
this.path = path;
|
|
2779
|
+
}
|
|
2780
|
+
/** POST /api/v1/runs/{run_id}/apps/{app_id}/open. Preserves response metadata; mutations are not replayed. */
|
|
2781
|
+
open(options = {}) {
|
|
2782
|
+
return jsonRequest(this.transport, "POST", this.path + "/open", undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2783
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2784
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2785
|
+
}
|
|
2786
|
+
get resources() {
|
|
2787
|
+
return new RunsRunIdAppsAppIdResourcesResource(this.transport, this.path + "/resources");
|
|
2788
|
+
}
|
|
2789
|
+
get tools() {
|
|
2790
|
+
return new RunsRunIdAppsAppIdToolsResource(this.transport, this.path + "/tools");
|
|
2791
|
+
}
|
|
2792
|
+
}
|
|
2793
|
+
export class RunsRunIdAppsAppIdResourcesResource {
|
|
2794
|
+
transport;
|
|
2795
|
+
path;
|
|
2796
|
+
constructor(transport, path) {
|
|
2797
|
+
this.transport = transport;
|
|
2798
|
+
this.path = path;
|
|
2799
|
+
}
|
|
2800
|
+
/** POST /api/v1/runs/{run_id}/apps/{app_id}/resources/read. Preserves response metadata; mutations are not replayed. */
|
|
2801
|
+
read(body, options = {}) {
|
|
2802
|
+
return jsonRequest(this.transport, "POST", this.path + "/read", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2803
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2804
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2805
|
+
}
|
|
2806
|
+
}
|
|
2807
|
+
export class RunsRunIdAppsAppIdToolsResource {
|
|
2808
|
+
transport;
|
|
2809
|
+
path;
|
|
2810
|
+
constructor(transport, path) {
|
|
2811
|
+
this.transport = transport;
|
|
2812
|
+
this.path = path;
|
|
2813
|
+
}
|
|
2814
|
+
/** POST /api/v1/runs/{run_id}/apps/{app_id}/tools/call. Preserves response metadata; mutations are not replayed. */
|
|
2815
|
+
call(body, options = {}) {
|
|
2816
|
+
return jsonRequest(this.transport, "POST", this.path + "/call", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2817
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2818
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2819
|
+
}
|
|
2820
|
+
}
|
|
2821
|
+
export class RunsRunIdAttemptsResource {
|
|
2822
|
+
transport;
|
|
2823
|
+
path;
|
|
2824
|
+
constructor(transport, path) {
|
|
2825
|
+
this.transport = transport;
|
|
2826
|
+
this.path = path;
|
|
2827
|
+
}
|
|
2828
|
+
/** GET /api/v1/runs/{run_id}/attempts. Preserves response metadata; mutations are not replayed. */
|
|
2829
|
+
list(options = {}) {
|
|
2830
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2831
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2832
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2833
|
+
}
|
|
2834
|
+
ref(value) {
|
|
2835
|
+
return new RunsRunIdAttemptsAttemptIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2836
|
+
}
|
|
2837
|
+
}
|
|
2838
|
+
export class RunsRunIdAttemptsAttemptIdResource {
|
|
2839
|
+
transport;
|
|
2840
|
+
path;
|
|
2841
|
+
constructor(transport, path) {
|
|
2842
|
+
this.transport = transport;
|
|
2843
|
+
this.path = path;
|
|
2844
|
+
}
|
|
2845
|
+
/** GET /api/v1/runs/{run_id}/attempts/{attempt_id}. Preserves response metadata; mutations are not replayed. */
|
|
2846
|
+
get(options = {}) {
|
|
2847
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2848
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2849
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2850
|
+
}
|
|
2851
|
+
get trace() {
|
|
2852
|
+
return new RunsRunIdAttemptsAttemptIdTraceResource(this.transport, this.path + "/trace");
|
|
2853
|
+
}
|
|
2854
|
+
}
|
|
2855
|
+
export class RunsRunIdAttemptsAttemptIdTraceResource {
|
|
2856
|
+
transport;
|
|
2857
|
+
path;
|
|
2858
|
+
constructor(transport, path) {
|
|
2859
|
+
this.transport = transport;
|
|
2860
|
+
this.path = path;
|
|
2861
|
+
}
|
|
2862
|
+
list(options = {}) {
|
|
2863
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2864
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2865
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
2866
|
+
}
|
|
2867
|
+
pages(options = {}) {
|
|
2868
|
+
const query = snapshot(options.query ?? {});
|
|
2869
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
2870
|
+
}
|
|
2871
|
+
items(options = {}) {
|
|
2872
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
2873
|
+
}
|
|
2874
|
+
}
|
|
2875
|
+
export class RunsRunIdContentsResource {
|
|
2876
|
+
transport;
|
|
2877
|
+
path;
|
|
2878
|
+
constructor(transport, path) {
|
|
2879
|
+
this.transport = transport;
|
|
2880
|
+
this.path = path;
|
|
2881
|
+
}
|
|
2882
|
+
ref(value) {
|
|
2883
|
+
return new RunsRunIdContentsContentIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2884
|
+
}
|
|
2885
|
+
}
|
|
2886
|
+
export class RunsRunIdContentsContentIdResource {
|
|
2887
|
+
transport;
|
|
2888
|
+
path;
|
|
2889
|
+
constructor(transport, path) {
|
|
2890
|
+
this.transport = transport;
|
|
2891
|
+
this.path = path;
|
|
2892
|
+
}
|
|
2893
|
+
get(options = {}) {
|
|
2894
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2895
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2896
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
2897
|
+
}
|
|
2898
|
+
}
|
|
2899
|
+
export class RunsRunIdDesktopAssistanceResource {
|
|
2900
|
+
transport;
|
|
2901
|
+
path;
|
|
2902
|
+
constructor(transport, path) {
|
|
2903
|
+
this.transport = transport;
|
|
2904
|
+
this.path = path;
|
|
2905
|
+
}
|
|
2906
|
+
ref(value) {
|
|
2907
|
+
return new RunsRunIdDesktopAssistanceCallIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2908
|
+
}
|
|
2909
|
+
}
|
|
2910
|
+
export class RunsRunIdDesktopAssistanceCallIdResource {
|
|
2911
|
+
transport;
|
|
2912
|
+
path;
|
|
2913
|
+
constructor(transport, path) {
|
|
2914
|
+
this.transport = transport;
|
|
2915
|
+
this.path = path;
|
|
2916
|
+
}
|
|
2917
|
+
/** GET /api/v1/runs/{run_id}/desktop-assistance/{call_id}. Preserves response metadata; mutations are not replayed. */
|
|
2918
|
+
get(options = {}) {
|
|
2919
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2920
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2921
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2922
|
+
}
|
|
2923
|
+
}
|
|
2924
|
+
export class RunsRunIdDesktopControlResource {
|
|
2925
|
+
transport;
|
|
2926
|
+
path;
|
|
2927
|
+
constructor(transport, path) {
|
|
2928
|
+
this.transport = transport;
|
|
2929
|
+
this.path = path;
|
|
2930
|
+
}
|
|
2931
|
+
/** GET /api/v1/runs/{run_id}/desktop-control. Preserves response metadata; mutations are not replayed. */
|
|
2932
|
+
get(options = {}) {
|
|
2933
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2934
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2935
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2936
|
+
}
|
|
2937
|
+
/** POST /api/v1/runs/{run_id}/desktop-control. Preserves response metadata; mutations are not replayed. */
|
|
2938
|
+
create(body, options = {}) {
|
|
2939
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2940
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2941
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2942
|
+
}
|
|
2943
|
+
/** POST /api/v1/runs/{run_id}/desktop-control/view. Preserves response metadata; mutations are not replayed. */
|
|
2944
|
+
view(body, options = {}) {
|
|
2945
|
+
return jsonRequest(this.transport, "POST", this.path + "/view", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2946
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2947
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2948
|
+
}
|
|
2949
|
+
}
|
|
2950
|
+
export class RunsRunIdImagesResource {
|
|
2951
|
+
transport;
|
|
2952
|
+
path;
|
|
2953
|
+
constructor(transport, path) {
|
|
2954
|
+
this.transport = transport;
|
|
2955
|
+
this.path = path;
|
|
2956
|
+
}
|
|
2957
|
+
ref(value) {
|
|
2958
|
+
return new RunsRunIdImagesImageIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2959
|
+
}
|
|
2960
|
+
}
|
|
2961
|
+
export class RunsRunIdImagesImageIdResource {
|
|
1526
2962
|
transport;
|
|
1527
2963
|
path;
|
|
1528
2964
|
constructor(transport, path) {
|
|
1529
2965
|
this.transport = transport;
|
|
1530
2966
|
this.path = path;
|
|
1531
2967
|
}
|
|
1532
|
-
/**
|
|
1533
|
-
delete(options) {
|
|
1534
|
-
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({ "If-Match": options.ifMatch })
|
|
1535
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
1536
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1537
|
-
}
|
|
1538
|
-
/** GET /api/v1/organizations/{organization_id}/icon. Caller owns and closes the unbuffered body. */
|
|
2968
|
+
/** GET /api/v1/runs/{run_id}/images/{image_id}. Caller owns and closes the unbuffered body. */
|
|
1539
2969
|
get(options = {}) {
|
|
1540
2970
|
return binaryRequest(this.transport, this.path, {
|
|
1541
2971
|
...{ signal: options.signal },
|
|
1542
|
-
headers:
|
|
1543
|
-
|
|
2972
|
+
headers: Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2973
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2974
|
+
.map(([key, value]) => [key, String(value)])),
|
|
2975
|
+
accept: "image/jpeg, image/png",
|
|
1544
2976
|
});
|
|
1545
2977
|
}
|
|
1546
|
-
/** PUT /api/v1/organizations/{organization_id}/icon. Preserves response metadata; mutations are not replayed. */
|
|
1547
|
-
replace(body, options) {
|
|
1548
|
-
return uploadRequest(this.transport, "PUT", this.path, body, options.contentType, Object.fromEntries(Object.entries({ "If-Match": options.ifMatch })
|
|
1549
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
1550
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1551
|
-
}
|
|
1552
2978
|
}
|
|
1553
|
-
export class
|
|
2979
|
+
export class RunsRunIdItemsResource {
|
|
1554
2980
|
transport;
|
|
1555
2981
|
path;
|
|
1556
2982
|
constructor(transport, path) {
|
|
1557
2983
|
this.transport = transport;
|
|
1558
2984
|
this.path = path;
|
|
1559
2985
|
}
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
signal: options.signal,
|
|
1564
|
-
query: options.query,
|
|
1565
|
-
});
|
|
1566
|
-
}
|
|
1567
|
-
pages(options = {}) {
|
|
1568
|
-
const query = snapshot(options.query ?? {});
|
|
1569
|
-
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
1570
|
-
}
|
|
1571
|
-
items(options = {}) {
|
|
1572
|
-
return flattenPages(this.pages(options), (value) => value);
|
|
1573
|
-
}
|
|
1574
|
-
/** POST /api/v1/organizations/{organization_id}/invitations. Preserves response metadata; mutations are not replayed. */
|
|
1575
|
-
create(body, options = {}) {
|
|
1576
|
-
return jsonRequest(this.transport, "POST", this.path, body, undefined, {
|
|
1577
|
-
signal: options.signal,
|
|
1578
|
-
});
|
|
2986
|
+
get(options = {}) {
|
|
2987
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2988
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
2989
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1579
2990
|
}
|
|
1580
2991
|
ref(value) {
|
|
1581
|
-
return new
|
|
2992
|
+
return new RunsRunIdItemsItemIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1582
2993
|
}
|
|
1583
2994
|
}
|
|
1584
|
-
export class
|
|
2995
|
+
export class RunsRunIdItemsItemIdResource {
|
|
1585
2996
|
transport;
|
|
1586
2997
|
path;
|
|
1587
2998
|
constructor(transport, path) {
|
|
1588
2999
|
this.transport = transport;
|
|
1589
3000
|
this.path = path;
|
|
1590
3001
|
}
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
return jsonRequest(this.transport, "POST", this.path + "/resend", undefined, Object.fromEntries(Object.entries({ "If-Match": options.ifMatch })
|
|
1594
|
-
.filter(([, value]) => value !== undefined && value !== null)
|
|
1595
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
3002
|
+
get content() {
|
|
3003
|
+
return new RunsRunIdItemsItemIdContentResource(this.transport, this.path + "/content");
|
|
1596
3004
|
}
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
3005
|
+
}
|
|
3006
|
+
export class RunsRunIdItemsItemIdContentResource {
|
|
3007
|
+
transport;
|
|
3008
|
+
path;
|
|
3009
|
+
constructor(transport, path) {
|
|
3010
|
+
this.transport = transport;
|
|
3011
|
+
this.path = path;
|
|
3012
|
+
}
|
|
3013
|
+
/** GET /api/v1/runs/{run_id}/items/{item_id}/content. Preserves response metadata; mutations are not replayed. */
|
|
3014
|
+
get(options) {
|
|
3015
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1600
3016
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1601
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
3017
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1602
3018
|
}
|
|
1603
3019
|
}
|
|
1604
|
-
export class
|
|
3020
|
+
export class RunsRunIdLineageResource {
|
|
1605
3021
|
transport;
|
|
1606
3022
|
path;
|
|
1607
3023
|
constructor(transport, path) {
|
|
1608
3024
|
this.transport = transport;
|
|
1609
3025
|
this.path = path;
|
|
1610
3026
|
}
|
|
1611
|
-
/** GET /api/v1/
|
|
3027
|
+
/** GET /api/v1/runs/{run_id}/lineage. Preserves response metadata; mutations are not replayed. */
|
|
1612
3028
|
list(options = {}) {
|
|
1613
|
-
return jsonRequest(this.transport, "GET", this.path, undefined,
|
|
1614
|
-
|
|
1615
|
-
query: options.query
|
|
1616
|
-
});
|
|
3029
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
3030
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3031
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1617
3032
|
}
|
|
1618
3033
|
pages(options = {}) {
|
|
1619
3034
|
const query = snapshot(options.query ?? {});
|
|
@@ -1623,19 +3038,18 @@ export class OrganizationsOrganizationIdMembersResource {
|
|
|
1623
3038
|
return flattenPages(this.pages(options), (value) => value);
|
|
1624
3039
|
}
|
|
1625
3040
|
}
|
|
1626
|
-
export class
|
|
3041
|
+
export class SchedulesResource {
|
|
1627
3042
|
transport;
|
|
1628
3043
|
path;
|
|
1629
3044
|
constructor(transport, path) {
|
|
1630
3045
|
this.transport = transport;
|
|
1631
3046
|
this.path = path;
|
|
1632
3047
|
}
|
|
1633
|
-
/** GET /api/v1/
|
|
3048
|
+
/** GET /api/v1/schedules. Preserves response metadata; mutations are not replayed. */
|
|
1634
3049
|
list(options = {}) {
|
|
1635
|
-
return jsonRequest(this.transport, "GET", this.path, undefined,
|
|
1636
|
-
|
|
1637
|
-
query: options.query
|
|
1638
|
-
});
|
|
3050
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
3051
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3052
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1639
3053
|
}
|
|
1640
3054
|
pages(options = {}) {
|
|
1641
3055
|
const query = snapshot(options.query ?? {});
|
|
@@ -1644,63 +3058,48 @@ export class OrganizationsOrganizationIdWorkspacesResource {
|
|
|
1644
3058
|
items(options = {}) {
|
|
1645
3059
|
return flattenPages(this.pages(options), (value) => value);
|
|
1646
3060
|
}
|
|
1647
|
-
/** POST /api/v1/
|
|
1648
|
-
create(body, options
|
|
1649
|
-
return jsonRequest(this.transport, "POST", this.path, body,
|
|
1650
|
-
|
|
1651
|
-
|
|
3061
|
+
/** POST /api/v1/schedules. Preserves response metadata; mutations are not replayed. */
|
|
3062
|
+
create(body, options) {
|
|
3063
|
+
return jsonRequest(this.transport, "POST", this.path, body, Object.fromEntries(Object.entries({
|
|
3064
|
+
"Idempotency-Key": options.idempotencyKey,
|
|
3065
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
3066
|
+
})
|
|
3067
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3068
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1652
3069
|
}
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
this.transport = transport;
|
|
1659
|
-
this.path = path;
|
|
3070
|
+
/** POST /api/v1/schedules/preview. Preserves response metadata; mutations are not replayed. */
|
|
3071
|
+
preview(body, options = {}) {
|
|
3072
|
+
return jsonRequest(this.transport, "POST", this.path + "/preview", body, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
3073
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3074
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1660
3075
|
}
|
|
1661
3076
|
ref(value) {
|
|
1662
|
-
return new
|
|
1663
|
-
}
|
|
1664
|
-
}
|
|
1665
|
-
export class ProviderTypesKindResource {
|
|
1666
|
-
transport;
|
|
1667
|
-
path;
|
|
1668
|
-
constructor(transport, path) {
|
|
1669
|
-
this.transport = transport;
|
|
1670
|
-
this.path = path;
|
|
1671
|
-
}
|
|
1672
|
-
/** GET /api/v1/provider-types/{kind}. Preserves response metadata; mutations are not replayed. */
|
|
1673
|
-
list(options = {}) {
|
|
1674
|
-
return jsonRequest(this.transport, "GET", this.path, undefined, undefined, {
|
|
1675
|
-
signal: options.signal,
|
|
1676
|
-
});
|
|
3077
|
+
return new SchedulesScheduleIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
1677
3078
|
}
|
|
1678
3079
|
}
|
|
1679
|
-
export class
|
|
3080
|
+
export class SchedulesScheduleIdResource {
|
|
1680
3081
|
transport;
|
|
1681
3082
|
path;
|
|
1682
3083
|
constructor(transport, path) {
|
|
1683
3084
|
this.transport = transport;
|
|
1684
3085
|
this.path = path;
|
|
1685
3086
|
}
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
this.transport = transport;
|
|
1695
|
-
this.path = path;
|
|
3087
|
+
/** DELETE /api/v1/schedules/{schedule_id}. Preserves response metadata; mutations are not replayed. */
|
|
3088
|
+
delete(options) {
|
|
3089
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
3090
|
+
"If-Match": options.ifMatch,
|
|
3091
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
3092
|
+
})
|
|
3093
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3094
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1696
3095
|
}
|
|
1697
|
-
/** GET /api/v1/
|
|
3096
|
+
/** GET /api/v1/schedules/{schedule_id}. Preserves response metadata; mutations are not replayed. */
|
|
1698
3097
|
get(options = {}) {
|
|
1699
3098
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1700
3099
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1701
3100
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1702
3101
|
}
|
|
1703
|
-
/** PATCH /api/v1/
|
|
3102
|
+
/** PATCH /api/v1/schedules/{schedule_id}. Preserves response metadata; mutations are not replayed. */
|
|
1704
3103
|
update(body, options) {
|
|
1705
3104
|
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
1706
3105
|
"If-Match": options.ifMatch,
|
|
@@ -1709,76 +3108,49 @@ export class RunsRunIdResource {
|
|
|
1709
3108
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1710
3109
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1711
3110
|
}
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
/** POST /api/v1/runs/{run_id}/fork. Preserves response metadata; mutations are not replayed. */
|
|
1716
|
-
fork(body, options) {
|
|
1717
|
-
return jsonRequest(this.transport, "POST", this.path + "/fork", body, Object.fromEntries(Object.entries({
|
|
3111
|
+
/** POST /api/v1/schedules/{schedule_id}/dispatch. Preserves response metadata; mutations are not replayed. */
|
|
3112
|
+
dispatch(body, options) {
|
|
3113
|
+
return jsonRequest(this.transport, "POST", this.path + "/dispatch", body, Object.fromEntries(Object.entries({
|
|
1718
3114
|
"Idempotency-Key": options.idempotencyKey,
|
|
3115
|
+
"If-Match": options.ifMatch,
|
|
1719
3116
|
"X-Workspace-ID": options.xWorkspaceId,
|
|
1720
3117
|
})
|
|
1721
3118
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1722
3119
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1723
3120
|
}
|
|
1724
|
-
/** POST /api/v1/
|
|
1725
|
-
|
|
1726
|
-
return jsonRequest(this.transport, "POST", this.path + "/
|
|
1727
|
-
.
|
|
1728
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1729
|
-
}
|
|
1730
|
-
get items() {
|
|
1731
|
-
return new RunsRunIdItemsResource(this.transport, this.path + "/items");
|
|
1732
|
-
}
|
|
1733
|
-
get lineage() {
|
|
1734
|
-
return new RunsRunIdLineageResource(this.transport, this.path + "/lineage");
|
|
1735
|
-
}
|
|
1736
|
-
/** POST /api/v1/runs/{run_id}/resume. Preserves response metadata; mutations are not replayed. */
|
|
1737
|
-
resume(body, options) {
|
|
1738
|
-
return jsonRequest(this.transport, "POST", this.path + "/resume", body, Object.fromEntries(Object.entries({
|
|
1739
|
-
"Idempotency-Key": options.idempotencyKey,
|
|
3121
|
+
/** POST /api/v1/schedules/{schedule_id}/enable. Preserves response metadata; mutations are not replayed. */
|
|
3122
|
+
enable(body, options) {
|
|
3123
|
+
return jsonRequest(this.transport, "POST", this.path + "/enable", body, Object.fromEntries(Object.entries({
|
|
3124
|
+
"If-Match": options.ifMatch,
|
|
1740
3125
|
"X-Workspace-ID": options.xWorkspaceId,
|
|
1741
3126
|
})
|
|
1742
3127
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1743
3128
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1744
3129
|
}
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
transport;
|
|
1748
|
-
path;
|
|
1749
|
-
constructor(transport, path) {
|
|
1750
|
-
this.transport = transport;
|
|
1751
|
-
this.path = path;
|
|
3130
|
+
get occurrences() {
|
|
3131
|
+
return new SchedulesScheduleIdOccurrencesResource(this.transport, this.path + "/occurrences");
|
|
1752
3132
|
}
|
|
1753
|
-
/**
|
|
1754
|
-
|
|
1755
|
-
return jsonRequest(this.transport, "
|
|
3133
|
+
/** POST /api/v1/schedules/{schedule_id}/pause. Preserves response metadata; mutations are not replayed. */
|
|
3134
|
+
pause(body, options) {
|
|
3135
|
+
return jsonRequest(this.transport, "POST", this.path + "/pause", body, Object.fromEntries(Object.entries({
|
|
3136
|
+
"If-Match": options.ifMatch,
|
|
3137
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
3138
|
+
})
|
|
1756
3139
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1757
3140
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1758
3141
|
}
|
|
1759
|
-
|
|
1760
|
-
return new
|
|
1761
|
-
}
|
|
1762
|
-
}
|
|
1763
|
-
export class RunsRunIdAttemptsAttemptIdResource {
|
|
1764
|
-
transport;
|
|
1765
|
-
path;
|
|
1766
|
-
constructor(transport, path) {
|
|
1767
|
-
this.transport = transport;
|
|
1768
|
-
this.path = path;
|
|
1769
|
-
}
|
|
1770
|
-
get trace() {
|
|
1771
|
-
return new RunsRunIdAttemptsAttemptIdTraceResource(this.transport, this.path + "/trace");
|
|
3142
|
+
get status() {
|
|
3143
|
+
return new SchedulesScheduleIdStatusResource(this.transport, this.path + "/status");
|
|
1772
3144
|
}
|
|
1773
3145
|
}
|
|
1774
|
-
export class
|
|
3146
|
+
export class SchedulesScheduleIdOccurrencesResource {
|
|
1775
3147
|
transport;
|
|
1776
3148
|
path;
|
|
1777
3149
|
constructor(transport, path) {
|
|
1778
3150
|
this.transport = transport;
|
|
1779
3151
|
this.path = path;
|
|
1780
3152
|
}
|
|
1781
|
-
/** GET /api/v1/
|
|
3153
|
+
/** GET /api/v1/schedules/{schedule_id}/occurrences. Preserves response metadata; mutations are not replayed. */
|
|
1782
3154
|
list(options = {}) {
|
|
1783
3155
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1784
3156
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -1791,40 +3163,36 @@ export class RunsRunIdAttemptsAttemptIdTraceResource {
|
|
|
1791
3163
|
items(options = {}) {
|
|
1792
3164
|
return flattenPages(this.pages(options), (value) => value);
|
|
1793
3165
|
}
|
|
3166
|
+
ref(value) {
|
|
3167
|
+
return new SchedulesScheduleIdOccurrencesOccurrenceIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
3168
|
+
}
|
|
1794
3169
|
}
|
|
1795
|
-
export class
|
|
3170
|
+
export class SchedulesScheduleIdOccurrencesOccurrenceIdResource {
|
|
1796
3171
|
transport;
|
|
1797
3172
|
path;
|
|
1798
3173
|
constructor(transport, path) {
|
|
1799
3174
|
this.transport = transport;
|
|
1800
3175
|
this.path = path;
|
|
1801
3176
|
}
|
|
1802
|
-
/** GET /api/v1/
|
|
3177
|
+
/** GET /api/v1/schedules/{schedule_id}/occurrences/{occurrence_id}. Preserves response metadata; mutations are not replayed. */
|
|
1803
3178
|
get(options = {}) {
|
|
1804
3179
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1805
3180
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1806
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
3181
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
1807
3182
|
}
|
|
1808
3183
|
}
|
|
1809
|
-
export class
|
|
3184
|
+
export class SchedulesScheduleIdStatusResource {
|
|
1810
3185
|
transport;
|
|
1811
3186
|
path;
|
|
1812
3187
|
constructor(transport, path) {
|
|
1813
3188
|
this.transport = transport;
|
|
1814
3189
|
this.path = path;
|
|
1815
3190
|
}
|
|
1816
|
-
/** GET /api/v1/
|
|
1817
|
-
|
|
3191
|
+
/** GET /api/v1/schedules/{schedule_id}/status. Preserves response metadata; mutations are not replayed. */
|
|
3192
|
+
get(options = {}) {
|
|
1818
3193
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
1819
3194
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1820
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal
|
|
1821
|
-
}
|
|
1822
|
-
pages(options = {}) {
|
|
1823
|
-
const query = snapshot(options.query ?? {});
|
|
1824
|
-
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
1825
|
-
}
|
|
1826
|
-
items(options = {}) {
|
|
1827
|
-
return flattenPages(this.pages(options), (value) => value);
|
|
3195
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1828
3196
|
}
|
|
1829
3197
|
}
|
|
1830
3198
|
export class SessionsResource {
|
|
@@ -1879,6 +3247,68 @@ export class SessionsSessionIdResource {
|
|
|
1879
3247
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
1880
3248
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
1881
3249
|
}
|
|
3250
|
+
get messageAuthors() {
|
|
3251
|
+
return new SessionsSessionIdMessageAuthorsResource(this.transport, this.path + "/message-authors");
|
|
3252
|
+
}
|
|
3253
|
+
get stream() {
|
|
3254
|
+
return new SessionsSessionIdStreamResource(this.transport, this.path + "/stream");
|
|
3255
|
+
}
|
|
3256
|
+
get threads() {
|
|
3257
|
+
return new SessionsSessionIdThreadsResource(this.transport, this.path + "/threads");
|
|
3258
|
+
}
|
|
3259
|
+
}
|
|
3260
|
+
export class SessionsSessionIdMessageAuthorsResource {
|
|
3261
|
+
transport;
|
|
3262
|
+
path;
|
|
3263
|
+
constructor(transport, path) {
|
|
3264
|
+
this.transport = transport;
|
|
3265
|
+
this.path = path;
|
|
3266
|
+
}
|
|
3267
|
+
/** GET /api/v1/sessions/{session_id}/message-authors. Preserves response metadata; mutations are not replayed. */
|
|
3268
|
+
list(options) {
|
|
3269
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
3270
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3271
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
3272
|
+
}
|
|
3273
|
+
}
|
|
3274
|
+
export class SessionsSessionIdStreamResource {
|
|
3275
|
+
transport;
|
|
3276
|
+
path;
|
|
3277
|
+
constructor(transport, path) {
|
|
3278
|
+
this.transport = transport;
|
|
3279
|
+
this.path = path;
|
|
3280
|
+
}
|
|
3281
|
+
/** GET /api/v1/sessions/{session_id}/stream. Caller owns and closes the unbuffered body. */
|
|
3282
|
+
get(options = {}) {
|
|
3283
|
+
return binaryRequest(this.transport, this.path, {
|
|
3284
|
+
...{ signal: options.signal },
|
|
3285
|
+
headers: Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
3286
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3287
|
+
.map(([key, value]) => [key, String(value)])),
|
|
3288
|
+
accept: "text/event-stream",
|
|
3289
|
+
});
|
|
3290
|
+
}
|
|
3291
|
+
}
|
|
3292
|
+
export class SessionsSessionIdThreadsResource {
|
|
3293
|
+
transport;
|
|
3294
|
+
path;
|
|
3295
|
+
constructor(transport, path) {
|
|
3296
|
+
this.transport = transport;
|
|
3297
|
+
this.path = path;
|
|
3298
|
+
}
|
|
3299
|
+
/** GET /api/v1/sessions/{session_id}/threads. Preserves response metadata; mutations are not replayed. */
|
|
3300
|
+
list(options = {}) {
|
|
3301
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
3302
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3303
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
3304
|
+
}
|
|
3305
|
+
pages(options = {}) {
|
|
3306
|
+
const query = snapshot(options.query ?? {});
|
|
3307
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
3308
|
+
}
|
|
3309
|
+
items(options = {}) {
|
|
3310
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
3311
|
+
}
|
|
1882
3312
|
}
|
|
1883
3313
|
export class SkillsResource {
|
|
1884
3314
|
transport;
|
|
@@ -2251,6 +3681,9 @@ export class ThreadsThreadIdResource {
|
|
|
2251
3681
|
get stream() {
|
|
2252
3682
|
return new ThreadsThreadIdStreamResource(this.transport, this.path + "/stream");
|
|
2253
3683
|
}
|
|
3684
|
+
get toolExecutions() {
|
|
3685
|
+
return new ThreadsThreadIdToolExecutionsResource(this.transport, this.path + "/tool-executions");
|
|
3686
|
+
}
|
|
2254
3687
|
}
|
|
2255
3688
|
export class ThreadsThreadIdEnvironmentsResource {
|
|
2256
3689
|
transport;
|
|
@@ -2294,6 +3727,15 @@ export class ThreadsThreadIdEnvironmentsNameResource {
|
|
|
2294
3727
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
2295
3728
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2296
3729
|
}
|
|
3730
|
+
/** PATCH /api/v1/threads/{thread_id}/environments/{name}. Preserves response metadata; mutations are not replayed. */
|
|
3731
|
+
update(body, options) {
|
|
3732
|
+
return jsonRequest(this.transport, "PATCH", this.path, body, Object.fromEntries(Object.entries({
|
|
3733
|
+
"If-Match": options.ifMatch,
|
|
3734
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
3735
|
+
})
|
|
3736
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3737
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
3738
|
+
}
|
|
2297
3739
|
}
|
|
2298
3740
|
export class ThreadsThreadIdInboxResource {
|
|
2299
3741
|
transport;
|
|
@@ -2302,7 +3744,6 @@ export class ThreadsThreadIdInboxResource {
|
|
|
2302
3744
|
this.transport = transport;
|
|
2303
3745
|
this.path = path;
|
|
2304
3746
|
}
|
|
2305
|
-
/** GET /api/v1/threads/{thread_id}/inbox. Preserves response metadata; mutations are not replayed. */
|
|
2306
3747
|
list(options = {}) {
|
|
2307
3748
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2308
3749
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -2364,11 +3805,10 @@ export class ThreadsThreadIdInboxEntryIdResource {
|
|
|
2364
3805
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
2365
3806
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2366
3807
|
}
|
|
2367
|
-
/** GET /api/v1/threads/{thread_id}/inbox/{entry_id}. Preserves response metadata; mutations are not replayed. */
|
|
2368
3808
|
get(options = {}) {
|
|
2369
3809
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2370
3810
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
2371
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
3811
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
2372
3812
|
}
|
|
2373
3813
|
/** PATCH /api/v1/threads/{thread_id}/inbox/{entry_id}. Preserves response metadata; mutations are not replayed. */
|
|
2374
3814
|
update(body, options) {
|
|
@@ -2463,7 +3903,7 @@ export class ThreadsThreadIdStreamResource {
|
|
|
2463
3903
|
/** GET /api/v1/threads/{thread_id}/stream. Caller owns and closes the unbuffered body. */
|
|
2464
3904
|
get(options = {}) {
|
|
2465
3905
|
return binaryRequest(this.transport, this.path, {
|
|
2466
|
-
...{ signal: options.signal },
|
|
3906
|
+
...{ signal: options.signal, query: options.query },
|
|
2467
3907
|
headers: Object.fromEntries(Object.entries({
|
|
2468
3908
|
"Last-Event-ID": options.lastEventId,
|
|
2469
3909
|
"X-Workspace-ID": options.xWorkspaceId,
|
|
@@ -2474,6 +3914,84 @@ export class ThreadsThreadIdStreamResource {
|
|
|
2474
3914
|
});
|
|
2475
3915
|
}
|
|
2476
3916
|
}
|
|
3917
|
+
export class ThreadsThreadIdToolExecutionsResource {
|
|
3918
|
+
transport;
|
|
3919
|
+
path;
|
|
3920
|
+
constructor(transport, path) {
|
|
3921
|
+
this.transport = transport;
|
|
3922
|
+
this.path = path;
|
|
3923
|
+
}
|
|
3924
|
+
/** GET /api/v1/threads/{thread_id}/tool-executions. Preserves response metadata; mutations are not replayed. */
|
|
3925
|
+
list(options = {}) {
|
|
3926
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
3927
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3928
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
3929
|
+
}
|
|
3930
|
+
pages(options = {}) {
|
|
3931
|
+
const query = snapshot(options.query ?? {});
|
|
3932
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
3933
|
+
}
|
|
3934
|
+
items(options = {}) {
|
|
3935
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
3936
|
+
}
|
|
3937
|
+
ref(value) {
|
|
3938
|
+
return new ThreadsThreadIdToolExecutionsExecutionIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
3939
|
+
}
|
|
3940
|
+
}
|
|
3941
|
+
export class ThreadsThreadIdToolExecutionsExecutionIdResource {
|
|
3942
|
+
transport;
|
|
3943
|
+
path;
|
|
3944
|
+
constructor(transport, path) {
|
|
3945
|
+
this.transport = transport;
|
|
3946
|
+
this.path = path;
|
|
3947
|
+
}
|
|
3948
|
+
/** GET /api/v1/threads/{thread_id}/tool-executions/{execution_id}. Preserves response metadata; mutations are not replayed. */
|
|
3949
|
+
get(options = {}) {
|
|
3950
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
3951
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3952
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
3953
|
+
}
|
|
3954
|
+
/** POST /api/v1/threads/{thread_id}/tool-executions/{execution_id}/cancel. Preserves response metadata; mutations are not replayed. */
|
|
3955
|
+
cancel(options = {}) {
|
|
3956
|
+
return jsonRequest(this.transport, "POST", this.path + "/cancel", undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
3957
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3958
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
3959
|
+
}
|
|
3960
|
+
get observation() {
|
|
3961
|
+
return new ThreadsThreadIdToolExecutionsExecutionIdObservationResource(this.transport, this.path + "/observation");
|
|
3962
|
+
}
|
|
3963
|
+
get result() {
|
|
3964
|
+
return new ThreadsThreadIdToolExecutionsExecutionIdResultResource(this.transport, this.path + "/result");
|
|
3965
|
+
}
|
|
3966
|
+
}
|
|
3967
|
+
export class ThreadsThreadIdToolExecutionsExecutionIdObservationResource {
|
|
3968
|
+
transport;
|
|
3969
|
+
path;
|
|
3970
|
+
constructor(transport, path) {
|
|
3971
|
+
this.transport = transport;
|
|
3972
|
+
this.path = path;
|
|
3973
|
+
}
|
|
3974
|
+
/** GET /api/v1/threads/{thread_id}/tool-executions/{execution_id}/observation. Preserves response metadata; mutations are not replayed. */
|
|
3975
|
+
get(options = {}) {
|
|
3976
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
3977
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3978
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
3979
|
+
}
|
|
3980
|
+
}
|
|
3981
|
+
export class ThreadsThreadIdToolExecutionsExecutionIdResultResource {
|
|
3982
|
+
transport;
|
|
3983
|
+
path;
|
|
3984
|
+
constructor(transport, path) {
|
|
3985
|
+
this.transport = transport;
|
|
3986
|
+
this.path = path;
|
|
3987
|
+
}
|
|
3988
|
+
/** GET /api/v1/threads/{thread_id}/tool-executions/{execution_id}/result. Preserves response metadata; mutations are not replayed. */
|
|
3989
|
+
get(options = {}) {
|
|
3990
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
3991
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
3992
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
3993
|
+
}
|
|
3994
|
+
}
|
|
2477
3995
|
export class ToolsetsResource {
|
|
2478
3996
|
transport;
|
|
2479
3997
|
path;
|
|
@@ -2487,6 +4005,47 @@ export class ToolsetsResource {
|
|
|
2487
4005
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
2488
4006
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
2489
4007
|
}
|
|
4008
|
+
get definitions() {
|
|
4009
|
+
return new ToolsetsDefinitionsResource(this.transport, this.path + "/definitions");
|
|
4010
|
+
}
|
|
4011
|
+
get index() {
|
|
4012
|
+
return new ToolsetsIndexResource(this.transport, this.path + "/index");
|
|
4013
|
+
}
|
|
4014
|
+
}
|
|
4015
|
+
export class ToolsetsDefinitionsResource {
|
|
4016
|
+
transport;
|
|
4017
|
+
path;
|
|
4018
|
+
constructor(transport, path) {
|
|
4019
|
+
this.transport = transport;
|
|
4020
|
+
this.path = path;
|
|
4021
|
+
}
|
|
4022
|
+
/** GET /api/v1/toolsets/definitions. Preserves response metadata; mutations are not replayed. */
|
|
4023
|
+
list(options) {
|
|
4024
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
4025
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
4026
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
4027
|
+
}
|
|
4028
|
+
}
|
|
4029
|
+
export class ToolsetsIndexResource {
|
|
4030
|
+
transport;
|
|
4031
|
+
path;
|
|
4032
|
+
constructor(transport, path) {
|
|
4033
|
+
this.transport = transport;
|
|
4034
|
+
this.path = path;
|
|
4035
|
+
}
|
|
4036
|
+
/** GET /api/v1/toolsets/index. Preserves response metadata; mutations are not replayed. */
|
|
4037
|
+
list(options = {}) {
|
|
4038
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
4039
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
4040
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
4041
|
+
}
|
|
4042
|
+
pages(options = {}) {
|
|
4043
|
+
const query = snapshot(options.query ?? {});
|
|
4044
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
4045
|
+
}
|
|
4046
|
+
items(options = {}) {
|
|
4047
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
4048
|
+
}
|
|
2490
4049
|
}
|
|
2491
4050
|
export class TraceBackendResource {
|
|
2492
4051
|
transport;
|
|
@@ -2509,7 +4068,6 @@ export class TracesResource {
|
|
|
2509
4068
|
this.transport = transport;
|
|
2510
4069
|
this.path = path;
|
|
2511
4070
|
}
|
|
2512
|
-
/** GET /api/v1/traces. Preserves response metadata; mutations are not replayed. */
|
|
2513
4071
|
list(options = {}) {
|
|
2514
4072
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2515
4073
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -2522,10 +4080,34 @@ export class TracesResource {
|
|
|
2522
4080
|
items(options = {}) {
|
|
2523
4081
|
return flattenPages(this.pages(options), (value) => value);
|
|
2524
4082
|
}
|
|
4083
|
+
get search() {
|
|
4084
|
+
return new TracesSearchResource(this.transport, this.path + "/search");
|
|
4085
|
+
}
|
|
2525
4086
|
ref(value) {
|
|
2526
4087
|
return new TracesTraceIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
2527
4088
|
}
|
|
2528
4089
|
}
|
|
4090
|
+
export class TracesSearchResource {
|
|
4091
|
+
transport;
|
|
4092
|
+
path;
|
|
4093
|
+
constructor(transport, path) {
|
|
4094
|
+
this.transport = transport;
|
|
4095
|
+
this.path = path;
|
|
4096
|
+
}
|
|
4097
|
+
/** GET /api/v1/traces/search. Preserves response metadata; mutations are not replayed. */
|
|
4098
|
+
list(options) {
|
|
4099
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
4100
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
4101
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
4102
|
+
}
|
|
4103
|
+
pages(options) {
|
|
4104
|
+
const query = snapshot(options.query ?? {});
|
|
4105
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
4106
|
+
}
|
|
4107
|
+
items(options) {
|
|
4108
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
4109
|
+
}
|
|
4110
|
+
}
|
|
2529
4111
|
export class TracesTraceIdResource {
|
|
2530
4112
|
transport;
|
|
2531
4113
|
path;
|
|
@@ -2533,11 +4115,10 @@ export class TracesTraceIdResource {
|
|
|
2533
4115
|
this.transport = transport;
|
|
2534
4116
|
this.path = path;
|
|
2535
4117
|
}
|
|
2536
|
-
/** GET /api/v1/traces/{trace_id}. Preserves response metadata; mutations are not replayed. */
|
|
2537
4118
|
get(options = {}) {
|
|
2538
4119
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2539
4120
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
2540
|
-
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
4121
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
2541
4122
|
}
|
|
2542
4123
|
get spans() {
|
|
2543
4124
|
return new TracesTraceIdSpansResource(this.transport, this.path + "/spans");
|
|
@@ -2550,7 +4131,6 @@ export class TracesTraceIdSpansResource {
|
|
|
2550
4131
|
this.transport = transport;
|
|
2551
4132
|
this.path = path;
|
|
2552
4133
|
}
|
|
2553
|
-
/** GET /api/v1/traces/{trace_id}/spans. Preserves response metadata; mutations are not replayed. */
|
|
2554
4134
|
list(options = {}) {
|
|
2555
4135
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
2556
4136
|
.filter(([, value]) => value !== undefined && value !== null)
|
|
@@ -2563,6 +4143,40 @@ export class TracesTraceIdSpansResource {
|
|
|
2563
4143
|
items(options = {}) {
|
|
2564
4144
|
return flattenPages(this.pages(options), (value) => value);
|
|
2565
4145
|
}
|
|
4146
|
+
ref(value) {
|
|
4147
|
+
return new TracesTraceIdSpansSpanIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
4148
|
+
}
|
|
4149
|
+
}
|
|
4150
|
+
export class TracesTraceIdSpansSpanIdResource {
|
|
4151
|
+
transport;
|
|
4152
|
+
path;
|
|
4153
|
+
constructor(transport, path) {
|
|
4154
|
+
this.transport = transport;
|
|
4155
|
+
this.path = path;
|
|
4156
|
+
}
|
|
4157
|
+
/** GET /api/v1/traces/{trace_id}/spans/{span_id}. Preserves response metadata; mutations are not replayed. */
|
|
4158
|
+
get(options = {}) {
|
|
4159
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
4160
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
4161
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
4162
|
+
}
|
|
4163
|
+
get content() {
|
|
4164
|
+
return new TracesTraceIdSpansSpanIdContentResource(this.transport, this.path + "/content");
|
|
4165
|
+
}
|
|
4166
|
+
}
|
|
4167
|
+
export class TracesTraceIdSpansSpanIdContentResource {
|
|
4168
|
+
transport;
|
|
4169
|
+
path;
|
|
4170
|
+
constructor(transport, path) {
|
|
4171
|
+
this.transport = transport;
|
|
4172
|
+
this.path = path;
|
|
4173
|
+
}
|
|
4174
|
+
/** GET /api/v1/traces/{trace_id}/spans/{span_id}/content. Preserves response metadata; mutations are not replayed. */
|
|
4175
|
+
list(options = {}) {
|
|
4176
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
4177
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
4178
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
4179
|
+
}
|
|
2566
4180
|
}
|
|
2567
4181
|
export class UploadsResource {
|
|
2568
4182
|
transport;
|
|
@@ -2597,12 +4211,24 @@ export class UsageResource {
|
|
|
2597
4211
|
get agents() {
|
|
2598
4212
|
return new UsageAgentsResource(this.transport, this.path + "/agents");
|
|
2599
4213
|
}
|
|
4214
|
+
get context() {
|
|
4215
|
+
return new UsageContextResource(this.transport, this.path + "/context");
|
|
4216
|
+
}
|
|
4217
|
+
get members() {
|
|
4218
|
+
return new UsageMembersResource(this.transport, this.path + "/members");
|
|
4219
|
+
}
|
|
2600
4220
|
get models() {
|
|
2601
4221
|
return new UsageModelsResource(this.transport, this.path + "/models");
|
|
2602
4222
|
}
|
|
2603
4223
|
get overview() {
|
|
2604
4224
|
return new UsageOverviewResource(this.transport, this.path + "/overview");
|
|
2605
4225
|
}
|
|
4226
|
+
get records() {
|
|
4227
|
+
return new UsageRecordsResource(this.transport, this.path + "/records");
|
|
4228
|
+
}
|
|
4229
|
+
get runs() {
|
|
4230
|
+
return new UsageRunsResource(this.transport, this.path + "/runs");
|
|
4231
|
+
}
|
|
2606
4232
|
}
|
|
2607
4233
|
export class UsageAgentsResource {
|
|
2608
4234
|
transport;
|
|
@@ -2625,6 +4251,41 @@ export class UsageAgentsResource {
|
|
|
2625
4251
|
return flattenPages(this.pages(options), (value) => value);
|
|
2626
4252
|
}
|
|
2627
4253
|
}
|
|
4254
|
+
export class UsageContextResource {
|
|
4255
|
+
transport;
|
|
4256
|
+
path;
|
|
4257
|
+
constructor(transport, path) {
|
|
4258
|
+
this.transport = transport;
|
|
4259
|
+
this.path = path;
|
|
4260
|
+
}
|
|
4261
|
+
/** GET /api/v1/usage/context. Preserves response metadata; mutations are not replayed. */
|
|
4262
|
+
get(options = {}) {
|
|
4263
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
4264
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
4265
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
4266
|
+
}
|
|
4267
|
+
}
|
|
4268
|
+
export class UsageMembersResource {
|
|
4269
|
+
transport;
|
|
4270
|
+
path;
|
|
4271
|
+
constructor(transport, path) {
|
|
4272
|
+
this.transport = transport;
|
|
4273
|
+
this.path = path;
|
|
4274
|
+
}
|
|
4275
|
+
/** GET /api/v1/usage/members. Preserves response metadata; mutations are not replayed. */
|
|
4276
|
+
list(options) {
|
|
4277
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
4278
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
4279
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
4280
|
+
}
|
|
4281
|
+
pages(options) {
|
|
4282
|
+
const query = snapshot(options.query ?? {});
|
|
4283
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
4284
|
+
}
|
|
4285
|
+
items(options) {
|
|
4286
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
4287
|
+
}
|
|
4288
|
+
}
|
|
2628
4289
|
export class UsageModelsResource {
|
|
2629
4290
|
transport;
|
|
2630
4291
|
path;
|
|
@@ -2660,6 +4321,63 @@ export class UsageOverviewResource {
|
|
|
2660
4321
|
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
2661
4322
|
}
|
|
2662
4323
|
}
|
|
4324
|
+
export class UsageRecordsResource {
|
|
4325
|
+
transport;
|
|
4326
|
+
path;
|
|
4327
|
+
constructor(transport, path) {
|
|
4328
|
+
this.transport = transport;
|
|
4329
|
+
this.path = path;
|
|
4330
|
+
}
|
|
4331
|
+
ref(value) {
|
|
4332
|
+
return new UsageRecordsRecordIdResource(this.transport, this.path + "/" + encodeURIComponent(selector(String(value))));
|
|
4333
|
+
}
|
|
4334
|
+
}
|
|
4335
|
+
export class UsageRecordsRecordIdResource {
|
|
4336
|
+
transport;
|
|
4337
|
+
path;
|
|
4338
|
+
constructor(transport, path) {
|
|
4339
|
+
this.transport = transport;
|
|
4340
|
+
this.path = path;
|
|
4341
|
+
}
|
|
4342
|
+
get metrics() {
|
|
4343
|
+
return new UsageRecordsRecordIdMetricsResource(this.transport, this.path + "/metrics");
|
|
4344
|
+
}
|
|
4345
|
+
}
|
|
4346
|
+
export class UsageRecordsRecordIdMetricsResource {
|
|
4347
|
+
transport;
|
|
4348
|
+
path;
|
|
4349
|
+
constructor(transport, path) {
|
|
4350
|
+
this.transport = transport;
|
|
4351
|
+
this.path = path;
|
|
4352
|
+
}
|
|
4353
|
+
/** GET /api/v1/usage/records/{record_id}/metrics. Preserves response metadata; mutations are not replayed. */
|
|
4354
|
+
get(options = {}) {
|
|
4355
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
4356
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
4357
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
4358
|
+
}
|
|
4359
|
+
}
|
|
4360
|
+
export class UsageRunsResource {
|
|
4361
|
+
transport;
|
|
4362
|
+
path;
|
|
4363
|
+
constructor(transport, path) {
|
|
4364
|
+
this.transport = transport;
|
|
4365
|
+
this.path = path;
|
|
4366
|
+
}
|
|
4367
|
+
/** GET /api/v1/usage/runs. Preserves response metadata; mutations are not replayed. */
|
|
4368
|
+
list(options = {}) {
|
|
4369
|
+
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|
|
4370
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
4371
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal, query: options.query });
|
|
4372
|
+
}
|
|
4373
|
+
pages(options = {}) {
|
|
4374
|
+
const query = snapshot(options.query ?? {});
|
|
4375
|
+
return new PageIterator(query.cursor, (cursor) => this.list({ ...options, query: withCursor(query, cursor) }), (value) => value);
|
|
4376
|
+
}
|
|
4377
|
+
items(options = {}) {
|
|
4378
|
+
return flattenPages(this.pages(options), (value) => value);
|
|
4379
|
+
}
|
|
4380
|
+
}
|
|
2663
4381
|
export class UsersResource {
|
|
2664
4382
|
transport;
|
|
2665
4383
|
path;
|
|
@@ -2902,6 +4620,15 @@ export class WebProvidersProviderIdResource {
|
|
|
2902
4620
|
this.transport = transport;
|
|
2903
4621
|
this.path = path;
|
|
2904
4622
|
}
|
|
4623
|
+
/** DELETE /api/v1/web-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
4624
|
+
delete(options) {
|
|
4625
|
+
return jsonRequest(this.transport, "DELETE", this.path, undefined, Object.fromEntries(Object.entries({
|
|
4626
|
+
"If-Match": options.ifMatch,
|
|
4627
|
+
"X-Workspace-ID": options.xWorkspaceId,
|
|
4628
|
+
})
|
|
4629
|
+
.filter(([, value]) => value !== undefined && value !== null)
|
|
4630
|
+
.map(([key, value]) => [key, String(value)])), { signal: options.signal });
|
|
4631
|
+
}
|
|
2905
4632
|
/** GET /api/v1/web-providers/{provider_id}. Preserves response metadata; mutations are not replayed. */
|
|
2906
4633
|
get(options = {}) {
|
|
2907
4634
|
return jsonRequest(this.transport, "GET", this.path, undefined, Object.fromEntries(Object.entries({ "X-Workspace-ID": options.xWorkspaceId })
|