Send a phone call from AI agent, in an API call. Or, directly call the bot from the configured phone number!
Python
quality: Validate phone numbers in the conf
Clémence Lesnéaa2af2ece2ea
diff --git a/helpers/config_models/communication_service.py b/helpers/config_models/communication_service.pyindex 347d36c..aeab3ec 100644--- a/helpers/config_models/communication_service.py+++ b/helpers/config_models/communication_service.py@@ -1,8 +1,13 @@from pydantic import BaseModel, SecretStr+from pydantic_extra_types.phone_numbers import PhoneNumber+++# E164 is standard accross all Microsoft services+PhoneNumber.phone_format = "E164"class CommunicationServiceModel(BaseModel):access_key: SecretStrendpoint: str- phone_number: str+ phone_number: PhoneNumbervoice_name: strdiff --git a/helpers/config_models/twilio.py b/helpers/config_models/twilio.pyindex 21bc044..0629a84 100644--- a/helpers/config_models/twilio.py+++ b/helpers/config_models/twilio.py@@ -1,7 +1,12 @@from pydantic import BaseModel, SecretStr+from pydantic_extra_types.phone_numbers import PhoneNumber+++# E164 is standard accross all Microsoft services+PhoneNumber.phone_format = "E164"class TwilioModel(BaseModel):account_sid: strauth_token: SecretStr- phone_number: str+ phone_number: PhoneNumberdiff --git a/helpers/config_models/workflow.py b/helpers/config_models/workflow.pyindex ae9fdb3..961a9e4 100644--- a/helpers/config_models/workflow.py+++ b/helpers/config_models/workflow.py@@ -1,8 +1,13 @@from pydantic import BaseModel+from pydantic_extra_types.phone_numbers import PhoneNumber+++# E164 is standard accross all Microsoft services+PhoneNumber.phone_format = "E164"class WorkflowModel(BaseModel):- agent_phone_number: str+ agent_phone_number: PhoneNumberbot_company: strbot_name: strconversation_lang: strdiff --git a/requirements.txt b/requirements.txtindex 8931330..8a1c672 100644--- a/requirements.txt+++ b/requirements.txt@@ -5,6 +5,8 @@ azure-identity==1.15.0azure-mgmt-eventgrid==10.2.0fastapi==0.108.0openai==1.7.0+phonenumbers==8.13.27+pydantic-extra-types==2.4.0python-dotenv==1.0.0pyyaml==6.0.1twilio==8.11.0