@alicloud/cs20151215 7.2.6 → 7.3.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.
@@ -0,0 +1,461 @@
1
+ // This file is auto-generated, don't edit it
2
+ import * as $dara from '@darabonba/typescript';
3
+
4
+
5
+ export class InvokeAgentRequestContext extends $dara.Model {
6
+ /**
7
+ * @remarks
8
+ * This parameter is required.
9
+ *
10
+ * @example
11
+ * test
12
+ */
13
+ description?: string;
14
+ /**
15
+ * @remarks
16
+ * This parameter is required.
17
+ *
18
+ * @example
19
+ * value
20
+ */
21
+ value?: string;
22
+ static names(): { [key: string]: string } {
23
+ return {
24
+ description: 'description',
25
+ value: 'value',
26
+ };
27
+ }
28
+
29
+ static types(): { [key: string]: any } {
30
+ return {
31
+ description: 'string',
32
+ value: 'string',
33
+ };
34
+ }
35
+
36
+ validate() {
37
+ super.validate();
38
+ }
39
+
40
+ constructor(map?: { [key: string]: any }) {
41
+ super(map);
42
+ }
43
+ }
44
+
45
+ export class InvokeAgentRequestForwardedProps extends $dara.Model {
46
+ /**
47
+ * @example
48
+ * true
49
+ */
50
+ enableThinking?: boolean;
51
+ /**
52
+ * @example
53
+ * zh
54
+ */
55
+ language?: string;
56
+ /**
57
+ * @example
58
+ * user
59
+ */
60
+ source?: string;
61
+ static names(): { [key: string]: string } {
62
+ return {
63
+ enableThinking: 'enableThinking',
64
+ language: 'language',
65
+ source: 'source',
66
+ };
67
+ }
68
+
69
+ static types(): { [key: string]: any } {
70
+ return {
71
+ enableThinking: 'boolean',
72
+ language: 'string',
73
+ source: 'string',
74
+ };
75
+ }
76
+
77
+ validate() {
78
+ super.validate();
79
+ }
80
+
81
+ constructor(map?: { [key: string]: any }) {
82
+ super(map);
83
+ }
84
+ }
85
+
86
+ export class InvokeAgentRequestMessagesToolCallsFunction extends $dara.Model {
87
+ /**
88
+ * @example
89
+ * {}
90
+ */
91
+ arguments?: string;
92
+ /**
93
+ * @example
94
+ * navy
95
+ */
96
+ name?: string;
97
+ static names(): { [key: string]: string } {
98
+ return {
99
+ arguments: 'arguments',
100
+ name: 'name',
101
+ };
102
+ }
103
+
104
+ static types(): { [key: string]: any } {
105
+ return {
106
+ arguments: 'string',
107
+ name: 'string',
108
+ };
109
+ }
110
+
111
+ validate() {
112
+ super.validate();
113
+ }
114
+
115
+ constructor(map?: { [key: string]: any }) {
116
+ super(map);
117
+ }
118
+ }
119
+
120
+ export class InvokeAgentRequestMessagesToolCalls extends $dara.Model {
121
+ /**
122
+ * @example
123
+ * ""
124
+ */
125
+ encryptedValue?: string;
126
+ /**
127
+ * @example
128
+ * {"name": "xxx", "arguments": "xxx"}
129
+ */
130
+ function?: InvokeAgentRequestMessagesToolCallsFunction;
131
+ /**
132
+ * @example
133
+ * 64ea4d94937a4c5c84e2b3b814d14696
134
+ */
135
+ id?: string;
136
+ /**
137
+ * @example
138
+ * {}
139
+ */
140
+ metadata?: { [key: string]: any };
141
+ /**
142
+ * @example
143
+ * function
144
+ */
145
+ type?: string;
146
+ static names(): { [key: string]: string } {
147
+ return {
148
+ encryptedValue: 'encryptedValue',
149
+ function: 'function',
150
+ id: 'id',
151
+ metadata: 'metadata',
152
+ type: 'type',
153
+ };
154
+ }
155
+
156
+ static types(): { [key: string]: any } {
157
+ return {
158
+ encryptedValue: 'string',
159
+ function: InvokeAgentRequestMessagesToolCallsFunction,
160
+ id: 'string',
161
+ metadata: { 'type': 'map', 'keyType': 'string', 'valueType': 'any' },
162
+ type: 'string',
163
+ };
164
+ }
165
+
166
+ validate() {
167
+ if(this.function && typeof (this.function as any).validate === 'function') {
168
+ (this.function as any).validate();
169
+ }
170
+ if(this.metadata) {
171
+ $dara.Model.validateMap(this.metadata);
172
+ }
173
+ super.validate();
174
+ }
175
+
176
+ constructor(map?: { [key: string]: any }) {
177
+ super(map);
178
+ }
179
+ }
180
+
181
+ export class InvokeAgentRequestMessages extends $dara.Model {
182
+ /**
183
+ * @example
184
+ * hello
185
+ */
186
+ content?: string;
187
+ /**
188
+ * @example
189
+ * ""
190
+ */
191
+ encryptedValue?: string;
192
+ /**
193
+ * @example
194
+ * 64ea4d94937a4c5c84e2b3b814d14696
195
+ */
196
+ id?: string;
197
+ /**
198
+ * @example
199
+ * {}
200
+ */
201
+ metadata?: { [key: string]: any };
202
+ /**
203
+ * @example
204
+ * n-1
205
+ */
206
+ name?: string;
207
+ /**
208
+ * @example
209
+ * user
210
+ */
211
+ role?: string;
212
+ /**
213
+ * @example
214
+ * 64ea4d94937a4c5c84e2b3b814d14696
215
+ */
216
+ subagentRunId?: string;
217
+ /**
218
+ * @example
219
+ * 64ea4d94937a4c5c84e2b3b814d14696
220
+ */
221
+ toolCallId?: string;
222
+ toolCalls?: InvokeAgentRequestMessagesToolCalls[];
223
+ static names(): { [key: string]: string } {
224
+ return {
225
+ content: 'content',
226
+ encryptedValue: 'encryptedValue',
227
+ id: 'id',
228
+ metadata: 'metadata',
229
+ name: 'name',
230
+ role: 'role',
231
+ subagentRunId: 'subagentRunId',
232
+ toolCallId: 'toolCallId',
233
+ toolCalls: 'toolCalls',
234
+ };
235
+ }
236
+
237
+ static types(): { [key: string]: any } {
238
+ return {
239
+ content: 'string',
240
+ encryptedValue: 'string',
241
+ id: 'string',
242
+ metadata: { 'type': 'map', 'keyType': 'string', 'valueType': 'any' },
243
+ name: 'string',
244
+ role: 'string',
245
+ subagentRunId: 'string',
246
+ toolCallId: 'string',
247
+ toolCalls: { 'type': 'array', 'itemType': InvokeAgentRequestMessagesToolCalls },
248
+ };
249
+ }
250
+
251
+ validate() {
252
+ if(this.metadata) {
253
+ $dara.Model.validateMap(this.metadata);
254
+ }
255
+ if(Array.isArray(this.toolCalls)) {
256
+ $dara.Model.validateArray(this.toolCalls);
257
+ }
258
+ super.validate();
259
+ }
260
+
261
+ constructor(map?: { [key: string]: any }) {
262
+ super(map);
263
+ }
264
+ }
265
+
266
+ export class InvokeAgentRequestResume extends $dara.Model {
267
+ /**
268
+ * @example
269
+ * i-1
270
+ */
271
+ interruptId?: string;
272
+ /**
273
+ * @example
274
+ * {"decision":"yes"}
275
+ */
276
+ payload?: any;
277
+ /**
278
+ * @example
279
+ * resolved
280
+ */
281
+ status?: string;
282
+ static names(): { [key: string]: string } {
283
+ return {
284
+ interruptId: 'interruptId',
285
+ payload: 'payload',
286
+ status: 'status',
287
+ };
288
+ }
289
+
290
+ static types(): { [key: string]: any } {
291
+ return {
292
+ interruptId: 'string',
293
+ payload: 'any',
294
+ status: 'string',
295
+ };
296
+ }
297
+
298
+ validate() {
299
+ super.validate();
300
+ }
301
+
302
+ constructor(map?: { [key: string]: any }) {
303
+ super(map);
304
+ }
305
+ }
306
+
307
+ export class InvokeAgentRequestTools extends $dara.Model {
308
+ /**
309
+ * @remarks
310
+ * This parameter is required.
311
+ *
312
+ * @example
313
+ * description
314
+ */
315
+ description?: string;
316
+ /**
317
+ * @example
318
+ * {}
319
+ */
320
+ metadata?: { [key: string]: any };
321
+ /**
322
+ * @remarks
323
+ * This parameter is required.
324
+ *
325
+ * @example
326
+ * cluster-qa-icloud-edge-ohttp
327
+ */
328
+ name?: string;
329
+ /**
330
+ * @example
331
+ * {\\"region\\": \\"cn-shanghai\\", \\"vpcId\\": \\"vpc-uf6bnhlxne8enjurxxjv4\\", \\"functionName\\": \\"filemgr-cn-shanghai-334a349cd2\\", \\"mountPointsServerAddr\\": \\"334a349cd2-umc45.cn-shanghai.nas.aliyuncs.com\\"}
332
+ */
333
+ parameters?: any;
334
+ static names(): { [key: string]: string } {
335
+ return {
336
+ description: 'description',
337
+ metadata: 'metadata',
338
+ name: 'name',
339
+ parameters: 'parameters',
340
+ };
341
+ }
342
+
343
+ static types(): { [key: string]: any } {
344
+ return {
345
+ description: 'string',
346
+ metadata: { 'type': 'map', 'keyType': 'string', 'valueType': 'any' },
347
+ name: 'string',
348
+ parameters: 'any',
349
+ };
350
+ }
351
+
352
+ validate() {
353
+ if(this.metadata) {
354
+ $dara.Model.validateMap(this.metadata);
355
+ }
356
+ super.validate();
357
+ }
358
+
359
+ constructor(map?: { [key: string]: any }) {
360
+ super(map);
361
+ }
362
+ }
363
+
364
+ export class InvokeAgentRequest extends $dara.Model {
365
+ /**
366
+ * @example
367
+ * [{"description":"cluster","value":"c-1"}]
368
+ */
369
+ context?: InvokeAgentRequestContext[];
370
+ /**
371
+ * @example
372
+ * {"enableThinking":true}
373
+ */
374
+ forwardedProps?: InvokeAgentRequestForwardedProps;
375
+ /**
376
+ * @example
377
+ * [{"id":"m-1","role":"user","content":"你好"}]
378
+ */
379
+ messages?: InvokeAgentRequestMessages[];
380
+ /**
381
+ * @example
382
+ * r-0
383
+ */
384
+ parentRunId?: string;
385
+ /**
386
+ * @example
387
+ * [{"interruptId":"i-1","status":"resolved","payload":{"decision":"yes"}}]
388
+ */
389
+ resume?: InvokeAgentRequestResume[];
390
+ /**
391
+ * @example
392
+ * run-1
393
+ */
394
+ runId?: string;
395
+ /**
396
+ * @example
397
+ * {}
398
+ */
399
+ state?: any;
400
+ /**
401
+ * @example
402
+ * abcdef0123456789abcdef0123456789
403
+ */
404
+ threadId?: string;
405
+ /**
406
+ * @example
407
+ * []
408
+ */
409
+ tools?: InvokeAgentRequestTools[];
410
+ static names(): { [key: string]: string } {
411
+ return {
412
+ context: 'context',
413
+ forwardedProps: 'forwardedProps',
414
+ messages: 'messages',
415
+ parentRunId: 'parentRunId',
416
+ resume: 'resume',
417
+ runId: 'runId',
418
+ state: 'state',
419
+ threadId: 'threadId',
420
+ tools: 'tools',
421
+ };
422
+ }
423
+
424
+ static types(): { [key: string]: any } {
425
+ return {
426
+ context: { 'type': 'array', 'itemType': InvokeAgentRequestContext },
427
+ forwardedProps: InvokeAgentRequestForwardedProps,
428
+ messages: { 'type': 'array', 'itemType': InvokeAgentRequestMessages },
429
+ parentRunId: 'string',
430
+ resume: { 'type': 'array', 'itemType': InvokeAgentRequestResume },
431
+ runId: 'string',
432
+ state: 'any',
433
+ threadId: 'string',
434
+ tools: { 'type': 'array', 'itemType': InvokeAgentRequestTools },
435
+ };
436
+ }
437
+
438
+ validate() {
439
+ if(Array.isArray(this.context)) {
440
+ $dara.Model.validateArray(this.context);
441
+ }
442
+ if(this.forwardedProps && typeof (this.forwardedProps as any).validate === 'function') {
443
+ (this.forwardedProps as any).validate();
444
+ }
445
+ if(Array.isArray(this.messages)) {
446
+ $dara.Model.validateArray(this.messages);
447
+ }
448
+ if(Array.isArray(this.resume)) {
449
+ $dara.Model.validateArray(this.resume);
450
+ }
451
+ if(Array.isArray(this.tools)) {
452
+ $dara.Model.validateArray(this.tools);
453
+ }
454
+ super.validate();
455
+ }
456
+
457
+ constructor(map?: { [key: string]: any }) {
458
+ super(map);
459
+ }
460
+ }
461
+
@@ -0,0 +1,46 @@
1
+ // This file is auto-generated, don't edit it
2
+ import * as $dara from '@darabonba/typescript';
3
+ import { InvokeAgentResponseBody } from "./InvokeAgentResponseBody";
4
+
5
+
6
+ export class InvokeAgentResponse extends $dara.Model {
7
+ headers?: { [key: string]: string };
8
+ statusCode?: number;
9
+ id?: string;
10
+ event?: string;
11
+ body?: InvokeAgentResponseBody;
12
+ static names(): { [key: string]: string } {
13
+ return {
14
+ headers: 'headers',
15
+ statusCode: 'statusCode',
16
+ id: 'id',
17
+ event: 'event',
18
+ body: 'body',
19
+ };
20
+ }
21
+
22
+ static types(): { [key: string]: any } {
23
+ return {
24
+ headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
25
+ statusCode: 'number',
26
+ id: 'string',
27
+ event: 'string',
28
+ body: InvokeAgentResponseBody,
29
+ };
30
+ }
31
+
32
+ validate() {
33
+ if(this.headers) {
34
+ $dara.Model.validateMap(this.headers);
35
+ }
36
+ if(this.body && typeof (this.body as any).validate === 'function') {
37
+ (this.body as any).validate();
38
+ }
39
+ super.validate();
40
+ }
41
+
42
+ constructor(map?: { [key: string]: any }) {
43
+ super(map);
44
+ }
45
+ }
46
+