@crestal/nation-sdk 0.7.16 → 0.7.18

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/dist/api.js CHANGED
@@ -5,7 +5,7 @@
5
5
  * Nation IntentKit API
6
6
  * API for Nation IntentKit services
7
7
  *
8
- * The version of the OpenAPI document: 0.7.16
8
+ * The version of the OpenAPI document: 0.7.18
9
9
  *
10
10
  *
11
11
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -996,6 +996,53 @@ var AgentApiAxiosParamCreator = function (configuration) {
996
996
  });
997
997
  });
998
998
  },
999
+ /**
1000
+ * Unpublish an agent by setting its state back to private.
1001
+ * @summary Unpublish Agent
1002
+ * @param {string} agentId ID of the agent to unpublish
1003
+ * @param {*} [options] Override http request option.
1004
+ * @throws {RequiredError}
1005
+ */
1006
+ unpublishAgent: function (agentId_1) {
1007
+ var args_1 = [];
1008
+ for (var _i = 1; _i < arguments.length; _i++) {
1009
+ args_1[_i - 1] = arguments[_i];
1010
+ }
1011
+ return __awaiter(_this, __spreadArray([agentId_1], args_1, true), void 0, function (agentId, options) {
1012
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
1013
+ if (options === void 0) { options = {}; }
1014
+ return __generator(this, function (_a) {
1015
+ switch (_a.label) {
1016
+ case 0:
1017
+ // verify required parameter 'agentId' is not null or undefined
1018
+ (0, common_1.assertParamExists)('unpublishAgent', 'agentId', agentId);
1019
+ localVarPath = "/agents/{agent_id}/unpublish"
1020
+ .replace("{".concat("agent_id", "}"), encodeURIComponent(String(agentId)));
1021
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1022
+ if (configuration) {
1023
+ baseOptions = configuration.baseOptions;
1024
+ }
1025
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
1026
+ localVarHeaderParameter = {};
1027
+ localVarQueryParameter = {};
1028
+ // authentication HTTPBearer required
1029
+ // http bearer authentication required
1030
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
1031
+ case 1:
1032
+ // authentication HTTPBearer required
1033
+ // http bearer authentication required
1034
+ _a.sent();
1035
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1036
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1037
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
1038
+ return [2 /*return*/, {
1039
+ url: (0, common_1.toPathString)(localVarUrlObj),
1040
+ options: localVarRequestOptions,
1041
+ }];
1042
+ }
1043
+ });
1044
+ });
1045
+ },
999
1046
  /**
1000
1047
  * 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 or JSON schema validation - 500: Server error
1001
1048
  * @summary Validate Agent Create
@@ -1409,6 +1456,29 @@ var AgentApiFp = function (configuration) {
1409
1456
  });
1410
1457
  });
1411
1458
  },
1459
+ /**
1460
+ * Unpublish an agent by setting its state back to private.
1461
+ * @summary Unpublish Agent
1462
+ * @param {string} agentId ID of the agent to unpublish
1463
+ * @param {*} [options] Override http request option.
1464
+ * @throws {RequiredError}
1465
+ */
1466
+ unpublishAgent: function (agentId, options) {
1467
+ return __awaiter(this, void 0, void 0, function () {
1468
+ var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
1469
+ var _a, _b, _c;
1470
+ return __generator(this, function (_d) {
1471
+ switch (_d.label) {
1472
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.unpublishAgent(agentId, options)];
1473
+ case 1:
1474
+ localVarAxiosArgs = _d.sent();
1475
+ localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
1476
+ localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['AgentApi.unpublishAgent']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
1477
+ return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
1478
+ }
1479
+ });
1480
+ });
1481
+ },
1412
1482
  /**
1413
1483
  * 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 or JSON schema validation - 500: Server error
1414
1484
  * @summary Validate Agent Create
@@ -1604,6 +1674,16 @@ var AgentApiFactory = function (configuration, basePath, axios) {
1604
1674
  resetAgentApiKey: function (agentId, options) {
1605
1675
  return localVarFp.resetAgentApiKey(agentId, options).then(function (request) { return request(axios, basePath); });
1606
1676
  },
1677
+ /**
1678
+ * Unpublish an agent by setting its state back to private.
1679
+ * @summary Unpublish Agent
1680
+ * @param {string} agentId ID of the agent to unpublish
1681
+ * @param {*} [options] Override http request option.
1682
+ * @throws {RequiredError}
1683
+ */
1684
+ unpublishAgent: function (agentId, options) {
1685
+ return localVarFp.unpublishAgent(agentId, options).then(function (request) { return request(axios, basePath); });
1686
+ },
1607
1687
  /**
1608
1688
  * 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 or JSON schema validation - 500: Server error
1609
1689
  * @summary Validate Agent Create
@@ -1803,6 +1883,18 @@ var AgentApi = /** @class */ (function (_super) {
1803
1883
  var _this = this;
1804
1884
  return (0, exports.AgentApiFp)(this.configuration).resetAgentApiKey(agentId, options).then(function (request) { return request(_this.axios, _this.basePath); });
1805
1885
  };
1886
+ /**
1887
+ * Unpublish an agent by setting its state back to private.
1888
+ * @summary Unpublish Agent
1889
+ * @param {string} agentId ID of the agent to unpublish
1890
+ * @param {*} [options] Override http request option.
1891
+ * @throws {RequiredError}
1892
+ * @memberof AgentApi
1893
+ */
1894
+ AgentApi.prototype.unpublishAgent = function (agentId, options) {
1895
+ var _this = this;
1896
+ return (0, exports.AgentApiFp)(this.configuration).unpublishAgent(agentId, options).then(function (request) { return request(_this.axios, _this.basePath); });
1897
+ };
1806
1898
  /**
1807
1899
  * 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 or JSON schema validation - 500: Server error
1808
1900
  * @summary Validate Agent Create
@@ -2246,6 +2338,61 @@ var ChatApiAxiosParamCreator = function (configuration) {
2246
2338
  });
2247
2339
  });
2248
2340
  },
2341
+ /**
2342
+ * Retrieve the message history for the draft chat session of an agent with cursor-based pagination.
2343
+ * @summary List messages in an agent draft session
2344
+ * @param {string} aid Agent ID
2345
+ * @param {string | null} [cursor] Cursor for pagination (message id)
2346
+ * @param {number} [limit] Maximum number of messages to return
2347
+ * @param {*} [options] Override http request option.
2348
+ * @throws {RequiredError}
2349
+ */
2350
+ listMessagesInDraft: function (aid_1, cursor_1, limit_1) {
2351
+ var args_1 = [];
2352
+ for (var _i = 3; _i < arguments.length; _i++) {
2353
+ args_1[_i - 3] = arguments[_i];
2354
+ }
2355
+ return __awaiter(_this, __spreadArray([aid_1, cursor_1, limit_1], args_1, true), void 0, function (aid, cursor, limit, options) {
2356
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
2357
+ if (options === void 0) { options = {}; }
2358
+ return __generator(this, function (_a) {
2359
+ switch (_a.label) {
2360
+ case 0:
2361
+ // verify required parameter 'aid' is not null or undefined
2362
+ (0, common_1.assertParamExists)('listMessagesInDraft', 'aid', aid);
2363
+ localVarPath = "/agents/{aid}/draft/messages"
2364
+ .replace("{".concat("aid", "}"), encodeURIComponent(String(aid)));
2365
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
2366
+ if (configuration) {
2367
+ baseOptions = configuration.baseOptions;
2368
+ }
2369
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
2370
+ localVarHeaderParameter = {};
2371
+ localVarQueryParameter = {};
2372
+ // authentication HTTPBearer required
2373
+ // http bearer authentication required
2374
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
2375
+ case 1:
2376
+ // authentication HTTPBearer required
2377
+ // http bearer authentication required
2378
+ _a.sent();
2379
+ if (cursor !== undefined) {
2380
+ localVarQueryParameter['cursor'] = cursor;
2381
+ }
2382
+ if (limit !== undefined) {
2383
+ localVarQueryParameter['limit'] = limit;
2384
+ }
2385
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
2386
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2387
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
2388
+ return [2 /*return*/, {
2389
+ url: (0, common_1.toPathString)(localVarUrlObj),
2390
+ options: localVarRequestOptions,
2391
+ }];
2392
+ }
2393
+ });
2394
+ });
2395
+ },
2249
2396
  /**
2250
2397
  * Retry sending the last message in a specific chat thread. If the last message is from an agent/system, returns all messages after the last user message. If the last message is from a user, generates a new agent response. Only works with non-streaming mode.
2251
2398
  * @summary Retry a message in a chat thread
@@ -2353,6 +2500,58 @@ var ChatApiAxiosParamCreator = function (configuration) {
2353
2500
  });
2354
2501
  });
2355
2502
  },
2503
+ /**
2504
+ * Send a message to the draft chat session of an agent. The response contains the messages generated by the agent for the draft session. If streaming is requested, the response will be a Server-Sent Events (SSE) stream with event type \'message\'.
2505
+ * @summary Send a message to an agent draft session
2506
+ * @param {string} aid Agent ID
2507
+ * @param {ChatMessageRequest} chatMessageRequest
2508
+ * @param {*} [options] Override http request option.
2509
+ * @throws {RequiredError}
2510
+ */
2511
+ sendMessageToDraft: function (aid_1, chatMessageRequest_1) {
2512
+ var args_1 = [];
2513
+ for (var _i = 2; _i < arguments.length; _i++) {
2514
+ args_1[_i - 2] = arguments[_i];
2515
+ }
2516
+ return __awaiter(_this, __spreadArray([aid_1, chatMessageRequest_1], args_1, true), void 0, function (aid, chatMessageRequest, options) {
2517
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
2518
+ if (options === void 0) { options = {}; }
2519
+ return __generator(this, function (_a) {
2520
+ switch (_a.label) {
2521
+ case 0:
2522
+ // verify required parameter 'aid' is not null or undefined
2523
+ (0, common_1.assertParamExists)('sendMessageToDraft', 'aid', aid);
2524
+ // verify required parameter 'chatMessageRequest' is not null or undefined
2525
+ (0, common_1.assertParamExists)('sendMessageToDraft', 'chatMessageRequest', chatMessageRequest);
2526
+ localVarPath = "/agents/{aid}/draft/messages"
2527
+ .replace("{".concat("aid", "}"), encodeURIComponent(String(aid)));
2528
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
2529
+ if (configuration) {
2530
+ baseOptions = configuration.baseOptions;
2531
+ }
2532
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
2533
+ localVarHeaderParameter = {};
2534
+ localVarQueryParameter = {};
2535
+ // authentication HTTPBearer required
2536
+ // http bearer authentication required
2537
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
2538
+ case 1:
2539
+ // authentication HTTPBearer required
2540
+ // http bearer authentication required
2541
+ _a.sent();
2542
+ localVarHeaderParameter['Content-Type'] = 'application/json';
2543
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
2544
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2545
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
2546
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(chatMessageRequest, localVarRequestOptions, configuration);
2547
+ return [2 /*return*/, {
2548
+ url: (0, common_1.toPathString)(localVarUrlObj),
2549
+ options: localVarRequestOptions,
2550
+ }];
2551
+ }
2552
+ });
2553
+ });
2554
+ },
2356
2555
  /**
2357
2556
  * Update details of a specific chat thread. Currently only supports updating the summary.
2358
2557
  * @summary Update a chat thread
@@ -2611,6 +2810,31 @@ var ChatApiFp = function (configuration) {
2611
2810
  });
2612
2811
  });
2613
2812
  },
2813
+ /**
2814
+ * Retrieve the message history for the draft chat session of an agent with cursor-based pagination.
2815
+ * @summary List messages in an agent draft session
2816
+ * @param {string} aid Agent ID
2817
+ * @param {string | null} [cursor] Cursor for pagination (message id)
2818
+ * @param {number} [limit] Maximum number of messages to return
2819
+ * @param {*} [options] Override http request option.
2820
+ * @throws {RequiredError}
2821
+ */
2822
+ listMessagesInDraft: function (aid, cursor, limit, options) {
2823
+ return __awaiter(this, void 0, void 0, function () {
2824
+ var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
2825
+ var _a, _b, _c;
2826
+ return __generator(this, function (_d) {
2827
+ switch (_d.label) {
2828
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.listMessagesInDraft(aid, cursor, limit, options)];
2829
+ case 1:
2830
+ localVarAxiosArgs = _d.sent();
2831
+ localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
2832
+ localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['ChatApi.listMessagesInDraft']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
2833
+ return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
2834
+ }
2835
+ });
2836
+ });
2837
+ },
2614
2838
  /**
2615
2839
  * Retry sending the last message in a specific chat thread. If the last message is from an agent/system, returns all messages after the last user message. If the last message is from a user, generates a new agent response. Only works with non-streaming mode.
2616
2840
  * @summary Retry a message in a chat thread
@@ -2660,6 +2884,30 @@ var ChatApiFp = function (configuration) {
2660
2884
  });
2661
2885
  });
2662
2886
  },
2887
+ /**
2888
+ * Send a message to the draft chat session of an agent. The response contains the messages generated by the agent for the draft session. If streaming is requested, the response will be a Server-Sent Events (SSE) stream with event type \'message\'.
2889
+ * @summary Send a message to an agent draft session
2890
+ * @param {string} aid Agent ID
2891
+ * @param {ChatMessageRequest} chatMessageRequest
2892
+ * @param {*} [options] Override http request option.
2893
+ * @throws {RequiredError}
2894
+ */
2895
+ sendMessageToDraft: function (aid, chatMessageRequest, options) {
2896
+ return __awaiter(this, void 0, void 0, function () {
2897
+ var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
2898
+ var _a, _b, _c;
2899
+ return __generator(this, function (_d) {
2900
+ switch (_d.label) {
2901
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.sendMessageToDraft(aid, chatMessageRequest, options)];
2902
+ case 1:
2903
+ localVarAxiosArgs = _d.sent();
2904
+ localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
2905
+ localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['ChatApi.sendMessageToDraft']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
2906
+ return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
2907
+ }
2908
+ });
2909
+ });
2910
+ },
2663
2911
  /**
2664
2912
  * Update details of a specific chat thread. Currently only supports updating the summary.
2665
2913
  * @summary Update a chat thread
@@ -2783,6 +3031,18 @@ var ChatApiFactory = function (configuration, basePath, axios) {
2783
3031
  listMessagesInChat: function (aid, chatId, cursor, limit, options) {
2784
3032
  return localVarFp.listMessagesInChat(aid, chatId, cursor, limit, options).then(function (request) { return request(axios, basePath); });
2785
3033
  },
3034
+ /**
3035
+ * Retrieve the message history for the draft chat session of an agent with cursor-based pagination.
3036
+ * @summary List messages in an agent draft session
3037
+ * @param {string} aid Agent ID
3038
+ * @param {string | null} [cursor] Cursor for pagination (message id)
3039
+ * @param {number} [limit] Maximum number of messages to return
3040
+ * @param {*} [options] Override http request option.
3041
+ * @throws {RequiredError}
3042
+ */
3043
+ listMessagesInDraft: function (aid, cursor, limit, options) {
3044
+ return localVarFp.listMessagesInDraft(aid, cursor, limit, options).then(function (request) { return request(axios, basePath); });
3045
+ },
2786
3046
  /**
2787
3047
  * Retry sending the last message in a specific chat thread. If the last message is from an agent/system, returns all messages after the last user message. If the last message is from a user, generates a new agent response. Only works with non-streaming mode.
2788
3048
  * @summary Retry a message in a chat thread
@@ -2806,6 +3066,17 @@ var ChatApiFactory = function (configuration, basePath, axios) {
2806
3066
  sendMessageToChat: function (aid, chatId, chatMessageRequest, options) {
2807
3067
  return localVarFp.sendMessageToChat(aid, chatId, chatMessageRequest, options).then(function (request) { return request(axios, basePath); });
2808
3068
  },
3069
+ /**
3070
+ * Send a message to the draft chat session of an agent. The response contains the messages generated by the agent for the draft session. If streaming is requested, the response will be a Server-Sent Events (SSE) stream with event type \'message\'.
3071
+ * @summary Send a message to an agent draft session
3072
+ * @param {string} aid Agent ID
3073
+ * @param {ChatMessageRequest} chatMessageRequest
3074
+ * @param {*} [options] Override http request option.
3075
+ * @throws {RequiredError}
3076
+ */
3077
+ sendMessageToDraft: function (aid, chatMessageRequest, options) {
3078
+ return localVarFp.sendMessageToDraft(aid, chatMessageRequest, options).then(function (request) { return request(axios, basePath); });
3079
+ },
2809
3080
  /**
2810
3081
  * Update details of a specific chat thread. Currently only supports updating the summary.
2811
3082
  * @summary Update a chat thread
@@ -2936,6 +3207,20 @@ var ChatApi = /** @class */ (function (_super) {
2936
3207
  var _this = this;
2937
3208
  return (0, exports.ChatApiFp)(this.configuration).listMessagesInChat(aid, chatId, cursor, limit, options).then(function (request) { return request(_this.axios, _this.basePath); });
2938
3209
  };
3210
+ /**
3211
+ * Retrieve the message history for the draft chat session of an agent with cursor-based pagination.
3212
+ * @summary List messages in an agent draft session
3213
+ * @param {string} aid Agent ID
3214
+ * @param {string | null} [cursor] Cursor for pagination (message id)
3215
+ * @param {number} [limit] Maximum number of messages to return
3216
+ * @param {*} [options] Override http request option.
3217
+ * @throws {RequiredError}
3218
+ * @memberof ChatApi
3219
+ */
3220
+ ChatApi.prototype.listMessagesInDraft = function (aid, cursor, limit, options) {
3221
+ var _this = this;
3222
+ return (0, exports.ChatApiFp)(this.configuration).listMessagesInDraft(aid, cursor, limit, options).then(function (request) { return request(_this.axios, _this.basePath); });
3223
+ };
2939
3224
  /**
2940
3225
  * Retry sending the last message in a specific chat thread. If the last message is from an agent/system, returns all messages after the last user message. If the last message is from a user, generates a new agent response. Only works with non-streaming mode.
2941
3226
  * @summary Retry a message in a chat thread
@@ -2963,6 +3248,19 @@ var ChatApi = /** @class */ (function (_super) {
2963
3248
  var _this = this;
2964
3249
  return (0, exports.ChatApiFp)(this.configuration).sendMessageToChat(aid, chatId, chatMessageRequest, options).then(function (request) { return request(_this.axios, _this.basePath); });
2965
3250
  };
3251
+ /**
3252
+ * Send a message to the draft chat session of an agent. The response contains the messages generated by the agent for the draft session. If streaming is requested, the response will be a Server-Sent Events (SSE) stream with event type \'message\'.
3253
+ * @summary Send a message to an agent draft session
3254
+ * @param {string} aid Agent ID
3255
+ * @param {ChatMessageRequest} chatMessageRequest
3256
+ * @param {*} [options] Override http request option.
3257
+ * @throws {RequiredError}
3258
+ * @memberof ChatApi
3259
+ */
3260
+ ChatApi.prototype.sendMessageToDraft = function (aid, chatMessageRequest, options) {
3261
+ var _this = this;
3262
+ return (0, exports.ChatApiFp)(this.configuration).sendMessageToDraft(aid, chatMessageRequest, options).then(function (request) { return request(_this.axios, _this.basePath); });
3263
+ };
2966
3264
  /**
2967
3265
  * Update details of a specific chat thread. Currently only supports updating the summary.
2968
3266
  * @summary Update a chat thread
package/dist/base.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  * Nation IntentKit API
3
3
  * API for Nation IntentKit services
4
4
  *
5
- * The version of the OpenAPI document: 0.7.16
5
+ * The version of the OpenAPI document: 0.7.18
6
6
  *
7
7
  *
8
8
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
package/dist/base.js CHANGED
@@ -5,7 +5,7 @@
5
5
  * Nation IntentKit API
6
6
  * API for Nation IntentKit services
7
7
  *
8
- * The version of the OpenAPI document: 0.7.16
8
+ * The version of the OpenAPI document: 0.7.18
9
9
  *
10
10
  *
11
11
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
package/dist/common.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  * Nation IntentKit API
3
3
  * API for Nation IntentKit services
4
4
  *
5
- * The version of the OpenAPI document: 0.7.16
5
+ * The version of the OpenAPI document: 0.7.18
6
6
  *
7
7
  *
8
8
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
package/dist/common.js CHANGED
@@ -5,7 +5,7 @@
5
5
  * Nation IntentKit API
6
6
  * API for Nation IntentKit services
7
7
  *
8
- * The version of the OpenAPI document: 0.7.16
8
+ * The version of the OpenAPI document: 0.7.18
9
9
  *
10
10
  *
11
11
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -2,7 +2,7 @@
2
2
  * Nation IntentKit API
3
3
  * API for Nation IntentKit services
4
4
  *
5
- * The version of the OpenAPI document: 0.7.16
5
+ * The version of the OpenAPI document: 0.7.18
6
6
  *
7
7
  *
8
8
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -5,7 +5,7 @@
5
5
  * Nation IntentKit API
6
6
  * API for Nation IntentKit services
7
7
  *
8
- * The version of the OpenAPI document: 0.7.16
8
+ * The version of the OpenAPI document: 0.7.18
9
9
  *
10
10
  *
11
11
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
package/dist/index.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  * Nation IntentKit API
3
3
  * API for Nation IntentKit services
4
4
  *
5
- * The version of the OpenAPI document: 0.7.16
5
+ * The version of the OpenAPI document: 0.7.18
6
6
  *
7
7
  *
8
8
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
package/dist/index.js CHANGED
@@ -5,7 +5,7 @@
5
5
  * Nation IntentKit API
6
6
  * API for Nation IntentKit services
7
7
  *
8
- * The version of the OpenAPI document: 0.7.16
8
+ * The version of the OpenAPI document: 0.7.18
9
9
  *
10
10
  *
11
11
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
package/docs/AgentApi.md CHANGED
@@ -17,6 +17,7 @@ All URIs are relative to *http://localhost*
17
17
  |[**overrideAgentPublicInfo**](#overrideagentpublicinfo) | **PUT** /agents/{agent_id}/public-info | Override Agent Public Information|
18
18
  |[**publishAgent**](#publishagent) | **POST** /agents/{agent_id}/publish | Publish Agent|
19
19
  |[**resetAgentApiKey**](#resetagentapikey) | **POST** /agents/{agent_id}/api-key/reset | Reset Agent API Key|
20
+ |[**unpublishAgent**](#unpublishagent) | **POST** /agents/{agent_id}/unpublish | Unpublish Agent|
20
21
  |[**validateAgentCreate**](#validateagentcreate) | **POST** /agent/validate | Validate Agent Create|
21
22
  |[**validateAgentUpdate**](#validateagentupdate) | **POST** /agents/{agent_id}/validate | Validate Agent Update|
22
23
 
@@ -732,6 +733,58 @@ const { status, data } = await apiInstance.resetAgentApiKey(
732
733
 
733
734
  [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
734
735
 
736
+ # **unpublishAgent**
737
+ > Agent unpublishAgent()
738
+
739
+ Unpublish an agent by setting its state back to private.
740
+
741
+ ### Example
742
+
743
+ ```typescript
744
+ import {
745
+ AgentApi,
746
+ Configuration
747
+ } from '@crestal/nation-sdk';
748
+
749
+ const configuration = new Configuration();
750
+ const apiInstance = new AgentApi(configuration);
751
+
752
+ let agentId: string; //ID of the agent to unpublish (default to undefined)
753
+
754
+ const { status, data } = await apiInstance.unpublishAgent(
755
+ agentId
756
+ );
757
+ ```
758
+
759
+ ### Parameters
760
+
761
+ |Name | Type | Description | Notes|
762
+ |------------- | ------------- | ------------- | -------------|
763
+ | **agentId** | [**string**] | ID of the agent to unpublish | defaults to undefined|
764
+
765
+
766
+ ### Return type
767
+
768
+ **Agent**
769
+
770
+ ### Authorization
771
+
772
+ [HTTPBearer](../README.md#HTTPBearer)
773
+
774
+ ### HTTP request headers
775
+
776
+ - **Content-Type**: Not defined
777
+ - **Accept**: application/json
778
+
779
+
780
+ ### HTTP response details
781
+ | Status code | Description | Response headers |
782
+ |-------------|-------------|------------------|
783
+ |**200** | Successful Response | - |
784
+ |**422** | Validation Error | - |
785
+
786
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
787
+
735
788
  # **validateAgentCreate**
736
789
  > validateAgentCreate()
737
790