@crestal/nation-sdk 0.1.19 → 0.1.20

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/api.ts CHANGED
@@ -4,7 +4,7 @@
4
4
  * Nation IntentKit API
5
5
  * API for Nation IntentKit services
6
6
  *
7
- * The version of the OpenAPI document: 0.1.19
7
+ * The version of the OpenAPI document: 0.1.20
8
8
  *
9
9
  *
10
10
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -97,6 +97,31 @@ export interface AgentExample {
97
97
  */
98
98
  'prompt': string;
99
99
  }
100
+ /**
101
+ * Paginated response model for agents list. Contains a list of agents, a flag indicating if more items are available, and a cursor for pagination.
102
+ * @export
103
+ * @interface AgentListResponse
104
+ */
105
+ export interface AgentListResponse {
106
+ /**
107
+ * List of agents
108
+ * @type {Array<AgentResponse>}
109
+ * @memberof AgentListResponse
110
+ */
111
+ 'data': Array<AgentResponse>;
112
+ /**
113
+ * Indicates if there are more items
114
+ * @type {boolean}
115
+ * @memberof AgentListResponse
116
+ */
117
+ 'has_more': boolean;
118
+ /**
119
+ *
120
+ * @type {string}
121
+ * @memberof AgentListResponse
122
+ */
123
+ 'next_cursor'?: string | null;
124
+ }
100
125
  /**
101
126
  * Response model for Agent API.
102
127
  * @export
@@ -333,6 +358,21 @@ export const AgentResponseWalletProviderEnum = {
333
358
 
334
359
  export type AgentResponseWalletProviderEnum = typeof AgentResponseWalletProviderEnum[keyof typeof AgentResponseWalletProviderEnum];
335
360
 
361
+ /**
362
+ * Sort options for agents list.
363
+ * @export
364
+ * @enum {string}
365
+ */
366
+
367
+ export const AgentSortOption = {
368
+ CreatedAtDesc: 'created_at desc',
369
+ CreatedAtAsc: 'created_at asc',
370
+ UpdatedAtDesc: 'updated_at desc'
371
+ } as const;
372
+
373
+ export type AgentSortOption = typeof AgentSortOption[keyof typeof AgentSortOption];
374
+
375
+
336
376
  /**
337
377
  * Response model for agent statistics.
338
378
  * @export
@@ -1232,6 +1272,12 @@ export interface CreditEvent {
1232
1272
  * @memberof CreditEvent
1233
1273
  */
1234
1274
  'agent_id'?: string | null;
1275
+ /**
1276
+ *
1277
+ * @type {string}
1278
+ * @memberof CreditEvent
1279
+ */
1280
+ 'agent_wallet_address'?: string | null;
1235
1281
  /**
1236
1282
  *
1237
1283
  * @type {string}
@@ -1487,6 +1533,12 @@ export interface CreditEventWithAgent {
1487
1533
  * @memberof CreditEventWithAgent
1488
1534
  */
1489
1535
  'agent_id'?: string | null;
1536
+ /**
1537
+ *
1538
+ * @type {string}
1539
+ * @memberof CreditEventWithAgent
1540
+ */
1541
+ 'agent_wallet_address'?: string | null;
1490
1542
  /**
1491
1543
  *
1492
1544
  * @type {string}
@@ -2235,15 +2287,13 @@ export interface ValidationErrorLocInner {
2235
2287
  export const AgentApiAxiosParamCreator = function (configuration?: Configuration) {
2236
2288
  return {
2237
2289
  /**
2238
- * Create a new agent owned by the current user. The agent will be initialized with the provided details.
2239
- * @summary Create a new agent
2240
- * @param {AgentUpdate} agentUpdate
2290
+ * Create a new agent. **Request Body:** * `agent` - Agent configuration **Returns:** * `AgentResponse` - Created agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format or agent ID already exists - 500: Database error
2291
+ * @summary Create Agent
2292
+ * @param {AgentUpdate} [agentUpdate]
2241
2293
  * @param {*} [options] Override http request option.
2242
2294
  * @throws {RequiredError}
2243
2295
  */
2244
- createAgent: async (agentUpdate: AgentUpdate, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2245
- // verify required parameter 'agentUpdate' is not null or undefined
2246
- assertParamExists('createAgent', 'agentUpdate', agentUpdate)
2296
+ createAgent: async (agentUpdate?: AgentUpdate, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2247
2297
  const localVarPath = `/agents`;
2248
2298
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
2249
2299
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
@@ -2275,17 +2325,14 @@ export const AgentApiAxiosParamCreator = function (configuration?: Configuration
2275
2325
  };
2276
2326
  },
2277
2327
  /**
2278
- * Retrieve a specific agent by its ID. Returns 404 if not found.
2279
- * @summary Get agent by ID
2280
- * @param {string} aid Agent ID
2328
+ * Create a new agent. **Request Body:** * `agent` - Agent configuration **Returns:** * `AgentResponse` - Created agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format or agent ID already exists - 500: Database error
2329
+ * @summary Create Agent
2330
+ * @param {AgentUpdate} [agentUpdate]
2281
2331
  * @param {*} [options] Override http request option.
2282
2332
  * @throws {RequiredError}
2283
2333
  */
2284
- getAgentById: async (aid: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2285
- // verify required parameter 'aid' is not null or undefined
2286
- assertParamExists('getAgentById', 'aid', aid)
2287
- const localVarPath = `/agents/{aid}`
2288
- .replace(`{${"aid"}}`, encodeURIComponent(String(aid)));
2334
+ createAgent_1: async (agentUpdate?: AgentUpdate, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2335
+ const localVarPath = `/agents`;
2289
2336
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
2290
2337
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2291
2338
  let baseOptions;
@@ -2293,15 +2340,22 @@ export const AgentApiAxiosParamCreator = function (configuration?: Configuration
2293
2340
  baseOptions = configuration.baseOptions;
2294
2341
  }
2295
2342
 
2296
- const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
2343
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
2297
2344
  const localVarHeaderParameter = {} as any;
2298
2345
  const localVarQueryParameter = {} as any;
2299
2346
 
2347
+ // authentication HTTPBearer required
2348
+ // http bearer authentication required
2349
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
2350
+
2300
2351
 
2301
2352
 
2353
+ localVarHeaderParameter['Content-Type'] = 'application/json';
2354
+
2302
2355
  setSearchParams(localVarUrlObj, localVarQueryParameter);
2303
2356
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2304
2357
  localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2358
+ localVarRequestOptions.data = serializeDataIfNeeded(agentUpdate, localVarRequestOptions, configuration)
2305
2359
 
2306
2360
  return {
2307
2361
  url: toPathString(localVarUrlObj),
@@ -2309,17 +2363,17 @@ export const AgentApiAxiosParamCreator = function (configuration?: Configuration
2309
2363
  };
2310
2364
  },
2311
2365
  /**
2312
- * Get statistics for an agent account. This endpoint is not in readonly router, because it may create a new account.
2313
- * @summary Get Agent Statistics
2314
- * @param {string} aid ID of the agent
2366
+ * Export agent configuration as YAML. **Path Parameters:** * `agent_id` - ID of the agent to export **Returns:** * `str` - YAML configuration of the agent **Raises:** * `HTTPException`: - 404: Agent not found
2367
+ * @summary Export Agent
2368
+ * @param {string} agentId ID of the agent to export
2315
2369
  * @param {*} [options] Override http request option.
2316
2370
  * @throws {RequiredError}
2317
2371
  */
2318
- getAgentStatistics: async (aid: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2319
- // verify required parameter 'aid' is not null or undefined
2320
- assertParamExists('getAgentStatistics', 'aid', aid)
2321
- const localVarPath = `/agents/{aid}/statistics`
2322
- .replace(`{${"aid"}}`, encodeURIComponent(String(aid)));
2372
+ exportAgent: async (agentId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2373
+ // verify required parameter 'agentId' is not null or undefined
2374
+ assertParamExists('exportAgent', 'agentId', agentId)
2375
+ const localVarPath = `/agents/{agent_id}/export`
2376
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
2323
2377
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
2324
2378
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2325
2379
  let baseOptions;
@@ -2331,6 +2385,10 @@ export const AgentApiAxiosParamCreator = function (configuration?: Configuration
2331
2385
  const localVarHeaderParameter = {} as any;
2332
2386
  const localVarQueryParameter = {} as any;
2333
2387
 
2388
+ // authentication HTTPBearer required
2389
+ // http bearer authentication required
2390
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
2391
+
2334
2392
 
2335
2393
 
2336
2394
  setSearchParams(localVarUrlObj, localVarQueryParameter);
@@ -2342,41 +2400,77 @@ export const AgentApiAxiosParamCreator = function (configuration?: Configuration
2342
2400
  options: localVarRequestOptions,
2343
2401
  };
2344
2402
  },
2345
- }
2346
- };
2347
-
2348
- /**
2349
- * AgentApi - functional programming interface
2350
- * @export
2351
- */
2352
- export const AgentApiFp = function(configuration?: Configuration) {
2353
- const localVarAxiosParamCreator = AgentApiAxiosParamCreator(configuration)
2354
- return {
2355
2403
  /**
2356
- * Create a new agent owned by the current user. The agent will be initialized with the provided details.
2357
- * @summary Create a new agent
2358
- * @param {AgentUpdate} agentUpdate
2404
+ * Export agent configuration as YAML. **Path Parameters:** * `agent_id` - ID of the agent to export **Returns:** * `str` - YAML configuration of the agent **Raises:** * `HTTPException`: - 404: Agent not found
2405
+ * @summary Export Agent
2406
+ * @param {string} agentId ID of the agent to export
2359
2407
  * @param {*} [options] Override http request option.
2360
2408
  * @throws {RequiredError}
2361
2409
  */
2362
- async createAgent(agentUpdate: AgentUpdate, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AgentResponse>> {
2363
- const localVarAxiosArgs = await localVarAxiosParamCreator.createAgent(agentUpdate, options);
2364
- const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
2365
- const localVarOperationServerBasePath = operationServerMap['AgentApi.createAgent']?.[localVarOperationServerIndex]?.url;
2366
- return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
2410
+ exportAgent_2: async (agentId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2411
+ // verify required parameter 'agentId' is not null or undefined
2412
+ assertParamExists('exportAgent_2', 'agentId', agentId)
2413
+ const localVarPath = `/agents/{agent_id}/export`
2414
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
2415
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2416
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2417
+ let baseOptions;
2418
+ if (configuration) {
2419
+ baseOptions = configuration.baseOptions;
2420
+ }
2421
+
2422
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
2423
+ const localVarHeaderParameter = {} as any;
2424
+ const localVarQueryParameter = {} as any;
2425
+
2426
+ // authentication HTTPBearer required
2427
+ // http bearer authentication required
2428
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
2429
+
2430
+
2431
+
2432
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2433
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2434
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2435
+
2436
+ return {
2437
+ url: toPathString(localVarUrlObj),
2438
+ options: localVarRequestOptions,
2439
+ };
2367
2440
  },
2368
2441
  /**
2369
- * Retrieve a specific agent by its ID. Returns 404 if not found.
2370
- * @summary Get agent by ID
2371
- * @param {string} aid Agent ID
2442
+ * Get a single agent by ID. **Path Parameters:** * `agent_id` - ID of the agent to retrieve **Returns:** * `AgentResponse` - Agent configuration with additional processed data **Raises:** * `HTTPException`: - 404: Agent not found
2443
+ * @summary Get Agent
2444
+ * @param {string} agentId ID of the agent to retrieve
2372
2445
  * @param {*} [options] Override http request option.
2373
2446
  * @throws {RequiredError}
2374
2447
  */
2375
- async getAgentById(aid: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AgentResponse>> {
2376
- const localVarAxiosArgs = await localVarAxiosParamCreator.getAgentById(aid, options);
2377
- const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
2378
- const localVarOperationServerBasePath = operationServerMap['AgentApi.getAgentById']?.[localVarOperationServerIndex]?.url;
2379
- return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
2448
+ getAgent: async (agentId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2449
+ // verify required parameter 'agentId' is not null or undefined
2450
+ assertParamExists('getAgent', 'agentId', agentId)
2451
+ const localVarPath = `/agents/{agent_id}`
2452
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
2453
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2454
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2455
+ let baseOptions;
2456
+ if (configuration) {
2457
+ baseOptions = configuration.baseOptions;
2458
+ }
2459
+
2460
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
2461
+ const localVarHeaderParameter = {} as any;
2462
+ const localVarQueryParameter = {} as any;
2463
+
2464
+
2465
+
2466
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2467
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2468
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2469
+
2470
+ return {
2471
+ url: toPathString(localVarUrlObj),
2472
+ options: localVarRequestOptions,
2473
+ };
2380
2474
  },
2381
2475
  /**
2382
2476
  * Get statistics for an agent account. This endpoint is not in readonly router, because it may create a new account.
@@ -2385,84 +2479,1132 @@ export const AgentApiFp = function(configuration?: Configuration) {
2385
2479
  * @param {*} [options] Override http request option.
2386
2480
  * @throws {RequiredError}
2387
2481
  */
2388
- async getAgentStatistics(aid: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AgentStatisticsResponse>> {
2389
- const localVarAxiosArgs = await localVarAxiosParamCreator.getAgentStatistics(aid, options);
2390
- const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
2391
- const localVarOperationServerBasePath = operationServerMap['AgentApi.getAgentStatistics']?.[localVarOperationServerIndex]?.url;
2392
- return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
2393
- },
2394
- }
2395
- };
2482
+ getAgentStatistics: async (aid: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2483
+ // verify required parameter 'aid' is not null or undefined
2484
+ assertParamExists('getAgentStatistics', 'aid', aid)
2485
+ const localVarPath = `/agents/{aid}/statistics`
2486
+ .replace(`{${"aid"}}`, encodeURIComponent(String(aid)));
2487
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2488
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2489
+ let baseOptions;
2490
+ if (configuration) {
2491
+ baseOptions = configuration.baseOptions;
2492
+ }
2396
2493
 
2397
- /**
2398
- * AgentApi - factory interface
2399
- * @export
2400
- */
2401
- export const AgentApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
2402
- const localVarFp = AgentApiFp(configuration)
2403
- return {
2494
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
2495
+ const localVarHeaderParameter = {} as any;
2496
+ const localVarQueryParameter = {} as any;
2497
+
2498
+
2499
+
2500
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2501
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2502
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2503
+
2504
+ return {
2505
+ url: toPathString(localVarUrlObj),
2506
+ options: localVarRequestOptions,
2507
+ };
2508
+ },
2404
2509
  /**
2405
- * Create a new agent owned by the current user. The agent will be initialized with the provided details.
2406
- * @summary Create a new agent
2407
- * @param {AgentUpdate} agentUpdate
2510
+ * Get a single agent by ID. **Path Parameters:** * `agent_id` - ID of the agent to retrieve **Returns:** * `AgentResponse` - Agent configuration with additional processed data **Raises:** * `HTTPException`: - 404: Agent not found
2511
+ * @summary Get Agent
2512
+ * @param {string} agentId ID of the agent to retrieve
2408
2513
  * @param {*} [options] Override http request option.
2409
2514
  * @throws {RequiredError}
2410
2515
  */
2411
- createAgent(agentUpdate: AgentUpdate, options?: RawAxiosRequestConfig): AxiosPromise<AgentResponse> {
2412
- return localVarFp.createAgent(agentUpdate, options).then((request) => request(axios, basePath));
2516
+ getAgent_3: async (agentId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2517
+ // verify required parameter 'agentId' is not null or undefined
2518
+ assertParamExists('getAgent_3', 'agentId', agentId)
2519
+ const localVarPath = `/agents/{agent_id}`
2520
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
2521
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2522
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2523
+ let baseOptions;
2524
+ if (configuration) {
2525
+ baseOptions = configuration.baseOptions;
2526
+ }
2527
+
2528
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
2529
+ const localVarHeaderParameter = {} as any;
2530
+ const localVarQueryParameter = {} as any;
2531
+
2532
+
2533
+
2534
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2535
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2536
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2537
+
2538
+ return {
2539
+ url: toPathString(localVarUrlObj),
2540
+ options: localVarRequestOptions,
2541
+ };
2413
2542
  },
2414
2543
  /**
2415
- * Retrieve a specific agent by its ID. Returns 404 if not found.
2416
- * @summary Get agent by ID
2417
- * @param {string} aid Agent ID
2544
+ * Get all agents with their quota information. **Query Parameters:** * `sort` - Sort order for the agents list * `cursor` - Cursor for pagination * `limit` - Maximum number of agents to return (1-100) **Returns:** * `AgentListResponse` - Paginated list of agents with their quota information and additional processed data
2545
+ * @summary Get Agents
2546
+ * @param {AgentSortOption} [sort] Sort order for agents list
2547
+ * @param {string | null} [cursor] Cursor for pagination
2548
+ * @param {number} [limit] Maximum number of agents to return
2418
2549
  * @param {*} [options] Override http request option.
2419
2550
  * @throws {RequiredError}
2420
2551
  */
2421
- getAgentById(aid: string, options?: RawAxiosRequestConfig): AxiosPromise<AgentResponse> {
2422
- return localVarFp.getAgentById(aid, options).then((request) => request(axios, basePath));
2552
+ getAgents: async (sort?: AgentSortOption, cursor?: string | null, limit?: number, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2553
+ const localVarPath = `/agents`;
2554
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2555
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2556
+ let baseOptions;
2557
+ if (configuration) {
2558
+ baseOptions = configuration.baseOptions;
2559
+ }
2560
+
2561
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
2562
+ const localVarHeaderParameter = {} as any;
2563
+ const localVarQueryParameter = {} as any;
2564
+
2565
+ if (sort !== undefined) {
2566
+ localVarQueryParameter['sort'] = sort;
2567
+ }
2568
+
2569
+ if (cursor !== undefined) {
2570
+ localVarQueryParameter['cursor'] = cursor;
2571
+ }
2572
+
2573
+ if (limit !== undefined) {
2574
+ localVarQueryParameter['limit'] = limit;
2575
+ }
2576
+
2577
+
2578
+
2579
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2580
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2581
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2582
+
2583
+ return {
2584
+ url: toPathString(localVarUrlObj),
2585
+ options: localVarRequestOptions,
2586
+ };
2423
2587
  },
2424
2588
  /**
2425
- * Get statistics for an agent account. This endpoint is not in readonly router, because it may create a new account.
2426
- * @summary Get Agent Statistics
2427
- * @param {string} aid ID of the agent
2589
+ * Get all agents with their quota information. **Query Parameters:** * `sort` - Sort order for the agents list * `cursor` - Cursor for pagination * `limit` - Maximum number of agents to return (1-100) **Returns:** * `AgentListResponse` - Paginated list of agents with their quota information and additional processed data
2590
+ * @summary Get Agents
2591
+ * @param {AgentSortOption} [sort] Sort order for agents list
2592
+ * @param {string | null} [cursor] Cursor for pagination
2593
+ * @param {number} [limit] Maximum number of agents to return
2428
2594
  * @param {*} [options] Override http request option.
2429
2595
  * @throws {RequiredError}
2430
2596
  */
2431
- getAgentStatistics(aid: string, options?: RawAxiosRequestConfig): AxiosPromise<AgentStatisticsResponse> {
2432
- return localVarFp.getAgentStatistics(aid, options).then((request) => request(axios, basePath));
2433
- },
2434
- };
2435
- };
2597
+ getAgents_4: async (sort?: AgentSortOption, cursor?: string | null, limit?: number, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2598
+ const localVarPath = `/agents`;
2599
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2600
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2601
+ let baseOptions;
2602
+ if (configuration) {
2603
+ baseOptions = configuration.baseOptions;
2604
+ }
2436
2605
 
2437
- /**
2438
- * AgentApi - object-oriented interface
2439
- * @export
2440
- * @class AgentApi
2441
- * @extends {BaseAPI}
2442
- */
2443
- export class AgentApi extends BaseAPI {
2444
- /**
2445
- * Create a new agent owned by the current user. The agent will be initialized with the provided details.
2446
- * @summary Create a new agent
2447
- * @param {AgentUpdate} agentUpdate
2448
- * @param {*} [options] Override http request option.
2449
- * @throws {RequiredError}
2450
- * @memberof AgentApi
2451
- */
2452
- public createAgent(agentUpdate: AgentUpdate, options?: RawAxiosRequestConfig) {
2606
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
2607
+ const localVarHeaderParameter = {} as any;
2608
+ const localVarQueryParameter = {} as any;
2609
+
2610
+ if (sort !== undefined) {
2611
+ localVarQueryParameter['sort'] = sort;
2612
+ }
2613
+
2614
+ if (cursor !== undefined) {
2615
+ localVarQueryParameter['cursor'] = cursor;
2616
+ }
2617
+
2618
+ if (limit !== undefined) {
2619
+ localVarQueryParameter['limit'] = limit;
2620
+ }
2621
+
2622
+
2623
+
2624
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2625
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2626
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2627
+
2628
+ return {
2629
+ url: toPathString(localVarUrlObj),
2630
+ options: localVarRequestOptions,
2631
+ };
2632
+ },
2633
+ /**
2634
+ * Import agent configuration from YAML file. Only updates existing agents, will not create new ones. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `file` - YAML file containing agent configuration **Returns:** * `str` - Success message **Raises:** * `HTTPException`: - 400: Invalid YAML or agent configuration - 404: Agent not found - 500: Server error
2635
+ * @summary Import Agent
2636
+ * @param {string} agentId
2637
+ * @param {File} file YAML file containing agent configuration
2638
+ * @param {*} [options] Override http request option.
2639
+ * @throws {RequiredError}
2640
+ */
2641
+ importAgent: async (agentId: string, file: File, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2642
+ // verify required parameter 'agentId' is not null or undefined
2643
+ assertParamExists('importAgent', 'agentId', agentId)
2644
+ // verify required parameter 'file' is not null or undefined
2645
+ assertParamExists('importAgent', 'file', file)
2646
+ const localVarPath = `/agents/{agent_id}/import`
2647
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
2648
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2649
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2650
+ let baseOptions;
2651
+ if (configuration) {
2652
+ baseOptions = configuration.baseOptions;
2653
+ }
2654
+
2655
+ const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
2656
+ const localVarHeaderParameter = {} as any;
2657
+ const localVarQueryParameter = {} as any;
2658
+ const localVarFormParams = new ((configuration && configuration.formDataCtor) || FormData)();
2659
+
2660
+ // authentication HTTPBearer required
2661
+ // http bearer authentication required
2662
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
2663
+
2664
+
2665
+ if (file !== undefined) {
2666
+ localVarFormParams.append('file', file as any);
2667
+ }
2668
+
2669
+
2670
+ localVarHeaderParameter['Content-Type'] = 'multipart/form-data';
2671
+
2672
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2673
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2674
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2675
+ localVarRequestOptions.data = localVarFormParams;
2676
+
2677
+ return {
2678
+ url: toPathString(localVarUrlObj),
2679
+ options: localVarRequestOptions,
2680
+ };
2681
+ },
2682
+ /**
2683
+ * Import agent configuration from YAML file. Only updates existing agents, will not create new ones. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `file` - YAML file containing agent configuration **Returns:** * `str` - Success message **Raises:** * `HTTPException`: - 400: Invalid YAML or agent configuration - 404: Agent not found - 500: Server error
2684
+ * @summary Import Agent
2685
+ * @param {string} agentId
2686
+ * @param {File} file YAML file containing agent configuration
2687
+ * @param {*} [options] Override http request option.
2688
+ * @throws {RequiredError}
2689
+ */
2690
+ importAgent_5: async (agentId: string, file: File, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2691
+ // verify required parameter 'agentId' is not null or undefined
2692
+ assertParamExists('importAgent_5', 'agentId', agentId)
2693
+ // verify required parameter 'file' is not null or undefined
2694
+ assertParamExists('importAgent_5', 'file', file)
2695
+ const localVarPath = `/agents/{agent_id}/import`
2696
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
2697
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2698
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2699
+ let baseOptions;
2700
+ if (configuration) {
2701
+ baseOptions = configuration.baseOptions;
2702
+ }
2703
+
2704
+ const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
2705
+ const localVarHeaderParameter = {} as any;
2706
+ const localVarQueryParameter = {} as any;
2707
+ const localVarFormParams = new ((configuration && configuration.formDataCtor) || FormData)();
2708
+
2709
+ // authentication HTTPBearer required
2710
+ // http bearer authentication required
2711
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
2712
+
2713
+
2714
+ if (file !== undefined) {
2715
+ localVarFormParams.append('file', file as any);
2716
+ }
2717
+
2718
+
2719
+ localVarHeaderParameter['Content-Type'] = 'multipart/form-data';
2720
+
2721
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2722
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2723
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2724
+ localVarRequestOptions.data = localVarFormParams;
2725
+
2726
+ return {
2727
+ url: toPathString(localVarUrlObj),
2728
+ options: localVarRequestOptions,
2729
+ };
2730
+ },
2731
+ /**
2732
+ * Override an existing agent. Use input to override agent configuration. If some fields are not provided, they will be reset to default values. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
2733
+ * @summary Override Agent
2734
+ * @param {string} agentId ID of the agent to update
2735
+ * @param {AgentUpdate} [agentUpdate]
2736
+ * @param {*} [options] Override http request option.
2737
+ * @throws {RequiredError}
2738
+ */
2739
+ overrideAgent: async (agentId: string, agentUpdate?: AgentUpdate, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2740
+ // verify required parameter 'agentId' is not null or undefined
2741
+ assertParamExists('overrideAgent', 'agentId', agentId)
2742
+ const localVarPath = `/agents/{agent_id}`
2743
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
2744
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2745
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2746
+ let baseOptions;
2747
+ if (configuration) {
2748
+ baseOptions = configuration.baseOptions;
2749
+ }
2750
+
2751
+ const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
2752
+ const localVarHeaderParameter = {} as any;
2753
+ const localVarQueryParameter = {} as any;
2754
+
2755
+ // authentication HTTPBearer required
2756
+ // http bearer authentication required
2757
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
2758
+
2759
+
2760
+
2761
+ localVarHeaderParameter['Content-Type'] = 'application/json';
2762
+
2763
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2764
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2765
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2766
+ localVarRequestOptions.data = serializeDataIfNeeded(agentUpdate, localVarRequestOptions, configuration)
2767
+
2768
+ return {
2769
+ url: toPathString(localVarUrlObj),
2770
+ options: localVarRequestOptions,
2771
+ };
2772
+ },
2773
+ /**
2774
+ * Override an existing agent. Use input to override agent configuration. If some fields are not provided, they will be reset to default values. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
2775
+ * @summary Override Agent
2776
+ * @param {string} agentId ID of the agent to update
2777
+ * @param {AgentUpdate} [agentUpdate]
2778
+ * @param {*} [options] Override http request option.
2779
+ * @throws {RequiredError}
2780
+ */
2781
+ overrideAgent_6: async (agentId: string, agentUpdate?: AgentUpdate, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2782
+ // verify required parameter 'agentId' is not null or undefined
2783
+ assertParamExists('overrideAgent_6', 'agentId', agentId)
2784
+ const localVarPath = `/agents/{agent_id}`
2785
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
2786
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2787
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2788
+ let baseOptions;
2789
+ if (configuration) {
2790
+ baseOptions = configuration.baseOptions;
2791
+ }
2792
+
2793
+ const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
2794
+ const localVarHeaderParameter = {} as any;
2795
+ const localVarQueryParameter = {} as any;
2796
+
2797
+ // authentication HTTPBearer required
2798
+ // http bearer authentication required
2799
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
2800
+
2801
+
2802
+
2803
+ localVarHeaderParameter['Content-Type'] = 'application/json';
2804
+
2805
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2806
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2807
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2808
+ localVarRequestOptions.data = serializeDataIfNeeded(agentUpdate, localVarRequestOptions, configuration)
2809
+
2810
+ return {
2811
+ url: toPathString(localVarUrlObj),
2812
+ options: localVarRequestOptions,
2813
+ };
2814
+ },
2815
+ /**
2816
+ * Update an existing agent. Use input to update agent configuration. If some fields are not provided, they will not be changed. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
2817
+ * @summary Update Agent
2818
+ * @param {string} agentId ID of the agent to update
2819
+ * @param {AgentUpdate} [agentUpdate]
2820
+ * @param {*} [options] Override http request option.
2821
+ * @throws {RequiredError}
2822
+ */
2823
+ updateAgent: async (agentId: string, agentUpdate?: AgentUpdate, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2824
+ // verify required parameter 'agentId' is not null or undefined
2825
+ assertParamExists('updateAgent', 'agentId', agentId)
2826
+ const localVarPath = `/agents/{agent_id}`
2827
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
2828
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2829
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2830
+ let baseOptions;
2831
+ if (configuration) {
2832
+ baseOptions = configuration.baseOptions;
2833
+ }
2834
+
2835
+ const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options};
2836
+ const localVarHeaderParameter = {} as any;
2837
+ const localVarQueryParameter = {} as any;
2838
+
2839
+ // authentication HTTPBearer required
2840
+ // http bearer authentication required
2841
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
2842
+
2843
+
2844
+
2845
+ localVarHeaderParameter['Content-Type'] = 'application/json';
2846
+
2847
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2848
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2849
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2850
+ localVarRequestOptions.data = serializeDataIfNeeded(agentUpdate, localVarRequestOptions, configuration)
2851
+
2852
+ return {
2853
+ url: toPathString(localVarUrlObj),
2854
+ options: localVarRequestOptions,
2855
+ };
2856
+ },
2857
+ /**
2858
+ * Update an existing agent. Use input to update agent configuration. If some fields are not provided, they will not be changed. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
2859
+ * @summary Update Agent
2860
+ * @param {string} agentId ID of the agent to update
2861
+ * @param {AgentUpdate} [agentUpdate]
2862
+ * @param {*} [options] Override http request option.
2863
+ * @throws {RequiredError}
2864
+ */
2865
+ updateAgent_7: async (agentId: string, agentUpdate?: AgentUpdate, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2866
+ // verify required parameter 'agentId' is not null or undefined
2867
+ assertParamExists('updateAgent_7', 'agentId', agentId)
2868
+ const localVarPath = `/agents/{agent_id}`
2869
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
2870
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2871
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2872
+ let baseOptions;
2873
+ if (configuration) {
2874
+ baseOptions = configuration.baseOptions;
2875
+ }
2876
+
2877
+ const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options};
2878
+ const localVarHeaderParameter = {} as any;
2879
+ const localVarQueryParameter = {} as any;
2880
+
2881
+ // authentication HTTPBearer required
2882
+ // http bearer authentication required
2883
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
2884
+
2885
+
2886
+
2887
+ localVarHeaderParameter['Content-Type'] = 'application/json';
2888
+
2889
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2890
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2891
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2892
+ localVarRequestOptions.data = serializeDataIfNeeded(agentUpdate, localVarRequestOptions, configuration)
2893
+
2894
+ return {
2895
+ url: toPathString(localVarUrlObj),
2896
+ options: localVarRequestOptions,
2897
+ };
2898
+ },
2899
+ /**
2900
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
2901
+ * @summary Validate Agent Create
2902
+ * @param {AgentUpdate} [agentUpdate]
2903
+ * @param {*} [options] Override http request option.
2904
+ * @throws {RequiredError}
2905
+ */
2906
+ validateAgentCreate: async (agentUpdate?: AgentUpdate, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2907
+ const localVarPath = `/agent/validate`;
2908
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2909
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2910
+ let baseOptions;
2911
+ if (configuration) {
2912
+ baseOptions = configuration.baseOptions;
2913
+ }
2914
+
2915
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
2916
+ const localVarHeaderParameter = {} as any;
2917
+ const localVarQueryParameter = {} as any;
2918
+
2919
+ // authentication HTTPBearer required
2920
+ // http bearer authentication required
2921
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
2922
+
2923
+
2924
+
2925
+ localVarHeaderParameter['Content-Type'] = 'application/json';
2926
+
2927
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2928
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2929
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2930
+ localVarRequestOptions.data = serializeDataIfNeeded(agentUpdate, localVarRequestOptions, configuration)
2931
+
2932
+ return {
2933
+ url: toPathString(localVarUrlObj),
2934
+ options: localVarRequestOptions,
2935
+ };
2936
+ },
2937
+ /**
2938
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
2939
+ * @summary Validate Agent Create
2940
+ * @param {AgentUpdate} [agentUpdate]
2941
+ * @param {*} [options] Override http request option.
2942
+ * @throws {RequiredError}
2943
+ */
2944
+ validateAgentCreate_8: async (agentUpdate?: AgentUpdate, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2945
+ const localVarPath = `/agent/validate`;
2946
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2947
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2948
+ let baseOptions;
2949
+ if (configuration) {
2950
+ baseOptions = configuration.baseOptions;
2951
+ }
2952
+
2953
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
2954
+ const localVarHeaderParameter = {} as any;
2955
+ const localVarQueryParameter = {} as any;
2956
+
2957
+ // authentication HTTPBearer required
2958
+ // http bearer authentication required
2959
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
2960
+
2961
+
2962
+
2963
+ localVarHeaderParameter['Content-Type'] = 'application/json';
2964
+
2965
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
2966
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2967
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
2968
+ localVarRequestOptions.data = serializeDataIfNeeded(agentUpdate, localVarRequestOptions, configuration)
2969
+
2970
+ return {
2971
+ url: toPathString(localVarUrlObj),
2972
+ options: localVarRequestOptions,
2973
+ };
2974
+ },
2975
+ /**
2976
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
2977
+ * @summary Validate Agent Update
2978
+ * @param {string} agentId Agent ID
2979
+ * @param {AgentUpdate} [agentUpdate]
2980
+ * @param {*} [options] Override http request option.
2981
+ * @throws {RequiredError}
2982
+ */
2983
+ validateAgentUpdate: async (agentId: string, agentUpdate?: AgentUpdate, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
2984
+ // verify required parameter 'agentId' is not null or undefined
2985
+ assertParamExists('validateAgentUpdate', 'agentId', agentId)
2986
+ const localVarPath = `/agents/{agent_id}/validate`
2987
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
2988
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
2989
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
2990
+ let baseOptions;
2991
+ if (configuration) {
2992
+ baseOptions = configuration.baseOptions;
2993
+ }
2994
+
2995
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
2996
+ const localVarHeaderParameter = {} as any;
2997
+ const localVarQueryParameter = {} as any;
2998
+
2999
+ // authentication HTTPBearer required
3000
+ // http bearer authentication required
3001
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
3002
+
3003
+
3004
+
3005
+ localVarHeaderParameter['Content-Type'] = 'application/json';
3006
+
3007
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
3008
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
3009
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
3010
+ localVarRequestOptions.data = serializeDataIfNeeded(agentUpdate, localVarRequestOptions, configuration)
3011
+
3012
+ return {
3013
+ url: toPathString(localVarUrlObj),
3014
+ options: localVarRequestOptions,
3015
+ };
3016
+ },
3017
+ /**
3018
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3019
+ * @summary Validate Agent Update
3020
+ * @param {string} agentId Agent ID
3021
+ * @param {AgentUpdate} [agentUpdate]
3022
+ * @param {*} [options] Override http request option.
3023
+ * @throws {RequiredError}
3024
+ */
3025
+ validateAgentUpdate_9: async (agentId: string, agentUpdate?: AgentUpdate, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
3026
+ // verify required parameter 'agentId' is not null or undefined
3027
+ assertParamExists('validateAgentUpdate_9', 'agentId', agentId)
3028
+ const localVarPath = `/agents/{agent_id}/validate`
3029
+ .replace(`{${"agent_id"}}`, encodeURIComponent(String(agentId)));
3030
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
3031
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
3032
+ let baseOptions;
3033
+ if (configuration) {
3034
+ baseOptions = configuration.baseOptions;
3035
+ }
3036
+
3037
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
3038
+ const localVarHeaderParameter = {} as any;
3039
+ const localVarQueryParameter = {} as any;
3040
+
3041
+ // authentication HTTPBearer required
3042
+ // http bearer authentication required
3043
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
3044
+
3045
+
3046
+
3047
+ localVarHeaderParameter['Content-Type'] = 'application/json';
3048
+
3049
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
3050
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
3051
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
3052
+ localVarRequestOptions.data = serializeDataIfNeeded(agentUpdate, localVarRequestOptions, configuration)
3053
+
3054
+ return {
3055
+ url: toPathString(localVarUrlObj),
3056
+ options: localVarRequestOptions,
3057
+ };
3058
+ },
3059
+ }
3060
+ };
3061
+
3062
+ /**
3063
+ * AgentApi - functional programming interface
3064
+ * @export
3065
+ */
3066
+ export const AgentApiFp = function(configuration?: Configuration) {
3067
+ const localVarAxiosParamCreator = AgentApiAxiosParamCreator(configuration)
3068
+ return {
3069
+ /**
3070
+ * Create a new agent. **Request Body:** * `agent` - Agent configuration **Returns:** * `AgentResponse` - Created agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format or agent ID already exists - 500: Database error
3071
+ * @summary Create Agent
3072
+ * @param {AgentUpdate} [agentUpdate]
3073
+ * @param {*} [options] Override http request option.
3074
+ * @throws {RequiredError}
3075
+ */
3076
+ async createAgent(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AgentResponse>> {
3077
+ const localVarAxiosArgs = await localVarAxiosParamCreator.createAgent(agentUpdate, options);
3078
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3079
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.createAgent']?.[localVarOperationServerIndex]?.url;
3080
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3081
+ },
3082
+ /**
3083
+ * Create a new agent. **Request Body:** * `agent` - Agent configuration **Returns:** * `AgentResponse` - Created agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format or agent ID already exists - 500: Database error
3084
+ * @summary Create Agent
3085
+ * @param {AgentUpdate} [agentUpdate]
3086
+ * @param {*} [options] Override http request option.
3087
+ * @throws {RequiredError}
3088
+ */
3089
+ async createAgent_1(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AgentResponse>> {
3090
+ const localVarAxiosArgs = await localVarAxiosParamCreator.createAgent_1(agentUpdate, options);
3091
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3092
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.createAgent_1']?.[localVarOperationServerIndex]?.url;
3093
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3094
+ },
3095
+ /**
3096
+ * Export agent configuration as YAML. **Path Parameters:** * `agent_id` - ID of the agent to export **Returns:** * `str` - YAML configuration of the agent **Raises:** * `HTTPException`: - 404: Agent not found
3097
+ * @summary Export Agent
3098
+ * @param {string} agentId ID of the agent to export
3099
+ * @param {*} [options] Override http request option.
3100
+ * @throws {RequiredError}
3101
+ */
3102
+ async exportAgent(agentId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<any>> {
3103
+ const localVarAxiosArgs = await localVarAxiosParamCreator.exportAgent(agentId, options);
3104
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3105
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.exportAgent']?.[localVarOperationServerIndex]?.url;
3106
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3107
+ },
3108
+ /**
3109
+ * Export agent configuration as YAML. **Path Parameters:** * `agent_id` - ID of the agent to export **Returns:** * `str` - YAML configuration of the agent **Raises:** * `HTTPException`: - 404: Agent not found
3110
+ * @summary Export Agent
3111
+ * @param {string} agentId ID of the agent to export
3112
+ * @param {*} [options] Override http request option.
3113
+ * @throws {RequiredError}
3114
+ */
3115
+ async exportAgent_2(agentId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<any>> {
3116
+ const localVarAxiosArgs = await localVarAxiosParamCreator.exportAgent_2(agentId, options);
3117
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3118
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.exportAgent_2']?.[localVarOperationServerIndex]?.url;
3119
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3120
+ },
3121
+ /**
3122
+ * Get a single agent by ID. **Path Parameters:** * `agent_id` - ID of the agent to retrieve **Returns:** * `AgentResponse` - Agent configuration with additional processed data **Raises:** * `HTTPException`: - 404: Agent not found
3123
+ * @summary Get Agent
3124
+ * @param {string} agentId ID of the agent to retrieve
3125
+ * @param {*} [options] Override http request option.
3126
+ * @throws {RequiredError}
3127
+ */
3128
+ async getAgent(agentId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<any>> {
3129
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getAgent(agentId, options);
3130
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3131
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.getAgent']?.[localVarOperationServerIndex]?.url;
3132
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3133
+ },
3134
+ /**
3135
+ * Get statistics for an agent account. This endpoint is not in readonly router, because it may create a new account.
3136
+ * @summary Get Agent Statistics
3137
+ * @param {string} aid ID of the agent
3138
+ * @param {*} [options] Override http request option.
3139
+ * @throws {RequiredError}
3140
+ */
3141
+ async getAgentStatistics(aid: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AgentStatisticsResponse>> {
3142
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getAgentStatistics(aid, options);
3143
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3144
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.getAgentStatistics']?.[localVarOperationServerIndex]?.url;
3145
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3146
+ },
3147
+ /**
3148
+ * Get a single agent by ID. **Path Parameters:** * `agent_id` - ID of the agent to retrieve **Returns:** * `AgentResponse` - Agent configuration with additional processed data **Raises:** * `HTTPException`: - 404: Agent not found
3149
+ * @summary Get Agent
3150
+ * @param {string} agentId ID of the agent to retrieve
3151
+ * @param {*} [options] Override http request option.
3152
+ * @throws {RequiredError}
3153
+ */
3154
+ async getAgent_3(agentId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<any>> {
3155
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getAgent_3(agentId, options);
3156
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3157
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.getAgent_3']?.[localVarOperationServerIndex]?.url;
3158
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3159
+ },
3160
+ /**
3161
+ * Get all agents with their quota information. **Query Parameters:** * `sort` - Sort order for the agents list * `cursor` - Cursor for pagination * `limit` - Maximum number of agents to return (1-100) **Returns:** * `AgentListResponse` - Paginated list of agents with their quota information and additional processed data
3162
+ * @summary Get Agents
3163
+ * @param {AgentSortOption} [sort] Sort order for agents list
3164
+ * @param {string | null} [cursor] Cursor for pagination
3165
+ * @param {number} [limit] Maximum number of agents to return
3166
+ * @param {*} [options] Override http request option.
3167
+ * @throws {RequiredError}
3168
+ */
3169
+ async getAgents(sort?: AgentSortOption, cursor?: string | null, limit?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AgentListResponse>> {
3170
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getAgents(sort, cursor, limit, options);
3171
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3172
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.getAgents']?.[localVarOperationServerIndex]?.url;
3173
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3174
+ },
3175
+ /**
3176
+ * Get all agents with their quota information. **Query Parameters:** * `sort` - Sort order for the agents list * `cursor` - Cursor for pagination * `limit` - Maximum number of agents to return (1-100) **Returns:** * `AgentListResponse` - Paginated list of agents with their quota information and additional processed data
3177
+ * @summary Get Agents
3178
+ * @param {AgentSortOption} [sort] Sort order for agents list
3179
+ * @param {string | null} [cursor] Cursor for pagination
3180
+ * @param {number} [limit] Maximum number of agents to return
3181
+ * @param {*} [options] Override http request option.
3182
+ * @throws {RequiredError}
3183
+ */
3184
+ async getAgents_4(sort?: AgentSortOption, cursor?: string | null, limit?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AgentListResponse>> {
3185
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getAgents_4(sort, cursor, limit, options);
3186
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3187
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.getAgents_4']?.[localVarOperationServerIndex]?.url;
3188
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3189
+ },
3190
+ /**
3191
+ * Import agent configuration from YAML file. Only updates existing agents, will not create new ones. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `file` - YAML file containing agent configuration **Returns:** * `str` - Success message **Raises:** * `HTTPException`: - 400: Invalid YAML or agent configuration - 404: Agent not found - 500: Server error
3192
+ * @summary Import Agent
3193
+ * @param {string} agentId
3194
+ * @param {File} file YAML file containing agent configuration
3195
+ * @param {*} [options] Override http request option.
3196
+ * @throws {RequiredError}
3197
+ */
3198
+ async importAgent(agentId: string, file: File, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<string>> {
3199
+ const localVarAxiosArgs = await localVarAxiosParamCreator.importAgent(agentId, file, options);
3200
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3201
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.importAgent']?.[localVarOperationServerIndex]?.url;
3202
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3203
+ },
3204
+ /**
3205
+ * Import agent configuration from YAML file. Only updates existing agents, will not create new ones. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `file` - YAML file containing agent configuration **Returns:** * `str` - Success message **Raises:** * `HTTPException`: - 400: Invalid YAML or agent configuration - 404: Agent not found - 500: Server error
3206
+ * @summary Import Agent
3207
+ * @param {string} agentId
3208
+ * @param {File} file YAML file containing agent configuration
3209
+ * @param {*} [options] Override http request option.
3210
+ * @throws {RequiredError}
3211
+ */
3212
+ async importAgent_5(agentId: string, file: File, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<string>> {
3213
+ const localVarAxiosArgs = await localVarAxiosParamCreator.importAgent_5(agentId, file, options);
3214
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3215
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.importAgent_5']?.[localVarOperationServerIndex]?.url;
3216
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3217
+ },
3218
+ /**
3219
+ * Override an existing agent. Use input to override agent configuration. If some fields are not provided, they will be reset to default values. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3220
+ * @summary Override Agent
3221
+ * @param {string} agentId ID of the agent to update
3222
+ * @param {AgentUpdate} [agentUpdate]
3223
+ * @param {*} [options] Override http request option.
3224
+ * @throws {RequiredError}
3225
+ */
3226
+ async overrideAgent(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<any>> {
3227
+ const localVarAxiosArgs = await localVarAxiosParamCreator.overrideAgent(agentId, agentUpdate, options);
3228
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3229
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.overrideAgent']?.[localVarOperationServerIndex]?.url;
3230
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3231
+ },
3232
+ /**
3233
+ * Override an existing agent. Use input to override agent configuration. If some fields are not provided, they will be reset to default values. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3234
+ * @summary Override Agent
3235
+ * @param {string} agentId ID of the agent to update
3236
+ * @param {AgentUpdate} [agentUpdate]
3237
+ * @param {*} [options] Override http request option.
3238
+ * @throws {RequiredError}
3239
+ */
3240
+ async overrideAgent_6(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<any>> {
3241
+ const localVarAxiosArgs = await localVarAxiosParamCreator.overrideAgent_6(agentId, agentUpdate, options);
3242
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3243
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.overrideAgent_6']?.[localVarOperationServerIndex]?.url;
3244
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3245
+ },
3246
+ /**
3247
+ * Update an existing agent. Use input to update agent configuration. If some fields are not provided, they will not be changed. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3248
+ * @summary Update Agent
3249
+ * @param {string} agentId ID of the agent to update
3250
+ * @param {AgentUpdate} [agentUpdate]
3251
+ * @param {*} [options] Override http request option.
3252
+ * @throws {RequiredError}
3253
+ */
3254
+ async updateAgent(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<any>> {
3255
+ const localVarAxiosArgs = await localVarAxiosParamCreator.updateAgent(agentId, agentUpdate, options);
3256
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3257
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.updateAgent']?.[localVarOperationServerIndex]?.url;
3258
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3259
+ },
3260
+ /**
3261
+ * Update an existing agent. Use input to update agent configuration. If some fields are not provided, they will not be changed. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3262
+ * @summary Update Agent
3263
+ * @param {string} agentId ID of the agent to update
3264
+ * @param {AgentUpdate} [agentUpdate]
3265
+ * @param {*} [options] Override http request option.
3266
+ * @throws {RequiredError}
3267
+ */
3268
+ async updateAgent_7(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<any>> {
3269
+ const localVarAxiosArgs = await localVarAxiosParamCreator.updateAgent_7(agentId, agentUpdate, options);
3270
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3271
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.updateAgent_7']?.[localVarOperationServerIndex]?.url;
3272
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3273
+ },
3274
+ /**
3275
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3276
+ * @summary Validate Agent Create
3277
+ * @param {AgentUpdate} [agentUpdate]
3278
+ * @param {*} [options] Override http request option.
3279
+ * @throws {RequiredError}
3280
+ */
3281
+ async validateAgentCreate(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
3282
+ const localVarAxiosArgs = await localVarAxiosParamCreator.validateAgentCreate(agentUpdate, options);
3283
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3284
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.validateAgentCreate']?.[localVarOperationServerIndex]?.url;
3285
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3286
+ },
3287
+ /**
3288
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3289
+ * @summary Validate Agent Create
3290
+ * @param {AgentUpdate} [agentUpdate]
3291
+ * @param {*} [options] Override http request option.
3292
+ * @throws {RequiredError}
3293
+ */
3294
+ async validateAgentCreate_8(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
3295
+ const localVarAxiosArgs = await localVarAxiosParamCreator.validateAgentCreate_8(agentUpdate, options);
3296
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3297
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.validateAgentCreate_8']?.[localVarOperationServerIndex]?.url;
3298
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3299
+ },
3300
+ /**
3301
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3302
+ * @summary Validate Agent Update
3303
+ * @param {string} agentId Agent ID
3304
+ * @param {AgentUpdate} [agentUpdate]
3305
+ * @param {*} [options] Override http request option.
3306
+ * @throws {RequiredError}
3307
+ */
3308
+ async validateAgentUpdate(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
3309
+ const localVarAxiosArgs = await localVarAxiosParamCreator.validateAgentUpdate(agentId, agentUpdate, options);
3310
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3311
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.validateAgentUpdate']?.[localVarOperationServerIndex]?.url;
3312
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3313
+ },
3314
+ /**
3315
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3316
+ * @summary Validate Agent Update
3317
+ * @param {string} agentId Agent ID
3318
+ * @param {AgentUpdate} [agentUpdate]
3319
+ * @param {*} [options] Override http request option.
3320
+ * @throws {RequiredError}
3321
+ */
3322
+ async validateAgentUpdate_9(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
3323
+ const localVarAxiosArgs = await localVarAxiosParamCreator.validateAgentUpdate_9(agentId, agentUpdate, options);
3324
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3325
+ const localVarOperationServerBasePath = operationServerMap['AgentApi.validateAgentUpdate_9']?.[localVarOperationServerIndex]?.url;
3326
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3327
+ },
3328
+ }
3329
+ };
3330
+
3331
+ /**
3332
+ * AgentApi - factory interface
3333
+ * @export
3334
+ */
3335
+ export const AgentApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
3336
+ const localVarFp = AgentApiFp(configuration)
3337
+ return {
3338
+ /**
3339
+ * Create a new agent. **Request Body:** * `agent` - Agent configuration **Returns:** * `AgentResponse` - Created agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format or agent ID already exists - 500: Database error
3340
+ * @summary Create Agent
3341
+ * @param {AgentUpdate} [agentUpdate]
3342
+ * @param {*} [options] Override http request option.
3343
+ * @throws {RequiredError}
3344
+ */
3345
+ createAgent(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): AxiosPromise<AgentResponse> {
3346
+ return localVarFp.createAgent(agentUpdate, options).then((request) => request(axios, basePath));
3347
+ },
3348
+ /**
3349
+ * Create a new agent. **Request Body:** * `agent` - Agent configuration **Returns:** * `AgentResponse` - Created agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format or agent ID already exists - 500: Database error
3350
+ * @summary Create Agent
3351
+ * @param {AgentUpdate} [agentUpdate]
3352
+ * @param {*} [options] Override http request option.
3353
+ * @throws {RequiredError}
3354
+ */
3355
+ createAgent_1(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): AxiosPromise<AgentResponse> {
3356
+ return localVarFp.createAgent_1(agentUpdate, options).then((request) => request(axios, basePath));
3357
+ },
3358
+ /**
3359
+ * Export agent configuration as YAML. **Path Parameters:** * `agent_id` - ID of the agent to export **Returns:** * `str` - YAML configuration of the agent **Raises:** * `HTTPException`: - 404: Agent not found
3360
+ * @summary Export Agent
3361
+ * @param {string} agentId ID of the agent to export
3362
+ * @param {*} [options] Override http request option.
3363
+ * @throws {RequiredError}
3364
+ */
3365
+ exportAgent(agentId: string, options?: RawAxiosRequestConfig): AxiosPromise<any> {
3366
+ return localVarFp.exportAgent(agentId, options).then((request) => request(axios, basePath));
3367
+ },
3368
+ /**
3369
+ * Export agent configuration as YAML. **Path Parameters:** * `agent_id` - ID of the agent to export **Returns:** * `str` - YAML configuration of the agent **Raises:** * `HTTPException`: - 404: Agent not found
3370
+ * @summary Export Agent
3371
+ * @param {string} agentId ID of the agent to export
3372
+ * @param {*} [options] Override http request option.
3373
+ * @throws {RequiredError}
3374
+ */
3375
+ exportAgent_2(agentId: string, options?: RawAxiosRequestConfig): AxiosPromise<any> {
3376
+ return localVarFp.exportAgent_2(agentId, options).then((request) => request(axios, basePath));
3377
+ },
3378
+ /**
3379
+ * Get a single agent by ID. **Path Parameters:** * `agent_id` - ID of the agent to retrieve **Returns:** * `AgentResponse` - Agent configuration with additional processed data **Raises:** * `HTTPException`: - 404: Agent not found
3380
+ * @summary Get Agent
3381
+ * @param {string} agentId ID of the agent to retrieve
3382
+ * @param {*} [options] Override http request option.
3383
+ * @throws {RequiredError}
3384
+ */
3385
+ getAgent(agentId: string, options?: RawAxiosRequestConfig): AxiosPromise<any> {
3386
+ return localVarFp.getAgent(agentId, options).then((request) => request(axios, basePath));
3387
+ },
3388
+ /**
3389
+ * Get statistics for an agent account. This endpoint is not in readonly router, because it may create a new account.
3390
+ * @summary Get Agent Statistics
3391
+ * @param {string} aid ID of the agent
3392
+ * @param {*} [options] Override http request option.
3393
+ * @throws {RequiredError}
3394
+ */
3395
+ getAgentStatistics(aid: string, options?: RawAxiosRequestConfig): AxiosPromise<AgentStatisticsResponse> {
3396
+ return localVarFp.getAgentStatistics(aid, options).then((request) => request(axios, basePath));
3397
+ },
3398
+ /**
3399
+ * Get a single agent by ID. **Path Parameters:** * `agent_id` - ID of the agent to retrieve **Returns:** * `AgentResponse` - Agent configuration with additional processed data **Raises:** * `HTTPException`: - 404: Agent not found
3400
+ * @summary Get Agent
3401
+ * @param {string} agentId ID of the agent to retrieve
3402
+ * @param {*} [options] Override http request option.
3403
+ * @throws {RequiredError}
3404
+ */
3405
+ getAgent_3(agentId: string, options?: RawAxiosRequestConfig): AxiosPromise<any> {
3406
+ return localVarFp.getAgent_3(agentId, options).then((request) => request(axios, basePath));
3407
+ },
3408
+ /**
3409
+ * Get all agents with their quota information. **Query Parameters:** * `sort` - Sort order for the agents list * `cursor` - Cursor for pagination * `limit` - Maximum number of agents to return (1-100) **Returns:** * `AgentListResponse` - Paginated list of agents with their quota information and additional processed data
3410
+ * @summary Get Agents
3411
+ * @param {AgentSortOption} [sort] Sort order for agents list
3412
+ * @param {string | null} [cursor] Cursor for pagination
3413
+ * @param {number} [limit] Maximum number of agents to return
3414
+ * @param {*} [options] Override http request option.
3415
+ * @throws {RequiredError}
3416
+ */
3417
+ getAgents(sort?: AgentSortOption, cursor?: string | null, limit?: number, options?: RawAxiosRequestConfig): AxiosPromise<AgentListResponse> {
3418
+ return localVarFp.getAgents(sort, cursor, limit, options).then((request) => request(axios, basePath));
3419
+ },
3420
+ /**
3421
+ * Get all agents with their quota information. **Query Parameters:** * `sort` - Sort order for the agents list * `cursor` - Cursor for pagination * `limit` - Maximum number of agents to return (1-100) **Returns:** * `AgentListResponse` - Paginated list of agents with their quota information and additional processed data
3422
+ * @summary Get Agents
3423
+ * @param {AgentSortOption} [sort] Sort order for agents list
3424
+ * @param {string | null} [cursor] Cursor for pagination
3425
+ * @param {number} [limit] Maximum number of agents to return
3426
+ * @param {*} [options] Override http request option.
3427
+ * @throws {RequiredError}
3428
+ */
3429
+ getAgents_4(sort?: AgentSortOption, cursor?: string | null, limit?: number, options?: RawAxiosRequestConfig): AxiosPromise<AgentListResponse> {
3430
+ return localVarFp.getAgents_4(sort, cursor, limit, options).then((request) => request(axios, basePath));
3431
+ },
3432
+ /**
3433
+ * Import agent configuration from YAML file. Only updates existing agents, will not create new ones. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `file` - YAML file containing agent configuration **Returns:** * `str` - Success message **Raises:** * `HTTPException`: - 400: Invalid YAML or agent configuration - 404: Agent not found - 500: Server error
3434
+ * @summary Import Agent
3435
+ * @param {string} agentId
3436
+ * @param {File} file YAML file containing agent configuration
3437
+ * @param {*} [options] Override http request option.
3438
+ * @throws {RequiredError}
3439
+ */
3440
+ importAgent(agentId: string, file: File, options?: RawAxiosRequestConfig): AxiosPromise<string> {
3441
+ return localVarFp.importAgent(agentId, file, options).then((request) => request(axios, basePath));
3442
+ },
3443
+ /**
3444
+ * Import agent configuration from YAML file. Only updates existing agents, will not create new ones. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `file` - YAML file containing agent configuration **Returns:** * `str` - Success message **Raises:** * `HTTPException`: - 400: Invalid YAML or agent configuration - 404: Agent not found - 500: Server error
3445
+ * @summary Import Agent
3446
+ * @param {string} agentId
3447
+ * @param {File} file YAML file containing agent configuration
3448
+ * @param {*} [options] Override http request option.
3449
+ * @throws {RequiredError}
3450
+ */
3451
+ importAgent_5(agentId: string, file: File, options?: RawAxiosRequestConfig): AxiosPromise<string> {
3452
+ return localVarFp.importAgent_5(agentId, file, options).then((request) => request(axios, basePath));
3453
+ },
3454
+ /**
3455
+ * Override an existing agent. Use input to override agent configuration. If some fields are not provided, they will be reset to default values. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3456
+ * @summary Override Agent
3457
+ * @param {string} agentId ID of the agent to update
3458
+ * @param {AgentUpdate} [agentUpdate]
3459
+ * @param {*} [options] Override http request option.
3460
+ * @throws {RequiredError}
3461
+ */
3462
+ overrideAgent(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): AxiosPromise<any> {
3463
+ return localVarFp.overrideAgent(agentId, agentUpdate, options).then((request) => request(axios, basePath));
3464
+ },
3465
+ /**
3466
+ * Override an existing agent. Use input to override agent configuration. If some fields are not provided, they will be reset to default values. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3467
+ * @summary Override Agent
3468
+ * @param {string} agentId ID of the agent to update
3469
+ * @param {AgentUpdate} [agentUpdate]
3470
+ * @param {*} [options] Override http request option.
3471
+ * @throws {RequiredError}
3472
+ */
3473
+ overrideAgent_6(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): AxiosPromise<any> {
3474
+ return localVarFp.overrideAgent_6(agentId, agentUpdate, options).then((request) => request(axios, basePath));
3475
+ },
3476
+ /**
3477
+ * Update an existing agent. Use input to update agent configuration. If some fields are not provided, they will not be changed. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3478
+ * @summary Update Agent
3479
+ * @param {string} agentId ID of the agent to update
3480
+ * @param {AgentUpdate} [agentUpdate]
3481
+ * @param {*} [options] Override http request option.
3482
+ * @throws {RequiredError}
3483
+ */
3484
+ updateAgent(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): AxiosPromise<any> {
3485
+ return localVarFp.updateAgent(agentId, agentUpdate, options).then((request) => request(axios, basePath));
3486
+ },
3487
+ /**
3488
+ * Update an existing agent. Use input to update agent configuration. If some fields are not provided, they will not be changed. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3489
+ * @summary Update Agent
3490
+ * @param {string} agentId ID of the agent to update
3491
+ * @param {AgentUpdate} [agentUpdate]
3492
+ * @param {*} [options] Override http request option.
3493
+ * @throws {RequiredError}
3494
+ */
3495
+ updateAgent_7(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): AxiosPromise<any> {
3496
+ return localVarFp.updateAgent_7(agentId, agentUpdate, options).then((request) => request(axios, basePath));
3497
+ },
3498
+ /**
3499
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3500
+ * @summary Validate Agent Create
3501
+ * @param {AgentUpdate} [agentUpdate]
3502
+ * @param {*} [options] Override http request option.
3503
+ * @throws {RequiredError}
3504
+ */
3505
+ validateAgentCreate(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): AxiosPromise<void> {
3506
+ return localVarFp.validateAgentCreate(agentUpdate, options).then((request) => request(axios, basePath));
3507
+ },
3508
+ /**
3509
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3510
+ * @summary Validate Agent Create
3511
+ * @param {AgentUpdate} [agentUpdate]
3512
+ * @param {*} [options] Override http request option.
3513
+ * @throws {RequiredError}
3514
+ */
3515
+ validateAgentCreate_8(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): AxiosPromise<void> {
3516
+ return localVarFp.validateAgentCreate_8(agentUpdate, options).then((request) => request(axios, basePath));
3517
+ },
3518
+ /**
3519
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3520
+ * @summary Validate Agent Update
3521
+ * @param {string} agentId Agent ID
3522
+ * @param {AgentUpdate} [agentUpdate]
3523
+ * @param {*} [options] Override http request option.
3524
+ * @throws {RequiredError}
3525
+ */
3526
+ validateAgentUpdate(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): AxiosPromise<void> {
3527
+ return localVarFp.validateAgentUpdate(agentId, agentUpdate, options).then((request) => request(axios, basePath));
3528
+ },
3529
+ /**
3530
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3531
+ * @summary Validate Agent Update
3532
+ * @param {string} agentId Agent ID
3533
+ * @param {AgentUpdate} [agentUpdate]
3534
+ * @param {*} [options] Override http request option.
3535
+ * @throws {RequiredError}
3536
+ */
3537
+ validateAgentUpdate_9(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig): AxiosPromise<void> {
3538
+ return localVarFp.validateAgentUpdate_9(agentId, agentUpdate, options).then((request) => request(axios, basePath));
3539
+ },
3540
+ };
3541
+ };
3542
+
3543
+ /**
3544
+ * AgentApi - object-oriented interface
3545
+ * @export
3546
+ * @class AgentApi
3547
+ * @extends {BaseAPI}
3548
+ */
3549
+ export class AgentApi extends BaseAPI {
3550
+ /**
3551
+ * Create a new agent. **Request Body:** * `agent` - Agent configuration **Returns:** * `AgentResponse` - Created agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format or agent ID already exists - 500: Database error
3552
+ * @summary Create Agent
3553
+ * @param {AgentUpdate} [agentUpdate]
3554
+ * @param {*} [options] Override http request option.
3555
+ * @throws {RequiredError}
3556
+ * @memberof AgentApi
3557
+ */
3558
+ public createAgent(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig) {
2453
3559
  return AgentApiFp(this.configuration).createAgent(agentUpdate, options).then((request) => request(this.axios, this.basePath));
2454
3560
  }
2455
3561
 
2456
3562
  /**
2457
- * Retrieve a specific agent by its ID. Returns 404 if not found.
2458
- * @summary Get agent by ID
2459
- * @param {string} aid Agent ID
3563
+ * Create a new agent. **Request Body:** * `agent` - Agent configuration **Returns:** * `AgentResponse` - Created agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format or agent ID already exists - 500: Database error
3564
+ * @summary Create Agent
3565
+ * @param {AgentUpdate} [agentUpdate]
3566
+ * @param {*} [options] Override http request option.
3567
+ * @throws {RequiredError}
3568
+ * @memberof AgentApi
3569
+ */
3570
+ public createAgent_1(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig) {
3571
+ return AgentApiFp(this.configuration).createAgent_1(agentUpdate, options).then((request) => request(this.axios, this.basePath));
3572
+ }
3573
+
3574
+ /**
3575
+ * Export agent configuration as YAML. **Path Parameters:** * `agent_id` - ID of the agent to export **Returns:** * `str` - YAML configuration of the agent **Raises:** * `HTTPException`: - 404: Agent not found
3576
+ * @summary Export Agent
3577
+ * @param {string} agentId ID of the agent to export
3578
+ * @param {*} [options] Override http request option.
3579
+ * @throws {RequiredError}
3580
+ * @memberof AgentApi
3581
+ */
3582
+ public exportAgent(agentId: string, options?: RawAxiosRequestConfig) {
3583
+ return AgentApiFp(this.configuration).exportAgent(agentId, options).then((request) => request(this.axios, this.basePath));
3584
+ }
3585
+
3586
+ /**
3587
+ * Export agent configuration as YAML. **Path Parameters:** * `agent_id` - ID of the agent to export **Returns:** * `str` - YAML configuration of the agent **Raises:** * `HTTPException`: - 404: Agent not found
3588
+ * @summary Export Agent
3589
+ * @param {string} agentId ID of the agent to export
3590
+ * @param {*} [options] Override http request option.
3591
+ * @throws {RequiredError}
3592
+ * @memberof AgentApi
3593
+ */
3594
+ public exportAgent_2(agentId: string, options?: RawAxiosRequestConfig) {
3595
+ return AgentApiFp(this.configuration).exportAgent_2(agentId, options).then((request) => request(this.axios, this.basePath));
3596
+ }
3597
+
3598
+ /**
3599
+ * Get a single agent by ID. **Path Parameters:** * `agent_id` - ID of the agent to retrieve **Returns:** * `AgentResponse` - Agent configuration with additional processed data **Raises:** * `HTTPException`: - 404: Agent not found
3600
+ * @summary Get Agent
3601
+ * @param {string} agentId ID of the agent to retrieve
2460
3602
  * @param {*} [options] Override http request option.
2461
3603
  * @throws {RequiredError}
2462
3604
  * @memberof AgentApi
2463
3605
  */
2464
- public getAgentById(aid: string, options?: RawAxiosRequestConfig) {
2465
- return AgentApiFp(this.configuration).getAgentById(aid, options).then((request) => request(this.axios, this.basePath));
3606
+ public getAgent(agentId: string, options?: RawAxiosRequestConfig) {
3607
+ return AgentApiFp(this.configuration).getAgent(agentId, options).then((request) => request(this.axios, this.basePath));
2466
3608
  }
2467
3609
 
2468
3610
  /**
@@ -2476,6 +3618,174 @@ export class AgentApi extends BaseAPI {
2476
3618
  public getAgentStatistics(aid: string, options?: RawAxiosRequestConfig) {
2477
3619
  return AgentApiFp(this.configuration).getAgentStatistics(aid, options).then((request) => request(this.axios, this.basePath));
2478
3620
  }
3621
+
3622
+ /**
3623
+ * Get a single agent by ID. **Path Parameters:** * `agent_id` - ID of the agent to retrieve **Returns:** * `AgentResponse` - Agent configuration with additional processed data **Raises:** * `HTTPException`: - 404: Agent not found
3624
+ * @summary Get Agent
3625
+ * @param {string} agentId ID of the agent to retrieve
3626
+ * @param {*} [options] Override http request option.
3627
+ * @throws {RequiredError}
3628
+ * @memberof AgentApi
3629
+ */
3630
+ public getAgent_3(agentId: string, options?: RawAxiosRequestConfig) {
3631
+ return AgentApiFp(this.configuration).getAgent_3(agentId, options).then((request) => request(this.axios, this.basePath));
3632
+ }
3633
+
3634
+ /**
3635
+ * Get all agents with their quota information. **Query Parameters:** * `sort` - Sort order for the agents list * `cursor` - Cursor for pagination * `limit` - Maximum number of agents to return (1-100) **Returns:** * `AgentListResponse` - Paginated list of agents with their quota information and additional processed data
3636
+ * @summary Get Agents
3637
+ * @param {AgentSortOption} [sort] Sort order for agents list
3638
+ * @param {string | null} [cursor] Cursor for pagination
3639
+ * @param {number} [limit] Maximum number of agents to return
3640
+ * @param {*} [options] Override http request option.
3641
+ * @throws {RequiredError}
3642
+ * @memberof AgentApi
3643
+ */
3644
+ public getAgents(sort?: AgentSortOption, cursor?: string | null, limit?: number, options?: RawAxiosRequestConfig) {
3645
+ return AgentApiFp(this.configuration).getAgents(sort, cursor, limit, options).then((request) => request(this.axios, this.basePath));
3646
+ }
3647
+
3648
+ /**
3649
+ * Get all agents with their quota information. **Query Parameters:** * `sort` - Sort order for the agents list * `cursor` - Cursor for pagination * `limit` - Maximum number of agents to return (1-100) **Returns:** * `AgentListResponse` - Paginated list of agents with their quota information and additional processed data
3650
+ * @summary Get Agents
3651
+ * @param {AgentSortOption} [sort] Sort order for agents list
3652
+ * @param {string | null} [cursor] Cursor for pagination
3653
+ * @param {number} [limit] Maximum number of agents to return
3654
+ * @param {*} [options] Override http request option.
3655
+ * @throws {RequiredError}
3656
+ * @memberof AgentApi
3657
+ */
3658
+ public getAgents_4(sort?: AgentSortOption, cursor?: string | null, limit?: number, options?: RawAxiosRequestConfig) {
3659
+ return AgentApiFp(this.configuration).getAgents_4(sort, cursor, limit, options).then((request) => request(this.axios, this.basePath));
3660
+ }
3661
+
3662
+ /**
3663
+ * Import agent configuration from YAML file. Only updates existing agents, will not create new ones. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `file` - YAML file containing agent configuration **Returns:** * `str` - Success message **Raises:** * `HTTPException`: - 400: Invalid YAML or agent configuration - 404: Agent not found - 500: Server error
3664
+ * @summary Import Agent
3665
+ * @param {string} agentId
3666
+ * @param {File} file YAML file containing agent configuration
3667
+ * @param {*} [options] Override http request option.
3668
+ * @throws {RequiredError}
3669
+ * @memberof AgentApi
3670
+ */
3671
+ public importAgent(agentId: string, file: File, options?: RawAxiosRequestConfig) {
3672
+ return AgentApiFp(this.configuration).importAgent(agentId, file, options).then((request) => request(this.axios, this.basePath));
3673
+ }
3674
+
3675
+ /**
3676
+ * Import agent configuration from YAML file. Only updates existing agents, will not create new ones. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `file` - YAML file containing agent configuration **Returns:** * `str` - Success message **Raises:** * `HTTPException`: - 400: Invalid YAML or agent configuration - 404: Agent not found - 500: Server error
3677
+ * @summary Import Agent
3678
+ * @param {string} agentId
3679
+ * @param {File} file YAML file containing agent configuration
3680
+ * @param {*} [options] Override http request option.
3681
+ * @throws {RequiredError}
3682
+ * @memberof AgentApi
3683
+ */
3684
+ public importAgent_5(agentId: string, file: File, options?: RawAxiosRequestConfig) {
3685
+ return AgentApiFp(this.configuration).importAgent_5(agentId, file, options).then((request) => request(this.axios, this.basePath));
3686
+ }
3687
+
3688
+ /**
3689
+ * Override an existing agent. Use input to override agent configuration. If some fields are not provided, they will be reset to default values. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3690
+ * @summary Override Agent
3691
+ * @param {string} agentId ID of the agent to update
3692
+ * @param {AgentUpdate} [agentUpdate]
3693
+ * @param {*} [options] Override http request option.
3694
+ * @throws {RequiredError}
3695
+ * @memberof AgentApi
3696
+ */
3697
+ public overrideAgent(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig) {
3698
+ return AgentApiFp(this.configuration).overrideAgent(agentId, agentUpdate, options).then((request) => request(this.axios, this.basePath));
3699
+ }
3700
+
3701
+ /**
3702
+ * Override an existing agent. Use input to override agent configuration. If some fields are not provided, they will be reset to default values. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3703
+ * @summary Override Agent
3704
+ * @param {string} agentId ID of the agent to update
3705
+ * @param {AgentUpdate} [agentUpdate]
3706
+ * @param {*} [options] Override http request option.
3707
+ * @throws {RequiredError}
3708
+ * @memberof AgentApi
3709
+ */
3710
+ public overrideAgent_6(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig) {
3711
+ return AgentApiFp(this.configuration).overrideAgent_6(agentId, agentUpdate, options).then((request) => request(this.axios, this.basePath));
3712
+ }
3713
+
3714
+ /**
3715
+ * Update an existing agent. Use input to update agent configuration. If some fields are not provided, they will not be changed. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3716
+ * @summary Update Agent
3717
+ * @param {string} agentId ID of the agent to update
3718
+ * @param {AgentUpdate} [agentUpdate]
3719
+ * @param {*} [options] Override http request option.
3720
+ * @throws {RequiredError}
3721
+ * @memberof AgentApi
3722
+ */
3723
+ public updateAgent(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig) {
3724
+ return AgentApiFp(this.configuration).updateAgent(agentId, agentUpdate, options).then((request) => request(this.axios, this.basePath));
3725
+ }
3726
+
3727
+ /**
3728
+ * Update an existing agent. Use input to update agent configuration. If some fields are not provided, they will not be changed. **Path Parameters:** * `agent_id` - ID of the agent to update **Request Body:** * `agent` - Agent update configuration **Returns:** * `AgentResponse` - Updated agent configuration with additional processed data **Raises:** * `HTTPException`: - 400: Invalid agent ID format - 404: Agent not found - 403: Permission denied (if owner mismatch) - 500: Database error
3729
+ * @summary Update Agent
3730
+ * @param {string} agentId ID of the agent to update
3731
+ * @param {AgentUpdate} [agentUpdate]
3732
+ * @param {*} [options] Override http request option.
3733
+ * @throws {RequiredError}
3734
+ * @memberof AgentApi
3735
+ */
3736
+ public updateAgent_7(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig) {
3737
+ return AgentApiFp(this.configuration).updateAgent_7(agentId, agentUpdate, options).then((request) => request(this.axios, this.basePath));
3738
+ }
3739
+
3740
+ /**
3741
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3742
+ * @summary Validate Agent Create
3743
+ * @param {AgentUpdate} [agentUpdate]
3744
+ * @param {*} [options] Override http request option.
3745
+ * @throws {RequiredError}
3746
+ * @memberof AgentApi
3747
+ */
3748
+ public validateAgentCreate(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig) {
3749
+ return AgentApiFp(this.configuration).validateAgentCreate(agentUpdate, options).then((request) => request(this.axios, this.basePath));
3750
+ }
3751
+
3752
+ /**
3753
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3754
+ * @summary Validate Agent Create
3755
+ * @param {AgentUpdate} [agentUpdate]
3756
+ * @param {*} [options] Override http request option.
3757
+ * @throws {RequiredError}
3758
+ * @memberof AgentApi
3759
+ */
3760
+ public validateAgentCreate_8(agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig) {
3761
+ return AgentApiFp(this.configuration).validateAgentCreate_8(agentUpdate, options).then((request) => request(this.axios, this.basePath));
3762
+ }
3763
+
3764
+ /**
3765
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3766
+ * @summary Validate Agent Update
3767
+ * @param {string} agentId Agent ID
3768
+ * @param {AgentUpdate} [agentUpdate]
3769
+ * @param {*} [options] Override http request option.
3770
+ * @throws {RequiredError}
3771
+ * @memberof AgentApi
3772
+ */
3773
+ public validateAgentUpdate(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig) {
3774
+ return AgentApiFp(this.configuration).validateAgentUpdate(agentId, agentUpdate, options).then((request) => request(this.axios, this.basePath));
3775
+ }
3776
+
3777
+ /**
3778
+ * Validate agent configuration. **Request Body:** * `agent` - Agent configuration **Returns:** * `204 No Content` - Agent configuration is valid **Raises:** * `HTTPException`: - 400: Invalid agent configuration - 422: Invalid agent configuration from intentkit core - 500: Server error
3779
+ * @summary Validate Agent Update
3780
+ * @param {string} agentId Agent ID
3781
+ * @param {AgentUpdate} [agentUpdate]
3782
+ * @param {*} [options] Override http request option.
3783
+ * @throws {RequiredError}
3784
+ * @memberof AgentApi
3785
+ */
3786
+ public validateAgentUpdate_9(agentId: string, agentUpdate?: AgentUpdate, options?: RawAxiosRequestConfig) {
3787
+ return AgentApiFp(this.configuration).validateAgentUpdate_9(agentId, agentUpdate, options).then((request) => request(this.axios, this.basePath));
3788
+ }
2479
3789
  }
2480
3790
 
2481
3791