Skip to content

Commit a3c6633

Browse files
committed
Release 0.0.42
1 parent c2ea18a commit a3c6633

35 files changed

+543
-5
lines changed

poetry.lock

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "vocode-api"
3-
version = "0.0.41"
3+
version = "0.0.42"
44
description = ""
55
readme = "README.md"
66
authors = []

src/vocode/__init__.py

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,24 +19,28 @@
1919
ActionPageItemsItem_ActionAddToConference,
2020
ActionPageItemsItem_ActionDtmf,
2121
ActionPageItemsItem_ActionEndConversation,
22+
ActionPageItemsItem_ActionExternal,
2223
ActionPageItemsItem_ActionSetHold,
2324
ActionPageItemsItem_ActionTransferCall,
2425
ActionParamsRequest,
2526
ActionParamsRequest_ActionAddToConference,
2627
ActionParamsRequest_ActionDtmf,
2728
ActionParamsRequest_ActionEndConversation,
29+
ActionParamsRequest_ActionExternal,
2830
ActionParamsRequest_ActionSetHold,
2931
ActionParamsRequest_ActionTransferCall,
3032
ActionResponseModel,
3133
ActionResponseModel_ActionAddToConference,
3234
ActionResponseModel_ActionDtmf,
3335
ActionResponseModel_ActionEndConversation,
36+
ActionResponseModel_ActionExternal,
3437
ActionResponseModel_ActionSetHold,
3538
ActionResponseModel_ActionTransferCall,
3639
ActionUpdateParamsRequest,
3740
ActionUpdateParamsRequest_ActionAddToConference,
3841
ActionUpdateParamsRequest_ActionDtmf,
3942
ActionUpdateParamsRequest_ActionEndConversation,
43+
ActionUpdateParamsRequest_ActionExternal,
4044
ActionUpdateParamsRequest_ActionSetHold,
4145
ActionUpdateParamsRequest_ActionTransferCall,
4246
AddToConferenceAction,
@@ -59,6 +63,7 @@
5963
AgentActionsItem_ActionAddToConference,
6064
AgentActionsItem_ActionDtmf,
6165
AgentActionsItem_ActionEndConversation,
66+
AgentActionsItem_ActionExternal,
6267
AgentActionsItem_ActionSetHold,
6368
AgentActionsItem_ActionTransferCall,
6469
AgentEndpointingSensitivity,
@@ -71,6 +76,7 @@
7176
AgentUpdateParamsActionsItemOne_ActionAddToConference,
7277
AgentUpdateParamsActionsItemOne_ActionDtmf,
7378
AgentUpdateParamsActionsItemOne_ActionEndConversation,
79+
AgentUpdateParamsActionsItemOne_ActionExternal,
7480
AgentUpdateParamsActionsItemOne_ActionSetHold,
7581
AgentUpdateParamsActionsItemOne_ActionTransferCall,
7682
AgentUpdateParamsAskIfHumanPresentOnIdle,
@@ -82,6 +88,7 @@
8288
AgentUpdateParamsInterruptSensitivity,
8389
AgentUpdateParamsIvrNavigationMode,
8490
AgentUpdateParamsLanguage,
91+
AgentUpdateParamsName,
8592
AgentUpdateParamsNoiseSuppression,
8693
AgentUpdateParamsOpenaiAccountConnection,
8794
AgentUpdateParamsOpenaiModelNameOverride,
@@ -123,6 +130,7 @@
123130
CreateCallAgentParamsActionsItemOne_ActionAddToConference,
124131
CreateCallAgentParamsActionsItemOne_ActionDtmf,
125132
CreateCallAgentParamsActionsItemOne_ActionEndConversation,
133+
CreateCallAgentParamsActionsItemOne_ActionExternal,
126134
CreateCallAgentParamsActionsItemOne_ActionSetHold,
127135
CreateCallAgentParamsActionsItemOne_ActionTransferCall,
128136
CreateCallAgentParamsEndpointingSensitivity,
@@ -177,6 +185,21 @@
177185
EndConversationActionUpdateParamsActionTriggerZero_ActionTriggerPhraseBased,
178186
EndConversationActionUpdateParamsConfig,
179187
EventType,
188+
ExternalAction,
189+
ExternalActionActionTrigger,
190+
ExternalActionActionTrigger_ActionTriggerFunctionCall,
191+
ExternalActionActionTrigger_ActionTriggerPhraseBased,
192+
ExternalActionConfig,
193+
ExternalActionParams,
194+
ExternalActionParamsActionTrigger,
195+
ExternalActionParamsActionTrigger_ActionTriggerFunctionCall,
196+
ExternalActionParamsActionTrigger_ActionTriggerPhraseBased,
197+
ExternalActionUpdateParams,
198+
ExternalActionUpdateParamsActionTrigger,
199+
ExternalActionUpdateParamsActionTriggerZero,
200+
ExternalActionUpdateParamsActionTriggerZero_ActionTriggerFunctionCall,
201+
ExternalActionUpdateParamsActionTriggerZero_ActionTriggerPhraseBased,
202+
ExternalActionUpdateParamsConfig,
180203
FunctionCallActionTrigger,
181204
FunctionCallActionTriggerConfig,
182205
HttpMethod,
@@ -247,8 +270,11 @@
247270
PromptUpdateParamsContextEndpoint,
248271
PromptUpdateParamsPromptTemplate,
249272
RimeVoice,
273+
RimeVoiceModelId,
250274
RimeVoiceParams,
275+
RimeVoiceParamsModelId,
251276
RimeVoiceUpdateParams,
277+
RimeVoiceUpdateParamsModelId,
252278
RimeVoiceUpdateParamsSpeaker,
253279
RimeVoiceUpdateParamsSpeedAlpha,
254280
SetHoldAction,
@@ -326,6 +352,7 @@
326352
AgentParamsActionsItemOne_ActionAddToConference,
327353
AgentParamsActionsItemOne_ActionDtmf,
328354
AgentParamsActionsItemOne_ActionEndConversation,
355+
AgentParamsActionsItemOne_ActionExternal,
329356
AgentParamsActionsItemOne_ActionSetHold,
330357
AgentParamsActionsItemOne_ActionTransferCall,
331358
AgentParamsEndpointingSensitivity,
@@ -378,24 +405,28 @@
378405
"ActionPageItemsItem_ActionAddToConference",
379406
"ActionPageItemsItem_ActionDtmf",
380407
"ActionPageItemsItem_ActionEndConversation",
408+
"ActionPageItemsItem_ActionExternal",
381409
"ActionPageItemsItem_ActionSetHold",
382410
"ActionPageItemsItem_ActionTransferCall",
383411
"ActionParamsRequest",
384412
"ActionParamsRequest_ActionAddToConference",
385413
"ActionParamsRequest_ActionDtmf",
386414
"ActionParamsRequest_ActionEndConversation",
415+
"ActionParamsRequest_ActionExternal",
387416
"ActionParamsRequest_ActionSetHold",
388417
"ActionParamsRequest_ActionTransferCall",
389418
"ActionResponseModel",
390419
"ActionResponseModel_ActionAddToConference",
391420
"ActionResponseModel_ActionDtmf",
392421
"ActionResponseModel_ActionEndConversation",
422+
"ActionResponseModel_ActionExternal",
393423
"ActionResponseModel_ActionSetHold",
394424
"ActionResponseModel_ActionTransferCall",
395425
"ActionUpdateParamsRequest",
396426
"ActionUpdateParamsRequest_ActionAddToConference",
397427
"ActionUpdateParamsRequest_ActionDtmf",
398428
"ActionUpdateParamsRequest_ActionEndConversation",
429+
"ActionUpdateParamsRequest_ActionExternal",
399430
"ActionUpdateParamsRequest_ActionSetHold",
400431
"ActionUpdateParamsRequest_ActionTransferCall",
401432
"AddToConferenceAction",
@@ -418,6 +449,7 @@
418449
"AgentActionsItem_ActionAddToConference",
419450
"AgentActionsItem_ActionDtmf",
420451
"AgentActionsItem_ActionEndConversation",
452+
"AgentActionsItem_ActionExternal",
421453
"AgentActionsItem_ActionSetHold",
422454
"AgentActionsItem_ActionTransferCall",
423455
"AgentEndpointingSensitivity",
@@ -428,6 +460,7 @@
428460
"AgentParamsActionsItemOne_ActionAddToConference",
429461
"AgentParamsActionsItemOne_ActionDtmf",
430462
"AgentParamsActionsItemOne_ActionEndConversation",
463+
"AgentParamsActionsItemOne_ActionExternal",
431464
"AgentParamsActionsItemOne_ActionSetHold",
432465
"AgentParamsActionsItemOne_ActionTransferCall",
433466
"AgentParamsEndpointingSensitivity",
@@ -449,6 +482,7 @@
449482
"AgentUpdateParamsActionsItemOne_ActionAddToConference",
450483
"AgentUpdateParamsActionsItemOne_ActionDtmf",
451484
"AgentUpdateParamsActionsItemOne_ActionEndConversation",
485+
"AgentUpdateParamsActionsItemOne_ActionExternal",
452486
"AgentUpdateParamsActionsItemOne_ActionSetHold",
453487
"AgentUpdateParamsActionsItemOne_ActionTransferCall",
454488
"AgentUpdateParamsAskIfHumanPresentOnIdle",
@@ -460,6 +494,7 @@
460494
"AgentUpdateParamsInterruptSensitivity",
461495
"AgentUpdateParamsIvrNavigationMode",
462496
"AgentUpdateParamsLanguage",
497+
"AgentUpdateParamsName",
463498
"AgentUpdateParamsNoiseSuppression",
464499
"AgentUpdateParamsOpenaiAccountConnection",
465500
"AgentUpdateParamsOpenaiModelNameOverride",
@@ -501,6 +536,7 @@
501536
"CreateCallAgentParamsActionsItemOne_ActionAddToConference",
502537
"CreateCallAgentParamsActionsItemOne_ActionDtmf",
503538
"CreateCallAgentParamsActionsItemOne_ActionEndConversation",
539+
"CreateCallAgentParamsActionsItemOne_ActionExternal",
504540
"CreateCallAgentParamsActionsItemOne_ActionSetHold",
505541
"CreateCallAgentParamsActionsItemOne_ActionTransferCall",
506542
"CreateCallAgentParamsEndpointingSensitivity",
@@ -557,6 +593,21 @@
557593
"EndConversationActionUpdateParamsActionTriggerZero_ActionTriggerPhraseBased",
558594
"EndConversationActionUpdateParamsConfig",
559595
"EventType",
596+
"ExternalAction",
597+
"ExternalActionActionTrigger",
598+
"ExternalActionActionTrigger_ActionTriggerFunctionCall",
599+
"ExternalActionActionTrigger_ActionTriggerPhraseBased",
600+
"ExternalActionConfig",
601+
"ExternalActionParams",
602+
"ExternalActionParamsActionTrigger",
603+
"ExternalActionParamsActionTrigger_ActionTriggerFunctionCall",
604+
"ExternalActionParamsActionTrigger_ActionTriggerPhraseBased",
605+
"ExternalActionUpdateParams",
606+
"ExternalActionUpdateParamsActionTrigger",
607+
"ExternalActionUpdateParamsActionTriggerZero",
608+
"ExternalActionUpdateParamsActionTriggerZero_ActionTriggerFunctionCall",
609+
"ExternalActionUpdateParamsActionTriggerZero_ActionTriggerPhraseBased",
610+
"ExternalActionUpdateParamsConfig",
560611
"FunctionCallActionTrigger",
561612
"FunctionCallActionTriggerConfig",
562613
"HttpMethod",
@@ -627,8 +678,11 @@
627678
"PromptUpdateParamsContextEndpoint",
628679
"PromptUpdateParamsPromptTemplate",
629680
"RimeVoice",
681+
"RimeVoiceModelId",
630682
"RimeVoiceParams",
683+
"RimeVoiceParamsModelId",
631684
"RimeVoiceUpdateParams",
685+
"RimeVoiceUpdateParamsModelId",
632686
"RimeVoiceUpdateParamsSpeaker",
633687
"RimeVoiceUpdateParamsSpeedAlpha",
634688
"SetHoldAction",

src/vocode/core/client_wrapper.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ def get_headers(self) -> typing.Dict[str, str]:
1414
headers: typing.Dict[str, str] = {
1515
"X-Fern-Language": "Python",
1616
"X-Fern-SDK-Name": "vocode-api",
17-
"X-Fern-SDK-Version": "0.0.41",
17+
"X-Fern-SDK-Version": "0.0.42",
1818
}
1919
headers["Authorization"] = f"Bearer {self._get_token()}"
2020
return headers

src/vocode/resources/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
AgentParamsActionsItemOne_ActionAddToConference,
88
AgentParamsActionsItemOne_ActionDtmf,
99
AgentParamsActionsItemOne_ActionEndConversation,
10+
AgentParamsActionsItemOne_ActionExternal,
1011
AgentParamsActionsItemOne_ActionSetHold,
1112
AgentParamsActionsItemOne_ActionTransferCall,
1213
AgentParamsEndpointingSensitivity,
@@ -36,6 +37,7 @@
3637
"AgentParamsActionsItemOne_ActionAddToConference",
3738
"AgentParamsActionsItemOne_ActionDtmf",
3839
"AgentParamsActionsItemOne_ActionEndConversation",
40+
"AgentParamsActionsItemOne_ActionExternal",
3941
"AgentParamsActionsItemOne_ActionSetHold",
4042
"AgentParamsActionsItemOne_ActionTransferCall",
4143
"AgentParamsEndpointingSensitivity",

src/vocode/resources/account_connections/client.py

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,36 @@ def update_account_connection(
136136
raise ApiError(status_code=_response.status_code, body=_response.text)
137137
raise ApiError(status_code=_response.status_code, body=_response_json)
138138

139+
def add_to_steering_pool(self, *, id: str, phone_number: typing.Optional[str] = OMIT) -> typing.Any:
140+
"""
141+
Parameters:
142+
- id: str.
143+
144+
- phone_number: typing.Optional[str].
145+
"""
146+
_request: typing.Dict[str, typing.Any] = {}
147+
if phone_number is not OMIT:
148+
_request["phone_number"] = phone_number
149+
_response = self._client_wrapper.httpx_client.request(
150+
"POST",
151+
urllib.parse.urljoin(
152+
f"{self._client_wrapper.get_base_url()}/", "v1/account_connections/add_to_steering_pool"
153+
),
154+
params=remove_none_from_dict({"id": id}),
155+
json=jsonable_encoder(_request),
156+
headers=self._client_wrapper.get_headers(),
157+
timeout=60,
158+
)
159+
if 200 <= _response.status_code < 300:
160+
return pydantic.parse_obj_as(typing.Any, _response.json()) # type: ignore
161+
if _response.status_code == 422:
162+
raise UnprocessableEntityError(pydantic.parse_obj_as(HttpValidationError, _response.json())) # type: ignore
163+
try:
164+
_response_json = _response.json()
165+
except JSONDecodeError:
166+
raise ApiError(status_code=_response.status_code, body=_response.text)
167+
raise ApiError(status_code=_response.status_code, body=_response_json)
168+
139169

140170
class AsyncAccountConnectionsClient:
141171
def __init__(self, *, client_wrapper: AsyncClientWrapper):
@@ -250,3 +280,33 @@ async def update_account_connection(
250280
except JSONDecodeError:
251281
raise ApiError(status_code=_response.status_code, body=_response.text)
252282
raise ApiError(status_code=_response.status_code, body=_response_json)
283+
284+
async def add_to_steering_pool(self, *, id: str, phone_number: typing.Optional[str] = OMIT) -> typing.Any:
285+
"""
286+
Parameters:
287+
- id: str.
288+
289+
- phone_number: typing.Optional[str].
290+
"""
291+
_request: typing.Dict[str, typing.Any] = {}
292+
if phone_number is not OMIT:
293+
_request["phone_number"] = phone_number
294+
_response = await self._client_wrapper.httpx_client.request(
295+
"POST",
296+
urllib.parse.urljoin(
297+
f"{self._client_wrapper.get_base_url()}/", "v1/account_connections/add_to_steering_pool"
298+
),
299+
params=remove_none_from_dict({"id": id}),
300+
json=jsonable_encoder(_request),
301+
headers=self._client_wrapper.get_headers(),
302+
timeout=60,
303+
)
304+
if 200 <= _response.status_code < 300:
305+
return pydantic.parse_obj_as(typing.Any, _response.json()) # type: ignore
306+
if _response.status_code == 422:
307+
raise UnprocessableEntityError(pydantic.parse_obj_as(HttpValidationError, _response.json())) # type: ignore
308+
try:
309+
_response_json = _response.json()
310+
except JSONDecodeError:
311+
raise ApiError(status_code=_response.status_code, body=_response.text)
312+
raise ApiError(status_code=_response.status_code, body=_response_json)

src/vocode/resources/agents/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
AgentParamsActionsItemOne_ActionAddToConference,
77
AgentParamsActionsItemOne_ActionDtmf,
88
AgentParamsActionsItemOne_ActionEndConversation,
9+
AgentParamsActionsItemOne_ActionExternal,
910
AgentParamsActionsItemOne_ActionSetHold,
1011
AgentParamsActionsItemOne_ActionTransferCall,
1112
AgentParamsEndpointingSensitivity,
@@ -28,6 +29,7 @@
2829
"AgentParamsActionsItemOne_ActionAddToConference",
2930
"AgentParamsActionsItemOne_ActionDtmf",
3031
"AgentParamsActionsItemOne_ActionEndConversation",
32+
"AgentParamsActionsItemOne_ActionExternal",
3133
"AgentParamsActionsItemOne_ActionSetHold",
3234
"AgentParamsActionsItemOne_ActionTransferCall",
3335
"AgentParamsEndpointingSensitivity",

src/vocode/resources/agents/client.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@ def list_agents(
9999
def create_agent(
100100
self,
101101
*,
102+
name: typing.Optional[str] = OMIT,
102103
prompt: AgentParamsPrompt,
103104
language: typing.Optional[Language] = OMIT,
104105
actions: typing.Optional[typing.List[AgentParamsActionsItem]] = OMIT,
@@ -121,6 +122,8 @@ def create_agent(
121122
) -> Agent:
122123
"""
123124
Parameters:
125+
- name: typing.Optional[str].
126+
124127
- prompt: AgentParamsPrompt.
125128
126129
- language: typing.Optional[Language].
@@ -160,6 +163,8 @@ def create_agent(
160163
- llm_temperature: typing.Optional[float].
161164
"""
162165
_request: typing.Dict[str, typing.Any] = {"prompt": prompt, "voice": voice}
166+
if name is not OMIT:
167+
_request["name"] = name
163168
if language is not OMIT:
164169
_request["language"] = language
165170
if actions is not OMIT:
@@ -303,6 +308,7 @@ async def list_agents(
303308
async def create_agent(
304309
self,
305310
*,
311+
name: typing.Optional[str] = OMIT,
306312
prompt: AgentParamsPrompt,
307313
language: typing.Optional[Language] = OMIT,
308314
actions: typing.Optional[typing.List[AgentParamsActionsItem]] = OMIT,
@@ -325,6 +331,8 @@ async def create_agent(
325331
) -> Agent:
326332
"""
327333
Parameters:
334+
- name: typing.Optional[str].
335+
328336
- prompt: AgentParamsPrompt.
329337
330338
- language: typing.Optional[Language].
@@ -364,6 +372,8 @@ async def create_agent(
364372
- llm_temperature: typing.Optional[float].
365373
"""
366374
_request: typing.Dict[str, typing.Any] = {"prompt": prompt, "voice": voice}
375+
if name is not OMIT:
376+
_request["name"] = name
367377
if language is not OMIT:
368378
_request["language"] = language
369379
if actions is not OMIT:

0 commit comments

Comments
 (0)