syllable-sdk 0.1.0-alpha.15 → 0.1.0-alpha.17
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/docs/sdks/agents/README.md +2 -2
- package/docs/sdks/custommessages/README.md +6 -6
- package/funcs/agentsGetById.d.ts +1 -1
- package/funcs/agentsGetById.d.ts.map +1 -1
- package/funcs/agentsGetById.js +1 -1
- package/funcs/agentsGetById.js.map +1 -1
- package/funcs/agentsList.d.ts +1 -1
- package/funcs/agentsList.d.ts.map +1 -1
- package/funcs/agentsList.js +1 -1
- package/funcs/agentsList.js.map +1 -1
- package/funcs/customMessagesCreate.d.ts +1 -1
- package/funcs/customMessagesCreate.d.ts.map +1 -1
- package/funcs/customMessagesCreate.js +2 -2
- package/funcs/customMessagesCreate.js.map +1 -1
- package/funcs/customMessagesGetById.d.ts +1 -1
- package/funcs/customMessagesGetById.d.ts.map +1 -1
- package/funcs/customMessagesGetById.js +1 -1
- package/funcs/customMessagesGetById.js.map +1 -1
- package/funcs/customMessagesList.d.ts +1 -1
- package/funcs/customMessagesList.d.ts.map +1 -1
- package/funcs/customMessagesList.js +1 -1
- package/funcs/customMessagesList.js.map +1 -1
- package/funcs/customMessagesUpdate.d.ts +1 -1
- package/funcs/customMessagesUpdate.d.ts.map +1 -1
- package/funcs/customMessagesUpdate.js +2 -2
- package/funcs/customMessagesUpdate.js.map +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/lib/config.js.map +1 -1
- package/models/components/agentresponse.d.ts +115 -0
- package/models/components/agentresponse.d.ts.map +1 -0
- package/models/components/agentresponse.js +118 -0
- package/models/components/agentresponse.js.map +1 -0
- package/models/components/channel.d.ts +0 -3
- package/models/components/channel.d.ts.map +1 -1
- package/models/components/channel.js.map +1 -1
- package/models/components/custommessage.d.ts +3 -5
- package/models/components/custommessage.d.ts.map +1 -1
- package/models/components/custommessage.js +0 -2
- package/models/components/custommessage.js.map +1 -1
- package/models/components/custommessagecreaterequest.d.ts +39 -0
- package/models/components/custommessagecreaterequest.d.ts.map +1 -0
- package/models/components/custommessagecreaterequest.js +63 -0
- package/models/components/custommessagecreaterequest.js.map +1 -0
- package/models/components/custommessageresponse.d.ts +44 -0
- package/models/components/custommessageresponse.d.ts.map +1 -0
- package/models/components/{custommessagecreate.js → custommessageresponse.js} +19 -17
- package/models/components/custommessageresponse.js.map +1 -0
- package/models/components/custommessageupdaterequest.d.ts +44 -0
- package/models/components/custommessageupdaterequest.d.ts.map +1 -0
- package/models/components/custommessageupdaterequest.js +65 -0
- package/models/components/custommessageupdaterequest.js.map +1 -0
- package/models/components/index.d.ts +7 -3
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +7 -3
- package/models/components/index.js.map +1 -1
- package/models/components/listresponseagentresponse.d.ts +38 -0
- package/models/components/{listresponsecustommessage.d.ts.map → listresponseagentresponse.d.ts.map} +1 -1
- package/models/components/{listresponsecustommessage.js → listresponseagentresponse.js} +20 -20
- package/models/components/{listresponsecustommessage.js.map → listresponseagentresponse.js.map} +1 -1
- package/models/components/listresponsecustommessageresponse.d.ts +38 -0
- package/models/components/listresponsecustommessageresponse.d.ts.map +1 -0
- package/models/components/{listresponseagent.js → listresponsecustommessageresponse.js} +20 -20
- package/models/components/listresponsecustommessageresponse.js.map +1 -0
- package/models/components/llmconfig.d.ts +3 -34
- package/models/components/llmconfig.d.ts.map +1 -1
- package/models/components/llmconfig.js +4 -26
- package/models/components/llmconfig.js.map +1 -1
- package/models/components/prompt.d.ts +0 -3
- package/models/components/prompt.d.ts.map +1 -1
- package/models/components/prompt.js.map +1 -1
- package/models/components/promptcreate.d.ts +0 -3
- package/models/components/promptcreate.d.ts.map +1 -1
- package/models/components/promptcreate.js.map +1 -1
- package/models/components/promptupdate.d.ts +0 -3
- package/models/components/promptupdate.d.ts.map +1 -1
- package/models/components/promptupdate.js.map +1 -1
- package/models/components/provider.d.ts +34 -0
- package/models/components/provider.d.ts.map +1 -0
- package/models/components/provider.js +54 -0
- package/models/components/provider.js.map +1 -0
- package/models/components/target.d.ts +0 -3
- package/models/components/target.d.ts.map +1 -1
- package/models/components/target.js.map +1 -1
- package/package.json +1 -1
- package/sdk/agents.d.ts +2 -2
- package/sdk/agents.d.ts.map +1 -1
- package/sdk/custommessages.d.ts +4 -4
- package/sdk/custommessages.d.ts.map +1 -1
- package/sdk/custommessages.js.map +1 -1
- package/src/funcs/agentsGetById.ts +3 -3
- package/src/funcs/agentsList.ts +3 -3
- package/src/funcs/customMessagesCreate.ts +6 -5
- package/src/funcs/customMessagesGetById.ts +3 -3
- package/src/funcs/customMessagesList.ts +3 -3
- package/src/funcs/customMessagesUpdate.ts +6 -5
- package/src/lib/config.ts +3 -3
- package/src/models/components/agentresponse.ts +215 -0
- package/src/models/components/channel.ts +0 -3
- package/src/models/components/custommessage.ts +3 -7
- package/src/models/components/custommessagecreaterequest.ts +80 -0
- package/src/models/components/custommessageresponse.ts +87 -0
- package/src/models/components/custommessageupdaterequest.ts +87 -0
- package/src/models/components/index.ts +7 -3
- package/src/models/components/{listresponsecustommessage.ts → listresponseagentresponse.ts} +30 -30
- package/src/models/components/listresponsecustommessageresponse.ts +104 -0
- package/src/models/components/llmconfig.ts +9 -36
- package/src/models/components/prompt.ts +0 -3
- package/src/models/components/promptcreate.ts +0 -3
- package/src/models/components/promptupdate.ts +0 -3
- package/src/models/components/provider.ts +37 -0
- package/src/models/components/target.ts +0 -3
- package/src/sdk/agents.ts +2 -2
- package/src/sdk/custommessages.ts +6 -6
- package/models/components/custommessagecreate.d.ts +0 -39
- package/models/components/custommessagecreate.d.ts.map +0 -1
- package/models/components/custommessagecreate.js.map +0 -1
- package/models/components/listresponseagent.d.ts +0 -38
- package/models/components/listresponseagent.d.ts.map +0 -1
- package/models/components/listresponseagent.js.map +0 -1
- package/models/components/listresponsecustommessage.d.ts +0 -38
- package/src/models/components/custommessagecreate.ts +0 -80
- package/src/models/components/listresponseagent.ts +0 -101
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*
|
|
3
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
4
|
+
*/
|
|
5
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
+
}
|
|
11
|
+
Object.defineProperty(o, k2, desc);
|
|
12
|
+
}) : (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
o[k2] = m[k];
|
|
15
|
+
}));
|
|
16
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
+
}) : function(o, v) {
|
|
19
|
+
o["default"] = v;
|
|
20
|
+
});
|
|
21
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
22
|
+
if (mod && mod.__esModule) return mod;
|
|
23
|
+
var result = {};
|
|
24
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
25
|
+
__setModuleDefault(result, mod);
|
|
26
|
+
return result;
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.Provider$ = exports.Provider$outboundSchema = exports.Provider$inboundSchema = exports.Provider = void 0;
|
|
30
|
+
const z = __importStar(require("zod"));
|
|
31
|
+
/**
|
|
32
|
+
* LLM API provider.
|
|
33
|
+
*/
|
|
34
|
+
exports.Provider = {
|
|
35
|
+
AzureOpenai: "azure_openai",
|
|
36
|
+
Openai: "openai",
|
|
37
|
+
};
|
|
38
|
+
/** @internal */
|
|
39
|
+
exports.Provider$inboundSchema = z
|
|
40
|
+
.nativeEnum(exports.Provider);
|
|
41
|
+
/** @internal */
|
|
42
|
+
exports.Provider$outboundSchema = exports.Provider$inboundSchema;
|
|
43
|
+
/**
|
|
44
|
+
* @internal
|
|
45
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
46
|
+
*/
|
|
47
|
+
var Provider$;
|
|
48
|
+
(function (Provider$) {
|
|
49
|
+
/** @deprecated use `Provider$inboundSchema` instead. */
|
|
50
|
+
Provider$.inboundSchema = exports.Provider$inboundSchema;
|
|
51
|
+
/** @deprecated use `Provider$outboundSchema` instead. */
|
|
52
|
+
Provider$.outboundSchema = exports.Provider$outboundSchema;
|
|
53
|
+
})(Provider$ || (exports.Provider$ = Provider$ = {}));
|
|
54
|
+
//# sourceMappingURL=provider.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"provider.js","sourceRoot":"","sources":["../../src/models/components/provider.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AAGzB;;GAEG;AACU,QAAA,QAAQ,GAAG;IACtB,WAAW,EAAE,cAAc;IAC3B,MAAM,EAAE,QAAQ;CACR,CAAC;AAMX,gBAAgB;AACH,QAAA,sBAAsB,GAAqC,CAAC;KACtE,UAAU,CAAC,gBAAQ,CAAC,CAAC;AAExB,gBAAgB;AACH,QAAA,uBAAuB,GAClC,8BAAsB,CAAC;AAEzB;;;GAGG;AACH,IAAiB,SAAS,CAKzB;AALD,WAAiB,SAAS;IACxB,wDAAwD;IAC3C,uBAAa,GAAG,8BAAsB,CAAC;IACpD,yDAAyD;IAC5C,wBAAc,GAAG,+BAAuB,CAAC;AACxD,CAAC,EALgB,SAAS,yBAAT,SAAS,QAKzB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"target.d.ts","sourceRoot":"","sources":["../../src/models/components/target.ts"],"names":[],"mappings":"AAIA,O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AC5B,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IAC5C,OAAO,EAAE,OAAO,CAAC;IACjB,EAAE,EAAE,MAAM,CAAC;IACX,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;CAC1C,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,qBAAqB,EAAE,CAAC,CAAC,OAAO,CAC3C,eAAe,EACf,CAAC,CAAC,UAAU,EACZ,MAAM,CAmBN,CAAC;AAEH;;;GAGG;AACH,yBAAiB,OAAO,CAAC;IACvB,sDAAsD;IAC/C,MAAM,aAAa,0CAAuB,CAAC;IAClD,uDAAuD;IAChD,MAAM,cAAc,kDAAwB,CAAC;IACpD,iDAAiD;IACjD,KAAY,QAAQ,GAAG,eAAe,CAAC;CACxC;AAED,wBAAgB,YAAY,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAEnD;AAED,wBAAgB,cAAc,CAC5B,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,MAAM,EAAE,kBAAkB,CAAC,CAM7C"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"target.js","sourceRoot":"","sources":["../../src/models/components/target.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"target.js","sourceRoot":"","sources":["../../src/models/components/target.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAqHH,oCAEC;AAED,wCAQC;AA/HD,uCAAyB;AACzB,2DAA0D;AAC1D,qDAAiD;AAGjD,qDAI0B;AAkC1B,gBAAgB;AACH,QAAA,oBAAoB,GAA6C,CAAC;KAC5E,MAAM,CAAC;IACN,QAAQ,EAAE,CAAC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AAE,CAAC,GAAG,EAAE;IACpB,WAAW,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;CAC/C,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,OAAO,EAAE,UAAU;QACnB,UAAU,EAAE,aAAa;QACzB,SAAS,EAAE,YAAY;QACvB,cAAc,EAAE,iBAAiB;QACjC,MAAM,EAAE,SAAS;QACjB,WAAW,EAAE,cAAc;KAC5B,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH;;;GAGG;AACH,IAAiB,OAAO,CAOvB;AAPD,WAAiB,OAAO;IACtB,sDAAsD;IACzC,qBAAa,GAAG,4BAAoB,CAAC;IAClD,uDAAuD;IAC1C,sBAAc,GAAG,6BAAqB,CAAC;AAGtD,CAAC,EAPgB,OAAO,uBAAP,OAAO,QAOvB;AAED,SAAgB,YAAY,CAAC,MAAc;IACzC,OAAO,IAAI,CAAC,SAAS,CAAC,6BAAqB,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC;AAC7D,CAAC;AAED,SAAgB,cAAc,CAC5B,UAAkB;IAElB,OAAO,IAAA,sBAAS,EACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CAAC,4BAAoB,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAChD,oCAAoC,CACrC,CAAC;AACJ,CAAC"}
|
package/package.json
CHANGED
package/sdk/agents.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ export declare class Agents extends ClientSDK {
|
|
|
11
11
|
* @remarks
|
|
12
12
|
* List the existing agents
|
|
13
13
|
*/
|
|
14
|
-
list(request: operations.AgentListRequest, options?: RequestOptions): Promise<components.
|
|
14
|
+
list(request: operations.AgentListRequest, options?: RequestOptions): Promise<components.ListResponseAgentResponse>;
|
|
15
15
|
/**
|
|
16
16
|
* Create Agent
|
|
17
17
|
*
|
|
@@ -32,7 +32,7 @@ export declare class Agents extends ClientSDK {
|
|
|
32
32
|
* @remarks
|
|
33
33
|
* Get an agent by ID.
|
|
34
34
|
*/
|
|
35
|
-
getById(request: operations.AgentGetByIdRequest, options?: RequestOptions): Promise<components.
|
|
35
|
+
getById(request: operations.AgentGetByIdRequest, options?: RequestOptions): Promise<components.AgentResponse>;
|
|
36
36
|
/**
|
|
37
37
|
* Delete Agent
|
|
38
38
|
*/
|
package/sdk/agents.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agents.d.ts","sourceRoot":"","sources":["../src/sdk/agents.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAE5D,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEjC,qBAAa,MAAO,SAAQ,SAAS;IACnC,OAAO,CAAC,KAAK,CAAC,CAAO;IACrB,IAAI,IAAI,IAAI,IAAI,CAEf;IAED;;;;;OAKG;IACG,IAAI,CACR,OAAO,EAAE,UAAU,CAAC,gBAAgB,EACpC,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,UAAU,CAAC,
|
|
1
|
+
{"version":3,"file":"agents.d.ts","sourceRoot":"","sources":["../src/sdk/agents.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAE5D,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEjC,qBAAa,MAAO,SAAQ,SAAS;IACnC,OAAO,CAAC,KAAK,CAAC,CAAO;IACrB,IAAI,IAAI,IAAI,IAAI,CAEf;IAED;;;;;OAKG;IACG,IAAI,CACR,OAAO,EAAE,UAAU,CAAC,gBAAgB,EACpC,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,UAAU,CAAC,yBAAyB,CAAC;IAQhD;;;;;OAKG;IACG,MAAM,CACV,OAAO,EAAE,UAAU,CAAC,WAAW,EAC/B,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC;IAQ5B;;;;;OAKG;IACG,MAAM,CACV,OAAO,EAAE,UAAU,CAAC,WAAW,EAC/B,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC;IAQ5B;;;;;OAKG;IACG,OAAO,CACX,OAAO,EAAE,UAAU,CAAC,mBAAmB,EACvC,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,UAAU,CAAC,aAAa,CAAC;IAQpC;;OAEG;IACG,MAAM,CACV,OAAO,EAAE,UAAU,CAAC,kBAAkB,EACtC,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,GAAG,CAAC;IAQf;;;;;OAKG;IACG,uBAAuB,CAC3B,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,KAAK,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC;CAMzC"}
|
package/sdk/custommessages.d.ts
CHANGED
|
@@ -8,28 +8,28 @@ export declare class CustomMessages extends ClientSDK {
|
|
|
8
8
|
* @remarks
|
|
9
9
|
* List the existing custom_messages
|
|
10
10
|
*/
|
|
11
|
-
list(request: operations.CustomMessagesListRequest, options?: RequestOptions): Promise<components.
|
|
11
|
+
list(request: operations.CustomMessagesListRequest, options?: RequestOptions): Promise<components.ListResponseCustomMessageResponse>;
|
|
12
12
|
/**
|
|
13
13
|
* Create Custom Message
|
|
14
14
|
*
|
|
15
15
|
* @remarks
|
|
16
16
|
* Create a new greeting
|
|
17
17
|
*/
|
|
18
|
-
create(request: components.
|
|
18
|
+
create(request: components.CustomMessageCreateRequest, options?: RequestOptions): Promise<components.CustomMessageResponse>;
|
|
19
19
|
/**
|
|
20
20
|
* Update Custom Message
|
|
21
21
|
*
|
|
22
22
|
* @remarks
|
|
23
23
|
* Update a greeting
|
|
24
24
|
*/
|
|
25
|
-
update(request: components.
|
|
25
|
+
update(request: components.CustomMessageUpdateRequest, options?: RequestOptions): Promise<components.CustomMessageResponse>;
|
|
26
26
|
/**
|
|
27
27
|
* Get Custom Message By Id
|
|
28
28
|
*
|
|
29
29
|
* @remarks
|
|
30
30
|
* Get the greeting by its ID
|
|
31
31
|
*/
|
|
32
|
-
getById(request: operations.CustomMessageGetByIdRequest, options?: RequestOptions): Promise<components.
|
|
32
|
+
getById(request: operations.CustomMessageGetByIdRequest, options?: RequestOptions): Promise<components.CustomMessageResponse>;
|
|
33
33
|
/**
|
|
34
34
|
* Delete Custom Message
|
|
35
35
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"custommessages.d.ts","sourceRoot":"","sources":["../src/sdk/custommessages.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAG5D,qBAAa,cAAe,SAAQ,SAAS;IAC3C;;;;;OAKG;IACG,IAAI,CACR,OAAO,EAAE,UAAU,CAAC,yBAAyB,EAC7C,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,UAAU,CAAC,
|
|
1
|
+
{"version":3,"file":"custommessages.d.ts","sourceRoot":"","sources":["../src/sdk/custommessages.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;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version":3,"file":"custommessages.js","sourceRoot":"","sources":["../src/sdk/custommessages.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,8EAAwE;AACxE,8EAAwE;AACxE,gFAA0E;AAC1E,0EAAoE;AACpE,8EAAwE;AACxE,4CAA2D;AAG3D,0CAA6C;AAE7C,MAAa,cAAe,SAAQ,mBAAS;IAC3C;;;;;OAKG;IACH,KAAK,CAAC,IAAI,CACR,OAA6C,EAC7C,OAAwB;QAExB,OAAO,IAAA,mBAAW,EAAC,IAAA,0CAAkB,EACnC,IAAI,EACJ,OAAO,EACP,OAAO,CACR,CAAC,CAAC;IACL,CAAC;IAED;;;;;OAKG;IACH,KAAK,CAAC,MAAM,CACV,OAA8C,EAC9C,OAAwB;QAExB,OAAO,IAAA,mBAAW,EAAC,IAAA,8CAAoB,EACrC,IAAI,EACJ,OAAO,EACP,OAAO,CACR,CAAC,CAAC;IACL,CAAC;IAED;;;;;OAKG;IACH,KAAK,CAAC,MAAM,CACV,OAA8C,EAC9C,OAAwB;QAExB,OAAO,IAAA,mBAAW,EAAC,IAAA,8CAAoB,EACrC,IAAI,EACJ,OAAO,EACP,OAAO,CACR,CAAC,CAAC;IACL,CAAC;IAED;;;;;OAKG;IACH,KAAK,CAAC,OAAO,CACX,OAA+C,EAC/C,OAAwB;QAExB,OAAO,IAAA,mBAAW,EAAC,IAAA,gDAAqB,EACtC,IAAI,EACJ,OAAO,EACP,OAAO,CACR,CAAC,CAAC;IACL,CAAC;IAED;;;;;OAKG;IACH,KAAK,CAAC,MAAM,CACV,OAA+C,EAC/C,OAAwB;QAExB,OAAO,IAAA,mBAAW,EAAC,IAAA,8CAAoB,EACrC,IAAI,EACJ,OAAO,EACP,OAAO,CACR,CAAC,CAAC;IACL,CAAC;CACF;AArFD,wCAqFC"}
|
|
@@ -35,7 +35,7 @@ export async function agentsGetById(
|
|
|
35
35
|
options?: RequestOptions,
|
|
36
36
|
): Promise<
|
|
37
37
|
Result<
|
|
38
|
-
components.
|
|
38
|
+
components.AgentResponse,
|
|
39
39
|
| errors.HTTPValidationError
|
|
40
40
|
| SDKError
|
|
41
41
|
| SDKValidationError
|
|
@@ -116,7 +116,7 @@ export async function agentsGetById(
|
|
|
116
116
|
};
|
|
117
117
|
|
|
118
118
|
const [result] = await M.match<
|
|
119
|
-
components.
|
|
119
|
+
components.AgentResponse,
|
|
120
120
|
| errors.HTTPValidationError
|
|
121
121
|
| SDKError
|
|
122
122
|
| SDKValidationError
|
|
@@ -126,7 +126,7 @@ export async function agentsGetById(
|
|
|
126
126
|
| RequestTimeoutError
|
|
127
127
|
| ConnectionError
|
|
128
128
|
>(
|
|
129
|
-
M.json(200, components.
|
|
129
|
+
M.json(200, components.AgentResponse$inboundSchema),
|
|
130
130
|
M.jsonErr(422, errors.HTTPValidationError$inboundSchema),
|
|
131
131
|
M.fail(["4XX", "5XX"]),
|
|
132
132
|
)(response, { extraFields: responseFields });
|
package/src/funcs/agentsList.ts
CHANGED
|
@@ -35,7 +35,7 @@ export async function agentsList(
|
|
|
35
35
|
options?: RequestOptions,
|
|
36
36
|
): Promise<
|
|
37
37
|
Result<
|
|
38
|
-
components.
|
|
38
|
+
components.ListResponseAgentResponse,
|
|
39
39
|
| errors.HTTPValidationError
|
|
40
40
|
| SDKError
|
|
41
41
|
| SDKValidationError
|
|
@@ -122,7 +122,7 @@ export async function agentsList(
|
|
|
122
122
|
};
|
|
123
123
|
|
|
124
124
|
const [result] = await M.match<
|
|
125
|
-
components.
|
|
125
|
+
components.ListResponseAgentResponse,
|
|
126
126
|
| errors.HTTPValidationError
|
|
127
127
|
| SDKError
|
|
128
128
|
| SDKValidationError
|
|
@@ -132,7 +132,7 @@ export async function agentsList(
|
|
|
132
132
|
| RequestTimeoutError
|
|
133
133
|
| ConnectionError
|
|
134
134
|
>(
|
|
135
|
-
M.json(200, components.
|
|
135
|
+
M.json(200, components.ListResponseAgentResponse$inboundSchema),
|
|
136
136
|
M.jsonErr(422, errors.HTTPValidationError$inboundSchema),
|
|
137
137
|
M.fail(["4XX", "5XX"]),
|
|
138
138
|
)(response, { extraFields: responseFields });
|
|
@@ -30,11 +30,11 @@ import { Result } from "../types/fp.js";
|
|
|
30
30
|
*/
|
|
31
31
|
export async function customMessagesCreate(
|
|
32
32
|
client: SyllableSDKCore,
|
|
33
|
-
request: components.
|
|
33
|
+
request: components.CustomMessageCreateRequest,
|
|
34
34
|
options?: RequestOptions,
|
|
35
35
|
): Promise<
|
|
36
36
|
Result<
|
|
37
|
-
components.
|
|
37
|
+
components.CustomMessageResponse,
|
|
38
38
|
| errors.HTTPValidationError
|
|
39
39
|
| SDKError
|
|
40
40
|
| SDKValidationError
|
|
@@ -47,7 +47,8 @@ export async function customMessagesCreate(
|
|
|
47
47
|
> {
|
|
48
48
|
const parsed = safeParse(
|
|
49
49
|
request,
|
|
50
|
-
(value) =>
|
|
50
|
+
(value) =>
|
|
51
|
+
components.CustomMessageCreateRequest$outboundSchema.parse(value),
|
|
51
52
|
"Input validation failed",
|
|
52
53
|
);
|
|
53
54
|
if (!parsed.ok) {
|
|
@@ -109,7 +110,7 @@ export async function customMessagesCreate(
|
|
|
109
110
|
};
|
|
110
111
|
|
|
111
112
|
const [result] = await M.match<
|
|
112
|
-
components.
|
|
113
|
+
components.CustomMessageResponse,
|
|
113
114
|
| errors.HTTPValidationError
|
|
114
115
|
| SDKError
|
|
115
116
|
| SDKValidationError
|
|
@@ -119,7 +120,7 @@ export async function customMessagesCreate(
|
|
|
119
120
|
| RequestTimeoutError
|
|
120
121
|
| ConnectionError
|
|
121
122
|
>(
|
|
122
|
-
M.json(200, components.
|
|
123
|
+
M.json(200, components.CustomMessageResponse$inboundSchema),
|
|
123
124
|
M.jsonErr(422, errors.HTTPValidationError$inboundSchema),
|
|
124
125
|
M.fail(["4XX", "5XX"]),
|
|
125
126
|
)(response, { extraFields: responseFields });
|
|
@@ -35,7 +35,7 @@ export async function customMessagesGetById(
|
|
|
35
35
|
options?: RequestOptions,
|
|
36
36
|
): Promise<
|
|
37
37
|
Result<
|
|
38
|
-
components.
|
|
38
|
+
components.CustomMessageResponse,
|
|
39
39
|
| errors.HTTPValidationError
|
|
40
40
|
| SDKError
|
|
41
41
|
| SDKValidationError
|
|
@@ -120,7 +120,7 @@ export async function customMessagesGetById(
|
|
|
120
120
|
};
|
|
121
121
|
|
|
122
122
|
const [result] = await M.match<
|
|
123
|
-
components.
|
|
123
|
+
components.CustomMessageResponse,
|
|
124
124
|
| errors.HTTPValidationError
|
|
125
125
|
| SDKError
|
|
126
126
|
| SDKValidationError
|
|
@@ -130,7 +130,7 @@ export async function customMessagesGetById(
|
|
|
130
130
|
| RequestTimeoutError
|
|
131
131
|
| ConnectionError
|
|
132
132
|
>(
|
|
133
|
-
M.json(200, components.
|
|
133
|
+
M.json(200, components.CustomMessageResponse$inboundSchema),
|
|
134
134
|
M.jsonErr(422, errors.HTTPValidationError$inboundSchema),
|
|
135
135
|
M.fail(["4XX", "5XX"]),
|
|
136
136
|
)(response, { extraFields: responseFields });
|
|
@@ -35,7 +35,7 @@ export async function customMessagesList(
|
|
|
35
35
|
options?: RequestOptions,
|
|
36
36
|
): Promise<
|
|
37
37
|
Result<
|
|
38
|
-
components.
|
|
38
|
+
components.ListResponseCustomMessageResponse,
|
|
39
39
|
| errors.HTTPValidationError
|
|
40
40
|
| SDKError
|
|
41
41
|
| SDKValidationError
|
|
@@ -122,7 +122,7 @@ export async function customMessagesList(
|
|
|
122
122
|
};
|
|
123
123
|
|
|
124
124
|
const [result] = await M.match<
|
|
125
|
-
components.
|
|
125
|
+
components.ListResponseCustomMessageResponse,
|
|
126
126
|
| errors.HTTPValidationError
|
|
127
127
|
| SDKError
|
|
128
128
|
| SDKValidationError
|
|
@@ -132,7 +132,7 @@ export async function customMessagesList(
|
|
|
132
132
|
| RequestTimeoutError
|
|
133
133
|
| ConnectionError
|
|
134
134
|
>(
|
|
135
|
-
M.json(200, components.
|
|
135
|
+
M.json(200, components.ListResponseCustomMessageResponse$inboundSchema),
|
|
136
136
|
M.jsonErr(422, errors.HTTPValidationError$inboundSchema),
|
|
137
137
|
M.fail(["4XX", "5XX"]),
|
|
138
138
|
)(response, { extraFields: responseFields });
|
|
@@ -30,11 +30,11 @@ import { Result } from "../types/fp.js";
|
|
|
30
30
|
*/
|
|
31
31
|
export async function customMessagesUpdate(
|
|
32
32
|
client: SyllableSDKCore,
|
|
33
|
-
request: components.
|
|
33
|
+
request: components.CustomMessageUpdateRequest,
|
|
34
34
|
options?: RequestOptions,
|
|
35
35
|
): Promise<
|
|
36
36
|
Result<
|
|
37
|
-
components.
|
|
37
|
+
components.CustomMessageResponse,
|
|
38
38
|
| errors.HTTPValidationError
|
|
39
39
|
| SDKError
|
|
40
40
|
| SDKValidationError
|
|
@@ -47,7 +47,8 @@ export async function customMessagesUpdate(
|
|
|
47
47
|
> {
|
|
48
48
|
const parsed = safeParse(
|
|
49
49
|
request,
|
|
50
|
-
(value) =>
|
|
50
|
+
(value) =>
|
|
51
|
+
components.CustomMessageUpdateRequest$outboundSchema.parse(value),
|
|
51
52
|
"Input validation failed",
|
|
52
53
|
);
|
|
53
54
|
if (!parsed.ok) {
|
|
@@ -109,7 +110,7 @@ export async function customMessagesUpdate(
|
|
|
109
110
|
};
|
|
110
111
|
|
|
111
112
|
const [result] = await M.match<
|
|
112
|
-
components.
|
|
113
|
+
components.CustomMessageResponse,
|
|
113
114
|
| errors.HTTPValidationError
|
|
114
115
|
| SDKError
|
|
115
116
|
| SDKValidationError
|
|
@@ -119,7 +120,7 @@ export async function customMessagesUpdate(
|
|
|
119
120
|
| RequestTimeoutError
|
|
120
121
|
| ConnectionError
|
|
121
122
|
>(
|
|
122
|
-
M.json(200, components.
|
|
123
|
+
M.json(200, components.CustomMessageResponse$inboundSchema),
|
|
123
124
|
M.jsonErr(422, errors.HTTPValidationError$inboundSchema),
|
|
124
125
|
M.fail(["4XX", "5XX"]),
|
|
125
126
|
)(response, { extraFields: responseFields });
|
package/src/lib/config.ts
CHANGED
|
@@ -61,8 +61,8 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
61
61
|
export const SDK_METADATA = {
|
|
62
62
|
language: "typescript",
|
|
63
63
|
openapiDocVersion: "0.0.2",
|
|
64
|
-
sdkVersion: "0.1.0-alpha.
|
|
65
|
-
genVersion: "2.
|
|
64
|
+
sdkVersion: "0.1.0-alpha.17",
|
|
65
|
+
genVersion: "2.477.0",
|
|
66
66
|
userAgent:
|
|
67
|
-
"speakeasy-sdk/typescript 0.1.0-alpha.
|
|
67
|
+
"speakeasy-sdk/typescript 0.1.0-alpha.17 2.477.0 0.0.2 syllable-sdk",
|
|
68
68
|
} as const;
|
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
import {
|
|
11
|
+
AgentToolDefaults,
|
|
12
|
+
AgentToolDefaults$inboundSchema,
|
|
13
|
+
AgentToolDefaults$Outbound,
|
|
14
|
+
AgentToolDefaults$outboundSchema,
|
|
15
|
+
} from "./agenttooldefaults.js";
|
|
16
|
+
import {
|
|
17
|
+
CustomMessage,
|
|
18
|
+
CustomMessage$inboundSchema,
|
|
19
|
+
CustomMessage$Outbound,
|
|
20
|
+
CustomMessage$outboundSchema,
|
|
21
|
+
} from "./custommessage.js";
|
|
22
|
+
import {
|
|
23
|
+
Prompt,
|
|
24
|
+
Prompt$inboundSchema,
|
|
25
|
+
Prompt$Outbound,
|
|
26
|
+
Prompt$outboundSchema,
|
|
27
|
+
} from "./prompt.js";
|
|
28
|
+
import {
|
|
29
|
+
Target,
|
|
30
|
+
Target$inboundSchema,
|
|
31
|
+
Target$Outbound,
|
|
32
|
+
Target$outboundSchema,
|
|
33
|
+
} from "./target.js";
|
|
34
|
+
|
|
35
|
+
export type AgentResponse = {
|
|
36
|
+
/**
|
|
37
|
+
* The Agent name
|
|
38
|
+
*/
|
|
39
|
+
name: string;
|
|
40
|
+
/**
|
|
41
|
+
* The Agent description
|
|
42
|
+
*/
|
|
43
|
+
description?: string | null | undefined;
|
|
44
|
+
/**
|
|
45
|
+
* The Agent label
|
|
46
|
+
*/
|
|
47
|
+
label?: string | null | undefined;
|
|
48
|
+
/**
|
|
49
|
+
* The Agent type
|
|
50
|
+
*/
|
|
51
|
+
type: string;
|
|
52
|
+
/**
|
|
53
|
+
* The Agent's prompt id
|
|
54
|
+
*/
|
|
55
|
+
promptId: number;
|
|
56
|
+
/**
|
|
57
|
+
* The Agent's custom message id
|
|
58
|
+
*/
|
|
59
|
+
customMessageId?: number | null | undefined;
|
|
60
|
+
/**
|
|
61
|
+
* The time zone the bot operates in
|
|
62
|
+
*/
|
|
63
|
+
timezone: string;
|
|
64
|
+
promptToolDefaults: Array<AgentToolDefaults>;
|
|
65
|
+
languages: Array<string>;
|
|
66
|
+
variables: { [k: string]: string };
|
|
67
|
+
/**
|
|
68
|
+
* Optional headers to include in tool calls.
|
|
69
|
+
*/
|
|
70
|
+
toolHeaders: { [k: string]: string } | null;
|
|
71
|
+
/**
|
|
72
|
+
* The Agent ID
|
|
73
|
+
*/
|
|
74
|
+
id: number;
|
|
75
|
+
/**
|
|
76
|
+
* Timestamp of most recent update
|
|
77
|
+
*/
|
|
78
|
+
updatedAt: Date;
|
|
79
|
+
/**
|
|
80
|
+
* Email of the user who last updated the agent
|
|
81
|
+
*/
|
|
82
|
+
lastUpdatedBy: string | null;
|
|
83
|
+
/**
|
|
84
|
+
* Channel targets associated with the agent
|
|
85
|
+
*/
|
|
86
|
+
channelTargets?: Array<Target> | null | undefined;
|
|
87
|
+
/**
|
|
88
|
+
* The prompt associated with the agent
|
|
89
|
+
*/
|
|
90
|
+
prompt?: Prompt | null | undefined;
|
|
91
|
+
/**
|
|
92
|
+
* The custom message associated with the agent
|
|
93
|
+
*/
|
|
94
|
+
customMessage?: CustomMessage | null | undefined;
|
|
95
|
+
};
|
|
96
|
+
|
|
97
|
+
/** @internal */
|
|
98
|
+
export const AgentResponse$inboundSchema: z.ZodType<
|
|
99
|
+
AgentResponse,
|
|
100
|
+
z.ZodTypeDef,
|
|
101
|
+
unknown
|
|
102
|
+
> = z.object({
|
|
103
|
+
name: z.string(),
|
|
104
|
+
description: z.nullable(z.string()).optional(),
|
|
105
|
+
label: z.nullable(z.string()).optional(),
|
|
106
|
+
type: z.string(),
|
|
107
|
+
prompt_id: z.number().int(),
|
|
108
|
+
custom_message_id: z.nullable(z.number().int()).optional(),
|
|
109
|
+
timezone: z.string(),
|
|
110
|
+
prompt_tool_defaults: z.array(AgentToolDefaults$inboundSchema),
|
|
111
|
+
languages: z.array(z.string()),
|
|
112
|
+
variables: z.record(z.string()),
|
|
113
|
+
tool_headers: z.nullable(z.record(z.string())),
|
|
114
|
+
id: z.number().int(),
|
|
115
|
+
updated_at: z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
116
|
+
last_updated_by: z.nullable(z.string()),
|
|
117
|
+
channel_targets: z.nullable(z.array(Target$inboundSchema)).optional(),
|
|
118
|
+
prompt: z.nullable(Prompt$inboundSchema).optional(),
|
|
119
|
+
custom_message: z.nullable(CustomMessage$inboundSchema).optional(),
|
|
120
|
+
}).transform((v) => {
|
|
121
|
+
return remap$(v, {
|
|
122
|
+
"prompt_id": "promptId",
|
|
123
|
+
"custom_message_id": "customMessageId",
|
|
124
|
+
"prompt_tool_defaults": "promptToolDefaults",
|
|
125
|
+
"tool_headers": "toolHeaders",
|
|
126
|
+
"updated_at": "updatedAt",
|
|
127
|
+
"last_updated_by": "lastUpdatedBy",
|
|
128
|
+
"channel_targets": "channelTargets",
|
|
129
|
+
"custom_message": "customMessage",
|
|
130
|
+
});
|
|
131
|
+
});
|
|
132
|
+
|
|
133
|
+
/** @internal */
|
|
134
|
+
export type AgentResponse$Outbound = {
|
|
135
|
+
name: string;
|
|
136
|
+
description?: string | null | undefined;
|
|
137
|
+
label?: string | null | undefined;
|
|
138
|
+
type: string;
|
|
139
|
+
prompt_id: number;
|
|
140
|
+
custom_message_id?: number | null | undefined;
|
|
141
|
+
timezone: string;
|
|
142
|
+
prompt_tool_defaults: Array<AgentToolDefaults$Outbound>;
|
|
143
|
+
languages: Array<string>;
|
|
144
|
+
variables: { [k: string]: string };
|
|
145
|
+
tool_headers: { [k: string]: string } | null;
|
|
146
|
+
id: number;
|
|
147
|
+
updated_at: string;
|
|
148
|
+
last_updated_by: string | null;
|
|
149
|
+
channel_targets?: Array<Target$Outbound> | null | undefined;
|
|
150
|
+
prompt?: Prompt$Outbound | null | undefined;
|
|
151
|
+
custom_message?: CustomMessage$Outbound | null | undefined;
|
|
152
|
+
};
|
|
153
|
+
|
|
154
|
+
/** @internal */
|
|
155
|
+
export const AgentResponse$outboundSchema: z.ZodType<
|
|
156
|
+
AgentResponse$Outbound,
|
|
157
|
+
z.ZodTypeDef,
|
|
158
|
+
AgentResponse
|
|
159
|
+
> = z.object({
|
|
160
|
+
name: z.string(),
|
|
161
|
+
description: z.nullable(z.string()).optional(),
|
|
162
|
+
label: z.nullable(z.string()).optional(),
|
|
163
|
+
type: z.string(),
|
|
164
|
+
promptId: z.number().int(),
|
|
165
|
+
customMessageId: z.nullable(z.number().int()).optional(),
|
|
166
|
+
timezone: z.string(),
|
|
167
|
+
promptToolDefaults: z.array(AgentToolDefaults$outboundSchema),
|
|
168
|
+
languages: z.array(z.string()),
|
|
169
|
+
variables: z.record(z.string()),
|
|
170
|
+
toolHeaders: z.nullable(z.record(z.string())),
|
|
171
|
+
id: z.number().int(),
|
|
172
|
+
updatedAt: z.date().transform(v => v.toISOString()),
|
|
173
|
+
lastUpdatedBy: z.nullable(z.string()),
|
|
174
|
+
channelTargets: z.nullable(z.array(Target$outboundSchema)).optional(),
|
|
175
|
+
prompt: z.nullable(Prompt$outboundSchema).optional(),
|
|
176
|
+
customMessage: z.nullable(CustomMessage$outboundSchema).optional(),
|
|
177
|
+
}).transform((v) => {
|
|
178
|
+
return remap$(v, {
|
|
179
|
+
promptId: "prompt_id",
|
|
180
|
+
customMessageId: "custom_message_id",
|
|
181
|
+
promptToolDefaults: "prompt_tool_defaults",
|
|
182
|
+
toolHeaders: "tool_headers",
|
|
183
|
+
updatedAt: "updated_at",
|
|
184
|
+
lastUpdatedBy: "last_updated_by",
|
|
185
|
+
channelTargets: "channel_targets",
|
|
186
|
+
customMessage: "custom_message",
|
|
187
|
+
});
|
|
188
|
+
});
|
|
189
|
+
|
|
190
|
+
/**
|
|
191
|
+
* @internal
|
|
192
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
193
|
+
*/
|
|
194
|
+
export namespace AgentResponse$ {
|
|
195
|
+
/** @deprecated use `AgentResponse$inboundSchema` instead. */
|
|
196
|
+
export const inboundSchema = AgentResponse$inboundSchema;
|
|
197
|
+
/** @deprecated use `AgentResponse$outboundSchema` instead. */
|
|
198
|
+
export const outboundSchema = AgentResponse$outboundSchema;
|
|
199
|
+
/** @deprecated use `AgentResponse$Outbound` instead. */
|
|
200
|
+
export type Outbound = AgentResponse$Outbound;
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
export function agentResponseToJSON(agentResponse: AgentResponse): string {
|
|
204
|
+
return JSON.stringify(AgentResponse$outboundSchema.parse(agentResponse));
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
export function agentResponseFromJSON(
|
|
208
|
+
jsonString: string,
|
|
209
|
+
): SafeParseResult<AgentResponse, SDKValidationError> {
|
|
210
|
+
return safeParse(
|
|
211
|
+
jsonString,
|
|
212
|
+
(x) => AgentResponse$inboundSchema.parse(JSON.parse(x)),
|
|
213
|
+
`Failed to parse 'AgentResponse' from JSON`,
|
|
214
|
+
);
|
|
215
|
+
}
|
|
@@ -9,18 +9,17 @@ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
|
9
9
|
|
|
10
10
|
export type CustomMessage = {
|
|
11
11
|
/**
|
|
12
|
-
* The name of the
|
|
12
|
+
* The name of the custom message
|
|
13
13
|
*/
|
|
14
14
|
name: string;
|
|
15
15
|
/**
|
|
16
|
-
* The text of the
|
|
16
|
+
* The text of the custom message
|
|
17
17
|
*/
|
|
18
18
|
text: string;
|
|
19
19
|
/**
|
|
20
|
-
* The ID of the
|
|
20
|
+
* The ID of the custom message
|
|
21
21
|
*/
|
|
22
22
|
id: number;
|
|
23
|
-
type?: string | undefined;
|
|
24
23
|
};
|
|
25
24
|
|
|
26
25
|
/** @internal */
|
|
@@ -32,7 +31,6 @@ export const CustomMessage$inboundSchema: z.ZodType<
|
|
|
32
31
|
name: z.string(),
|
|
33
32
|
text: z.string(),
|
|
34
33
|
id: z.number().int(),
|
|
35
|
-
type: z.string().default("greeting"),
|
|
36
34
|
});
|
|
37
35
|
|
|
38
36
|
/** @internal */
|
|
@@ -40,7 +38,6 @@ export type CustomMessage$Outbound = {
|
|
|
40
38
|
name: string;
|
|
41
39
|
text: string;
|
|
42
40
|
id: number;
|
|
43
|
-
type: string;
|
|
44
41
|
};
|
|
45
42
|
|
|
46
43
|
/** @internal */
|
|
@@ -52,7 +49,6 @@ export const CustomMessage$outboundSchema: z.ZodType<
|
|
|
52
49
|
name: z.string(),
|
|
53
50
|
text: z.string(),
|
|
54
51
|
id: z.number().int(),
|
|
55
|
-
type: z.string().default("greeting"),
|
|
56
52
|
});
|
|
57
53
|
|
|
58
54
|
/**
|