@getmodus/sdk 0.9.0 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +166 -0
- package/README.md +189 -14
- package/dist/{conversations-D7ffhHIh.d.cts → _client-base-DdnxB9JA.d.cts} +4425 -1674
- package/dist/{conversations-D7ffhHIh.d.ts → _client-base-DdnxB9JA.d.ts} +4425 -1674
- package/dist/chunk-3MHHVC6C.cjs +2678 -0
- package/dist/chunk-3MHHVC6C.cjs.map +1 -0
- package/dist/{chunk-SP4UYRYG.js → chunk-JVTQBBMZ.js} +613 -304
- package/dist/chunk-JVTQBBMZ.js.map +1 -0
- package/dist/index.cjs +585 -2800
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +802 -614
- package/dist/index.d.ts +802 -614
- package/dist/index.js +434 -300
- package/dist/index.js.map +1 -1
- package/dist/management/index.cjs +555 -2659
- package/dist/management/index.cjs.map +1 -1
- package/dist/management/index.d.cts +211 -42
- package/dist/management/index.d.ts +211 -42
- package/dist/management/index.js +291 -98
- package/dist/management/index.js.map +1 -1
- package/package.json +8 -1
- package/dist/chunk-SP4UYRYG.js.map +0 -1
|
@@ -8,7 +8,8 @@ var OPERATIONS = {
|
|
|
8
8
|
pathParams: [],
|
|
9
9
|
queryParams: ["pageToken", "pageSize", "type"],
|
|
10
10
|
requestSchema: null,
|
|
11
|
-
responseSchema: "ListConnectionsResponseDto"
|
|
11
|
+
responseSchema: "ListConnectionsResponseDto",
|
|
12
|
+
idempotent: false
|
|
12
13
|
},
|
|
13
14
|
"ConnectionsController_listSelections": {
|
|
14
15
|
method: "GET",
|
|
@@ -18,7 +19,8 @@ var OPERATIONS = {
|
|
|
18
19
|
pathParams: ["connectionId"],
|
|
19
20
|
queryParams: ["pageToken", "pageSize"],
|
|
20
21
|
requestSchema: null,
|
|
21
|
-
responseSchema: "ListConnectionSelectionsResponseDto"
|
|
22
|
+
responseSchema: "ListConnectionSelectionsResponseDto",
|
|
23
|
+
idempotent: false
|
|
22
24
|
},
|
|
23
25
|
"ContextCreatorsController_createLink": {
|
|
24
26
|
method: "POST",
|
|
@@ -28,7 +30,8 @@ var OPERATIONS = {
|
|
|
28
30
|
pathParams: [],
|
|
29
31
|
queryParams: [],
|
|
30
32
|
requestSchema: "CreateLinkDto",
|
|
31
|
-
responseSchema: "CreatedContextItemResponseDto"
|
|
33
|
+
responseSchema: "CreatedContextItemResponseDto",
|
|
34
|
+
idempotent: false
|
|
32
35
|
},
|
|
33
36
|
"ContextCreatorsController_createNote": {
|
|
34
37
|
method: "POST",
|
|
@@ -38,7 +41,8 @@ var OPERATIONS = {
|
|
|
38
41
|
pathParams: [],
|
|
39
42
|
queryParams: [],
|
|
40
43
|
requestSchema: "CreateNoteDto",
|
|
41
|
-
responseSchema: "CreatedContextItemResponseDto"
|
|
44
|
+
responseSchema: "CreatedContextItemResponseDto",
|
|
45
|
+
idempotent: false
|
|
42
46
|
},
|
|
43
47
|
"ContextCreatorsController_createSavedQuery": {
|
|
44
48
|
method: "POST",
|
|
@@ -48,7 +52,8 @@ var OPERATIONS = {
|
|
|
48
52
|
pathParams: [],
|
|
49
53
|
queryParams: [],
|
|
50
54
|
requestSchema: "CreateSavedQueryDto",
|
|
51
|
-
responseSchema: "CreatedContextItemResponseDto"
|
|
55
|
+
responseSchema: "CreatedContextItemResponseDto",
|
|
56
|
+
idempotent: false
|
|
52
57
|
},
|
|
53
58
|
"ContextFilesController_finalize": {
|
|
54
59
|
method: "POST",
|
|
@@ -58,7 +63,8 @@ var OPERATIONS = {
|
|
|
58
63
|
pathParams: ["uploadId"],
|
|
59
64
|
queryParams: [],
|
|
60
65
|
requestSchema: "FinalizeUploadDto",
|
|
61
|
-
responseSchema: "FileUploadResourceDto"
|
|
66
|
+
responseSchema: "FileUploadResourceDto",
|
|
67
|
+
idempotent: false
|
|
62
68
|
},
|
|
63
69
|
"ContextFilesController_finalizeMany": {
|
|
64
70
|
method: "POST",
|
|
@@ -68,7 +74,8 @@ var OPERATIONS = {
|
|
|
68
74
|
pathParams: [],
|
|
69
75
|
queryParams: [],
|
|
70
76
|
requestSchema: "BulkFinalizeDto",
|
|
71
|
-
responseSchema: "BulkFinalizeResponseDto"
|
|
77
|
+
responseSchema: "BulkFinalizeResponseDto",
|
|
78
|
+
idempotent: false
|
|
72
79
|
},
|
|
73
80
|
"ContextFilesController_get": {
|
|
74
81
|
method: "GET",
|
|
@@ -78,7 +85,8 @@ var OPERATIONS = {
|
|
|
78
85
|
pathParams: ["uploadId"],
|
|
79
86
|
queryParams: [],
|
|
80
87
|
requestSchema: null,
|
|
81
|
-
responseSchema: "FileUploadResourceDto"
|
|
88
|
+
responseSchema: "FileUploadResourceDto",
|
|
89
|
+
idempotent: false
|
|
82
90
|
},
|
|
83
91
|
"ContextFilesController_list": {
|
|
84
92
|
method: "GET",
|
|
@@ -88,7 +96,8 @@ var OPERATIONS = {
|
|
|
88
96
|
pathParams: [],
|
|
89
97
|
queryParams: ["pageToken", "pageSize"],
|
|
90
98
|
requestSchema: null,
|
|
91
|
-
responseSchema: "ListFilesResponseDto"
|
|
99
|
+
responseSchema: "ListFilesResponseDto",
|
|
100
|
+
idempotent: false
|
|
92
101
|
},
|
|
93
102
|
"ContextFilesController_uploadFromUrl": {
|
|
94
103
|
method: "POST",
|
|
@@ -98,7 +107,8 @@ var OPERATIONS = {
|
|
|
98
107
|
pathParams: [],
|
|
99
108
|
queryParams: [],
|
|
100
109
|
requestSchema: "UploadFromUrlDto",
|
|
101
|
-
responseSchema: "FileUploadResourceDto"
|
|
110
|
+
responseSchema: "FileUploadResourceDto",
|
|
111
|
+
idempotent: false
|
|
102
112
|
},
|
|
103
113
|
"ContextFilesController_uploadFromUrls": {
|
|
104
114
|
method: "POST",
|
|
@@ -108,7 +118,8 @@ var OPERATIONS = {
|
|
|
108
118
|
pathParams: [],
|
|
109
119
|
queryParams: [],
|
|
110
120
|
requestSchema: "BulkUploadFromUrlsDto",
|
|
111
|
-
responseSchema: "BulkUploadFromUrlsResponseDto"
|
|
121
|
+
responseSchema: "BulkUploadFromUrlsResponseDto",
|
|
122
|
+
idempotent: false
|
|
112
123
|
},
|
|
113
124
|
"ContextFilesController_uploadUrl": {
|
|
114
125
|
method: "POST",
|
|
@@ -118,7 +129,8 @@ var OPERATIONS = {
|
|
|
118
129
|
pathParams: [],
|
|
119
130
|
queryParams: [],
|
|
120
131
|
requestSchema: "UploadUrlDto",
|
|
121
|
-
responseSchema: "UploadUrlResponseDto"
|
|
132
|
+
responseSchema: "UploadUrlResponseDto",
|
|
133
|
+
idempotent: false
|
|
122
134
|
},
|
|
123
135
|
"ContextFilesController_uploadUrls": {
|
|
124
136
|
method: "POST",
|
|
@@ -128,7 +140,19 @@ var OPERATIONS = {
|
|
|
128
140
|
pathParams: [],
|
|
129
141
|
queryParams: [],
|
|
130
142
|
requestSchema: "BulkUploadUrlsDto",
|
|
131
|
-
responseSchema: "BulkUploadUrlsResponseDto"
|
|
143
|
+
responseSchema: "BulkUploadUrlsResponseDto",
|
|
144
|
+
idempotent: false
|
|
145
|
+
},
|
|
146
|
+
"ContextItemAccessController_updateAccess": {
|
|
147
|
+
method: "PATCH",
|
|
148
|
+
path: "/api/v1/context/items/{uid}/access",
|
|
149
|
+
service: "modus-api",
|
|
150
|
+
serverUrl: "https://api.getmodus.com",
|
|
151
|
+
pathParams: ["uid"],
|
|
152
|
+
queryParams: [],
|
|
153
|
+
requestSchema: "UpdateContextItemAccessDto",
|
|
154
|
+
responseSchema: "ContextItemAccessResponseDto",
|
|
155
|
+
idempotent: false
|
|
132
156
|
},
|
|
133
157
|
"ContextItemsController_delete": {
|
|
134
158
|
method: "DELETE",
|
|
@@ -138,7 +162,8 @@ var OPERATIONS = {
|
|
|
138
162
|
pathParams: ["uid"],
|
|
139
163
|
queryParams: [],
|
|
140
164
|
requestSchema: null,
|
|
141
|
-
responseSchema: "DeleteContextItemResponseDto"
|
|
165
|
+
responseSchema: "DeleteContextItemResponseDto",
|
|
166
|
+
idempotent: false
|
|
142
167
|
},
|
|
143
168
|
"ContextItemsController_get": {
|
|
144
169
|
method: "GET",
|
|
@@ -148,7 +173,8 @@ var OPERATIONS = {
|
|
|
148
173
|
pathParams: ["uid"],
|
|
149
174
|
queryParams: [],
|
|
150
175
|
requestSchema: null,
|
|
151
|
-
responseSchema: "ContextItemDto"
|
|
176
|
+
responseSchema: "ContextItemDto",
|
|
177
|
+
idempotent: false
|
|
152
178
|
},
|
|
153
179
|
"ContextItemsController_list": {
|
|
154
180
|
method: "GET",
|
|
@@ -158,7 +184,8 @@ var OPERATIONS = {
|
|
|
158
184
|
pathParams: [],
|
|
159
185
|
queryParams: ["pageToken", "pageSize", "contextTypes", "verificationStatuses", "searchQuery", "topics", "connectionIds", "parentUids", "ancestorUids"],
|
|
160
186
|
requestSchema: null,
|
|
161
|
-
responseSchema: "ListContextItemsResponseDto"
|
|
187
|
+
responseSchema: "ListContextItemsResponseDto",
|
|
188
|
+
idempotent: false
|
|
162
189
|
},
|
|
163
190
|
"ContextItemsController_listValues": {
|
|
164
191
|
method: "GET",
|
|
@@ -166,9 +193,10 @@ var OPERATIONS = {
|
|
|
166
193
|
service: "modus-api",
|
|
167
194
|
serverUrl: "https://api.getmodus.com",
|
|
168
195
|
pathParams: ["uid"],
|
|
169
|
-
queryParams: ["contextType", "contentKeyPath", "pageSize", "
|
|
196
|
+
queryParams: ["contextType", "contentKeyPath", "pageSize", "pageToken", "searchQuery"],
|
|
170
197
|
requestSchema: null,
|
|
171
|
-
responseSchema: "ListContextItemValuesResponseDto"
|
|
198
|
+
responseSchema: "ListContextItemValuesResponseDto",
|
|
199
|
+
idempotent: false
|
|
172
200
|
},
|
|
173
201
|
"ContextItemsController_lookup": {
|
|
174
202
|
method: "POST",
|
|
@@ -178,7 +206,8 @@ var OPERATIONS = {
|
|
|
178
206
|
pathParams: [],
|
|
179
207
|
queryParams: [],
|
|
180
208
|
requestSchema: "LookupContextItemDto",
|
|
181
|
-
responseSchema: "LookupContextItemResponseDto"
|
|
209
|
+
responseSchema: "LookupContextItemResponseDto",
|
|
210
|
+
idempotent: true
|
|
182
211
|
},
|
|
183
212
|
"ContextItemsController_move": {
|
|
184
213
|
method: "POST",
|
|
@@ -188,7 +217,8 @@ var OPERATIONS = {
|
|
|
188
217
|
pathParams: ["uid"],
|
|
189
218
|
queryParams: [],
|
|
190
219
|
requestSchema: "MoveContextItemDto",
|
|
191
|
-
responseSchema: "MoveContextItemResponseDto"
|
|
220
|
+
responseSchema: "MoveContextItemResponseDto",
|
|
221
|
+
idempotent: false
|
|
192
222
|
},
|
|
193
223
|
"ContextItemsController_update": {
|
|
194
224
|
method: "PATCH",
|
|
@@ -198,7 +228,19 @@ var OPERATIONS = {
|
|
|
198
228
|
pathParams: ["uid"],
|
|
199
229
|
queryParams: ["updateMask"],
|
|
200
230
|
requestSchema: "UpdateContextItemDto",
|
|
201
|
-
responseSchema: null
|
|
231
|
+
responseSchema: null,
|
|
232
|
+
idempotent: false
|
|
233
|
+
},
|
|
234
|
+
"ContextItemsQueryController_query": {
|
|
235
|
+
method: "POST",
|
|
236
|
+
path: "/api/v1/context/items/query",
|
|
237
|
+
service: "modus-api",
|
|
238
|
+
serverUrl: "https://api.getmodus.com",
|
|
239
|
+
pathParams: [],
|
|
240
|
+
queryParams: [],
|
|
241
|
+
requestSchema: "QueryContextItemsRequestDto",
|
|
242
|
+
responseSchema: "QueryContextItemsResponseDto",
|
|
243
|
+
idempotent: true
|
|
202
244
|
},
|
|
203
245
|
"CustomContextItemsController_batchCreate": {
|
|
204
246
|
method: "POST",
|
|
@@ -208,7 +250,8 @@ var OPERATIONS = {
|
|
|
208
250
|
pathParams: [],
|
|
209
251
|
queryParams: [],
|
|
210
252
|
requestSchema: "BatchCreateCustomContextItemsDto",
|
|
211
|
-
responseSchema: "BatchCreateCustomContextItemsResponseDto"
|
|
253
|
+
responseSchema: "BatchCreateCustomContextItemsResponseDto",
|
|
254
|
+
idempotent: false
|
|
212
255
|
},
|
|
213
256
|
"CustomContextItemsController_create": {
|
|
214
257
|
method: "POST",
|
|
@@ -218,7 +261,8 @@ var OPERATIONS = {
|
|
|
218
261
|
pathParams: [],
|
|
219
262
|
queryParams: [],
|
|
220
263
|
requestSchema: "CreateCustomContextItemDto",
|
|
221
|
-
responseSchema: "CreatedCustomContextItemResponseDto"
|
|
264
|
+
responseSchema: "CreatedCustomContextItemResponseDto",
|
|
265
|
+
idempotent: false
|
|
222
266
|
},
|
|
223
267
|
"CustomContextItemsController_createRelations": {
|
|
224
268
|
method: "POST",
|
|
@@ -228,7 +272,8 @@ var OPERATIONS = {
|
|
|
228
272
|
pathParams: [],
|
|
229
273
|
queryParams: [],
|
|
230
274
|
requestSchema: "BatchCreateCustomContextItemRelationsDto",
|
|
231
|
-
responseSchema: "BatchCreateCustomContextItemRelationsResponseDto"
|
|
275
|
+
responseSchema: "BatchCreateCustomContextItemRelationsResponseDto",
|
|
276
|
+
idempotent: false
|
|
232
277
|
},
|
|
233
278
|
"CustomContextItemsController_delete": {
|
|
234
279
|
method: "DELETE",
|
|
@@ -238,7 +283,8 @@ var OPERATIONS = {
|
|
|
238
283
|
pathParams: ["uid"],
|
|
239
284
|
queryParams: [],
|
|
240
285
|
requestSchema: null,
|
|
241
|
-
responseSchema: "DeleteContextItemResponseDto"
|
|
286
|
+
responseSchema: "DeleteContextItemResponseDto",
|
|
287
|
+
idempotent: false
|
|
242
288
|
},
|
|
243
289
|
"CustomContextItemsController_get": {
|
|
244
290
|
method: "GET",
|
|
@@ -248,7 +294,8 @@ var OPERATIONS = {
|
|
|
248
294
|
pathParams: ["uid"],
|
|
249
295
|
queryParams: [],
|
|
250
296
|
requestSchema: null,
|
|
251
|
-
responseSchema: "ContextItemDto"
|
|
297
|
+
responseSchema: "ContextItemDto",
|
|
298
|
+
idempotent: false
|
|
252
299
|
},
|
|
253
300
|
"CustomContextItemsController_list": {
|
|
254
301
|
method: "GET",
|
|
@@ -258,7 +305,8 @@ var OPERATIONS = {
|
|
|
258
305
|
pathParams: [],
|
|
259
306
|
queryParams: ["pageToken", "pageSize", "contextTypes", "verificationStatuses", "searchQuery", "topics"],
|
|
260
307
|
requestSchema: null,
|
|
261
|
-
responseSchema: "ListCustomContextItemsResponseDto"
|
|
308
|
+
responseSchema: "ListCustomContextItemsResponseDto",
|
|
309
|
+
idempotent: false
|
|
262
310
|
},
|
|
263
311
|
"CustomContextItemsController_update": {
|
|
264
312
|
method: "PATCH",
|
|
@@ -268,7 +316,8 @@ var OPERATIONS = {
|
|
|
268
316
|
pathParams: ["uid"],
|
|
269
317
|
queryParams: [],
|
|
270
318
|
requestSchema: "UpdateCustomContextItemDto",
|
|
271
|
-
responseSchema: null
|
|
319
|
+
responseSchema: null,
|
|
320
|
+
idempotent: false
|
|
272
321
|
},
|
|
273
322
|
"DashboardsController_acceptOwnership": {
|
|
274
323
|
method: "POST",
|
|
@@ -278,7 +327,8 @@ var OPERATIONS = {
|
|
|
278
327
|
pathParams: ["dashboardId"],
|
|
279
328
|
queryParams: [],
|
|
280
329
|
requestSchema: null,
|
|
281
|
-
responseSchema: "DashboardDto"
|
|
330
|
+
responseSchema: "DashboardDto",
|
|
331
|
+
idempotent: false
|
|
282
332
|
},
|
|
283
333
|
"DashboardsController_cancelOwnership": {
|
|
284
334
|
method: "DELETE",
|
|
@@ -288,7 +338,8 @@ var OPERATIONS = {
|
|
|
288
338
|
pathParams: ["dashboardId"],
|
|
289
339
|
queryParams: [],
|
|
290
340
|
requestSchema: null,
|
|
291
|
-
responseSchema: "DashboardDto"
|
|
341
|
+
responseSchema: "DashboardDto",
|
|
342
|
+
idempotent: false
|
|
292
343
|
},
|
|
293
344
|
"DashboardsController_create": {
|
|
294
345
|
method: "POST",
|
|
@@ -298,7 +349,8 @@ var OPERATIONS = {
|
|
|
298
349
|
pathParams: [],
|
|
299
350
|
queryParams: [],
|
|
300
351
|
requestSchema: "CreateDashboardDto",
|
|
301
|
-
responseSchema: "DashboardDto"
|
|
352
|
+
responseSchema: "DashboardDto",
|
|
353
|
+
idempotent: false
|
|
302
354
|
},
|
|
303
355
|
"DashboardsController_createElement": {
|
|
304
356
|
method: "POST",
|
|
@@ -308,7 +360,8 @@ var OPERATIONS = {
|
|
|
308
360
|
pathParams: ["dashboardId"],
|
|
309
361
|
queryParams: [],
|
|
310
362
|
requestSchema: "CreateDashboardElementDto",
|
|
311
|
-
responseSchema: "DashboardElementResponseDto"
|
|
363
|
+
responseSchema: "DashboardElementResponseDto",
|
|
364
|
+
idempotent: false
|
|
312
365
|
},
|
|
313
366
|
"DashboardsController_delete": {
|
|
314
367
|
method: "DELETE",
|
|
@@ -318,7 +371,8 @@ var OPERATIONS = {
|
|
|
318
371
|
pathParams: ["dashboardId"],
|
|
319
372
|
queryParams: [],
|
|
320
373
|
requestSchema: null,
|
|
321
|
-
responseSchema: null
|
|
374
|
+
responseSchema: null,
|
|
375
|
+
idempotent: false
|
|
322
376
|
},
|
|
323
377
|
"DashboardsController_get": {
|
|
324
378
|
method: "GET",
|
|
@@ -328,7 +382,8 @@ var OPERATIONS = {
|
|
|
328
382
|
pathParams: ["dashboardId"],
|
|
329
383
|
queryParams: ["view"],
|
|
330
384
|
requestSchema: null,
|
|
331
|
-
responseSchema: "DashboardDto"
|
|
385
|
+
responseSchema: "DashboardDto",
|
|
386
|
+
idempotent: false
|
|
332
387
|
},
|
|
333
388
|
"DashboardsController_getElement": {
|
|
334
389
|
method: "GET",
|
|
@@ -338,7 +393,8 @@ var OPERATIONS = {
|
|
|
338
393
|
pathParams: ["dashboardId", "elementId"],
|
|
339
394
|
queryParams: [],
|
|
340
395
|
requestSchema: null,
|
|
341
|
-
responseSchema: "DashboardElementResponseDto"
|
|
396
|
+
responseSchema: "DashboardElementResponseDto",
|
|
397
|
+
idempotent: false
|
|
342
398
|
},
|
|
343
399
|
"DashboardsController_getVersion": {
|
|
344
400
|
method: "GET",
|
|
@@ -348,7 +404,8 @@ var OPERATIONS = {
|
|
|
348
404
|
pathParams: ["dashboardId", "versionId"],
|
|
349
405
|
queryParams: [],
|
|
350
406
|
requestSchema: null,
|
|
351
|
-
responseSchema: "DashboardDto"
|
|
407
|
+
responseSchema: "DashboardDto",
|
|
408
|
+
idempotent: false
|
|
352
409
|
},
|
|
353
410
|
"DashboardsController_list": {
|
|
354
411
|
method: "GET",
|
|
@@ -358,7 +415,8 @@ var OPERATIONS = {
|
|
|
358
415
|
pathParams: [],
|
|
359
416
|
queryParams: ["view"],
|
|
360
417
|
requestSchema: null,
|
|
361
|
-
responseSchema: "ListDashboardsResponseDto"
|
|
418
|
+
responseSchema: "ListDashboardsResponseDto",
|
|
419
|
+
idempotent: false
|
|
362
420
|
},
|
|
363
421
|
"DashboardsController_listDraftSnapshots": {
|
|
364
422
|
method: "GET",
|
|
@@ -368,7 +426,8 @@ var OPERATIONS = {
|
|
|
368
426
|
pathParams: ["dashboardId"],
|
|
369
427
|
queryParams: [],
|
|
370
428
|
requestSchema: null,
|
|
371
|
-
responseSchema: "ListDashboardDraftSnapshotsResponseDto"
|
|
429
|
+
responseSchema: "ListDashboardDraftSnapshotsResponseDto",
|
|
430
|
+
idempotent: false
|
|
372
431
|
},
|
|
373
432
|
"DashboardsController_listElements": {
|
|
374
433
|
method: "GET",
|
|
@@ -378,7 +437,8 @@ var OPERATIONS = {
|
|
|
378
437
|
pathParams: ["dashboardId"],
|
|
379
438
|
queryParams: [],
|
|
380
439
|
requestSchema: null,
|
|
381
|
-
responseSchema: "DashboardElementsListResponseDto"
|
|
440
|
+
responseSchema: "DashboardElementsListResponseDto",
|
|
441
|
+
idempotent: false
|
|
382
442
|
},
|
|
383
443
|
"DashboardsController_listVersions": {
|
|
384
444
|
method: "GET",
|
|
@@ -388,7 +448,8 @@ var OPERATIONS = {
|
|
|
388
448
|
pathParams: ["dashboardId"],
|
|
389
449
|
queryParams: [],
|
|
390
450
|
requestSchema: null,
|
|
391
|
-
responseSchema: "ListDashboardVersionsResponseDto"
|
|
451
|
+
responseSchema: "ListDashboardVersionsResponseDto",
|
|
452
|
+
idempotent: false
|
|
392
453
|
},
|
|
393
454
|
"DashboardsController_publish": {
|
|
394
455
|
method: "POST",
|
|
@@ -398,7 +459,8 @@ var OPERATIONS = {
|
|
|
398
459
|
pathParams: ["dashboardId"],
|
|
399
460
|
queryParams: [],
|
|
400
461
|
requestSchema: "PublishDashboardDto",
|
|
401
|
-
responseSchema: "PublishDashboardResponseDto"
|
|
462
|
+
responseSchema: "PublishDashboardResponseDto",
|
|
463
|
+
idempotent: false
|
|
402
464
|
},
|
|
403
465
|
"DashboardsController_restore": {
|
|
404
466
|
method: "POST",
|
|
@@ -408,7 +470,8 @@ var OPERATIONS = {
|
|
|
408
470
|
pathParams: ["dashboardId", "versionId"],
|
|
409
471
|
queryParams: [],
|
|
410
472
|
requestSchema: null,
|
|
411
|
-
responseSchema: "DashboardDto"
|
|
473
|
+
responseSchema: "DashboardDto",
|
|
474
|
+
idempotent: false
|
|
412
475
|
},
|
|
413
476
|
"DashboardsController_transferOwnership": {
|
|
414
477
|
method: "POST",
|
|
@@ -418,7 +481,8 @@ var OPERATIONS = {
|
|
|
418
481
|
pathParams: ["dashboardId"],
|
|
419
482
|
queryParams: [],
|
|
420
483
|
requestSchema: "TransferDashboardOwnershipDto",
|
|
421
|
-
responseSchema: "DashboardDto"
|
|
484
|
+
responseSchema: "DashboardDto",
|
|
485
|
+
idempotent: false
|
|
422
486
|
},
|
|
423
487
|
"DashboardsController_updateAccess": {
|
|
424
488
|
method: "PATCH",
|
|
@@ -428,7 +492,8 @@ var OPERATIONS = {
|
|
|
428
492
|
pathParams: ["dashboardId"],
|
|
429
493
|
queryParams: [],
|
|
430
494
|
requestSchema: "UpdateDashboardAccessDto",
|
|
431
|
-
responseSchema: "DashboardDto"
|
|
495
|
+
responseSchema: "DashboardDto",
|
|
496
|
+
idempotent: false
|
|
432
497
|
},
|
|
433
498
|
"DashboardsController_updateDraft": {
|
|
434
499
|
method: "PATCH",
|
|
@@ -438,7 +503,8 @@ var OPERATIONS = {
|
|
|
438
503
|
pathParams: ["dashboardId"],
|
|
439
504
|
queryParams: [],
|
|
440
505
|
requestSchema: "UpdateDashboardDraftDto",
|
|
441
|
-
responseSchema: "DashboardDto"
|
|
506
|
+
responseSchema: "DashboardDto",
|
|
507
|
+
idempotent: false
|
|
442
508
|
},
|
|
443
509
|
"DashboardsController_updateElement": {
|
|
444
510
|
method: "PATCH",
|
|
@@ -448,7 +514,8 @@ var OPERATIONS = {
|
|
|
448
514
|
pathParams: ["dashboardId", "elementId"],
|
|
449
515
|
queryParams: [],
|
|
450
516
|
requestSchema: "UpdateDashboardElementDto",
|
|
451
|
-
responseSchema: "DashboardDto"
|
|
517
|
+
responseSchema: "DashboardDto",
|
|
518
|
+
idempotent: false
|
|
452
519
|
},
|
|
453
520
|
"DashboardsController_updateLayout": {
|
|
454
521
|
method: "PATCH",
|
|
@@ -458,7 +525,8 @@ var OPERATIONS = {
|
|
|
458
525
|
pathParams: ["dashboardId"],
|
|
459
526
|
queryParams: [],
|
|
460
527
|
requestSchema: "UpdateDashboardLayoutDto",
|
|
461
|
-
responseSchema: "DashboardDto"
|
|
528
|
+
responseSchema: "DashboardDto",
|
|
529
|
+
idempotent: false
|
|
462
530
|
},
|
|
463
531
|
"EvaluationsController_getConfig": {
|
|
464
532
|
method: "GET",
|
|
@@ -468,7 +536,8 @@ var OPERATIONS = {
|
|
|
468
536
|
pathParams: ["id"],
|
|
469
537
|
queryParams: [],
|
|
470
538
|
requestSchema: null,
|
|
471
|
-
responseSchema: "EvaluationConfigDto"
|
|
539
|
+
responseSchema: "EvaluationConfigDto",
|
|
540
|
+
idempotent: false
|
|
472
541
|
},
|
|
473
542
|
"EvaluationsController_getRun": {
|
|
474
543
|
method: "GET",
|
|
@@ -478,7 +547,8 @@ var OPERATIONS = {
|
|
|
478
547
|
pathParams: ["id", "runId"],
|
|
479
548
|
queryParams: [],
|
|
480
549
|
requestSchema: null,
|
|
481
|
-
responseSchema: "EvaluationRunWithResultsDto"
|
|
550
|
+
responseSchema: "EvaluationRunWithResultsDto",
|
|
551
|
+
idempotent: false
|
|
482
552
|
},
|
|
483
553
|
"EvaluationsController_listRuns": {
|
|
484
554
|
method: "GET",
|
|
@@ -488,7 +558,8 @@ var OPERATIONS = {
|
|
|
488
558
|
pathParams: ["id"],
|
|
489
559
|
queryParams: ["pageSize", "pageToken"],
|
|
490
560
|
requestSchema: null,
|
|
491
|
-
responseSchema: "ListEvaluationRunsResponseDto"
|
|
561
|
+
responseSchema: "ListEvaluationRunsResponseDto",
|
|
562
|
+
idempotent: false
|
|
492
563
|
},
|
|
493
564
|
"EvaluationsController_triggerRun": {
|
|
494
565
|
method: "POST",
|
|
@@ -498,7 +569,8 @@ var OPERATIONS = {
|
|
|
498
569
|
pathParams: ["id"],
|
|
499
570
|
queryParams: [],
|
|
500
571
|
requestSchema: null,
|
|
501
|
-
responseSchema: "TriggerEvaluationRunResponseDto"
|
|
572
|
+
responseSchema: "TriggerEvaluationRunResponseDto",
|
|
573
|
+
idempotent: false
|
|
502
574
|
},
|
|
503
575
|
"EvaluationsController_updateConfig": {
|
|
504
576
|
method: "PUT",
|
|
@@ -508,7 +580,8 @@ var OPERATIONS = {
|
|
|
508
580
|
pathParams: ["id"],
|
|
509
581
|
queryParams: [],
|
|
510
582
|
requestSchema: "UpdateEvaluationConfigDto",
|
|
511
|
-
responseSchema: "EvaluationConfigDto"
|
|
583
|
+
responseSchema: "EvaluationConfigDto",
|
|
584
|
+
idempotent: false
|
|
512
585
|
},
|
|
513
586
|
"IngestedDataController_upload": {
|
|
514
587
|
method: "POST",
|
|
@@ -518,7 +591,8 @@ var OPERATIONS = {
|
|
|
518
591
|
pathParams: [],
|
|
519
592
|
queryParams: [],
|
|
520
593
|
requestSchema: "CreateIngestedDataDto",
|
|
521
|
-
responseSchema: "CreatedIngestedDataResponseDto"
|
|
594
|
+
responseSchema: "CreatedIngestedDataResponseDto",
|
|
595
|
+
idempotent: true
|
|
522
596
|
},
|
|
523
597
|
"MemberGroupsController_list": {
|
|
524
598
|
method: "GET",
|
|
@@ -528,27 +602,19 @@ var OPERATIONS = {
|
|
|
528
602
|
pathParams: [],
|
|
529
603
|
queryParams: [],
|
|
530
604
|
requestSchema: null,
|
|
531
|
-
responseSchema: "ListMemberGroupsResponseDto"
|
|
605
|
+
responseSchema: "ListMemberGroupsResponseDto",
|
|
606
|
+
idempotent: false
|
|
532
607
|
},
|
|
533
|
-
"
|
|
608
|
+
"ModusContextComposeController_compose": {
|
|
534
609
|
method: "POST",
|
|
535
|
-
path: "/
|
|
536
|
-
service: "
|
|
537
|
-
serverUrl: "https://
|
|
610
|
+
path: "/agent/v1/modus/context",
|
|
611
|
+
service: "agent-service",
|
|
612
|
+
serverUrl: "https://agent.getmodus.com",
|
|
538
613
|
pathParams: [],
|
|
539
614
|
queryParams: [],
|
|
540
|
-
requestSchema: "
|
|
541
|
-
responseSchema: "
|
|
542
|
-
|
|
543
|
-
"ModusChatController_chatContinue": {
|
|
544
|
-
method: "POST",
|
|
545
|
-
path: "/api/v1/modus/conversations/{threadId}/chat",
|
|
546
|
-
service: "modus-api",
|
|
547
|
-
serverUrl: "https://api.getmodus.com",
|
|
548
|
-
pathParams: ["threadId"],
|
|
549
|
-
queryParams: [],
|
|
550
|
-
requestSchema: "ModusChatRequestDto",
|
|
551
|
-
responseSchema: "ModusChatResponseDto"
|
|
615
|
+
requestSchema: "ModusContextRequestDto",
|
|
616
|
+
responseSchema: "ModusContextResponseDto",
|
|
617
|
+
idempotent: true
|
|
552
618
|
},
|
|
553
619
|
"ModusContextController_compose": {
|
|
554
620
|
method: "POST",
|
|
@@ -558,7 +624,8 @@ var OPERATIONS = {
|
|
|
558
624
|
pathParams: [],
|
|
559
625
|
queryParams: [],
|
|
560
626
|
requestSchema: "ModusContextRequestDto",
|
|
561
|
-
responseSchema: "ModusContextResponseDto"
|
|
627
|
+
responseSchema: "ModusContextResponseDto",
|
|
628
|
+
idempotent: false
|
|
562
629
|
},
|
|
563
630
|
"ModusConversationsController_get": {
|
|
564
631
|
method: "GET",
|
|
@@ -568,7 +635,8 @@ var OPERATIONS = {
|
|
|
568
635
|
pathParams: ["threadId"],
|
|
569
636
|
queryParams: [],
|
|
570
637
|
requestSchema: null,
|
|
571
|
-
responseSchema: "ConversationDto"
|
|
638
|
+
responseSchema: "ConversationDto",
|
|
639
|
+
idempotent: false
|
|
572
640
|
},
|
|
573
641
|
"ModusConversationsController_list": {
|
|
574
642
|
method: "GET",
|
|
@@ -578,7 +646,8 @@ var OPERATIONS = {
|
|
|
578
646
|
pathParams: [],
|
|
579
647
|
queryParams: ["pageToken", "page", "pageSize", "userId", "toolName", "source", "sourceRef", "timeframe", "includeTools", "kind"],
|
|
580
648
|
requestSchema: null,
|
|
581
|
-
responseSchema: "ListConversationsResponseDto"
|
|
649
|
+
responseSchema: "ListConversationsResponseDto",
|
|
650
|
+
idempotent: false
|
|
582
651
|
},
|
|
583
652
|
"ModusRunsController_create": {
|
|
584
653
|
method: "POST",
|
|
@@ -588,7 +657,8 @@ var OPERATIONS = {
|
|
|
588
657
|
pathParams: [],
|
|
589
658
|
queryParams: [],
|
|
590
659
|
requestSchema: "ModusRunDto",
|
|
591
|
-
responseSchema: null
|
|
660
|
+
responseSchema: null,
|
|
661
|
+
idempotent: false
|
|
592
662
|
},
|
|
593
663
|
"OrgMembersController_list": {
|
|
594
664
|
method: "GET",
|
|
@@ -598,7 +668,8 @@ var OPERATIONS = {
|
|
|
598
668
|
pathParams: [],
|
|
599
669
|
queryParams: [],
|
|
600
670
|
requestSchema: null,
|
|
601
|
-
responseSchema: "ListOrgMembersResponseDto"
|
|
671
|
+
responseSchema: "ListOrgMembersResponseDto",
|
|
672
|
+
idempotent: false
|
|
602
673
|
},
|
|
603
674
|
"ResumeRunsController_create": {
|
|
604
675
|
method: "POST",
|
|
@@ -608,7 +679,8 @@ var OPERATIONS = {
|
|
|
608
679
|
pathParams: ["runId"],
|
|
609
680
|
queryParams: [],
|
|
610
681
|
requestSchema: "ResumeRunDto",
|
|
611
|
-
responseSchema: null
|
|
682
|
+
responseSchema: null,
|
|
683
|
+
idempotent: false
|
|
612
684
|
},
|
|
613
685
|
"RunLifecycleController_active": {
|
|
614
686
|
method: "GET",
|
|
@@ -618,7 +690,8 @@ var OPERATIONS = {
|
|
|
618
690
|
pathParams: [],
|
|
619
691
|
queryParams: ["pageToken", "pageSize"],
|
|
620
692
|
requestSchema: null,
|
|
621
|
-
responseSchema: "ActiveRunsResponseDto"
|
|
693
|
+
responseSchema: "ActiveRunsResponseDto",
|
|
694
|
+
idempotent: false
|
|
622
695
|
},
|
|
623
696
|
"RunLifecycleController_activeBySession": {
|
|
624
697
|
method: "POST",
|
|
@@ -628,7 +701,8 @@ var OPERATIONS = {
|
|
|
628
701
|
pathParams: [],
|
|
629
702
|
queryParams: [],
|
|
630
703
|
requestSchema: "ActiveRunsBySessionDto",
|
|
631
|
-
responseSchema: "ActiveRunsBySessionResponseDto"
|
|
704
|
+
responseSchema: "ActiveRunsBySessionResponseDto",
|
|
705
|
+
idempotent: true
|
|
632
706
|
},
|
|
633
707
|
"RunLifecycleController_cancel": {
|
|
634
708
|
method: "POST",
|
|
@@ -638,7 +712,8 @@ var OPERATIONS = {
|
|
|
638
712
|
pathParams: ["runId"],
|
|
639
713
|
queryParams: [],
|
|
640
714
|
requestSchema: "CancelRunDto",
|
|
641
|
-
responseSchema: null
|
|
715
|
+
responseSchema: null,
|
|
716
|
+
idempotent: true
|
|
642
717
|
},
|
|
643
718
|
"RunLifecycleController_editQueued": {
|
|
644
719
|
method: "POST",
|
|
@@ -648,7 +723,8 @@ var OPERATIONS = {
|
|
|
648
723
|
pathParams: ["runId"],
|
|
649
724
|
queryParams: [],
|
|
650
725
|
requestSchema: "EditQueuedRunDto",
|
|
651
|
-
responseSchema:
|
|
726
|
+
responseSchema: "RunAdmissionResponseDto",
|
|
727
|
+
idempotent: false
|
|
652
728
|
},
|
|
653
729
|
"RunLifecycleController_events": {
|
|
654
730
|
method: "GET",
|
|
@@ -658,7 +734,8 @@ var OPERATIONS = {
|
|
|
658
734
|
pathParams: ["runId"],
|
|
659
735
|
queryParams: [],
|
|
660
736
|
requestSchema: null,
|
|
661
|
-
responseSchema:
|
|
737
|
+
responseSchema: "RunEventsPollResponseDto",
|
|
738
|
+
idempotent: false
|
|
662
739
|
},
|
|
663
740
|
"RunLifecycleController_interrupt": {
|
|
664
741
|
method: "POST",
|
|
@@ -668,7 +745,8 @@ var OPERATIONS = {
|
|
|
668
745
|
pathParams: ["runId"],
|
|
669
746
|
queryParams: [],
|
|
670
747
|
requestSchema: "InterruptRunDto",
|
|
671
|
-
responseSchema:
|
|
748
|
+
responseSchema: "RunAdmissionResponseDto",
|
|
749
|
+
idempotent: true
|
|
672
750
|
},
|
|
673
751
|
"RunLifecycleController_stream": {
|
|
674
752
|
method: "GET",
|
|
@@ -678,27 +756,19 @@ var OPERATIONS = {
|
|
|
678
756
|
pathParams: ["runId"],
|
|
679
757
|
queryParams: [],
|
|
680
758
|
requestSchema: null,
|
|
681
|
-
responseSchema: null
|
|
759
|
+
responseSchema: null,
|
|
760
|
+
idempotent: false
|
|
682
761
|
},
|
|
683
|
-
"
|
|
762
|
+
"ScopeContextComposeController_compose": {
|
|
684
763
|
method: "POST",
|
|
685
|
-
path: "/
|
|
686
|
-
service: "
|
|
687
|
-
serverUrl: "https://
|
|
764
|
+
path: "/agent/v1/scopes/{id}/context",
|
|
765
|
+
service: "agent-service",
|
|
766
|
+
serverUrl: "https://agent.getmodus.com",
|
|
688
767
|
pathParams: ["id"],
|
|
689
768
|
queryParams: [],
|
|
690
|
-
requestSchema: "
|
|
691
|
-
responseSchema: "
|
|
692
|
-
|
|
693
|
-
"ScopeChatController_chatContinue": {
|
|
694
|
-
method: "POST",
|
|
695
|
-
path: "/api/v1/scopes/{id}/conversations/{threadId}/chat",
|
|
696
|
-
service: "modus-api",
|
|
697
|
-
serverUrl: "https://api.getmodus.com",
|
|
698
|
-
pathParams: ["id", "threadId"],
|
|
699
|
-
queryParams: [],
|
|
700
|
-
requestSchema: "SkillChatRequestDto",
|
|
701
|
-
responseSchema: "SkillChatResponseDto"
|
|
769
|
+
requestSchema: "ComposeSkillContextRequestDto",
|
|
770
|
+
responseSchema: "ComposeSkillContextResponseDto",
|
|
771
|
+
idempotent: true
|
|
702
772
|
},
|
|
703
773
|
"ScopeContextController_compose": {
|
|
704
774
|
method: "POST",
|
|
@@ -708,7 +778,8 @@ var OPERATIONS = {
|
|
|
708
778
|
pathParams: ["id"],
|
|
709
779
|
queryParams: [],
|
|
710
780
|
requestSchema: "ComposeSkillContextRequestDto",
|
|
711
|
-
responseSchema: "ComposeSkillContextResponseDto"
|
|
781
|
+
responseSchema: "ComposeSkillContextResponseDto",
|
|
782
|
+
idempotent: false
|
|
712
783
|
},
|
|
713
784
|
"ScopeConversationsController_get": {
|
|
714
785
|
method: "GET",
|
|
@@ -718,7 +789,8 @@ var OPERATIONS = {
|
|
|
718
789
|
pathParams: ["id", "threadId"],
|
|
719
790
|
queryParams: ["messageLimit", "beforeMessageIndex"],
|
|
720
791
|
requestSchema: null,
|
|
721
|
-
responseSchema: "ConversationDto"
|
|
792
|
+
responseSchema: "ConversationDto",
|
|
793
|
+
idempotent: false
|
|
722
794
|
},
|
|
723
795
|
"ScopeConversationsController_list": {
|
|
724
796
|
method: "GET",
|
|
@@ -728,7 +800,8 @@ var OPERATIONS = {
|
|
|
728
800
|
pathParams: ["id"],
|
|
729
801
|
queryParams: ["pageToken", "page", "pageSize", "userId", "toolName", "source", "sourceRef", "timeframe", "includeTools"],
|
|
730
802
|
requestSchema: null,
|
|
731
|
-
responseSchema: "ListConversationsResponseDto"
|
|
803
|
+
responseSchema: "ListConversationsResponseDto",
|
|
804
|
+
idempotent: false
|
|
732
805
|
},
|
|
733
806
|
"ScopeInterfacesController_add": {
|
|
734
807
|
method: "POST",
|
|
@@ -738,7 +811,8 @@ var OPERATIONS = {
|
|
|
738
811
|
pathParams: ["id"],
|
|
739
812
|
queryParams: [],
|
|
740
813
|
requestSchema: "AddScopeInterfaceDto",
|
|
741
|
-
responseSchema: "ScopeInterfaceDto"
|
|
814
|
+
responseSchema: "ScopeInterfaceDto",
|
|
815
|
+
idempotent: false
|
|
742
816
|
},
|
|
743
817
|
"ScopeInterfacesController_delete": {
|
|
744
818
|
method: "DELETE",
|
|
@@ -748,7 +822,8 @@ var OPERATIONS = {
|
|
|
748
822
|
pathParams: ["id", "interfaceId"],
|
|
749
823
|
queryParams: [],
|
|
750
824
|
requestSchema: null,
|
|
751
|
-
responseSchema: null
|
|
825
|
+
responseSchema: null,
|
|
826
|
+
idempotent: false
|
|
752
827
|
},
|
|
753
828
|
"ScopeInterfacesController_list": {
|
|
754
829
|
method: "GET",
|
|
@@ -758,7 +833,8 @@ var OPERATIONS = {
|
|
|
758
833
|
pathParams: ["id"],
|
|
759
834
|
queryParams: [],
|
|
760
835
|
requestSchema: null,
|
|
761
|
-
responseSchema: "ListScopeInterfacesResponseDto"
|
|
836
|
+
responseSchema: "ListScopeInterfacesResponseDto",
|
|
837
|
+
idempotent: false
|
|
762
838
|
},
|
|
763
839
|
"ScopeInterfacesController_update": {
|
|
764
840
|
method: "PATCH",
|
|
@@ -768,7 +844,8 @@ var OPERATIONS = {
|
|
|
768
844
|
pathParams: ["id", "interfaceId"],
|
|
769
845
|
queryParams: ["updateMask"],
|
|
770
846
|
requestSchema: "UpdateScopeInterfaceDto",
|
|
771
|
-
responseSchema: "ScopeInterfaceDto"
|
|
847
|
+
responseSchema: "ScopeInterfaceDto",
|
|
848
|
+
idempotent: false
|
|
772
849
|
},
|
|
773
850
|
"ScopeMemoriesController_delete": {
|
|
774
851
|
method: "DELETE",
|
|
@@ -778,7 +855,8 @@ var OPERATIONS = {
|
|
|
778
855
|
pathParams: ["id", "memoryId"],
|
|
779
856
|
queryParams: [],
|
|
780
857
|
requestSchema: null,
|
|
781
|
-
responseSchema: null
|
|
858
|
+
responseSchema: null,
|
|
859
|
+
idempotent: false
|
|
782
860
|
},
|
|
783
861
|
"ScopeMemoriesController_list": {
|
|
784
862
|
method: "GET",
|
|
@@ -788,7 +866,8 @@ var OPERATIONS = {
|
|
|
788
866
|
pathParams: ["id"],
|
|
789
867
|
queryParams: ["pageToken", "pageSize", "userId", "limit"],
|
|
790
868
|
requestSchema: null,
|
|
791
|
-
responseSchema: "ListMemoriesResponseDto"
|
|
869
|
+
responseSchema: "ListMemoriesResponseDto",
|
|
870
|
+
idempotent: false
|
|
792
871
|
},
|
|
793
872
|
"ScopeMemoriesController_search": {
|
|
794
873
|
method: "POST",
|
|
@@ -798,7 +877,8 @@ var OPERATIONS = {
|
|
|
798
877
|
pathParams: ["id"],
|
|
799
878
|
queryParams: [],
|
|
800
879
|
requestSchema: "SearchMemoriesRequestDto",
|
|
801
|
-
responseSchema: "ListMemoriesResponseDto"
|
|
880
|
+
responseSchema: "ListMemoriesResponseDto",
|
|
881
|
+
idempotent: true
|
|
802
882
|
},
|
|
803
883
|
"ScopeMemoriesController_update": {
|
|
804
884
|
method: "PATCH",
|
|
@@ -808,7 +888,8 @@ var OPERATIONS = {
|
|
|
808
888
|
pathParams: ["id", "memoryId"],
|
|
809
889
|
queryParams: ["updateMask"],
|
|
810
890
|
requestSchema: "UpdateMemoryRequestDto",
|
|
811
|
-
responseSchema: null
|
|
891
|
+
responseSchema: null,
|
|
892
|
+
idempotent: false
|
|
812
893
|
},
|
|
813
894
|
"ScopeRunsController_create": {
|
|
814
895
|
method: "POST",
|
|
@@ -818,7 +899,8 @@ var OPERATIONS = {
|
|
|
818
899
|
pathParams: ["id"],
|
|
819
900
|
queryParams: [],
|
|
820
901
|
requestSchema: "SkillRunDto",
|
|
821
|
-
responseSchema: null
|
|
902
|
+
responseSchema: null,
|
|
903
|
+
idempotent: false
|
|
822
904
|
},
|
|
823
905
|
"ScopeSupervisionController_get": {
|
|
824
906
|
method: "GET",
|
|
@@ -828,7 +910,8 @@ var OPERATIONS = {
|
|
|
828
910
|
pathParams: ["id"],
|
|
829
911
|
queryParams: ["view"],
|
|
830
912
|
requestSchema: null,
|
|
831
|
-
responseSchema: "SupervisionDto"
|
|
913
|
+
responseSchema: "SupervisionDto",
|
|
914
|
+
idempotent: false
|
|
832
915
|
},
|
|
833
916
|
"ScopeSupervisionController_set": {
|
|
834
917
|
method: "PUT",
|
|
@@ -838,7 +921,8 @@ var OPERATIONS = {
|
|
|
838
921
|
pathParams: ["id"],
|
|
839
922
|
queryParams: [],
|
|
840
923
|
requestSchema: "SetSupervisionRequestDto",
|
|
841
|
-
responseSchema: "SupervisionDto"
|
|
924
|
+
responseSchema: "SupervisionDto",
|
|
925
|
+
idempotent: false
|
|
842
926
|
},
|
|
843
927
|
"ScopeSupervisionController_setActive": {
|
|
844
928
|
method: "PUT",
|
|
@@ -848,7 +932,8 @@ var OPERATIONS = {
|
|
|
848
932
|
pathParams: ["id"],
|
|
849
933
|
queryParams: [],
|
|
850
934
|
requestSchema: "SetSupervisionRequestDto",
|
|
851
|
-
responseSchema: "SupervisionDto"
|
|
935
|
+
responseSchema: "SupervisionDto",
|
|
936
|
+
idempotent: false
|
|
852
937
|
},
|
|
853
938
|
"ScopesController_acceptOwnershipTransfer": {
|
|
854
939
|
method: "POST",
|
|
@@ -858,7 +943,30 @@ var OPERATIONS = {
|
|
|
858
943
|
pathParams: ["id"],
|
|
859
944
|
queryParams: [],
|
|
860
945
|
requestSchema: null,
|
|
861
|
-
responseSchema: "ScopeDto"
|
|
946
|
+
responseSchema: "ScopeDto",
|
|
947
|
+
idempotent: false
|
|
948
|
+
},
|
|
949
|
+
"ScopesController_addEvaluationCase": {
|
|
950
|
+
method: "POST",
|
|
951
|
+
path: "/api/v1/scopes/{id}/evaluations/cases",
|
|
952
|
+
service: "modus-api",
|
|
953
|
+
serverUrl: "https://api.getmodus.com",
|
|
954
|
+
pathParams: ["id"],
|
|
955
|
+
queryParams: [],
|
|
956
|
+
requestSchema: "EvaluationCaseInputDto",
|
|
957
|
+
responseSchema: "EvaluationCaseDto",
|
|
958
|
+
idempotent: false
|
|
959
|
+
},
|
|
960
|
+
"ScopesController_applySelectionOps": {
|
|
961
|
+
method: "POST",
|
|
962
|
+
path: "/api/v1/scopes/{id}/applySelectionOps",
|
|
963
|
+
service: "modus-api",
|
|
964
|
+
serverUrl: "https://api.getmodus.com",
|
|
965
|
+
pathParams: ["id"],
|
|
966
|
+
queryParams: [],
|
|
967
|
+
requestSchema: "ApplySelectionOpsDto",
|
|
968
|
+
responseSchema: "ScopeDto",
|
|
969
|
+
idempotent: false
|
|
862
970
|
},
|
|
863
971
|
"ScopesController_cancelOwnershipTransfer": {
|
|
864
972
|
method: "DELETE",
|
|
@@ -868,7 +976,8 @@ var OPERATIONS = {
|
|
|
868
976
|
pathParams: ["id"],
|
|
869
977
|
queryParams: [],
|
|
870
978
|
requestSchema: null,
|
|
871
|
-
responseSchema: "ScopeDto"
|
|
979
|
+
responseSchema: "ScopeDto",
|
|
980
|
+
idempotent: false
|
|
872
981
|
},
|
|
873
982
|
"ScopesController_create": {
|
|
874
983
|
method: "POST",
|
|
@@ -878,7 +987,8 @@ var OPERATIONS = {
|
|
|
878
987
|
pathParams: [],
|
|
879
988
|
queryParams: [],
|
|
880
989
|
requestSchema: "CreateSkillDto",
|
|
881
|
-
responseSchema: "ScopeDto"
|
|
990
|
+
responseSchema: "ScopeDto",
|
|
991
|
+
idempotent: false
|
|
882
992
|
},
|
|
883
993
|
"ScopesController_delete": {
|
|
884
994
|
method: "DELETE",
|
|
@@ -888,7 +998,19 @@ var OPERATIONS = {
|
|
|
888
998
|
pathParams: ["id"],
|
|
889
999
|
queryParams: [],
|
|
890
1000
|
requestSchema: null,
|
|
891
|
-
responseSchema: null
|
|
1001
|
+
responseSchema: null,
|
|
1002
|
+
idempotent: false
|
|
1003
|
+
},
|
|
1004
|
+
"ScopesController_deleteEvaluationCase": {
|
|
1005
|
+
method: "DELETE",
|
|
1006
|
+
path: "/api/v1/scopes/{id}/evaluations/cases/{caseId}",
|
|
1007
|
+
service: "modus-api",
|
|
1008
|
+
serverUrl: "https://api.getmodus.com",
|
|
1009
|
+
pathParams: ["id", "caseId"],
|
|
1010
|
+
queryParams: [],
|
|
1011
|
+
requestSchema: null,
|
|
1012
|
+
responseSchema: null,
|
|
1013
|
+
idempotent: false
|
|
892
1014
|
},
|
|
893
1015
|
"ScopesController_deploy": {
|
|
894
1016
|
method: "POST",
|
|
@@ -898,7 +1020,8 @@ var OPERATIONS = {
|
|
|
898
1020
|
pathParams: ["id"],
|
|
899
1021
|
queryParams: [],
|
|
900
1022
|
requestSchema: "DeploySkillDto",
|
|
901
|
-
responseSchema: "DeployResponseDto"
|
|
1023
|
+
responseSchema: "DeployResponseDto",
|
|
1024
|
+
idempotent: false
|
|
902
1025
|
},
|
|
903
1026
|
"ScopesController_get": {
|
|
904
1027
|
method: "GET",
|
|
@@ -908,7 +1031,8 @@ var OPERATIONS = {
|
|
|
908
1031
|
pathParams: ["id"],
|
|
909
1032
|
queryParams: ["view"],
|
|
910
1033
|
requestSchema: null,
|
|
911
|
-
responseSchema: "ScopeDto"
|
|
1034
|
+
responseSchema: "ScopeDto",
|
|
1035
|
+
idempotent: false
|
|
912
1036
|
},
|
|
913
1037
|
"ScopesController_getVariation": {
|
|
914
1038
|
method: "GET",
|
|
@@ -918,7 +1042,8 @@ var OPERATIONS = {
|
|
|
918
1042
|
pathParams: ["id", "variationUid"],
|
|
919
1043
|
queryParams: [],
|
|
920
1044
|
requestSchema: null,
|
|
921
|
-
responseSchema: "ScopeDto"
|
|
1045
|
+
responseSchema: "ScopeDto",
|
|
1046
|
+
idempotent: false
|
|
922
1047
|
},
|
|
923
1048
|
"ScopesController_list": {
|
|
924
1049
|
method: "GET",
|
|
@@ -928,7 +1053,19 @@ var OPERATIONS = {
|
|
|
928
1053
|
pathParams: [],
|
|
929
1054
|
queryParams: ["pageToken", "pageSize", "view", "search", "managerId", "includeVariation"],
|
|
930
1055
|
requestSchema: null,
|
|
931
|
-
responseSchema: "ListSkillsResponseDto"
|
|
1056
|
+
responseSchema: "ListSkillsResponseDto",
|
|
1057
|
+
idempotent: false
|
|
1058
|
+
},
|
|
1059
|
+
"ScopesController_mcpExposureCatalog": {
|
|
1060
|
+
method: "POST",
|
|
1061
|
+
path: "/api/v1/scopes/{id}/mcp-exposure-catalog",
|
|
1062
|
+
service: "modus-api",
|
|
1063
|
+
serverUrl: "https://api.getmodus.com",
|
|
1064
|
+
pathParams: ["id"],
|
|
1065
|
+
queryParams: [],
|
|
1066
|
+
requestSchema: "McpExposureCatalogRequestDto",
|
|
1067
|
+
responseSchema: "McpExposureCatalogResponseDto",
|
|
1068
|
+
idempotent: true
|
|
932
1069
|
},
|
|
933
1070
|
"ScopesController_patchMcpConfig": {
|
|
934
1071
|
method: "PATCH",
|
|
@@ -938,7 +1075,8 @@ var OPERATIONS = {
|
|
|
938
1075
|
pathParams: ["id"],
|
|
939
1076
|
queryParams: [],
|
|
940
1077
|
requestSchema: "PatchSkillMcpConfigDto",
|
|
941
|
-
responseSchema: "PatchSkillMcpConfigResponseDto"
|
|
1078
|
+
responseSchema: "PatchSkillMcpConfigResponseDto",
|
|
1079
|
+
idempotent: false
|
|
942
1080
|
},
|
|
943
1081
|
"ScopesController_requestOwnershipTransfer": {
|
|
944
1082
|
method: "POST",
|
|
@@ -948,7 +1086,8 @@ var OPERATIONS = {
|
|
|
948
1086
|
pathParams: ["id"],
|
|
949
1087
|
queryParams: [],
|
|
950
1088
|
requestSchema: "TransferOwnershipDto",
|
|
951
|
-
responseSchema: "ScopeDto"
|
|
1089
|
+
responseSchema: "ScopeDto",
|
|
1090
|
+
idempotent: false
|
|
952
1091
|
},
|
|
953
1092
|
"ScopesController_restore": {
|
|
954
1093
|
method: "POST",
|
|
@@ -958,7 +1097,8 @@ var OPERATIONS = {
|
|
|
958
1097
|
pathParams: ["id"],
|
|
959
1098
|
queryParams: [],
|
|
960
1099
|
requestSchema: null,
|
|
961
|
-
responseSchema: "ScopeDto"
|
|
1100
|
+
responseSchema: "ScopeDto",
|
|
1101
|
+
idempotent: false
|
|
962
1102
|
},
|
|
963
1103
|
"ScopesController_update": {
|
|
964
1104
|
method: "PATCH",
|
|
@@ -968,7 +1108,19 @@ var OPERATIONS = {
|
|
|
968
1108
|
pathParams: ["id"],
|
|
969
1109
|
queryParams: ["updateMask"],
|
|
970
1110
|
requestSchema: "UpdateSkillDto",
|
|
971
|
-
responseSchema: "ScopeDto"
|
|
1111
|
+
responseSchema: "ScopeDto",
|
|
1112
|
+
idempotent: false
|
|
1113
|
+
},
|
|
1114
|
+
"ScopesController_updateEvaluationCase": {
|
|
1115
|
+
method: "PATCH",
|
|
1116
|
+
path: "/api/v1/scopes/{id}/evaluations/cases/{caseId}",
|
|
1117
|
+
service: "modus-api",
|
|
1118
|
+
serverUrl: "https://api.getmodus.com",
|
|
1119
|
+
pathParams: ["id", "caseId"],
|
|
1120
|
+
queryParams: [],
|
|
1121
|
+
requestSchema: "UpdateEvaluationCaseDto",
|
|
1122
|
+
responseSchema: "EvaluationCaseDto",
|
|
1123
|
+
idempotent: false
|
|
972
1124
|
},
|
|
973
1125
|
"SuggestionsController_listApproved": {
|
|
974
1126
|
method: "GET",
|
|
@@ -978,7 +1130,8 @@ var OPERATIONS = {
|
|
|
978
1130
|
pathParams: [],
|
|
979
1131
|
queryParams: ["pageToken", "pageSize", "scopeId", "scopeIds"],
|
|
980
1132
|
requestSchema: null,
|
|
981
|
-
responseSchema: "ListSuggestionQuestionsResponseDto"
|
|
1133
|
+
responseSchema: "ListSuggestionQuestionsResponseDto",
|
|
1134
|
+
idempotent: false
|
|
982
1135
|
},
|
|
983
1136
|
"SuggestionsController_recordEvent": {
|
|
984
1137
|
method: "POST",
|
|
@@ -988,7 +1141,8 @@ var OPERATIONS = {
|
|
|
988
1141
|
pathParams: ["id"],
|
|
989
1142
|
queryParams: [],
|
|
990
1143
|
requestSchema: "RecordSuggestionEventDto",
|
|
991
|
-
responseSchema: null
|
|
1144
|
+
responseSchema: null,
|
|
1145
|
+
idempotent: false
|
|
992
1146
|
},
|
|
993
1147
|
"ToolsController_list": {
|
|
994
1148
|
method: "GET",
|
|
@@ -998,7 +1152,8 @@ var OPERATIONS = {
|
|
|
998
1152
|
pathParams: [],
|
|
999
1153
|
queryParams: ["pageToken", "pageSize"],
|
|
1000
1154
|
requestSchema: null,
|
|
1001
|
-
responseSchema: "ListToolsResponseDto"
|
|
1155
|
+
responseSchema: "ListToolsResponseDto",
|
|
1156
|
+
idempotent: false
|
|
1002
1157
|
},
|
|
1003
1158
|
"UsageController_list": {
|
|
1004
1159
|
method: "GET",
|
|
@@ -1008,7 +1163,8 @@ var OPERATIONS = {
|
|
|
1008
1163
|
pathParams: [],
|
|
1009
1164
|
queryParams: ["since", "until", "rollup", "model", "group_by", "skill_id", "agent_id", "user_id", "interface", "user_email"],
|
|
1010
1165
|
requestSchema: null,
|
|
1011
|
-
responseSchema: "ListUsageResponseDto"
|
|
1166
|
+
responseSchema: "ListUsageResponseDto",
|
|
1167
|
+
idempotent: false
|
|
1012
1168
|
},
|
|
1013
1169
|
"UsageController_listUsers": {
|
|
1014
1170
|
method: "GET",
|
|
@@ -1018,7 +1174,8 @@ var OPERATIONS = {
|
|
|
1018
1174
|
pathParams: [],
|
|
1019
1175
|
queryParams: ["since", "until"],
|
|
1020
1176
|
requestSchema: null,
|
|
1021
|
-
responseSchema: "ListUsageUsersResponseDto"
|
|
1177
|
+
responseSchema: "ListUsageUsersResponseDto",
|
|
1178
|
+
idempotent: false
|
|
1022
1179
|
},
|
|
1023
1180
|
"WorkflowActionsController_cancel": {
|
|
1024
1181
|
method: "POST",
|
|
@@ -1028,7 +1185,8 @@ var OPERATIONS = {
|
|
|
1028
1185
|
pathParams: ["runId"],
|
|
1029
1186
|
queryParams: [],
|
|
1030
1187
|
requestSchema: "CancelRunDto",
|
|
1031
|
-
responseSchema: null
|
|
1188
|
+
responseSchema: null,
|
|
1189
|
+
idempotent: true
|
|
1032
1190
|
},
|
|
1033
1191
|
"WorkflowActionsController_execute": {
|
|
1034
1192
|
method: "POST",
|
|
@@ -1038,7 +1196,8 @@ var OPERATIONS = {
|
|
|
1038
1196
|
pathParams: [],
|
|
1039
1197
|
queryParams: [],
|
|
1040
1198
|
requestSchema: "WorkflowActionDto",
|
|
1041
|
-
responseSchema: null
|
|
1199
|
+
responseSchema: null,
|
|
1200
|
+
idempotent: false
|
|
1042
1201
|
},
|
|
1043
1202
|
"WorkflowInterfacesController_add": {
|
|
1044
1203
|
method: "POST",
|
|
@@ -1048,7 +1207,8 @@ var OPERATIONS = {
|
|
|
1048
1207
|
pathParams: ["id"],
|
|
1049
1208
|
queryParams: [],
|
|
1050
1209
|
requestSchema: "AddAgentInterfaceDto",
|
|
1051
|
-
responseSchema: "AgentInterfaceDto"
|
|
1210
|
+
responseSchema: "AgentInterfaceDto",
|
|
1211
|
+
idempotent: false
|
|
1052
1212
|
},
|
|
1053
1213
|
"WorkflowInterfacesController_delete": {
|
|
1054
1214
|
method: "DELETE",
|
|
@@ -1058,7 +1218,8 @@ var OPERATIONS = {
|
|
|
1058
1218
|
pathParams: ["id", "interfaceId"],
|
|
1059
1219
|
queryParams: [],
|
|
1060
1220
|
requestSchema: null,
|
|
1061
|
-
responseSchema: null
|
|
1221
|
+
responseSchema: null,
|
|
1222
|
+
idempotent: false
|
|
1062
1223
|
},
|
|
1063
1224
|
"WorkflowInterfacesController_deleteAll": {
|
|
1064
1225
|
method: "DELETE",
|
|
@@ -1068,7 +1229,8 @@ var OPERATIONS = {
|
|
|
1068
1229
|
pathParams: ["id"],
|
|
1069
1230
|
queryParams: [],
|
|
1070
1231
|
requestSchema: null,
|
|
1071
|
-
responseSchema: null
|
|
1232
|
+
responseSchema: null,
|
|
1233
|
+
idempotent: false
|
|
1072
1234
|
},
|
|
1073
1235
|
"WorkflowInterfacesController_list": {
|
|
1074
1236
|
method: "GET",
|
|
@@ -1078,7 +1240,8 @@ var OPERATIONS = {
|
|
|
1078
1240
|
pathParams: ["id"],
|
|
1079
1241
|
queryParams: [],
|
|
1080
1242
|
requestSchema: null,
|
|
1081
|
-
responseSchema: "ListAgentInterfacesResponseDto"
|
|
1243
|
+
responseSchema: "ListAgentInterfacesResponseDto",
|
|
1244
|
+
idempotent: false
|
|
1082
1245
|
},
|
|
1083
1246
|
"WorkflowInterfacesController_update": {
|
|
1084
1247
|
method: "PATCH",
|
|
@@ -1088,7 +1251,8 @@ var OPERATIONS = {
|
|
|
1088
1251
|
pathParams: ["id", "interfaceId"],
|
|
1089
1252
|
queryParams: ["updateMask"],
|
|
1090
1253
|
requestSchema: "UpdateAgentInterfaceDto",
|
|
1091
|
-
responseSchema: "AgentInterfaceDto"
|
|
1254
|
+
responseSchema: "AgentInterfaceDto",
|
|
1255
|
+
idempotent: false
|
|
1092
1256
|
},
|
|
1093
1257
|
"WorkflowRunsController_create": {
|
|
1094
1258
|
method: "POST",
|
|
@@ -1098,7 +1262,8 @@ var OPERATIONS = {
|
|
|
1098
1262
|
pathParams: ["id"],
|
|
1099
1263
|
queryParams: [],
|
|
1100
1264
|
requestSchema: "AgentRunDto",
|
|
1101
|
-
responseSchema: null
|
|
1265
|
+
responseSchema: null,
|
|
1266
|
+
idempotent: false
|
|
1102
1267
|
},
|
|
1103
1268
|
"WorkflowRunsController_get": {
|
|
1104
1269
|
method: "GET",
|
|
@@ -1108,7 +1273,8 @@ var OPERATIONS = {
|
|
|
1108
1273
|
pathParams: ["id", "runId"],
|
|
1109
1274
|
queryParams: ["temporalRunId"],
|
|
1110
1275
|
requestSchema: null,
|
|
1111
|
-
responseSchema: "GetAutomationRunResponseDto"
|
|
1276
|
+
responseSchema: "GetAutomationRunResponseDto",
|
|
1277
|
+
idempotent: false
|
|
1112
1278
|
},
|
|
1113
1279
|
"WorkflowRunsController_list": {
|
|
1114
1280
|
method: "GET",
|
|
@@ -1118,7 +1284,8 @@ var OPERATIONS = {
|
|
|
1118
1284
|
pathParams: ["id"],
|
|
1119
1285
|
queryParams: ["status", "timeframe", "approvalScope", "search", "pageSize", "pageToken"],
|
|
1120
1286
|
requestSchema: null,
|
|
1121
|
-
responseSchema: "ListAutomationRunsResponseDto"
|
|
1287
|
+
responseSchema: "ListAutomationRunsResponseDto",
|
|
1288
|
+
idempotent: false
|
|
1122
1289
|
},
|
|
1123
1290
|
"WorkflowsController_acceptOwnershipTransfer": {
|
|
1124
1291
|
method: "POST",
|
|
@@ -1128,7 +1295,8 @@ var OPERATIONS = {
|
|
|
1128
1295
|
pathParams: ["id"],
|
|
1129
1296
|
queryParams: [],
|
|
1130
1297
|
requestSchema: null,
|
|
1131
|
-
responseSchema: "WorkflowDto"
|
|
1298
|
+
responseSchema: "WorkflowDto",
|
|
1299
|
+
idempotent: false
|
|
1132
1300
|
},
|
|
1133
1301
|
"WorkflowsController_cancelOwnershipTransfer": {
|
|
1134
1302
|
method: "DELETE",
|
|
@@ -1138,7 +1306,8 @@ var OPERATIONS = {
|
|
|
1138
1306
|
pathParams: ["id"],
|
|
1139
1307
|
queryParams: [],
|
|
1140
1308
|
requestSchema: null,
|
|
1141
|
-
responseSchema: "WorkflowDto"
|
|
1309
|
+
responseSchema: "WorkflowDto",
|
|
1310
|
+
idempotent: false
|
|
1142
1311
|
},
|
|
1143
1312
|
"WorkflowsController_create": {
|
|
1144
1313
|
method: "POST",
|
|
@@ -1148,7 +1317,8 @@ var OPERATIONS = {
|
|
|
1148
1317
|
pathParams: [],
|
|
1149
1318
|
queryParams: [],
|
|
1150
1319
|
requestSchema: "CreateAgentDto",
|
|
1151
|
-
responseSchema: "WorkflowDto"
|
|
1320
|
+
responseSchema: "WorkflowDto",
|
|
1321
|
+
idempotent: false
|
|
1152
1322
|
},
|
|
1153
1323
|
"WorkflowsController_delete": {
|
|
1154
1324
|
method: "DELETE",
|
|
@@ -1158,7 +1328,8 @@ var OPERATIONS = {
|
|
|
1158
1328
|
pathParams: ["id"],
|
|
1159
1329
|
queryParams: [],
|
|
1160
1330
|
requestSchema: null,
|
|
1161
|
-
responseSchema: null
|
|
1331
|
+
responseSchema: null,
|
|
1332
|
+
idempotent: false
|
|
1162
1333
|
},
|
|
1163
1334
|
"WorkflowsController_deploy": {
|
|
1164
1335
|
method: "POST",
|
|
@@ -1168,7 +1339,8 @@ var OPERATIONS = {
|
|
|
1168
1339
|
pathParams: ["id"],
|
|
1169
1340
|
queryParams: [],
|
|
1170
1341
|
requestSchema: "DeployAgentDto",
|
|
1171
|
-
responseSchema: "AgentDeployResponseDto"
|
|
1342
|
+
responseSchema: "AgentDeployResponseDto",
|
|
1343
|
+
idempotent: false
|
|
1172
1344
|
},
|
|
1173
1345
|
"WorkflowsController_get": {
|
|
1174
1346
|
method: "GET",
|
|
@@ -1178,7 +1350,8 @@ var OPERATIONS = {
|
|
|
1178
1350
|
pathParams: ["id"],
|
|
1179
1351
|
queryParams: ["view"],
|
|
1180
1352
|
requestSchema: null,
|
|
1181
|
-
responseSchema: "WorkflowDto"
|
|
1353
|
+
responseSchema: "WorkflowDto",
|
|
1354
|
+
idempotent: false
|
|
1182
1355
|
},
|
|
1183
1356
|
"WorkflowsController_list": {
|
|
1184
1357
|
method: "GET",
|
|
@@ -1188,7 +1361,8 @@ var OPERATIONS = {
|
|
|
1188
1361
|
pathParams: [],
|
|
1189
1362
|
queryParams: ["pageToken", "pageSize", "view", "type", "search", "includeVariation"],
|
|
1190
1363
|
requestSchema: null,
|
|
1191
|
-
responseSchema: "ListAgentsResponseDto"
|
|
1364
|
+
responseSchema: "ListAgentsResponseDto",
|
|
1365
|
+
idempotent: false
|
|
1192
1366
|
},
|
|
1193
1367
|
"WorkflowsController_requestOwnershipTransfer": {
|
|
1194
1368
|
method: "POST",
|
|
@@ -1198,7 +1372,8 @@ var OPERATIONS = {
|
|
|
1198
1372
|
pathParams: ["id"],
|
|
1199
1373
|
queryParams: [],
|
|
1200
1374
|
requestSchema: "TransferOwnershipDto",
|
|
1201
|
-
responseSchema: "WorkflowDto"
|
|
1375
|
+
responseSchema: "WorkflowDto",
|
|
1376
|
+
idempotent: false
|
|
1202
1377
|
},
|
|
1203
1378
|
"WorkflowsController_restore": {
|
|
1204
1379
|
method: "POST",
|
|
@@ -1208,7 +1383,8 @@ var OPERATIONS = {
|
|
|
1208
1383
|
pathParams: ["id"],
|
|
1209
1384
|
queryParams: [],
|
|
1210
1385
|
requestSchema: null,
|
|
1211
|
-
responseSchema: "WorkflowDto"
|
|
1386
|
+
responseSchema: "WorkflowDto",
|
|
1387
|
+
idempotent: false
|
|
1212
1388
|
},
|
|
1213
1389
|
"WorkflowsController_toggle": {
|
|
1214
1390
|
method: "POST",
|
|
@@ -1218,7 +1394,8 @@ var OPERATIONS = {
|
|
|
1218
1394
|
pathParams: ["id"],
|
|
1219
1395
|
queryParams: [],
|
|
1220
1396
|
requestSchema: "ToggleAgentDto",
|
|
1221
|
-
responseSchema: "WorkflowDto"
|
|
1397
|
+
responseSchema: "WorkflowDto",
|
|
1398
|
+
idempotent: true
|
|
1222
1399
|
},
|
|
1223
1400
|
"WorkflowsController_update": {
|
|
1224
1401
|
method: "PATCH",
|
|
@@ -1228,7 +1405,8 @@ var OPERATIONS = {
|
|
|
1228
1405
|
pathParams: ["id"],
|
|
1229
1406
|
queryParams: ["updateMask"],
|
|
1230
1407
|
requestSchema: "UpdateAgentDto",
|
|
1231
|
-
responseSchema: "WorkflowDto"
|
|
1408
|
+
responseSchema: "WorkflowDto",
|
|
1409
|
+
idempotent: false
|
|
1232
1410
|
}
|
|
1233
1411
|
};
|
|
1234
1412
|
|
|
@@ -1240,17 +1418,26 @@ var ModusError = class extends Error {
|
|
|
1240
1418
|
this.message = message;
|
|
1241
1419
|
this.statusCode = options.statusCode;
|
|
1242
1420
|
this.requestId = options.requestId;
|
|
1421
|
+
this.traceId = options.traceId;
|
|
1243
1422
|
this.responseHeaders = options.responseHeaders;
|
|
1244
1423
|
this.body = options.body;
|
|
1245
1424
|
this.code = options.code;
|
|
1425
|
+
this.info = options.info;
|
|
1426
|
+
this.retryable = options.retryable ?? false;
|
|
1246
1427
|
}
|
|
1247
1428
|
};
|
|
1248
1429
|
var APIConnectionError = class extends ModusError {
|
|
1249
|
-
constructor(message) {
|
|
1250
|
-
super(message);
|
|
1430
|
+
constructor(message, options = {}) {
|
|
1431
|
+
super(message, options);
|
|
1251
1432
|
this.name = "APIConnectionError";
|
|
1252
1433
|
}
|
|
1253
1434
|
};
|
|
1435
|
+
var BadRequestError = class extends ModusError {
|
|
1436
|
+
constructor(message, options = {}) {
|
|
1437
|
+
super(message, { ...options, statusCode: 400 });
|
|
1438
|
+
this.name = "BadRequestError";
|
|
1439
|
+
}
|
|
1440
|
+
};
|
|
1254
1441
|
var AuthenticationError = class extends ModusError {
|
|
1255
1442
|
constructor(message, options = {}) {
|
|
1256
1443
|
super(message, { ...options, statusCode: 401 });
|
|
@@ -1333,11 +1520,11 @@ var Page = class {
|
|
|
1333
1520
|
* Fetch the next page using {@link Page.nextPageToken}.
|
|
1334
1521
|
*
|
|
1335
1522
|
* @returns The following page of results.
|
|
1336
|
-
* @throws {
|
|
1523
|
+
* @throws {ValidationError} When there is no next page. Check {@link Page.hasNextPage} first.
|
|
1337
1524
|
*/
|
|
1338
1525
|
async getNextPage() {
|
|
1339
1526
|
if (this.nextPageToken === void 0) {
|
|
1340
|
-
throw new
|
|
1527
|
+
throw new ValidationError(
|
|
1341
1528
|
"No next page available. Check hasNextPage() before calling getNextPage()."
|
|
1342
1529
|
);
|
|
1343
1530
|
}
|
|
@@ -1423,7 +1610,10 @@ function resolveBaseUrl(baseUrl) {
|
|
|
1423
1610
|
return baseUrl ?? process.env[ENV_BASE_URL] ?? void 0;
|
|
1424
1611
|
}
|
|
1425
1612
|
function resolveAgentHost(agentHost) {
|
|
1426
|
-
|
|
1613
|
+
for (const value of [agentHost, process.env[ENV_AGENT_HOST]]) {
|
|
1614
|
+
if (value?.trim()) return value.trim();
|
|
1615
|
+
}
|
|
1616
|
+
return void 0;
|
|
1427
1617
|
}
|
|
1428
1618
|
function isModusApiHostname(hostname) {
|
|
1429
1619
|
return hostname === "api.getmodus.com" || /^api\.[a-z0-9-]+\.getmodus\.com$/i.test(hostname);
|
|
@@ -1467,7 +1657,6 @@ function authHeaders(apiKey) {
|
|
|
1467
1657
|
|
|
1468
1658
|
// src/_config.ts
|
|
1469
1659
|
var DEFAULT_BASE_URL = "https://api.getmodus.com";
|
|
1470
|
-
var DEFAULT_AGENT_HOST = "https://agent.getmodus.com";
|
|
1471
1660
|
var DEFAULT_TIMEOUT_MS = 3e5;
|
|
1472
1661
|
var DEFAULT_MAX_RETRIES = 2;
|
|
1473
1662
|
function normalizeBaseUrl(baseUrl) {
|
|
@@ -1488,9 +1677,8 @@ function createModusConfig(options = {}) {
|
|
|
1488
1677
|
}
|
|
1489
1678
|
const baseUrl = normalizeBaseUrl(resolveBaseUrl(options.baseUrl) ?? DEFAULT_BASE_URL);
|
|
1490
1679
|
const baseUrlOverrides = normalizeBaseUrls(options.baseUrls);
|
|
1491
|
-
const
|
|
1492
|
-
|
|
1493
|
-
);
|
|
1680
|
+
const explicitAgentHost = baseUrlOverrides["agent-service"] ?? resolveAgentHost(options.agentHost) ?? deriveAgentHostFromBaseUrl(baseUrl);
|
|
1681
|
+
const agentHost = explicitAgentHost === void 0 ? void 0 : normalizeBaseUrl(explicitAgentHost);
|
|
1494
1682
|
const organizationId = resolveOrganizationId(options.organizationId);
|
|
1495
1683
|
return Object.freeze({
|
|
1496
1684
|
apiKey: resolveApiKey(options.apiKey),
|
|
@@ -1499,7 +1687,7 @@ function createModusConfig(options = {}) {
|
|
|
1499
1687
|
...organizationId !== void 0 ? { organizationId } : {},
|
|
1500
1688
|
baseUrls: Object.freeze({
|
|
1501
1689
|
"modus-api": baseUrl,
|
|
1502
|
-
"agent-service": agentHost,
|
|
1690
|
+
...agentHost !== void 0 ? { "agent-service": agentHost } : {},
|
|
1503
1691
|
...baseUrlOverrides
|
|
1504
1692
|
}),
|
|
1505
1693
|
timeoutMs: resolveTimeoutMs(options.timeoutMs) ?? DEFAULT_TIMEOUT_MS,
|
|
@@ -1509,18 +1697,84 @@ function createModusConfig(options = {}) {
|
|
|
1509
1697
|
});
|
|
1510
1698
|
}
|
|
1511
1699
|
function resolveServiceBaseUrl(config, service, generatedBaseUrl) {
|
|
1512
|
-
if (service === "agent-service")
|
|
1513
|
-
return config.baseUrls["agent-service"] ?? config.agentHost ?? generatedBaseUrl ?? config.baseUrl;
|
|
1514
|
-
}
|
|
1700
|
+
if (service === "agent-service") return requireAgentHost(config);
|
|
1515
1701
|
return config.baseUrls[service] ?? generatedBaseUrl ?? config.baseUrl;
|
|
1516
1702
|
}
|
|
1517
1703
|
function formatConfigForLog(config) {
|
|
1518
1704
|
const masked = config.apiKey.length > 10 ? `${config.apiKey.slice(0, 10)}***` : "***";
|
|
1519
1705
|
return `ModusConfig(apiKey=${JSON.stringify(masked)}, baseUrl=${JSON.stringify(config.baseUrl)}, timeoutMs=${config.timeoutMs}, maxRetries=${config.maxRetries})`;
|
|
1520
1706
|
}
|
|
1707
|
+
function requireAgentHost(config) {
|
|
1708
|
+
if (config.agentHost === void 0) {
|
|
1709
|
+
throw new ModusError(
|
|
1710
|
+
`No agent host for baseUrl ${JSON.stringify(config.baseUrl)}. Pass agentHost (or set MODUS_AGENT_HOST) to chat or run with a custom baseUrl.`
|
|
1711
|
+
);
|
|
1712
|
+
}
|
|
1713
|
+
return config.agentHost;
|
|
1714
|
+
}
|
|
1715
|
+
|
|
1716
|
+
// src/_retry.ts
|
|
1717
|
+
var DEPLOY_NOT_FOUND_BACKOFF_MS = 500;
|
|
1718
|
+
var MAX_DEPLOY_NOT_FOUND_RETRIES = 1;
|
|
1719
|
+
var MAX_RETRY_AFTER_SECONDS = 60;
|
|
1720
|
+
var RETRY_STATUSES = /* @__PURE__ */ new Set([408, 429, 500, 502, 503, 504]);
|
|
1721
|
+
var CONNECT_PHASE_CODES = /* @__PURE__ */ new Set(["ECONNREFUSED", "ENOTFOUND", "EAI_AGAIN", "UND_ERR_CONNECT_TIMEOUT"]);
|
|
1722
|
+
function isRetrySafe(method, idempotent, failure) {
|
|
1723
|
+
if ("status" in failure) {
|
|
1724
|
+
if (failure.status === 429) return (failure.retryAfter ?? 0) <= MAX_RETRY_AFTER_SECONDS;
|
|
1725
|
+
if (!RETRY_STATUSES.has(failure.status)) return false;
|
|
1726
|
+
} else if (failure.causeCode !== void 0 && CONNECT_PHASE_CODES.has(failure.causeCode)) {
|
|
1727
|
+
return true;
|
|
1728
|
+
}
|
|
1729
|
+
return method !== "POST" || idempotent;
|
|
1730
|
+
}
|
|
1731
|
+
function backoffSeconds(attempt, error) {
|
|
1732
|
+
if (error instanceof RateLimitError && error.retryAfter !== void 0) return error.retryAfter;
|
|
1733
|
+
if (attempt === 0) return 0;
|
|
1734
|
+
return Math.max(0.5, 2 ** (attempt - 1) + (Math.random() * 0.6 - 0.3));
|
|
1735
|
+
}
|
|
1736
|
+
function sleep(ms) {
|
|
1737
|
+
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
1738
|
+
}
|
|
1739
|
+
async function withRetry(fn, maxRetries, options = {}) {
|
|
1740
|
+
let deployNotFoundRetries = 0;
|
|
1741
|
+
let attempt = 0;
|
|
1742
|
+
let sends = 0;
|
|
1743
|
+
while (true) {
|
|
1744
|
+
try {
|
|
1745
|
+
return await fn(sends++);
|
|
1746
|
+
} catch (error) {
|
|
1747
|
+
if (options.retryNotFoundOnDeploy && error instanceof NotFoundError && deployNotFoundRetries < MAX_DEPLOY_NOT_FOUND_RETRIES) {
|
|
1748
|
+
deployNotFoundRetries++;
|
|
1749
|
+
await sleep(DEPLOY_NOT_FOUND_BACKOFF_MS);
|
|
1750
|
+
continue;
|
|
1751
|
+
}
|
|
1752
|
+
if (!(error instanceof ModusError) || !error.retryable || attempt >= maxRetries) throw error;
|
|
1753
|
+
await sleep(backoffSeconds(attempt, error) * 1e3);
|
|
1754
|
+
attempt++;
|
|
1755
|
+
}
|
|
1756
|
+
}
|
|
1757
|
+
}
|
|
1758
|
+
|
|
1759
|
+
// src/_trace.ts
|
|
1760
|
+
import { randomBytes } from "crypto";
|
|
1761
|
+
var TRACEPARENT = /^[0-9a-f]{2}-([0-9a-f]{32})-[0-9a-f]{16}-[0-9a-f]{2}$/;
|
|
1762
|
+
function newTraceId() {
|
|
1763
|
+
return randomBytes(16).toString("hex");
|
|
1764
|
+
}
|
|
1765
|
+
function traceparent(traceId = newTraceId()) {
|
|
1766
|
+
return `00-${traceId}-${randomBytes(8).toString("hex")}-00`;
|
|
1767
|
+
}
|
|
1768
|
+
function traceIdOf(value) {
|
|
1769
|
+
return value ? TRACEPARENT.exec(value)?.[1] : void 0;
|
|
1770
|
+
}
|
|
1771
|
+
function headerValue(headers, name) {
|
|
1772
|
+
const lower = name.toLowerCase();
|
|
1773
|
+
return Object.entries(headers ?? {}).find(([key]) => key.toLowerCase() === lower)?.[1];
|
|
1774
|
+
}
|
|
1521
1775
|
|
|
1522
1776
|
// src/_http.ts
|
|
1523
|
-
var USER_AGENT = `modus-typescript/${"0.
|
|
1777
|
+
var USER_AGENT = `modus-typescript/${"0.11.0"} (node/${process.version}; ${process.platform})`;
|
|
1524
1778
|
function buildUrl(baseUrl, path, params) {
|
|
1525
1779
|
const url = new URL(path.startsWith("/") ? path : `/${path}`, baseUrl);
|
|
1526
1780
|
if (params) {
|
|
@@ -1551,41 +1805,60 @@ function headersToRecord(headers) {
|
|
|
1551
1805
|
});
|
|
1552
1806
|
return out;
|
|
1553
1807
|
}
|
|
1554
|
-
function
|
|
1555
|
-
|
|
1556
|
-
try {
|
|
1557
|
-
const body = JSON.parse(raw);
|
|
1558
|
-
if (body && typeof body === "object") {
|
|
1559
|
-
const record = body;
|
|
1560
|
-
const envelope = record.error;
|
|
1561
|
-
if (envelope && typeof envelope === "object") {
|
|
1562
|
-
const msg2 = envelope.message;
|
|
1563
|
-
if (typeof msg2 === "string" && msg2) return msg2;
|
|
1564
|
-
}
|
|
1565
|
-
const msg = record.message ?? record.error;
|
|
1566
|
-
if (Array.isArray(msg)) return msg.map(String).join("; ");
|
|
1567
|
-
if (typeof msg === "string" && msg) return msg;
|
|
1568
|
-
}
|
|
1569
|
-
} catch {
|
|
1570
|
-
}
|
|
1571
|
-
return raw;
|
|
1808
|
+
function isRecord(value) {
|
|
1809
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
1572
1810
|
}
|
|
1573
|
-
function
|
|
1811
|
+
function nonEmptyString(value) {
|
|
1812
|
+
return typeof value === "string" && value ? value : void 0;
|
|
1813
|
+
}
|
|
1814
|
+
function parseErrorBody(raw, statusCode) {
|
|
1815
|
+
let parsed;
|
|
1574
1816
|
try {
|
|
1575
|
-
|
|
1576
|
-
return typeof body.error?.code === "string" ? body.error.code : void 0;
|
|
1817
|
+
parsed = JSON.parse(raw);
|
|
1577
1818
|
} catch {
|
|
1578
|
-
return
|
|
1579
|
-
}
|
|
1819
|
+
return { message: raw || `HTTP ${statusCode}` };
|
|
1820
|
+
}
|
|
1821
|
+
if (!isRecord(parsed)) return { message: raw, parsed };
|
|
1822
|
+
const envelope = parsed.error;
|
|
1823
|
+
if (isRecord(envelope)) {
|
|
1824
|
+
return {
|
|
1825
|
+
message: nonEmptyString(envelope.message) ?? raw,
|
|
1826
|
+
code: nonEmptyString(envelope.code),
|
|
1827
|
+
requestId: nonEmptyString(envelope.requestId),
|
|
1828
|
+
info: isRecord(envelope.info) ? envelope.info : void 0,
|
|
1829
|
+
parsed
|
|
1830
|
+
};
|
|
1831
|
+
}
|
|
1832
|
+
const message = parsed.message ?? parsed.error;
|
|
1833
|
+
if (Array.isArray(message)) return { message: message.map(String).join("; "), parsed };
|
|
1834
|
+
return { message: nonEmptyString(message) ?? raw, parsed };
|
|
1580
1835
|
}
|
|
1581
|
-
function
|
|
1836
|
+
function parseRetryAfter(headers) {
|
|
1837
|
+
const ms = headers.get("retry-after-ms")?.trim();
|
|
1838
|
+
if (ms && /^\d+(\.\d+)?$/.test(ms)) return Math.ceil(Number(ms) / 1e3);
|
|
1839
|
+
const value = headers.get("retry-after")?.trim();
|
|
1840
|
+
if (!value) return void 0;
|
|
1841
|
+
if (/^\d+$/.test(value)) return Number(value);
|
|
1842
|
+
const date = Date.parse(value);
|
|
1843
|
+
return Number.isNaN(date) ? void 0 : Math.max(0, Math.ceil((date - Date.now()) / 1e3));
|
|
1844
|
+
}
|
|
1845
|
+
function raiseForStatus(response, body, method = "GET", idempotent = false, traceId) {
|
|
1582
1846
|
if (response.ok) return;
|
|
1583
|
-
const
|
|
1584
|
-
const requestId =
|
|
1585
|
-
const
|
|
1586
|
-
const
|
|
1587
|
-
|
|
1588
|
-
|
|
1847
|
+
const status = response.status;
|
|
1848
|
+
const { message, code, requestId, info, parsed } = parseErrorBody(body, status);
|
|
1849
|
+
const retryAfter = status === 429 ? parseRetryAfter(response.headers) : void 0;
|
|
1850
|
+
const base = {
|
|
1851
|
+
requestId: requestId ?? response.headers.get("x-request-id") ?? void 0,
|
|
1852
|
+
traceId,
|
|
1853
|
+
responseHeaders: headersToRecord(response.headers),
|
|
1854
|
+
body,
|
|
1855
|
+
code,
|
|
1856
|
+
info,
|
|
1857
|
+
retryable: isRetrySafe(method, idempotent, { status, retryAfter })
|
|
1858
|
+
};
|
|
1859
|
+
switch (status) {
|
|
1860
|
+
case 400:
|
|
1861
|
+
throw new BadRequestError(message, base);
|
|
1589
1862
|
case 401:
|
|
1590
1863
|
throw new AuthenticationError(message, base);
|
|
1591
1864
|
case 403:
|
|
@@ -1594,35 +1867,46 @@ function raiseForStatus(response, body) {
|
|
|
1594
1867
|
throw new NotFoundError(message, base);
|
|
1595
1868
|
case 409:
|
|
1596
1869
|
throw new ConflictError(message, base);
|
|
1597
|
-
case 422:
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
errors = JSON.parse(body);
|
|
1601
|
-
} catch {
|
|
1602
|
-
errors = void 0;
|
|
1603
|
-
}
|
|
1604
|
-
throw new UnprocessableError(message, { ...base, errors });
|
|
1605
|
-
}
|
|
1606
|
-
case 429: {
|
|
1607
|
-
const retryHeader = response.headers.get("retry-after") ?? "";
|
|
1608
|
-
const retryAfter = /^\d+$/.test(retryHeader) ? Number.parseInt(retryHeader, 10) : void 0;
|
|
1870
|
+
case 422:
|
|
1871
|
+
throw new UnprocessableError(message, { ...base, errors: parsed });
|
|
1872
|
+
case 429:
|
|
1609
1873
|
throw new RateLimitError(message, { ...base, retryAfter });
|
|
1610
|
-
}
|
|
1611
1874
|
default:
|
|
1612
|
-
if (
|
|
1613
|
-
|
|
1614
|
-
}
|
|
1615
|
-
throw new ModusError(message, { ...base, statusCode: response.status });
|
|
1875
|
+
if (status >= 500) throw new InternalServerError(message, status, base);
|
|
1876
|
+
throw new ModusError(message, { ...base, statusCode: status });
|
|
1616
1877
|
}
|
|
1617
1878
|
}
|
|
1618
|
-
function wrapNetworkError(error, baseUrl) {
|
|
1619
|
-
const detail = error instanceof Error ? error.message : String(error);
|
|
1879
|
+
function wrapNetworkError(error, baseUrl, method, idempotent, traceId) {
|
|
1880
|
+
const detail = error instanceof DOMException && (error.name === "AbortError" || error.name === "TimeoutError") ? "Request timed out" : error instanceof Error ? error.message : String(error);
|
|
1881
|
+
const cause = error instanceof Error ? error.cause : void 0;
|
|
1882
|
+
const causeCode = isRecord(cause) ? nonEmptyString(cause.code) : void 0;
|
|
1620
1883
|
return new APIConnectionError(
|
|
1621
|
-
`Network error communicating with Modus API at ${JSON.stringify(baseUrl)}: ${detail}. Check connectivity and that baseUrl is correct
|
|
1884
|
+
`Network error communicating with Modus API at ${JSON.stringify(baseUrl)}: ${detail}. Check connectivity and that baseUrl is correct.`,
|
|
1885
|
+
{ retryable: isRetrySafe(method, idempotent, { causeCode }), traceId }
|
|
1622
1886
|
);
|
|
1623
1887
|
}
|
|
1624
|
-
|
|
1625
|
-
|
|
1888
|
+
function parseJsonBody(response, body, traceId) {
|
|
1889
|
+
try {
|
|
1890
|
+
return JSON.parse(body);
|
|
1891
|
+
} catch {
|
|
1892
|
+
const contentType = response.headers.get("content-type") ?? "";
|
|
1893
|
+
throw new ModusError(
|
|
1894
|
+
`Invalid JSON in HTTP ${response.status} response (content-type ${JSON.stringify(contentType)}): ` + body.slice(0, 200),
|
|
1895
|
+
{
|
|
1896
|
+
statusCode: response.status,
|
|
1897
|
+
requestId: response.headers.get("x-request-id") ?? void 0,
|
|
1898
|
+
traceId,
|
|
1899
|
+
responseHeaders: headersToRecord(response.headers),
|
|
1900
|
+
body
|
|
1901
|
+
}
|
|
1902
|
+
);
|
|
1903
|
+
}
|
|
1904
|
+
}
|
|
1905
|
+
function withTraceparent(headers) {
|
|
1906
|
+
const own = headerValue(headers, "traceparent");
|
|
1907
|
+
if (own !== void 0) return { headers, traceId: traceIdOf(own) };
|
|
1908
|
+
const value = traceparent();
|
|
1909
|
+
return { headers: { ...headers, traceparent: value }, traceId: traceIdOf(value) };
|
|
1626
1910
|
}
|
|
1627
1911
|
async function readBodyPreview(response, maxChars = 200) {
|
|
1628
1912
|
if (!response.body) return "";
|
|
@@ -1662,24 +1946,26 @@ var HttpClient = class {
|
|
|
1662
1946
|
async request(method, path, options = {}) {
|
|
1663
1947
|
const baseUrl = options.baseUrl ?? this.config.baseUrl;
|
|
1664
1948
|
const url = buildUrl(baseUrl, path, options.params);
|
|
1949
|
+
const idempotent = options.idempotent ?? false;
|
|
1950
|
+
const { headers, traceId } = withTraceparent(
|
|
1951
|
+
mergeHeaders(this.defaultHeaders(), options.headers, authHeaders(this.config.apiKey))
|
|
1952
|
+
);
|
|
1953
|
+
let response;
|
|
1954
|
+
let body;
|
|
1665
1955
|
try {
|
|
1666
|
-
|
|
1956
|
+
response = await this.config.fetch(url, {
|
|
1667
1957
|
method,
|
|
1668
|
-
headers
|
|
1958
|
+
headers,
|
|
1669
1959
|
body: options.json !== void 0 ? JSON.stringify(options.json) : void 0,
|
|
1670
1960
|
signal: AbortSignal.timeout(this.config.timeoutMs)
|
|
1671
1961
|
});
|
|
1672
|
-
|
|
1673
|
-
raiseForStatus(response, body);
|
|
1674
|
-
if (response.status === 204 || !body) return null;
|
|
1675
|
-
return JSON.parse(body);
|
|
1962
|
+
body = await response.text();
|
|
1676
1963
|
} catch (error) {
|
|
1677
|
-
|
|
1678
|
-
if (error instanceof DOMException && error.name === "AbortError") {
|
|
1679
|
-
throw wrapNetworkError(new Error("Request timed out"), baseUrl);
|
|
1680
|
-
}
|
|
1681
|
-
throw wrapNetworkError(error, baseUrl);
|
|
1964
|
+
throw wrapNetworkError(error, baseUrl, method, idempotent, traceId);
|
|
1682
1965
|
}
|
|
1966
|
+
raiseForStatus(response, body, method, idempotent, traceId);
|
|
1967
|
+
if (response.status === 204 || !body) return null;
|
|
1968
|
+
return parseJsonBody(response, body, traceId);
|
|
1683
1969
|
}
|
|
1684
1970
|
get(path, params, options = {}) {
|
|
1685
1971
|
return this.request("GET", path, { params, ...options });
|
|
@@ -1699,23 +1985,27 @@ var HttpClient = class {
|
|
|
1699
1985
|
async *stream(method, path, options = {}) {
|
|
1700
1986
|
const baseUrl = options.baseUrl ?? this.config.baseUrl;
|
|
1701
1987
|
const url = buildUrl(baseUrl, path, options.params);
|
|
1988
|
+
const idempotent = options.idempotent ?? false;
|
|
1989
|
+
const idle = new IdleTimeout(this.config.timeoutMs);
|
|
1990
|
+
const { headers, traceId } = withTraceparent(
|
|
1991
|
+
mergeHeaders(
|
|
1992
|
+
this.defaultHeaders(),
|
|
1993
|
+
options.headers,
|
|
1994
|
+
{ Accept: "text/event-stream" },
|
|
1995
|
+
authHeaders(this.config.apiKey)
|
|
1996
|
+
)
|
|
1997
|
+
);
|
|
1998
|
+
let reader;
|
|
1702
1999
|
try {
|
|
1703
2000
|
const response = await this.config.fetch(url, {
|
|
1704
2001
|
method,
|
|
1705
|
-
|
|
1706
|
-
// Accept returns {"runId","status":"pending"} instead of token SSE.
|
|
1707
|
-
headers: mergeHeaders(
|
|
1708
|
-
this.defaultHeaders(),
|
|
1709
|
-
options.headers,
|
|
1710
|
-
{ Accept: "text/event-stream" },
|
|
1711
|
-
authHeaders(this.config.apiKey)
|
|
1712
|
-
),
|
|
2002
|
+
headers,
|
|
1713
2003
|
body: options.json !== void 0 ? JSON.stringify(options.json) : void 0,
|
|
1714
|
-
signal:
|
|
2004
|
+
signal: idle.signal
|
|
1715
2005
|
});
|
|
2006
|
+
idle.touch();
|
|
1716
2007
|
if (!response.ok) {
|
|
1717
|
-
|
|
1718
|
-
raiseForStatus(response, body);
|
|
2008
|
+
raiseForStatus(response, await response.text(), method, idempotent, traceId);
|
|
1719
2009
|
return;
|
|
1720
2010
|
}
|
|
1721
2011
|
const contentType = response.headers.get("content-type") ?? "";
|
|
@@ -1723,16 +2013,17 @@ var HttpClient = class {
|
|
|
1723
2013
|
const preview = await readBodyPreview(response);
|
|
1724
2014
|
throw new ModusError(
|
|
1725
2015
|
`Unexpected stream response: expected Content-Type text/event-stream, got ${JSON.stringify(contentType) || "(missing)"}. Body preview: ${preview}`,
|
|
1726
|
-
{ statusCode: response.status, body: preview }
|
|
2016
|
+
{ statusCode: response.status, body: preview, traceId }
|
|
1727
2017
|
);
|
|
1728
2018
|
}
|
|
1729
2019
|
if (!response.body) return;
|
|
1730
|
-
|
|
2020
|
+
reader = response.body.getReader();
|
|
1731
2021
|
const decoder = new TextDecoder();
|
|
1732
2022
|
let buffer = "";
|
|
1733
2023
|
while (true) {
|
|
1734
2024
|
const { done, value } = await reader.read();
|
|
1735
2025
|
if (done) break;
|
|
2026
|
+
idle.touch();
|
|
1736
2027
|
buffer += decoder.decode(value, { stream: true });
|
|
1737
2028
|
const lines = buffer.split("\n");
|
|
1738
2029
|
buffer = lines.pop() ?? "";
|
|
@@ -1743,10 +2034,10 @@ var HttpClient = class {
|
|
|
1743
2034
|
if (buffer.trim()) yield buffer;
|
|
1744
2035
|
} catch (error) {
|
|
1745
2036
|
if (error instanceof ModusError) throw error;
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
2037
|
+
throw wrapNetworkError(error, baseUrl, method, idempotent, traceId);
|
|
2038
|
+
} finally {
|
|
2039
|
+
idle.clear();
|
|
2040
|
+
await reader?.cancel().catch(() => void 0);
|
|
1750
2041
|
}
|
|
1751
2042
|
}
|
|
1752
2043
|
streamGet(path, params, options = {}) {
|
|
@@ -1756,6 +2047,26 @@ var HttpClient = class {
|
|
|
1756
2047
|
return this.stream("POST", path, { json, ...options });
|
|
1757
2048
|
}
|
|
1758
2049
|
};
|
|
2050
|
+
var IdleTimeout = class {
|
|
2051
|
+
constructor(ms) {
|
|
2052
|
+
this.ms = ms;
|
|
2053
|
+
this.controller = new AbortController();
|
|
2054
|
+
this.touch();
|
|
2055
|
+
}
|
|
2056
|
+
get signal() {
|
|
2057
|
+
return this.controller.signal;
|
|
2058
|
+
}
|
|
2059
|
+
touch() {
|
|
2060
|
+
this.clear();
|
|
2061
|
+
this.timer = setTimeout(
|
|
2062
|
+
() => this.controller.abort(new DOMException("Stream idle timeout", "TimeoutError")),
|
|
2063
|
+
this.ms
|
|
2064
|
+
);
|
|
2065
|
+
}
|
|
2066
|
+
clear() {
|
|
2067
|
+
if (this.timer !== void 0) clearTimeout(this.timer);
|
|
2068
|
+
}
|
|
2069
|
+
};
|
|
1759
2070
|
|
|
1760
2071
|
// src/_client-base.ts
|
|
1761
2072
|
var ModusClientBase = class {
|
|
@@ -1786,9 +2097,11 @@ var WRITE_BODY_ALLOWED_KEYS = {
|
|
|
1786
2097
|
ContextFilesController_uploadFromUrls: ["urls"],
|
|
1787
2098
|
ContextFilesController_uploadUrl: ["fileName", "contentType", "fileSize"],
|
|
1788
2099
|
ContextFilesController_uploadUrls: ["files"],
|
|
2100
|
+
ContextItemAccessController_updateAccess: ["visibility", "groupPermissions", "sharedWith"],
|
|
1789
2101
|
ContextItemsController_lookup: ["contextType", "dataPath", "contentProjection"],
|
|
1790
2102
|
ContextItemsController_move: ["destinationFolderUid"],
|
|
1791
2103
|
ContextItemsController_update: ["contextType", "content", "description", "userFeedback", "topics"],
|
|
2104
|
+
ContextItemsQueryController_query: ["sql", "maxRows"],
|
|
1792
2105
|
CustomContextItemsController_batchCreate: ["items"],
|
|
1793
2106
|
CustomContextItemsController_create: ["kind", "sourceId", "sourceName", "collectionId", "collectionName", "externalId", "fieldName", "name", "entityType", "description", "content", "url", "attributes", "dataType", "value", "samples", "raw", "topics", "idempotencyKey", "access"],
|
|
1794
2107
|
CustomContextItemsController_createRelations: ["relations"],
|
|
@@ -1803,15 +2116,15 @@ var WRITE_BODY_ALLOWED_KEYS = {
|
|
|
1803
2116
|
DashboardsController_updateLayout: ["expectedRevision", "elements"],
|
|
1804
2117
|
EvaluationsController_updateConfig: ["enabled", "cadence", "judgeModel", "judgeGuidance", "notifications"],
|
|
1805
2118
|
IngestedDataController_upload: ["integration_type", "request", "response"],
|
|
1806
|
-
|
|
2119
|
+
ModusContextComposeController_compose: ["message", "limit"],
|
|
1807
2120
|
ModusContextController_compose: ["message", "limit"],
|
|
1808
2121
|
ModusRunsController_create: ["message", "sessionId", "organizationId", "version", "fileThreadId", "config", "attachments", "userContext", "source", "runId", "subordinateSkillIds"],
|
|
1809
2122
|
ResumeRunsController_create: ["message", "sessionId", "organizationId", "version", "fileThreadId", "config", "attachments", "userContext", "source", "runId", "decision"],
|
|
1810
2123
|
RunLifecycleController_activeBySession: ["sessionIds"],
|
|
1811
2124
|
RunLifecycleController_cancel: [],
|
|
1812
|
-
RunLifecycleController_editQueued: [],
|
|
1813
|
-
RunLifecycleController_interrupt: [],
|
|
1814
|
-
|
|
2125
|
+
RunLifecycleController_editQueued: ["nextRun"],
|
|
2126
|
+
RunLifecycleController_interrupt: ["nextRun", "lastSeenEventId"],
|
|
2127
|
+
ScopeContextComposeController_compose: ["message", "limit"],
|
|
1815
2128
|
ScopeContextController_compose: ["message", "limit"],
|
|
1816
2129
|
ScopeInterfacesController_add: ["type", "name", "config"],
|
|
1817
2130
|
ScopeInterfacesController_update: ["name", "config"],
|
|
@@ -1819,12 +2132,16 @@ var WRITE_BODY_ALLOWED_KEYS = {
|
|
|
1819
2132
|
ScopeMemoriesController_update: ["memory", "metadata"],
|
|
1820
2133
|
ScopeRunsController_create: ["message", "sessionId", "organizationId", "version", "fileThreadId", "config", "attachments", "userContext", "source", "runId", "subordinateSkillIds"],
|
|
1821
2134
|
ScopesController_acceptOwnershipTransfer: [],
|
|
2135
|
+
ScopesController_addEvaluationCase: ["id", "task", "expectedOutput"],
|
|
2136
|
+
ScopesController_applySelectionOps: ["ops", "toolset", "validateOnly"],
|
|
1822
2137
|
ScopesController_create: ["name", "description", "expectedOutput", "instructions", "toolset", "model", "connectionSet", "contextSelections", "includeOwnLearnings", "interfaces", "accessConfig"],
|
|
1823
2138
|
ScopesController_deploy: [],
|
|
2139
|
+
ScopesController_mcpExposureCatalog: ["toolset", "connectionSet", "mcpToolExposure"],
|
|
1824
2140
|
ScopesController_patchMcpConfig: ["config"],
|
|
1825
2141
|
ScopesController_requestOwnershipTransfer: ["newOwnerUserId"],
|
|
1826
2142
|
ScopesController_restore: [],
|
|
1827
2143
|
ScopesController_update: ["name", "description", "expectedOutput", "instructions", "toolset", "model", "connectionSet", "contextSelections", "interfaces", "accessConfig", "managerId", "evaluations", "supervisionSubordinateDescriptions"],
|
|
2144
|
+
ScopesController_updateEvaluationCase: ["task", "expectedOutput"],
|
|
1828
2145
|
ScopeSupervisionController_set: ["subordinateAgentIds"],
|
|
1829
2146
|
ScopeSupervisionController_setActive: ["subordinateAgentIds"],
|
|
1830
2147
|
SuggestionsController_recordEvent: ["eventType", "source", "skillId", "threadId", "metadata"],
|
|
@@ -1846,23 +2163,29 @@ var WRITE_BODY_ALLOWED_KEYS = {
|
|
|
1846
2163
|
var DEFAULT_MAX_PAGE_SIZE = 200;
|
|
1847
2164
|
function validatePageSize(pageSize, maxPageSize) {
|
|
1848
2165
|
if (!Number.isInteger(pageSize) || pageSize < 1) {
|
|
1849
|
-
throw new
|
|
2166
|
+
throw new ValidationError(`page_size must be a positive int, got ${pageSize}`);
|
|
1850
2167
|
}
|
|
1851
2168
|
if (maxPageSize !== void 0 && pageSize > maxPageSize) {
|
|
1852
|
-
throw new
|
|
2169
|
+
throw new ValidationError(`page_size must be <= ${maxPageSize}, got ${pageSize}`);
|
|
1853
2170
|
}
|
|
1854
2171
|
}
|
|
1855
2172
|
function validateId(resourceId, name = "id") {
|
|
1856
|
-
if (typeof resourceId === "
|
|
1857
|
-
throw new
|
|
2173
|
+
if (typeof resourceId === "number") {
|
|
2174
|
+
if (!Number.isInteger(resourceId)) throw new ValidationError(`${name} must be an integer, got ${resourceId}`);
|
|
2175
|
+
return;
|
|
2176
|
+
}
|
|
2177
|
+
if (!resourceId.trim()) throw new ValidationError(`${name} must be a non-empty string or int`);
|
|
2178
|
+
if (resourceId === "." || resourceId === "..") {
|
|
2179
|
+
throw new ValidationError(`${name} must not be ${JSON.stringify(resourceId)}`);
|
|
1858
2180
|
}
|
|
1859
2181
|
}
|
|
1860
|
-
var
|
|
2182
|
+
var CHAT_MODELS = [
|
|
1861
2183
|
"claude-sonnet-5",
|
|
1862
2184
|
"claude-sonnet-5.5",
|
|
1863
2185
|
"claude-sonnet-4.6",
|
|
1864
2186
|
"claude-opus-4.8",
|
|
1865
2187
|
"claude-opus-5.5",
|
|
2188
|
+
"claude-haiku-5.5",
|
|
1866
2189
|
"gpt-5.2",
|
|
1867
2190
|
"gpt-5.5",
|
|
1868
2191
|
"gpt-5-mini",
|
|
@@ -1876,21 +2199,24 @@ var ALLOWED_CHAT_MODELS = /* @__PURE__ */ new Set([
|
|
|
1876
2199
|
"deepseek-chat-v3.1",
|
|
1877
2200
|
"deepseek-v4-pro",
|
|
1878
2201
|
"deepseek-v4-flash-latest",
|
|
2202
|
+
"deepseek-v4.1-flash-1017",
|
|
1879
2203
|
"minimax-m2.7",
|
|
1880
2204
|
"llama-4-maverick",
|
|
1881
2205
|
"llama-4-scout",
|
|
1882
2206
|
"llama-3.3-70b-instruct",
|
|
1883
2207
|
"gemini-3.1-pro-preview",
|
|
1884
2208
|
"gemini-3-flash-preview",
|
|
2209
|
+
"gemini-3.8-flash",
|
|
1885
2210
|
"grok-4.3-fast",
|
|
1886
2211
|
"grok-4.3",
|
|
1887
2212
|
"grok-4.7",
|
|
1888
2213
|
"kimi-k3"
|
|
1889
|
-
]
|
|
2214
|
+
];
|
|
2215
|
+
var ALLOWED_CHAT_MODELS = new Set(CHAT_MODELS);
|
|
1890
2216
|
function validateChatModel(model) {
|
|
1891
2217
|
if (!ALLOWED_CHAT_MODELS.has(model)) {
|
|
1892
2218
|
const supported = [...ALLOWED_CHAT_MODELS].sort().join(", ");
|
|
1893
|
-
throw new
|
|
2219
|
+
throw new ValidationError(`Unsupported model ${JSON.stringify(model)}. Choose one of: ${supported}.`);
|
|
1894
2220
|
}
|
|
1895
2221
|
}
|
|
1896
2222
|
function assertWriteBodyKeys(operationId, body) {
|
|
@@ -1923,9 +2249,11 @@ function formatPath(template, pathParams) {
|
|
|
1923
2249
|
if (!segment.startsWith("{") || !segment.endsWith("}")) return segment;
|
|
1924
2250
|
const key = segment.slice(1, -1);
|
|
1925
2251
|
if (!(key in pathParams)) {
|
|
1926
|
-
throw new
|
|
2252
|
+
throw new ValidationError(`Missing path parameter ${JSON.stringify(key)} for ${JSON.stringify(template)}`);
|
|
1927
2253
|
}
|
|
1928
|
-
|
|
2254
|
+
const value = String(pathParams[key]);
|
|
2255
|
+
validateId(value, key);
|
|
2256
|
+
return encodeURIComponent(value);
|
|
1929
2257
|
}).join("/");
|
|
1930
2258
|
}
|
|
1931
2259
|
function operationBaseUrl(http, operation) {
|
|
@@ -1946,7 +2274,7 @@ async function invokeOperation(http, operationId, options = {}) {
|
|
|
1946
2274
|
case "GET":
|
|
1947
2275
|
return http.get(path, params, requestOptions);
|
|
1948
2276
|
case "POST":
|
|
1949
|
-
return http.post(path, options.jsonBody, requestOptions);
|
|
2277
|
+
return http.post(path, options.jsonBody, { ...requestOptions, idempotent: op.idempotent });
|
|
1950
2278
|
case "PUT":
|
|
1951
2279
|
return http.put(path, options.jsonBody, requestOptions);
|
|
1952
2280
|
case "PATCH":
|
|
@@ -1958,50 +2286,25 @@ async function invokeOperation(http, operationId, options = {}) {
|
|
|
1958
2286
|
}
|
|
1959
2287
|
}
|
|
1960
2288
|
|
|
1961
|
-
// src/_retry.ts
|
|
1962
|
-
var DEPLOY_NOT_FOUND_BACKOFF_MS = 500;
|
|
1963
|
-
var MAX_DEPLOY_NOT_FOUND_RETRIES = 1;
|
|
1964
|
-
var RETRYABLE = [RateLimitError, InternalServerError, APIConnectionError];
|
|
1965
|
-
function isRetryable(error) {
|
|
1966
|
-
return RETRYABLE.some((Cls) => error instanceof Cls);
|
|
1967
|
-
}
|
|
1968
|
-
function backoffSeconds(attempt, error) {
|
|
1969
|
-
if (error instanceof RateLimitError && error.retryAfter !== void 0) {
|
|
1970
|
-
return Math.max(0, error.retryAfter);
|
|
1971
|
-
}
|
|
1972
|
-
if (attempt === 0) return 0;
|
|
1973
|
-
return Math.max(0.5, 2 ** (attempt - 1) + (Math.random() * 0.6 - 0.3));
|
|
1974
|
-
}
|
|
1975
|
-
function sleep(ms) {
|
|
1976
|
-
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
1977
|
-
}
|
|
1978
|
-
async function withRetry(fn, maxRetries, options = {}) {
|
|
1979
|
-
let deployNotFoundRetries = 0;
|
|
1980
|
-
let attempt = 0;
|
|
1981
|
-
while (true) {
|
|
1982
|
-
try {
|
|
1983
|
-
return await fn();
|
|
1984
|
-
} catch (error) {
|
|
1985
|
-
if (options.retryNotFoundOnDeploy && error instanceof NotFoundError && deployNotFoundRetries < MAX_DEPLOY_NOT_FOUND_RETRIES) {
|
|
1986
|
-
deployNotFoundRetries++;
|
|
1987
|
-
await sleep(DEPLOY_NOT_FOUND_BACKOFF_MS);
|
|
1988
|
-
continue;
|
|
1989
|
-
}
|
|
1990
|
-
if (!isRetryable(error) || attempt >= maxRetries) throw error;
|
|
1991
|
-
await sleep(backoffSeconds(attempt, error) * 1e3);
|
|
1992
|
-
attempt++;
|
|
1993
|
-
}
|
|
1994
|
-
}
|
|
1995
|
-
}
|
|
1996
|
-
|
|
1997
2289
|
// src/_request.ts
|
|
1998
2290
|
async function invokeWithRetry(config, http, operationId, options = {}) {
|
|
1999
2291
|
if (options.jsonBody !== void 0) {
|
|
2000
2292
|
assertWriteBodyKeys(operationId, options.jsonBody);
|
|
2001
2293
|
}
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
|
|
2294
|
+
const own = headerValue(config.defaultHeaders, "traceparent") ?? headerValue(options.headers, "traceparent");
|
|
2295
|
+
const traceId = own === void 0 ? newTraceId() : void 0;
|
|
2296
|
+
return withRetry(
|
|
2297
|
+
(resend) => invokeOperation(http, operationId, {
|
|
2298
|
+
...options,
|
|
2299
|
+
headers: {
|
|
2300
|
+
...traceId ? { traceparent: traceparent(traceId) } : {},
|
|
2301
|
+
...resend > 0 ? { "X-Modus-Retry-Attempt": String(resend) } : {},
|
|
2302
|
+
...options.headers
|
|
2303
|
+
}
|
|
2304
|
+
}),
|
|
2305
|
+
config.maxRetries,
|
|
2306
|
+
{ retryNotFoundOnDeploy: operationId.endsWith("_deploy") }
|
|
2307
|
+
);
|
|
2005
2308
|
}
|
|
2006
2309
|
function omitUndefined(obj) {
|
|
2007
2310
|
return Object.fromEntries(
|
|
@@ -2311,9 +2614,13 @@ var ScopeConversationsResource = class extends ScopesConversationsResourceBase {
|
|
|
2311
2614
|
*
|
|
2312
2615
|
* @example
|
|
2313
2616
|
* ```ts
|
|
2314
|
-
* const
|
|
2315
|
-
*
|
|
2316
|
-
*
|
|
2617
|
+
* const { items } = await client.scopes.conversations(scopeId).list()
|
|
2618
|
+
* const [first] = items
|
|
2619
|
+
* if (first) {
|
|
2620
|
+
* const thread = await client.scopes.conversations(scopeId).get(first.threadId)
|
|
2621
|
+
* for (const msg of thread.messages) {
|
|
2622
|
+
* console.log(msg.type, String(msg.content).slice(0, 80))
|
|
2623
|
+
* }
|
|
2317
2624
|
* }
|
|
2318
2625
|
* ```
|
|
2319
2626
|
*/
|
|
@@ -2321,7 +2628,7 @@ var ScopeConversationsResource = class extends ScopesConversationsResourceBase {
|
|
|
2321
2628
|
validateId(this.scopeId, "scope_id");
|
|
2322
2629
|
validateId(threadId, "thread_id");
|
|
2323
2630
|
if (options.beforeMessageIndex !== void 0 && options.messageLimit === void 0) {
|
|
2324
|
-
throw new
|
|
2631
|
+
throw new ValidationError("beforeMessageIndex requires messageLimit");
|
|
2325
2632
|
}
|
|
2326
2633
|
const data = await invokeWithRetry(this.config, this.http, "ScopeConversationsController_get", {
|
|
2327
2634
|
pathParams: { id: this.scopeId, threadId },
|
|
@@ -2338,6 +2645,7 @@ export {
|
|
|
2338
2645
|
OPERATIONS,
|
|
2339
2646
|
ModusError,
|
|
2340
2647
|
APIConnectionError,
|
|
2648
|
+
BadRequestError,
|
|
2341
2649
|
AuthenticationError,
|
|
2342
2650
|
PermissionDeniedError,
|
|
2343
2651
|
NotFoundError,
|
|
@@ -2348,6 +2656,7 @@ export {
|
|
|
2348
2656
|
RunCancelledError,
|
|
2349
2657
|
StreamTimeoutError,
|
|
2350
2658
|
ValidationError,
|
|
2659
|
+
requireAgentHost,
|
|
2351
2660
|
DEFAULT_MAX_PAGE_SIZE,
|
|
2352
2661
|
validatePageSize,
|
|
2353
2662
|
validateId,
|
|
@@ -2366,4 +2675,4 @@ export {
|
|
|
2366
2675
|
CustomContextItemsResource,
|
|
2367
2676
|
ScopeConversationsResource
|
|
2368
2677
|
};
|
|
2369
|
-
//# sourceMappingURL=chunk-
|
|
2678
|
+
//# sourceMappingURL=chunk-JVTQBBMZ.js.map
|