phonic 0.30.19 → 0.30.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/dist/cjs/Client.js +2 -2
- package/dist/cjs/api/resources/agents/client/requests/AgentsCreateRequest.d.ts +5 -1
- package/dist/cjs/api/resources/agents/client/requests/UpdateAgentRequest.d.ts +10 -1
- package/dist/cjs/api/resources/agents/client/requests/UpdateAgentRequest.js +4 -0
- package/dist/cjs/api/resources/conversations/client/Client.js +2 -9
- package/dist/cjs/api/resources/conversations/client/requests/ConversationsSipOutboundCallRequest.d.ts +0 -4
- package/dist/cjs/api/resources/conversations/types/ConversationsSipOutboundCallResponse.d.ts +2 -0
- package/dist/cjs/api/types/Agent.d.ts +3 -1
- package/dist/cjs/api/types/Conversation.d.ts +13 -0
- package/dist/cjs/api/types/CreateAgentRequest.d.ts +10 -1
- package/dist/cjs/api/types/CreateAgentRequest.js +4 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/Client.mjs +2 -2
- package/dist/esm/api/resources/agents/client/requests/AgentsCreateRequest.d.mts +5 -1
- package/dist/esm/api/resources/agents/client/requests/UpdateAgentRequest.d.mts +10 -1
- package/dist/esm/api/resources/agents/client/requests/UpdateAgentRequest.mjs +4 -0
- package/dist/esm/api/resources/conversations/client/Client.mjs +2 -9
- package/dist/esm/api/resources/conversations/client/requests/ConversationsSipOutboundCallRequest.d.mts +0 -4
- package/dist/esm/api/resources/conversations/types/ConversationsSipOutboundCallResponse.d.mts +2 -0
- package/dist/esm/api/types/Agent.d.mts +3 -1
- package/dist/esm/api/types/Conversation.d.mts +13 -0
- package/dist/esm/api/types/CreateAgentRequest.d.mts +10 -1
- package/dist/esm/api/types/CreateAgentRequest.mjs +4 -0
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
package/dist/cjs/Client.js
CHANGED
|
@@ -50,8 +50,8 @@ class PhonicClient {
|
|
|
50
50
|
this._options = Object.assign(Object.assign({}, _options), { headers: (0, headers_js_1.mergeHeaders)({
|
|
51
51
|
"X-Fern-Language": "JavaScript",
|
|
52
52
|
"X-Fern-SDK-Name": "phonic",
|
|
53
|
-
"X-Fern-SDK-Version": "0.30.
|
|
54
|
-
"User-Agent": "phonic/0.30.
|
|
53
|
+
"X-Fern-SDK-Version": "0.30.20",
|
|
54
|
+
"User-Agent": "phonic/0.30.20",
|
|
55
55
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
56
56
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
57
57
|
}, _options === null || _options === void 0 ? void 0 : _options.headers) });
|
|
@@ -41,7 +41,11 @@ export interface AgentsCreateRequest {
|
|
|
41
41
|
project?: string;
|
|
42
42
|
/** The name of the agent. Can only contain lowercase letters, numbers and hyphens. Must be unique within the project. */
|
|
43
43
|
name: string;
|
|
44
|
-
phone_number:
|
|
44
|
+
phone_number: Phonic.CreateAgentRequest.PhoneNumber | null;
|
|
45
|
+
/** The custom phone number to use for the agent in E.164 format (e.g., +1234567890). This field is deprecated. Use `custom_phone_numbers` instead. */
|
|
46
|
+
custom_phone_number?: string | null;
|
|
47
|
+
/** Array of custom phone numbers in E.164 format (e.g., ["+1234567890", "+0987654321"]). The agent will be able to receive phone calls on any of these numbers. Required when `phone_number` is set to `"custom"`. All phone numbers must be unique. */
|
|
48
|
+
custom_phone_numbers?: string[];
|
|
45
49
|
/** The timezone of the agent. Used to format system variables like `{{system_time}}`. */
|
|
46
50
|
timezone?: string;
|
|
47
51
|
/** The voice ID to use. */
|
|
@@ -41,7 +41,11 @@ export interface UpdateAgentRequest {
|
|
|
41
41
|
project?: string;
|
|
42
42
|
/** The name of the agent. Can only contain lowercase letters, numbers and hyphens. Must be unique within the project. */
|
|
43
43
|
name?: string;
|
|
44
|
-
phone_number:
|
|
44
|
+
phone_number: UpdateAgentRequest.PhoneNumber | null;
|
|
45
|
+
/** The custom phone number to use for the agent in E.164 format (e.g., +1234567890). This field is deprecated. Use `custom_phone_numbers` instead. */
|
|
46
|
+
custom_phone_number?: string | null;
|
|
47
|
+
/** Array of custom phone numbers in E.164 format (e.g., ["+1234567890", "+0987654321"]). The agent will be able to receive phone calls on any of these numbers. Required when `phone_number` is set to `"custom"`. All phone numbers must be unique. */
|
|
48
|
+
custom_phone_numbers?: string[];
|
|
45
49
|
/** The timezone of the agent. Used to format system variables like `{{system_time}}`. */
|
|
46
50
|
timezone?: string;
|
|
47
51
|
/** The voice ID to use. */
|
|
@@ -78,6 +82,11 @@ export interface UpdateAgentRequest {
|
|
|
78
82
|
configuration_endpoint?: UpdateAgentRequest.ConfigurationEndpoint | null;
|
|
79
83
|
}
|
|
80
84
|
export declare namespace UpdateAgentRequest {
|
|
85
|
+
type PhoneNumber = "assign-automatically" | "custom";
|
|
86
|
+
const PhoneNumber: {
|
|
87
|
+
readonly AssignAutomatically: "assign-automatically";
|
|
88
|
+
readonly Custom: "custom";
|
|
89
|
+
};
|
|
81
90
|
/**
|
|
82
91
|
* The audio format of the agent.
|
|
83
92
|
*/
|
|
@@ -6,6 +6,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
6
6
|
exports.UpdateAgentRequest = void 0;
|
|
7
7
|
var UpdateAgentRequest;
|
|
8
8
|
(function (UpdateAgentRequest) {
|
|
9
|
+
UpdateAgentRequest.PhoneNumber = {
|
|
10
|
+
AssignAutomatically: "assign-automatically",
|
|
11
|
+
Custom: "custom",
|
|
12
|
+
};
|
|
9
13
|
UpdateAgentRequest.AudioFormat = {
|
|
10
14
|
Pcm44100: "pcm_44100",
|
|
11
15
|
Pcm16000: "pcm_16000",
|
|
@@ -803,14 +803,7 @@ class Conversations {
|
|
|
803
803
|
__sipOutboundCall(request, requestOptions) {
|
|
804
804
|
return __awaiter(this, void 0, void 0, function* () {
|
|
805
805
|
var _a, _b, _c, _d;
|
|
806
|
-
const {
|
|
807
|
-
const _queryParams = {};
|
|
808
|
-
if (token != null) {
|
|
809
|
-
_queryParams["token"] = token;
|
|
810
|
-
}
|
|
811
|
-
if (downstreamWebsocketUrl != null) {
|
|
812
|
-
_queryParams["downstream_websocket_url"] = downstreamWebsocketUrl;
|
|
813
|
-
}
|
|
806
|
+
const { "X-Sip-Address": sipAddress, "X-Sip-Auth-Username": sipAuthUsername, "X-Sip-Auth-Password": sipAuthPassword } = request, _body = __rest(request, ["X-Sip-Address", "X-Sip-Auth-Username", "X-Sip-Auth-Password"]);
|
|
814
807
|
let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({
|
|
815
808
|
Authorization: yield this._getAuthorizationHeader(),
|
|
816
809
|
"X-Sip-Address": sipAddress,
|
|
@@ -823,7 +816,7 @@ class Conversations {
|
|
|
823
816
|
method: "POST",
|
|
824
817
|
headers: _headers,
|
|
825
818
|
contentType: "application/json",
|
|
826
|
-
queryParameters:
|
|
819
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
827
820
|
requestType: "json",
|
|
828
821
|
body: _body,
|
|
829
822
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -11,10 +11,6 @@ import * as Phonic from "../../../../index.js";
|
|
|
11
11
|
* }
|
|
12
12
|
*/
|
|
13
13
|
export interface ConversationsSipOutboundCallRequest {
|
|
14
|
-
/** Optional session token used for STS authorization. */
|
|
15
|
-
token?: string;
|
|
16
|
-
/** Optional downstream STS WebSocket URL to override the default. */
|
|
17
|
-
downstream_websocket_url?: string;
|
|
18
14
|
/** SIP address of the user's SIP trunk. Required. */
|
|
19
15
|
"X-Sip-Address": string;
|
|
20
16
|
/** SIP auth username, if your provider requires it. */
|
|
@@ -7,8 +7,10 @@ export interface Agent {
|
|
|
7
7
|
id: string;
|
|
8
8
|
/** The name of the agent. */
|
|
9
9
|
name: string;
|
|
10
|
-
/** The phone number that the agent uses to accept
|
|
10
|
+
/** The phone number that the agent uses to accept calls. `null` if the agent is not associated with a phone number, in which can the agent can be used via WebSockets. This field is deprecated. Use `phone_numbers` instead. */
|
|
11
11
|
phone_number: string | null;
|
|
12
|
+
/** Array of phone numbers that the agent uses to accept phone calls. */
|
|
13
|
+
phone_numbers: string[];
|
|
12
14
|
/** The project the agent belongs to. */
|
|
13
15
|
project: Agent.Project;
|
|
14
16
|
/** The timezone of the agent. Used to format system variables like `{{system_time}}`. */
|
|
@@ -55,6 +55,8 @@ export interface Conversation {
|
|
|
55
55
|
task_results: Record<string, unknown>;
|
|
56
56
|
/** Array of conversation items (turns). */
|
|
57
57
|
items: Phonic.ConversationItem[];
|
|
58
|
+
/** Phone call metadata. `null` for non-phone call conversations. */
|
|
59
|
+
call_info: Conversation.CallInfo | null;
|
|
58
60
|
}
|
|
59
61
|
export declare namespace Conversation {
|
|
60
62
|
/**
|
|
@@ -97,4 +99,15 @@ export declare namespace Conversation {
|
|
|
97
99
|
readonly Assistant: "assistant";
|
|
98
100
|
readonly Error: "error";
|
|
99
101
|
};
|
|
102
|
+
/**
|
|
103
|
+
* Phone call metadata. `null` for non-phone call conversations.
|
|
104
|
+
*/
|
|
105
|
+
interface CallInfo {
|
|
106
|
+
/** Caller phone number in E.164 format. */
|
|
107
|
+
from_phone_number: string;
|
|
108
|
+
/** Callee phone number in E.164 format. */
|
|
109
|
+
to_phone_number: string;
|
|
110
|
+
/** Twilio Call SID. Only present for user SIP trunking calls. */
|
|
111
|
+
twilio_call_sid?: string;
|
|
112
|
+
}
|
|
100
113
|
}
|
|
@@ -5,7 +5,11 @@ import * as Phonic from "../index.js";
|
|
|
5
5
|
export interface CreateAgentRequest {
|
|
6
6
|
/** The name of the agent. Can only contain lowercase letters, numbers and hyphens. Must be unique within the project. */
|
|
7
7
|
name: string;
|
|
8
|
-
phone_number:
|
|
8
|
+
phone_number: CreateAgentRequest.PhoneNumber | null;
|
|
9
|
+
/** The custom phone number to use for the agent in E.164 format (e.g., +1234567890). This field is deprecated. Use `custom_phone_numbers` instead. */
|
|
10
|
+
custom_phone_number?: string | null;
|
|
11
|
+
/** Array of custom phone numbers in E.164 format (e.g., ["+1234567890", "+0987654321"]). The agent will be able to receive phone calls on any of these numbers. Required when `phone_number` is set to `"custom"`. All phone numbers must be unique. */
|
|
12
|
+
custom_phone_numbers?: string[];
|
|
9
13
|
/** The timezone of the agent. Used to format system variables like `{{system_time}}`. */
|
|
10
14
|
timezone?: string;
|
|
11
15
|
/** The voice ID to use. */
|
|
@@ -42,6 +46,11 @@ export interface CreateAgentRequest {
|
|
|
42
46
|
configuration_endpoint?: CreateAgentRequest.ConfigurationEndpoint | null;
|
|
43
47
|
}
|
|
44
48
|
export declare namespace CreateAgentRequest {
|
|
49
|
+
type PhoneNumber = "assign-automatically" | "custom";
|
|
50
|
+
const PhoneNumber: {
|
|
51
|
+
readonly AssignAutomatically: "assign-automatically";
|
|
52
|
+
readonly Custom: "custom";
|
|
53
|
+
};
|
|
45
54
|
/**
|
|
46
55
|
* The audio format of the agent.
|
|
47
56
|
*/
|
|
@@ -6,6 +6,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
6
6
|
exports.CreateAgentRequest = void 0;
|
|
7
7
|
var CreateAgentRequest;
|
|
8
8
|
(function (CreateAgentRequest) {
|
|
9
|
+
CreateAgentRequest.PhoneNumber = {
|
|
10
|
+
AssignAutomatically: "assign-automatically",
|
|
11
|
+
Custom: "custom",
|
|
12
|
+
};
|
|
9
13
|
CreateAgentRequest.AudioFormat = {
|
|
10
14
|
Pcm44100: "pcm_44100",
|
|
11
15
|
Pcm16000: "pcm_16000",
|
package/dist/cjs/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "0.30.
|
|
1
|
+
export declare const SDK_VERSION = "0.30.20";
|
package/dist/cjs/version.js
CHANGED
package/dist/esm/Client.mjs
CHANGED
|
@@ -14,8 +14,8 @@ export class PhonicClient {
|
|
|
14
14
|
this._options = Object.assign(Object.assign({}, _options), { headers: mergeHeaders({
|
|
15
15
|
"X-Fern-Language": "JavaScript",
|
|
16
16
|
"X-Fern-SDK-Name": "phonic",
|
|
17
|
-
"X-Fern-SDK-Version": "0.30.
|
|
18
|
-
"User-Agent": "phonic/0.30.
|
|
17
|
+
"X-Fern-SDK-Version": "0.30.20",
|
|
18
|
+
"User-Agent": "phonic/0.30.20",
|
|
19
19
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
20
20
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
21
21
|
}, _options === null || _options === void 0 ? void 0 : _options.headers) });
|
|
@@ -41,7 +41,11 @@ export interface AgentsCreateRequest {
|
|
|
41
41
|
project?: string;
|
|
42
42
|
/** The name of the agent. Can only contain lowercase letters, numbers and hyphens. Must be unique within the project. */
|
|
43
43
|
name: string;
|
|
44
|
-
phone_number:
|
|
44
|
+
phone_number: Phonic.CreateAgentRequest.PhoneNumber | null;
|
|
45
|
+
/** The custom phone number to use for the agent in E.164 format (e.g., +1234567890). This field is deprecated. Use `custom_phone_numbers` instead. */
|
|
46
|
+
custom_phone_number?: string | null;
|
|
47
|
+
/** Array of custom phone numbers in E.164 format (e.g., ["+1234567890", "+0987654321"]). The agent will be able to receive phone calls on any of these numbers. Required when `phone_number` is set to `"custom"`. All phone numbers must be unique. */
|
|
48
|
+
custom_phone_numbers?: string[];
|
|
45
49
|
/** The timezone of the agent. Used to format system variables like `{{system_time}}`. */
|
|
46
50
|
timezone?: string;
|
|
47
51
|
/** The voice ID to use. */
|
|
@@ -41,7 +41,11 @@ export interface UpdateAgentRequest {
|
|
|
41
41
|
project?: string;
|
|
42
42
|
/** The name of the agent. Can only contain lowercase letters, numbers and hyphens. Must be unique within the project. */
|
|
43
43
|
name?: string;
|
|
44
|
-
phone_number:
|
|
44
|
+
phone_number: UpdateAgentRequest.PhoneNumber | null;
|
|
45
|
+
/** The custom phone number to use for the agent in E.164 format (e.g., +1234567890). This field is deprecated. Use `custom_phone_numbers` instead. */
|
|
46
|
+
custom_phone_number?: string | null;
|
|
47
|
+
/** Array of custom phone numbers in E.164 format (e.g., ["+1234567890", "+0987654321"]). The agent will be able to receive phone calls on any of these numbers. Required when `phone_number` is set to `"custom"`. All phone numbers must be unique. */
|
|
48
|
+
custom_phone_numbers?: string[];
|
|
45
49
|
/** The timezone of the agent. Used to format system variables like `{{system_time}}`. */
|
|
46
50
|
timezone?: string;
|
|
47
51
|
/** The voice ID to use. */
|
|
@@ -78,6 +82,11 @@ export interface UpdateAgentRequest {
|
|
|
78
82
|
configuration_endpoint?: UpdateAgentRequest.ConfigurationEndpoint | null;
|
|
79
83
|
}
|
|
80
84
|
export declare namespace UpdateAgentRequest {
|
|
85
|
+
type PhoneNumber = "assign-automatically" | "custom";
|
|
86
|
+
const PhoneNumber: {
|
|
87
|
+
readonly AssignAutomatically: "assign-automatically";
|
|
88
|
+
readonly Custom: "custom";
|
|
89
|
+
};
|
|
81
90
|
/**
|
|
82
91
|
* The audio format of the agent.
|
|
83
92
|
*/
|
|
@@ -3,6 +3,10 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export var UpdateAgentRequest;
|
|
5
5
|
(function (UpdateAgentRequest) {
|
|
6
|
+
UpdateAgentRequest.PhoneNumber = {
|
|
7
|
+
AssignAutomatically: "assign-automatically",
|
|
8
|
+
Custom: "custom",
|
|
9
|
+
};
|
|
6
10
|
UpdateAgentRequest.AudioFormat = {
|
|
7
11
|
Pcm44100: "pcm_44100",
|
|
8
12
|
Pcm16000: "pcm_16000",
|
|
@@ -767,14 +767,7 @@ export class Conversations {
|
|
|
767
767
|
__sipOutboundCall(request, requestOptions) {
|
|
768
768
|
return __awaiter(this, void 0, void 0, function* () {
|
|
769
769
|
var _a, _b, _c, _d;
|
|
770
|
-
const {
|
|
771
|
-
const _queryParams = {};
|
|
772
|
-
if (token != null) {
|
|
773
|
-
_queryParams["token"] = token;
|
|
774
|
-
}
|
|
775
|
-
if (downstreamWebsocketUrl != null) {
|
|
776
|
-
_queryParams["downstream_websocket_url"] = downstreamWebsocketUrl;
|
|
777
|
-
}
|
|
770
|
+
const { "X-Sip-Address": sipAddress, "X-Sip-Auth-Username": sipAuthUsername, "X-Sip-Auth-Password": sipAuthPassword } = request, _body = __rest(request, ["X-Sip-Address", "X-Sip-Auth-Username", "X-Sip-Auth-Password"]);
|
|
778
771
|
let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({
|
|
779
772
|
Authorization: yield this._getAuthorizationHeader(),
|
|
780
773
|
"X-Sip-Address": sipAddress,
|
|
@@ -787,7 +780,7 @@ export class Conversations {
|
|
|
787
780
|
method: "POST",
|
|
788
781
|
headers: _headers,
|
|
789
782
|
contentType: "application/json",
|
|
790
|
-
queryParameters:
|
|
783
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
791
784
|
requestType: "json",
|
|
792
785
|
body: _body,
|
|
793
786
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -11,10 +11,6 @@ import * as Phonic from "../../../../index.mjs";
|
|
|
11
11
|
* }
|
|
12
12
|
*/
|
|
13
13
|
export interface ConversationsSipOutboundCallRequest {
|
|
14
|
-
/** Optional session token used for STS authorization. */
|
|
15
|
-
token?: string;
|
|
16
|
-
/** Optional downstream STS WebSocket URL to override the default. */
|
|
17
|
-
downstream_websocket_url?: string;
|
|
18
14
|
/** SIP address of the user's SIP trunk. Required. */
|
|
19
15
|
"X-Sip-Address": string;
|
|
20
16
|
/** SIP auth username, if your provider requires it. */
|
|
@@ -7,8 +7,10 @@ export interface Agent {
|
|
|
7
7
|
id: string;
|
|
8
8
|
/** The name of the agent. */
|
|
9
9
|
name: string;
|
|
10
|
-
/** The phone number that the agent uses to accept
|
|
10
|
+
/** The phone number that the agent uses to accept calls. `null` if the agent is not associated with a phone number, in which can the agent can be used via WebSockets. This field is deprecated. Use `phone_numbers` instead. */
|
|
11
11
|
phone_number: string | null;
|
|
12
|
+
/** Array of phone numbers that the agent uses to accept phone calls. */
|
|
13
|
+
phone_numbers: string[];
|
|
12
14
|
/** The project the agent belongs to. */
|
|
13
15
|
project: Agent.Project;
|
|
14
16
|
/** The timezone of the agent. Used to format system variables like `{{system_time}}`. */
|
|
@@ -55,6 +55,8 @@ export interface Conversation {
|
|
|
55
55
|
task_results: Record<string, unknown>;
|
|
56
56
|
/** Array of conversation items (turns). */
|
|
57
57
|
items: Phonic.ConversationItem[];
|
|
58
|
+
/** Phone call metadata. `null` for non-phone call conversations. */
|
|
59
|
+
call_info: Conversation.CallInfo | null;
|
|
58
60
|
}
|
|
59
61
|
export declare namespace Conversation {
|
|
60
62
|
/**
|
|
@@ -97,4 +99,15 @@ export declare namespace Conversation {
|
|
|
97
99
|
readonly Assistant: "assistant";
|
|
98
100
|
readonly Error: "error";
|
|
99
101
|
};
|
|
102
|
+
/**
|
|
103
|
+
* Phone call metadata. `null` for non-phone call conversations.
|
|
104
|
+
*/
|
|
105
|
+
interface CallInfo {
|
|
106
|
+
/** Caller phone number in E.164 format. */
|
|
107
|
+
from_phone_number: string;
|
|
108
|
+
/** Callee phone number in E.164 format. */
|
|
109
|
+
to_phone_number: string;
|
|
110
|
+
/** Twilio Call SID. Only present for user SIP trunking calls. */
|
|
111
|
+
twilio_call_sid?: string;
|
|
112
|
+
}
|
|
100
113
|
}
|
|
@@ -5,7 +5,11 @@ import * as Phonic from "../index.mjs";
|
|
|
5
5
|
export interface CreateAgentRequest {
|
|
6
6
|
/** The name of the agent. Can only contain lowercase letters, numbers and hyphens. Must be unique within the project. */
|
|
7
7
|
name: string;
|
|
8
|
-
phone_number:
|
|
8
|
+
phone_number: CreateAgentRequest.PhoneNumber | null;
|
|
9
|
+
/** The custom phone number to use for the agent in E.164 format (e.g., +1234567890). This field is deprecated. Use `custom_phone_numbers` instead. */
|
|
10
|
+
custom_phone_number?: string | null;
|
|
11
|
+
/** Array of custom phone numbers in E.164 format (e.g., ["+1234567890", "+0987654321"]). The agent will be able to receive phone calls on any of these numbers. Required when `phone_number` is set to `"custom"`. All phone numbers must be unique. */
|
|
12
|
+
custom_phone_numbers?: string[];
|
|
9
13
|
/** The timezone of the agent. Used to format system variables like `{{system_time}}`. */
|
|
10
14
|
timezone?: string;
|
|
11
15
|
/** The voice ID to use. */
|
|
@@ -42,6 +46,11 @@ export interface CreateAgentRequest {
|
|
|
42
46
|
configuration_endpoint?: CreateAgentRequest.ConfigurationEndpoint | null;
|
|
43
47
|
}
|
|
44
48
|
export declare namespace CreateAgentRequest {
|
|
49
|
+
type PhoneNumber = "assign-automatically" | "custom";
|
|
50
|
+
const PhoneNumber: {
|
|
51
|
+
readonly AssignAutomatically: "assign-automatically";
|
|
52
|
+
readonly Custom: "custom";
|
|
53
|
+
};
|
|
45
54
|
/**
|
|
46
55
|
* The audio format of the agent.
|
|
47
56
|
*/
|
|
@@ -3,6 +3,10 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export var CreateAgentRequest;
|
|
5
5
|
(function (CreateAgentRequest) {
|
|
6
|
+
CreateAgentRequest.PhoneNumber = {
|
|
7
|
+
AssignAutomatically: "assign-automatically",
|
|
8
|
+
Custom: "custom",
|
|
9
|
+
};
|
|
6
10
|
CreateAgentRequest.AudioFormat = {
|
|
7
11
|
Pcm44100: "pcm_44100",
|
|
8
12
|
Pcm16000: "pcm_16000",
|
package/dist/esm/version.d.mts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "0.30.
|
|
1
|
+
export declare const SDK_VERSION = "0.30.20";
|
package/dist/esm/version.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const SDK_VERSION = "0.30.
|
|
1
|
+
export const SDK_VERSION = "0.30.20";
|