From f4a83f3ec4a359547cc08917fc2277b8b4663fb6 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 1 May 2025 17:22:29 +0000 Subject: [PATCH 01/10] feat(api): api update --- .stats.yml | 2 +- src/retell/types/agent_response.py | 5 ++++- src/retell/types/llm_response.py | 5 ++++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.stats.yml b/.stats.yml index 8f3fbc8a..e425313f 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 34 openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-bd98f7f1d3719abfc66e25f422097c72c6504f85615412419bb88dafebb3d36e.yml -openapi_spec_hash: 202e8e5ba60e0e03c6ef0ddf43af624b +openapi_spec_hash: ae10c326681c633b86c08613ef17beac config_hash: 9d9a24bf8bb4553cbb30ce59eb910b2f diff --git a/src/retell/types/agent_response.py b/src/retell/types/agent_response.py index 0d40aa5e..357f4546 100644 --- a/src/retell/types/agent_response.py +++ b/src/retell/types/agent_response.py @@ -268,6 +268,9 @@ class AgentResponse(BaseModel): agent would never be interrupted. """ + is_published: Optional[bool] = None + """Whether the agent is published.""" + language: Optional[ Literal[ "en-US", @@ -400,7 +403,7 @@ class AgentResponse(BaseModel): Default to fast mode. """ - version: Optional[float] = None + version: Optional[object] = None """Version of the agent.""" voice_model: Optional[ diff --git a/src/retell/types/llm_response.py b/src/retell/types/llm_response.py index e1dbad0b..0096d4e7 100644 --- a/src/retell/types/llm_response.py +++ b/src/retell/types/llm_response.py @@ -742,6 +742,9 @@ class LlmResponse(BaseModel): - Tools of LLM (no state) = general tools """ + is_published: Optional[bool] = None + """Whether the Retell LLM Response Engine is published.""" + knowledge_base_ids: Optional[List[str]] = None """A list of knowledge base ids to use for this resource. @@ -805,5 +808,5 @@ class LlmResponse(BaseModel): longer as additional processing is needed. Default to false. """ - version: Optional[float] = None + version: Optional[object] = None """Version of the Retell LLM.""" From 84bc6f9064fe0272f3e71a0963ae7f17c92672ff Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 1 May 2025 20:13:08 +0000 Subject: [PATCH 02/10] feat(api): api update --- .stats.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.stats.yml b/.stats.yml index e425313f..36e717a3 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 34 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-bd98f7f1d3719abfc66e25f422097c72c6504f85615412419bb88dafebb3d36e.yml +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-dd49046bb8e5c943cbb23e906bd6dd9573213f28f4c8d08df7b885c5947b470b.yml openapi_spec_hash: ae10c326681c633b86c08613ef17beac config_hash: 9d9a24bf8bb4553cbb30ce59eb910b2f From fb974a7a9f4367f3146443b7d484997791f40639 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 7 May 2025 18:05:47 +0000 Subject: [PATCH 03/10] feat(api): api update --- .stats.yml | 4 +-- README.md | 37 ++++++++----------------- src/retell/resources/agent.py | 8 ++++++ src/retell/types/agent_create_params.py | 14 ++++++++++ src/retell/types/agent_response.py | 14 ++++++++++ src/retell/types/agent_update_params.py | 14 ++++++++++ tests/api_resources/test_agent.py | 20 +++++++++++++ 7 files changed, 83 insertions(+), 28 deletions(-) diff --git a/.stats.yml b/.stats.yml index 36e717a3..2befa7cd 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 34 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-dd49046bb8e5c943cbb23e906bd6dd9573213f28f4c8d08df7b885c5947b470b.yml -openapi_spec_hash: ae10c326681c633b86c08613ef17beac +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-db7157c3392982f46fe0ad376bbefae977ae81aac3817313374eeeb6242b9ecf.yml +openapi_spec_hash: 838f30bd4fd9ab62824f6c9ba94eacb4 config_hash: 9d9a24bf8bb4553cbb30ce59eb910b2f diff --git a/README.md b/README.md index 6e883efa..ef9b8568 100644 --- a/README.md +++ b/README.md @@ -85,34 +85,19 @@ from retell import Retell client = Retell() -call_responses = client.call.list( - filter_criteria={ - "agent_id": ["agent_oBeDLoLOeuAbiuaMFXRtDOLriT12345"], - "call_status": ["ended"], - "call_successful": [True], - "call_type": ["phone_call"], - "direction": ["inbound"], - "disconnection_reason": ["user_hangup"], - "duration_ms": { - "lower_threshold": 0, - "upper_threshold": 0, - }, - "e2e_latency_p50": { - "lower_threshold": 0, - "upper_threshold": 0, - }, - "from_number": ["string"], - "in_voicemail": [True], - "start_timestamp": { - "lower_threshold": 1738475411000, - "upper_threshold": 1738475421000, - }, - "to_number": ["string"], - "user_sentiment": ["Positive"], - "version": [0], +agent_response = client.agent.create( + response_engine={ + "llm_id": "llm_234sdertfsdsfsdf", + "type": "retell-llm", + }, + voice_id="11labs-Adrian", + user_dtmf_options={ + "digit_limit": 1, + "termination_key": "#", + "timeout_ms": 1000, }, ) -print(call_responses.filter_criteria) +print(agent_response.user_dtmf_options) ``` ## Handling errors diff --git a/src/retell/resources/agent.py b/src/retell/resources/agent.py index b864bf43..8910498d 100644 --- a/src/retell/resources/agent.py +++ b/src/retell/resources/agent.py @@ -119,6 +119,7 @@ def create( responsiveness: float | NotGiven = NOT_GIVEN, ring_duration_ms: int | NotGiven = NOT_GIVEN, stt_mode: Literal["fast", "accurate"] | NotGiven = NOT_GIVEN, + user_dtmf_options: Optional[agent_create_params.UserDtmfOptions] | NotGiven = NOT_GIVEN, version: Optional[float] | NotGiven = NOT_GIVEN, voice_model: Optional[ Literal[ @@ -364,6 +365,7 @@ def create( "responsiveness": responsiveness, "ring_duration_ms": ring_duration_ms, "stt_mode": stt_mode, + "user_dtmf_options": user_dtmf_options, "version": version, "voice_model": voice_model, "voice_speed": voice_speed, @@ -495,6 +497,7 @@ def update( responsiveness: float | NotGiven = NOT_GIVEN, ring_duration_ms: int | NotGiven = NOT_GIVEN, stt_mode: Literal["fast", "accurate"] | NotGiven = NOT_GIVEN, + user_dtmf_options: Optional[agent_update_params.UserDtmfOptions] | NotGiven = NOT_GIVEN, body_version: Optional[float] | NotGiven = NOT_GIVEN, voice_id: str | NotGiven = NOT_GIVEN, voice_model: Optional[ @@ -744,6 +747,7 @@ def update( "responsiveness": responsiveness, "ring_duration_ms": ring_duration_ms, "stt_mode": stt_mode, + "user_dtmf_options": user_dtmf_options, "body_version": body_version, "voice_id": voice_id, "voice_model": voice_model, @@ -946,6 +950,7 @@ async def create( responsiveness: float | NotGiven = NOT_GIVEN, ring_duration_ms: int | NotGiven = NOT_GIVEN, stt_mode: Literal["fast", "accurate"] | NotGiven = NOT_GIVEN, + user_dtmf_options: Optional[agent_create_params.UserDtmfOptions] | NotGiven = NOT_GIVEN, version: Optional[float] | NotGiven = NOT_GIVEN, voice_model: Optional[ Literal[ @@ -1191,6 +1196,7 @@ async def create( "responsiveness": responsiveness, "ring_duration_ms": ring_duration_ms, "stt_mode": stt_mode, + "user_dtmf_options": user_dtmf_options, "version": version, "voice_model": voice_model, "voice_speed": voice_speed, @@ -1322,6 +1328,7 @@ async def update( responsiveness: float | NotGiven = NOT_GIVEN, ring_duration_ms: int | NotGiven = NOT_GIVEN, stt_mode: Literal["fast", "accurate"] | NotGiven = NOT_GIVEN, + user_dtmf_options: Optional[agent_update_params.UserDtmfOptions] | NotGiven = NOT_GIVEN, body_version: Optional[float] | NotGiven = NOT_GIVEN, voice_id: str | NotGiven = NOT_GIVEN, voice_model: Optional[ @@ -1571,6 +1578,7 @@ async def update( "responsiveness": responsiveness, "ring_duration_ms": ring_duration_ms, "stt_mode": stt_mode, + "user_dtmf_options": user_dtmf_options, "body_version": body_version, "voice_id": voice_id, "voice_model": voice_model, diff --git a/src/retell/types/agent_create_params.py b/src/retell/types/agent_create_params.py index 780bff0b..ce065e67 100644 --- a/src/retell/types/agent_create_params.py +++ b/src/retell/types/agent_create_params.py @@ -17,6 +17,7 @@ "PostCallAnalysisDataBooleanAnalysisData", "PostCallAnalysisDataNumberAnalysisData", "PronunciationDictionary", + "UserDtmfOptions", ] @@ -283,6 +284,8 @@ class AgentCreateParams(TypedDict, total=False): Default to fast mode. """ + user_dtmf_options: Optional[UserDtmfOptions] + version: Optional[float] """Version of the agent.""" @@ -455,3 +458,14 @@ class PronunciationDictionary(TypedDict, total=False): word: Required[str] """The string of word / phrase to be annotated with pronunciation.""" + + +class UserDtmfOptions(TypedDict, total=False): + digit_limit: Optional[float] + """The maximum number of digits allowed in user DTMF input.""" + + termination_key: Optional[str] + """The key that terminates the DTMF input. Any digit, #, or \\** is allowed.""" + + timeout_ms: int + """The timeout for user DTMF input in milliseconds.""" diff --git a/src/retell/types/agent_response.py b/src/retell/types/agent_response.py index 357f4546..0a07cba5 100644 --- a/src/retell/types/agent_response.py +++ b/src/retell/types/agent_response.py @@ -17,6 +17,7 @@ "PostCallAnalysisDataBooleanAnalysisData", "PostCallAnalysisDataNumberAnalysisData", "PronunciationDictionary", + "UserDtmfOptions", ] @@ -126,6 +127,17 @@ class PronunciationDictionary(BaseModel): """The string of word / phrase to be annotated with pronunciation.""" +class UserDtmfOptions(BaseModel): + digit_limit: Optional[float] = None + """The maximum number of digits allowed in user DTMF input.""" + + termination_key: Optional[str] = None + """The key that terminates the DTMF input. Any digit, #, or \\** is allowed.""" + + timeout_ms: Optional[int] = None + """The timeout for user DTMF input in milliseconds.""" + + class AgentResponse(BaseModel): agent_id: str """Unique id of agent.""" @@ -403,6 +415,8 @@ class AgentResponse(BaseModel): Default to fast mode. """ + user_dtmf_options: Optional[UserDtmfOptions] = None + version: Optional[object] = None """Version of the agent.""" diff --git a/src/retell/types/agent_update_params.py b/src/retell/types/agent_update_params.py index b7a2d4e2..4c4723d1 100644 --- a/src/retell/types/agent_update_params.py +++ b/src/retell/types/agent_update_params.py @@ -19,6 +19,7 @@ "ResponseEngineResponseEngineRetellLm", "ResponseEngineResponseEngineCustomLm", "ResponseEngineResponseEngineConversationFlow", + "UserDtmfOptions", ] @@ -282,6 +283,8 @@ class AgentUpdateParams(TypedDict, total=False): Default to fast mode. """ + user_dtmf_options: Optional[UserDtmfOptions] + body_version: Annotated[Optional[float], PropertyInfo(alias="version")] """Version of the agent.""" @@ -460,3 +463,14 @@ class ResponseEngineResponseEngineConversationFlow(TypedDict, total=False): ResponseEngineResponseEngineCustomLm, ResponseEngineResponseEngineConversationFlow, ] + + +class UserDtmfOptions(TypedDict, total=False): + digit_limit: Optional[float] + """The maximum number of digits allowed in user DTMF input.""" + + termination_key: Optional[str] + """The key that terminates the DTMF input. Any digit, #, or \\** is allowed.""" + + timeout_ms: int + """The timeout for user DTMF input in milliseconds.""" diff --git a/tests/api_resources/test_agent.py b/tests/api_resources/test_agent.py index 34e329cd..8643576e 100644 --- a/tests/api_resources/test_agent.py +++ b/tests/api_resources/test_agent.py @@ -80,6 +80,11 @@ def test_method_create_with_all_params(self, client: Retell) -> None: responsiveness=1, ring_duration_ms=30000, stt_mode="fast", + user_dtmf_options={ + "digit_limit": 1, + "termination_key": "#", + "timeout_ms": 1000, + }, version=0, voice_model="eleven_turbo_v2", voice_speed=1, @@ -225,6 +230,11 @@ def test_method_update_with_all_params(self, client: Retell) -> None: responsiveness=1, ring_duration_ms=30000, stt_mode="fast", + user_dtmf_options={ + "digit_limit": 1, + "termination_key": "#", + "timeout_ms": 1000, + }, body_version=0, voice_id="11labs-Adrian", voice_model="eleven_turbo_v2", @@ -432,6 +442,11 @@ async def test_method_create_with_all_params(self, async_client: AsyncRetell) -> responsiveness=1, ring_duration_ms=30000, stt_mode="fast", + user_dtmf_options={ + "digit_limit": 1, + "termination_key": "#", + "timeout_ms": 1000, + }, version=0, voice_model="eleven_turbo_v2", voice_speed=1, @@ -577,6 +592,11 @@ async def test_method_update_with_all_params(self, async_client: AsyncRetell) -> responsiveness=1, ring_duration_ms=30000, stt_mode="fast", + user_dtmf_options={ + "digit_limit": 1, + "termination_key": "#", + "timeout_ms": 1000, + }, body_version=0, voice_id="11labs-Adrian", voice_model="eleven_turbo_v2", From 3cb87df96dfce683feaa0a4a3b8d7285da07678b Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 7 May 2025 18:52:03 +0000 Subject: [PATCH 04/10] feat(api): api update --- .stats.yml | 4 ++-- src/retell/resources/agent.py | 16 ++++++++++++++++ src/retell/types/agent_create_params.py | 3 +++ src/retell/types/agent_response.py | 3 +++ src/retell/types/agent_update_params.py | 3 +++ tests/api_resources/test_agent.py | 4 ++++ 6 files changed, 31 insertions(+), 2 deletions(-) diff --git a/.stats.yml b/.stats.yml index 2befa7cd..8a393efd 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 34 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-db7157c3392982f46fe0ad376bbefae977ae81aac3817313374eeeb6242b9ecf.yml -openapi_spec_hash: 838f30bd4fd9ab62824f6c9ba94eacb4 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-c713d66253e9ecd7753ebb009a7e3faba287cdebf243193cac249c26af8884ab.yml +openapi_spec_hash: cf8d6d697919854ce52dd69ed70b1ff0 config_hash: 9d9a24bf8bb4553cbb30ce59eb910b2f diff --git a/src/retell/resources/agent.py b/src/retell/resources/agent.py index 8910498d..74ec3f18 100644 --- a/src/retell/resources/agent.py +++ b/src/retell/resources/agent.py @@ -52,6 +52,7 @@ def create( response_engine: agent_create_params.ResponseEngine, voice_id: str, agent_name: Optional[str] | NotGiven = NOT_GIVEN, + allow_user_dtmf: bool | NotGiven = NOT_GIVEN, ambient_sound: Optional[ Literal[ "coffee-shop", "convention-hall", "summer-outdoor", "mountain-outdoor", "static-noise", "call-center" @@ -159,6 +160,8 @@ def create( agent_name: The name of the agent. Only used for your own reference. + allow_user_dtmf: If set to true, will allow user to input DTMF digits. + ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: @@ -340,6 +343,7 @@ def create( "response_engine": response_engine, "voice_id": voice_id, "agent_name": agent_name, + "allow_user_dtmf": allow_user_dtmf, "ambient_sound": ambient_sound, "ambient_sound_volume": ambient_sound_volume, "backchannel_frequency": backchannel_frequency, @@ -429,6 +433,7 @@ def update( *, query_version: int | NotGiven = NOT_GIVEN, agent_name: Optional[str] | NotGiven = NOT_GIVEN, + allow_user_dtmf: bool | NotGiven = NOT_GIVEN, ambient_sound: Optional[ Literal[ "coffee-shop", "convention-hall", "summer-outdoor", "mountain-outdoor", "static-noise", "call-center" @@ -533,6 +538,8 @@ def update( agent_name: The name of the agent. Only used for your own reference. + allow_user_dtmf: If set to true, will allow user to input DTMF digits. + ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: @@ -721,6 +728,7 @@ def update( body=maybe_transform( { "agent_name": agent_name, + "allow_user_dtmf": allow_user_dtmf, "ambient_sound": ambient_sound, "ambient_sound_volume": ambient_sound_volume, "backchannel_frequency": backchannel_frequency, @@ -883,6 +891,7 @@ async def create( response_engine: agent_create_params.ResponseEngine, voice_id: str, agent_name: Optional[str] | NotGiven = NOT_GIVEN, + allow_user_dtmf: bool | NotGiven = NOT_GIVEN, ambient_sound: Optional[ Literal[ "coffee-shop", "convention-hall", "summer-outdoor", "mountain-outdoor", "static-noise", "call-center" @@ -990,6 +999,8 @@ async def create( agent_name: The name of the agent. Only used for your own reference. + allow_user_dtmf: If set to true, will allow user to input DTMF digits. + ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: @@ -1171,6 +1182,7 @@ async def create( "response_engine": response_engine, "voice_id": voice_id, "agent_name": agent_name, + "allow_user_dtmf": allow_user_dtmf, "ambient_sound": ambient_sound, "ambient_sound_volume": ambient_sound_volume, "backchannel_frequency": backchannel_frequency, @@ -1260,6 +1272,7 @@ async def update( *, query_version: int | NotGiven = NOT_GIVEN, agent_name: Optional[str] | NotGiven = NOT_GIVEN, + allow_user_dtmf: bool | NotGiven = NOT_GIVEN, ambient_sound: Optional[ Literal[ "coffee-shop", "convention-hall", "summer-outdoor", "mountain-outdoor", "static-noise", "call-center" @@ -1364,6 +1377,8 @@ async def update( agent_name: The name of the agent. Only used for your own reference. + allow_user_dtmf: If set to true, will allow user to input DTMF digits. + ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: @@ -1552,6 +1567,7 @@ async def update( body=await async_maybe_transform( { "agent_name": agent_name, + "allow_user_dtmf": allow_user_dtmf, "ambient_sound": ambient_sound, "ambient_sound_volume": ambient_sound_volume, "backchannel_frequency": backchannel_frequency, diff --git a/src/retell/types/agent_create_params.py b/src/retell/types/agent_create_params.py index ce065e67..4d7ceee7 100644 --- a/src/retell/types/agent_create_params.py +++ b/src/retell/types/agent_create_params.py @@ -38,6 +38,9 @@ class AgentCreateParams(TypedDict, total=False): agent_name: Optional[str] """The name of the agent. Only used for your own reference.""" + allow_user_dtmf: bool + """If set to true, will allow user to input DTMF digits.""" + ambient_sound: Optional[ Literal["coffee-shop", "convention-hall", "summer-outdoor", "mountain-outdoor", "static-noise", "call-center"] ] diff --git a/src/retell/types/agent_response.py b/src/retell/types/agent_response.py index 0a07cba5..35ec520e 100644 --- a/src/retell/types/agent_response.py +++ b/src/retell/types/agent_response.py @@ -164,6 +164,9 @@ class AgentResponse(BaseModel): agent_name: Optional[str] = None """The name of the agent. Only used for your own reference.""" + allow_user_dtmf: Optional[bool] = None + """If set to true, will allow user to input DTMF digits.""" + ambient_sound: Optional[ Literal["coffee-shop", "convention-hall", "summer-outdoor", "mountain-outdoor", "static-noise", "call-center"] ] = None diff --git a/src/retell/types/agent_update_params.py b/src/retell/types/agent_update_params.py index 4c4723d1..88344327 100644 --- a/src/retell/types/agent_update_params.py +++ b/src/retell/types/agent_update_params.py @@ -30,6 +30,9 @@ class AgentUpdateParams(TypedDict, total=False): agent_name: Optional[str] """The name of the agent. Only used for your own reference.""" + allow_user_dtmf: bool + """If set to true, will allow user to input DTMF digits.""" + ambient_sound: Optional[ Literal["coffee-shop", "convention-hall", "summer-outdoor", "mountain-outdoor", "static-noise", "call-center"] ] diff --git a/tests/api_resources/test_agent.py b/tests/api_resources/test_agent.py index 8643576e..29606c9e 100644 --- a/tests/api_resources/test_agent.py +++ b/tests/api_resources/test_agent.py @@ -42,6 +42,7 @@ def test_method_create_with_all_params(self, client: Retell) -> None: }, voice_id="11labs-Adrian", agent_name="Jarvis", + allow_user_dtmf=True, ambient_sound="coffee-shop", ambient_sound_volume=1, backchannel_frequency=0.9, @@ -187,6 +188,7 @@ def test_method_update_with_all_params(self, client: Retell) -> None: agent_id="16b980523634a6dc504898cda492e939", query_version=1, agent_name="Jarvis", + allow_user_dtmf=True, ambient_sound="coffee-shop", ambient_sound_volume=1, backchannel_frequency=0.9, @@ -404,6 +406,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncRetell) -> }, voice_id="11labs-Adrian", agent_name="Jarvis", + allow_user_dtmf=True, ambient_sound="coffee-shop", ambient_sound_volume=1, backchannel_frequency=0.9, @@ -549,6 +552,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncRetell) -> agent_id="16b980523634a6dc504898cda492e939", query_version=1, agent_name="Jarvis", + allow_user_dtmf=True, ambient_sound="coffee-shop", ambient_sound_volume=1, backchannel_frequency=0.9, From 4e2edb1f2d4b9aa1116e31d546b005f1d03b1b48 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 7 May 2025 18:55:45 +0000 Subject: [PATCH 05/10] feat(api): api update --- .stats.yml | 4 ++-- src/retell/types/agent_create_params.py | 2 +- src/retell/types/agent_response.py | 2 +- src/retell/types/agent_update_params.py | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.stats.yml b/.stats.yml index 8a393efd..378ef9bb 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 34 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-c713d66253e9ecd7753ebb009a7e3faba287cdebf243193cac249c26af8884ab.yml -openapi_spec_hash: cf8d6d697919854ce52dd69ed70b1ff0 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-24db49290e24e9d6acae57ed2a3c5e7577ee45cf79b000d731b6b5196454f4c3.yml +openapi_spec_hash: 2fc74db4d328f301ec63627f823e52e1 config_hash: 9d9a24bf8bb4553cbb30ce59eb910b2f diff --git a/src/retell/types/agent_create_params.py b/src/retell/types/agent_create_params.py index 4d7ceee7..abe7088a 100644 --- a/src/retell/types/agent_create_params.py +++ b/src/retell/types/agent_create_params.py @@ -464,7 +464,7 @@ class PronunciationDictionary(TypedDict, total=False): class UserDtmfOptions(TypedDict, total=False): - digit_limit: Optional[float] + digit_limit: Optional[int] """The maximum number of digits allowed in user DTMF input.""" termination_key: Optional[str] diff --git a/src/retell/types/agent_response.py b/src/retell/types/agent_response.py index 35ec520e..16e998d1 100644 --- a/src/retell/types/agent_response.py +++ b/src/retell/types/agent_response.py @@ -128,7 +128,7 @@ class PronunciationDictionary(BaseModel): class UserDtmfOptions(BaseModel): - digit_limit: Optional[float] = None + digit_limit: Optional[int] = None """The maximum number of digits allowed in user DTMF input.""" termination_key: Optional[str] = None diff --git a/src/retell/types/agent_update_params.py b/src/retell/types/agent_update_params.py index 88344327..0217e0e9 100644 --- a/src/retell/types/agent_update_params.py +++ b/src/retell/types/agent_update_params.py @@ -469,7 +469,7 @@ class ResponseEngineResponseEngineConversationFlow(TypedDict, total=False): class UserDtmfOptions(TypedDict, total=False): - digit_limit: Optional[float] + digit_limit: Optional[int] """The maximum number of digits allowed in user DTMF input.""" termination_key: Optional[str] From dc028721305eec0c8c6126ac795011b07c6d82cd Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 7 May 2025 19:04:43 +0000 Subject: [PATCH 06/10] feat(api): api update --- .stats.yml | 4 ++-- src/retell/resources/agent.py | 12 ++++++++---- src/retell/types/agent_create_params.py | 22 ++++++++++++++++++---- src/retell/types/agent_response.py | 22 ++++++++++++++++++---- src/retell/types/agent_update_params.py | 22 ++++++++++++++++++---- 5 files changed, 64 insertions(+), 18 deletions(-) diff --git a/.stats.yml b/.stats.yml index 378ef9bb..aa7a7775 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 34 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-24db49290e24e9d6acae57ed2a3c5e7577ee45cf79b000d731b6b5196454f4c3.yml -openapi_spec_hash: 2fc74db4d328f301ec63627f823e52e1 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-f2c0410def02516b658b22cdf861e4a8ed6972ce5a8e4e1ff3f44ba2cc0caa22.yml +openapi_spec_hash: 923ea9d315f60b21e122c244e9a12527 config_hash: 9d9a24bf8bb4553cbb30ce59eb910b2f diff --git a/src/retell/resources/agent.py b/src/retell/resources/agent.py index 74ec3f18..76b15ee3 100644 --- a/src/retell/resources/agent.py +++ b/src/retell/resources/agent.py @@ -160,7 +160,8 @@ def create( agent_name: The name of the agent. Only used for your own reference. - allow_user_dtmf: If set to true, will allow user to input DTMF digits. + allow_user_dtmf: If set to true, DTMF input will be accepted and processed. If false, any DTMF + input will be ignored. ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: @@ -538,7 +539,8 @@ def update( agent_name: The name of the agent. Only used for your own reference. - allow_user_dtmf: If set to true, will allow user to input DTMF digits. + allow_user_dtmf: If set to true, DTMF input will be accepted and processed. If false, any DTMF + input will be ignored. ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: @@ -999,7 +1001,8 @@ async def create( agent_name: The name of the agent. Only used for your own reference. - allow_user_dtmf: If set to true, will allow user to input DTMF digits. + allow_user_dtmf: If set to true, DTMF input will be accepted and processed. If false, any DTMF + input will be ignored. ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: @@ -1377,7 +1380,8 @@ async def update( agent_name: The name of the agent. Only used for your own reference. - allow_user_dtmf: If set to true, will allow user to input DTMF digits. + allow_user_dtmf: If set to true, DTMF input will be accepted and processed. If false, any DTMF + input will be ignored. ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: diff --git a/src/retell/types/agent_create_params.py b/src/retell/types/agent_create_params.py index abe7088a..c8114851 100644 --- a/src/retell/types/agent_create_params.py +++ b/src/retell/types/agent_create_params.py @@ -39,7 +39,10 @@ class AgentCreateParams(TypedDict, total=False): """The name of the agent. Only used for your own reference.""" allow_user_dtmf: bool - """If set to true, will allow user to input DTMF digits.""" + """If set to true, DTMF input will be accepted and processed. + + If false, any DTMF input will be ignored. + """ ambient_sound: Optional[ Literal["coffee-shop", "convention-hall", "summer-outdoor", "mountain-outdoor", "static-noise", "call-center"] @@ -465,10 +468,21 @@ class PronunciationDictionary(TypedDict, total=False): class UserDtmfOptions(TypedDict, total=False): digit_limit: Optional[int] - """The maximum number of digits allowed in user DTMF input.""" + """ + The maximum number of digits allowed in the user's DTMF (Dual-Tone + Multi-Frequency) input per turn. Once this limit is reached, the input is + considered complete and a response will be generated immediately. + """ termination_key: Optional[str] - """The key that terminates the DTMF input. Any digit, #, or \\** is allowed.""" + """A single key that signals the end of DTMF input. + + Acceptable values include any digit (0–9), the pound/hash symbol (#), or the + asterisk (\\**). + """ timeout_ms: int - """The timeout for user DTMF input in milliseconds.""" + """The time (in milliseconds) to wait for user DTMF input before timing out. + + The timer resets with each digit received. + """ diff --git a/src/retell/types/agent_response.py b/src/retell/types/agent_response.py index 16e998d1..bd03312f 100644 --- a/src/retell/types/agent_response.py +++ b/src/retell/types/agent_response.py @@ -129,13 +129,24 @@ class PronunciationDictionary(BaseModel): class UserDtmfOptions(BaseModel): digit_limit: Optional[int] = None - """The maximum number of digits allowed in user DTMF input.""" + """ + The maximum number of digits allowed in the user's DTMF (Dual-Tone + Multi-Frequency) input per turn. Once this limit is reached, the input is + considered complete and a response will be generated immediately. + """ termination_key: Optional[str] = None - """The key that terminates the DTMF input. Any digit, #, or \\** is allowed.""" + """A single key that signals the end of DTMF input. + + Acceptable values include any digit (0–9), the pound/hash symbol (#), or the + asterisk (\\**). + """ timeout_ms: Optional[int] = None - """The timeout for user DTMF input in milliseconds.""" + """The time (in milliseconds) to wait for user DTMF input before timing out. + + The timer resets with each digit received. + """ class AgentResponse(BaseModel): @@ -165,7 +176,10 @@ class AgentResponse(BaseModel): """The name of the agent. Only used for your own reference.""" allow_user_dtmf: Optional[bool] = None - """If set to true, will allow user to input DTMF digits.""" + """If set to true, DTMF input will be accepted and processed. + + If false, any DTMF input will be ignored. + """ ambient_sound: Optional[ Literal["coffee-shop", "convention-hall", "summer-outdoor", "mountain-outdoor", "static-noise", "call-center"] diff --git a/src/retell/types/agent_update_params.py b/src/retell/types/agent_update_params.py index 0217e0e9..b86d4302 100644 --- a/src/retell/types/agent_update_params.py +++ b/src/retell/types/agent_update_params.py @@ -31,7 +31,10 @@ class AgentUpdateParams(TypedDict, total=False): """The name of the agent. Only used for your own reference.""" allow_user_dtmf: bool - """If set to true, will allow user to input DTMF digits.""" + """If set to true, DTMF input will be accepted and processed. + + If false, any DTMF input will be ignored. + """ ambient_sound: Optional[ Literal["coffee-shop", "convention-hall", "summer-outdoor", "mountain-outdoor", "static-noise", "call-center"] @@ -470,10 +473,21 @@ class ResponseEngineResponseEngineConversationFlow(TypedDict, total=False): class UserDtmfOptions(TypedDict, total=False): digit_limit: Optional[int] - """The maximum number of digits allowed in user DTMF input.""" + """ + The maximum number of digits allowed in the user's DTMF (Dual-Tone + Multi-Frequency) input per turn. Once this limit is reached, the input is + considered complete and a response will be generated immediately. + """ termination_key: Optional[str] - """The key that terminates the DTMF input. Any digit, #, or \\** is allowed.""" + """A single key that signals the end of DTMF input. + + Acceptable values include any digit (0–9), the pound/hash symbol (#), or the + asterisk (\\**). + """ timeout_ms: int - """The timeout for user DTMF input in milliseconds.""" + """The time (in milliseconds) to wait for user DTMF input before timing out. + + The timer resets with each digit received. + """ From ae0efc9c584268ba9bfd7b5a3681145a97322133 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 8 May 2025 12:45:27 +0000 Subject: [PATCH 07/10] chore(internal): avoid errors for isinstance checks on proxies --- src/retell/_utils/_proxy.py | 5 ++++- tests/test_utils/test_proxy.py | 11 +++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/src/retell/_utils/_proxy.py b/src/retell/_utils/_proxy.py index ffd883e9..0f239a33 100644 --- a/src/retell/_utils/_proxy.py +++ b/src/retell/_utils/_proxy.py @@ -46,7 +46,10 @@ def __dir__(self) -> Iterable[str]: @property # type: ignore @override def __class__(self) -> type: # pyright: ignore - proxied = self.__get_proxied__() + try: + proxied = self.__get_proxied__() + except Exception: + return type(self) if issubclass(type(proxied), LazyProxy): return type(proxied) return proxied.__class__ diff --git a/tests/test_utils/test_proxy.py b/tests/test_utils/test_proxy.py index de63e6ad..516d1db0 100644 --- a/tests/test_utils/test_proxy.py +++ b/tests/test_utils/test_proxy.py @@ -21,3 +21,14 @@ def test_recursive_proxy() -> None: assert dir(proxy) == [] assert type(proxy).__name__ == "RecursiveLazyProxy" assert type(operator.attrgetter("name.foo.bar.baz")(proxy)).__name__ == "RecursiveLazyProxy" + + +def test_isinstance_does_not_error() -> None: + class AlwaysErrorProxy(LazyProxy[Any]): + @override + def __load__(self) -> Any: + raise RuntimeError("Mocking missing dependency") + + proxy = AlwaysErrorProxy() + assert not isinstance(proxy, dict) + assert isinstance(proxy, LazyProxy) From 94bf9a5e4e91f44902d777683498b82bdba1a691 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 9 May 2025 14:22:21 +0000 Subject: [PATCH 08/10] fix(package): support direct resource imports --- src/retell/__init__.py | 5 +++++ src/retell/_utils/_resources_proxy.py | 24 ++++++++++++++++++++++++ 2 files changed, 29 insertions(+) create mode 100644 src/retell/_utils/_resources_proxy.py diff --git a/src/retell/__init__.py b/src/retell/__init__.py index a687f078..c5ddb67e 100644 --- a/src/retell/__init__.py +++ b/src/retell/__init__.py @@ -1,5 +1,7 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. +import typing as _t + from . import types from ._types import NOT_GIVEN, Omit, NoneType, NotGiven, Transport, ProxiesTypes from ._utils import file_from_path @@ -68,6 +70,9 @@ "DefaultAsyncHttpxClient", ] +if not _t.TYPE_CHECKING: + from ._utils._resources_proxy import resources as resources + _setup_logging() # Update the __module__ attribute for exported symbols so that diff --git a/src/retell/_utils/_resources_proxy.py b/src/retell/_utils/_resources_proxy.py new file mode 100644 index 00000000..c6616a3d --- /dev/null +++ b/src/retell/_utils/_resources_proxy.py @@ -0,0 +1,24 @@ +from __future__ import annotations + +from typing import Any +from typing_extensions import override + +from ._proxy import LazyProxy + + +class ResourcesProxy(LazyProxy[Any]): + """A proxy for the `retell.resources` module. + + This is used so that we can lazily import `retell.resources` only when + needed *and* so that users can just import `retell` and reference `retell.resources` + """ + + @override + def __load__(self) -> Any: + import importlib + + mod = importlib.import_module("retell.resources") + return mod + + +resources = ResourcesProxy().__as_proxied__() From 3f6509cf38b6f1f3cb73b0d8bb918edb54c383ba Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 14 May 2025 02:50:33 +0000 Subject: [PATCH 09/10] feat(api): api update --- .stats.yml | 4 ++-- src/retell/resources/agent.py | 28 +++++++++++++++++++++---- src/retell/types/agent_create_params.py | 5 ++++- src/retell/types/agent_response.py | 5 ++++- src/retell/types/agent_update_params.py | 5 ++++- tests/api_resources/test_agent.py | 4 ++++ 6 files changed, 42 insertions(+), 9 deletions(-) diff --git a/.stats.yml b/.stats.yml index aa7a7775..b4e37de6 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 34 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-f2c0410def02516b658b22cdf861e4a8ed6972ce5a8e4e1ff3f44ba2cc0caa22.yml -openapi_spec_hash: 923ea9d315f60b21e122c244e9a12527 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/retell%2Ftoddlzt-101be623bbd5eca19cb36dd5a5f75052d04ef89578dfd03bf675a5323e43ca8b.yml +openapi_spec_hash: 5f06a39218b958f8973595f616d1586a config_hash: 9d9a24bf8bb4553cbb30ce59eb910b2f diff --git a/src/retell/resources/agent.py b/src/retell/resources/agent.py index 76b15ee3..2f2f3dd0 100644 --- a/src/retell/resources/agent.py +++ b/src/retell/resources/agent.py @@ -64,6 +64,8 @@ def create( backchannel_words: Optional[List[str]] | NotGiven = NOT_GIVEN, begin_message_delay_ms: int | NotGiven = NOT_GIVEN, boosted_keywords: Optional[List[str]] | NotGiven = NOT_GIVEN, + denoising_mode: Literal["noise-cancellation", "noise-and-background-speech-cancellation"] + | NotGiven = NOT_GIVEN, enable_backchannel: bool | NotGiven = NOT_GIVEN, enable_transcription_formatting: bool | NotGiven = NOT_GIVEN, enable_voicemail_detection: bool | NotGiven = NOT_GIVEN, @@ -161,7 +163,7 @@ def create( agent_name: The name of the agent. Only used for your own reference. allow_user_dtmf: If set to true, DTMF input will be accepted and processed. If false, any DTMF - input will be ignored. + input will be ignored. Default to true. ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: @@ -212,6 +214,8 @@ def create( these words are more likely to get transcribed. Commonly used for names, brands, street, etc. + denoising_mode: If set, determines what denoising mode to use. Default to noise-cancellation. + enable_backchannel: Controls whether the agent would backchannel (agent interjects the speaker with phrases like "yeah", "uh-huh" to signify interest and engagement). Backchannel when enabled tends to show up more in longer user utterances. If not set, agent @@ -351,6 +355,7 @@ def create( "backchannel_words": backchannel_words, "begin_message_delay_ms": begin_message_delay_ms, "boosted_keywords": boosted_keywords, + "denoising_mode": denoising_mode, "enable_backchannel": enable_backchannel, "enable_transcription_formatting": enable_transcription_formatting, "enable_voicemail_detection": enable_voicemail_detection, @@ -446,6 +451,8 @@ def update( backchannel_words: Optional[List[str]] | NotGiven = NOT_GIVEN, begin_message_delay_ms: int | NotGiven = NOT_GIVEN, boosted_keywords: Optional[List[str]] | NotGiven = NOT_GIVEN, + denoising_mode: Literal["noise-cancellation", "noise-and-background-speech-cancellation"] + | NotGiven = NOT_GIVEN, enable_backchannel: bool | NotGiven = NOT_GIVEN, enable_transcription_formatting: bool | NotGiven = NOT_GIVEN, enable_voicemail_detection: bool | NotGiven = NOT_GIVEN, @@ -540,7 +547,7 @@ def update( agent_name: The name of the agent. Only used for your own reference. allow_user_dtmf: If set to true, DTMF input will be accepted and processed. If false, any DTMF - input will be ignored. + input will be ignored. Default to true. ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: @@ -591,6 +598,8 @@ def update( these words are more likely to get transcribed. Commonly used for names, brands, street, etc. + denoising_mode: If set, determines what denoising mode to use. Default to noise-cancellation. + enable_backchannel: Controls whether the agent would backchannel (agent interjects the speaker with phrases like "yeah", "uh-huh" to signify interest and engagement). Backchannel when enabled tends to show up more in longer user utterances. If not set, agent @@ -737,6 +746,7 @@ def update( "backchannel_words": backchannel_words, "begin_message_delay_ms": begin_message_delay_ms, "boosted_keywords": boosted_keywords, + "denoising_mode": denoising_mode, "enable_backchannel": enable_backchannel, "enable_transcription_formatting": enable_transcription_formatting, "enable_voicemail_detection": enable_voicemail_detection, @@ -905,6 +915,8 @@ async def create( backchannel_words: Optional[List[str]] | NotGiven = NOT_GIVEN, begin_message_delay_ms: int | NotGiven = NOT_GIVEN, boosted_keywords: Optional[List[str]] | NotGiven = NOT_GIVEN, + denoising_mode: Literal["noise-cancellation", "noise-and-background-speech-cancellation"] + | NotGiven = NOT_GIVEN, enable_backchannel: bool | NotGiven = NOT_GIVEN, enable_transcription_formatting: bool | NotGiven = NOT_GIVEN, enable_voicemail_detection: bool | NotGiven = NOT_GIVEN, @@ -1002,7 +1014,7 @@ async def create( agent_name: The name of the agent. Only used for your own reference. allow_user_dtmf: If set to true, DTMF input will be accepted and processed. If false, any DTMF - input will be ignored. + input will be ignored. Default to true. ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: @@ -1053,6 +1065,8 @@ async def create( these words are more likely to get transcribed. Commonly used for names, brands, street, etc. + denoising_mode: If set, determines what denoising mode to use. Default to noise-cancellation. + enable_backchannel: Controls whether the agent would backchannel (agent interjects the speaker with phrases like "yeah", "uh-huh" to signify interest and engagement). Backchannel when enabled tends to show up more in longer user utterances. If not set, agent @@ -1192,6 +1206,7 @@ async def create( "backchannel_words": backchannel_words, "begin_message_delay_ms": begin_message_delay_ms, "boosted_keywords": boosted_keywords, + "denoising_mode": denoising_mode, "enable_backchannel": enable_backchannel, "enable_transcription_formatting": enable_transcription_formatting, "enable_voicemail_detection": enable_voicemail_detection, @@ -1287,6 +1302,8 @@ async def update( backchannel_words: Optional[List[str]] | NotGiven = NOT_GIVEN, begin_message_delay_ms: int | NotGiven = NOT_GIVEN, boosted_keywords: Optional[List[str]] | NotGiven = NOT_GIVEN, + denoising_mode: Literal["noise-cancellation", "noise-and-background-speech-cancellation"] + | NotGiven = NOT_GIVEN, enable_backchannel: bool | NotGiven = NOT_GIVEN, enable_transcription_formatting: bool | NotGiven = NOT_GIVEN, enable_voicemail_detection: bool | NotGiven = NOT_GIVEN, @@ -1381,7 +1398,7 @@ async def update( agent_name: The name of the agent. Only used for your own reference. allow_user_dtmf: If set to true, DTMF input will be accepted and processed. If false, any DTMF - input will be ignored. + input will be ignored. Default to true. ambient_sound: If set, will add ambient environment sound to the call to make experience more realistic. Currently supports the following options: @@ -1432,6 +1449,8 @@ async def update( these words are more likely to get transcribed. Commonly used for names, brands, street, etc. + denoising_mode: If set, determines what denoising mode to use. Default to noise-cancellation. + enable_backchannel: Controls whether the agent would backchannel (agent interjects the speaker with phrases like "yeah", "uh-huh" to signify interest and engagement). Backchannel when enabled tends to show up more in longer user utterances. If not set, agent @@ -1578,6 +1597,7 @@ async def update( "backchannel_words": backchannel_words, "begin_message_delay_ms": begin_message_delay_ms, "boosted_keywords": boosted_keywords, + "denoising_mode": denoising_mode, "enable_backchannel": enable_backchannel, "enable_transcription_formatting": enable_transcription_formatting, "enable_voicemail_detection": enable_voicemail_detection, diff --git a/src/retell/types/agent_create_params.py b/src/retell/types/agent_create_params.py index c8114851..9e6d980b 100644 --- a/src/retell/types/agent_create_params.py +++ b/src/retell/types/agent_create_params.py @@ -41,7 +41,7 @@ class AgentCreateParams(TypedDict, total=False): allow_user_dtmf: bool """If set to true, DTMF input will be accepted and processed. - If false, any DTMF input will be ignored. + If false, any DTMF input will be ignored. Default to true. """ ambient_sound: Optional[ @@ -114,6 +114,9 @@ class AgentCreateParams(TypedDict, total=False): street, etc. """ + denoising_mode: Literal["noise-cancellation", "noise-and-background-speech-cancellation"] + """If set, determines what denoising mode to use. Default to noise-cancellation.""" + enable_backchannel: bool """ Controls whether the agent would backchannel (agent interjects the speaker with diff --git a/src/retell/types/agent_response.py b/src/retell/types/agent_response.py index bd03312f..e79b69db 100644 --- a/src/retell/types/agent_response.py +++ b/src/retell/types/agent_response.py @@ -178,7 +178,7 @@ class AgentResponse(BaseModel): allow_user_dtmf: Optional[bool] = None """If set to true, DTMF input will be accepted and processed. - If false, any DTMF input will be ignored. + If false, any DTMF input will be ignored. Default to true. """ ambient_sound: Optional[ @@ -251,6 +251,9 @@ class AgentResponse(BaseModel): street, etc. """ + denoising_mode: Optional[Literal["noise-cancellation", "noise-and-background-speech-cancellation"]] = None + """If set, determines what denoising mode to use. Default to noise-cancellation.""" + enable_backchannel: Optional[bool] = None """ Controls whether the agent would backchannel (agent interjects the speaker with diff --git a/src/retell/types/agent_update_params.py b/src/retell/types/agent_update_params.py index b86d4302..17d44bdf 100644 --- a/src/retell/types/agent_update_params.py +++ b/src/retell/types/agent_update_params.py @@ -33,7 +33,7 @@ class AgentUpdateParams(TypedDict, total=False): allow_user_dtmf: bool """If set to true, DTMF input will be accepted and processed. - If false, any DTMF input will be ignored. + If false, any DTMF input will be ignored. Default to true. """ ambient_sound: Optional[ @@ -106,6 +106,9 @@ class AgentUpdateParams(TypedDict, total=False): street, etc. """ + denoising_mode: Literal["noise-cancellation", "noise-and-background-speech-cancellation"] + """If set, determines what denoising mode to use. Default to noise-cancellation.""" + enable_backchannel: bool """ Controls whether the agent would backchannel (agent interjects the speaker with diff --git a/tests/api_resources/test_agent.py b/tests/api_resources/test_agent.py index 29606c9e..b8cb7c7b 100644 --- a/tests/api_resources/test_agent.py +++ b/tests/api_resources/test_agent.py @@ -49,6 +49,7 @@ def test_method_create_with_all_params(self, client: Retell) -> None: backchannel_words=["yeah", "uh-huh"], begin_message_delay_ms=1000, boosted_keywords=["retell", "kroger"], + denoising_mode="noise-cancellation", enable_backchannel=True, enable_transcription_formatting=True, enable_voicemail_detection=True, @@ -195,6 +196,7 @@ def test_method_update_with_all_params(self, client: Retell) -> None: backchannel_words=["yeah", "uh-huh"], begin_message_delay_ms=1000, boosted_keywords=["retell", "kroger"], + denoising_mode="noise-cancellation", enable_backchannel=True, enable_transcription_formatting=True, enable_voicemail_detection=True, @@ -413,6 +415,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncRetell) -> backchannel_words=["yeah", "uh-huh"], begin_message_delay_ms=1000, boosted_keywords=["retell", "kroger"], + denoising_mode="noise-cancellation", enable_backchannel=True, enable_transcription_formatting=True, enable_voicemail_detection=True, @@ -559,6 +562,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncRetell) -> backchannel_words=["yeah", "uh-huh"], begin_message_delay_ms=1000, boosted_keywords=["retell", "kroger"], + denoising_mode="noise-cancellation", enable_backchannel=True, enable_transcription_formatting=True, enable_voicemail_detection=True, From f2b5b1e4f4a60d2755d26d15914d95963541a40a Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 14 May 2025 02:50:57 +0000 Subject: [PATCH 10/10] release: 4.29.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 24 ++++++++++++++++++++++++ pyproject.toml | 2 +- src/retell/_version.py | 2 +- 4 files changed, 27 insertions(+), 3 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index cd95c250..1b159305 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "4.28.0" + ".": "4.29.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 1705d6da..43a26893 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,29 @@ # Changelog +## 4.29.0 (2025-05-14) + +Full Changelog: [v4.28.0...v4.29.0](https://github.com/RetellAI/retell-python-sdk/compare/v4.28.0...v4.29.0) + +### Features + +* **api:** api update ([3f6509c](https://github.com/RetellAI/retell-python-sdk/commit/3f6509cf38b6f1f3cb73b0d8bb918edb54c383ba)) +* **api:** api update ([dc02872](https://github.com/RetellAI/retell-python-sdk/commit/dc028721305eec0c8c6126ac795011b07c6d82cd)) +* **api:** api update ([4e2edb1](https://github.com/RetellAI/retell-python-sdk/commit/4e2edb1f2d4b9aa1116e31d546b005f1d03b1b48)) +* **api:** api update ([3cb87df](https://github.com/RetellAI/retell-python-sdk/commit/3cb87df96dfce683feaa0a4a3b8d7285da07678b)) +* **api:** api update ([fb974a7](https://github.com/RetellAI/retell-python-sdk/commit/fb974a7a9f4367f3146443b7d484997791f40639)) +* **api:** api update ([84bc6f9](https://github.com/RetellAI/retell-python-sdk/commit/84bc6f9064fe0272f3e71a0963ae7f17c92672ff)) +* **api:** api update ([f4a83f3](https://github.com/RetellAI/retell-python-sdk/commit/f4a83f3ec4a359547cc08917fc2277b8b4663fb6)) + + +### Bug Fixes + +* **package:** support direct resource imports ([94bf9a5](https://github.com/RetellAI/retell-python-sdk/commit/94bf9a5e4e91f44902d777683498b82bdba1a691)) + + +### Chores + +* **internal:** avoid errors for isinstance checks on proxies ([ae0efc9](https://github.com/RetellAI/retell-python-sdk/commit/ae0efc9c584268ba9bfd7b5a3681145a97322133)) + ## 4.28.0 (2025-04-28) Full Changelog: [v4.27.0...v4.28.0](https://github.com/RetellAI/retell-python-sdk/compare/v4.27.0...v4.28.0) diff --git a/pyproject.toml b/pyproject.toml index ba9ae3cd..ed73b4f2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "retell-sdk" -version = "4.28.0" +version = "4.29.0" description = "The official Python library for the retell API" dynamic = ["readme"] license = "Apache-2.0" diff --git a/src/retell/_version.py b/src/retell/_version.py index 1b2b24aa..6b864715 100644 --- a/src/retell/_version.py +++ b/src/retell/_version.py @@ -1,4 +1,4 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. __title__ = "retell" -__version__ = "4.28.0" # x-release-please-version +__version__ = "4.29.0" # x-release-please-version