Skip to content

Commit

Permalink
Release 0.0.21
Browse files Browse the repository at this point in the history
  • Loading branch information
fern-api[bot] committed Sep 8, 2023
1 parent 2a9548a commit 2e511e0
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "vocode-api"
version = "0.0.20"
version = "0.0.21"
description = ""
readme = "README.md"
authors = []
Expand Down
2 changes: 1 addition & 1 deletion src/vocode/core/client_wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ def get_headers(self) -> typing.Dict[str, str]:
headers: typing.Dict[str, str] = {
"X-Fern-Language": "Python",
"X-Fern-SDK-Name": "vocode-api",
"X-Fern-SDK-Version": "0.0.20",
"X-Fern-SDK-Version": "0.0.21",
}
headers["Authorization"] = f"Bearer {self._get_token()}"
return headers
Expand Down
10 changes: 10 additions & 0 deletions src/vocode/resources/calls/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ def create_call(
to_number: str,
agent: CreateCallRequestAgent,
on_machine_answer: typing.Optional[CreateCallRequestOnMachineAnswer] = OMIT,
hipaa_compliant: typing.Optional[bool] = OMIT,
) -> Call:
"""
Parameters:
Expand All @@ -110,10 +111,14 @@ def create_call(
- agent: CreateCallRequestAgent.
- on_machine_answer: typing.Optional[CreateCallRequestOnMachineAnswer].
- hipaa_compliant: typing.Optional[bool].
"""
_request: typing.Dict[str, typing.Any] = {"from_number": from_number, "to_number": to_number, "agent": agent}
if on_machine_answer is not OMIT:
_request["on_machine_answer"] = on_machine_answer
if hipaa_compliant is not OMIT:
_request["hipaa_compliant"] = hipaa_compliant
_response = self._client_wrapper.httpx_client.request(
"POST",
urllib.parse.urljoin(f"{self._client_wrapper.get_base_url()}/", "v1/calls/create"),
Expand Down Expand Up @@ -233,6 +238,7 @@ async def create_call(
to_number: str,
agent: CreateCallRequestAgent,
on_machine_answer: typing.Optional[CreateCallRequestOnMachineAnswer] = OMIT,
hipaa_compliant: typing.Optional[bool] = OMIT,
) -> Call:
"""
Parameters:
Expand All @@ -243,10 +249,14 @@ async def create_call(
- agent: CreateCallRequestAgent.
- on_machine_answer: typing.Optional[CreateCallRequestOnMachineAnswer].
- hipaa_compliant: typing.Optional[bool].
"""
_request: typing.Dict[str, typing.Any] = {"from_number": from_number, "to_number": to_number, "agent": agent}
if on_machine_answer is not OMIT:
_request["on_machine_answer"] = on_machine_answer
if hipaa_compliant is not OMIT:
_request["hipaa_compliant"] = hipaa_compliant
_response = await self._client_wrapper.httpx_client.request(
"POST",
urllib.parse.urljoin(f"{self._client_wrapper.get_base_url()}/", "v1/calls/create"),
Expand Down
1 change: 1 addition & 0 deletions src/vocode/types/call.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ class Call(pydantic.BaseModel):
agent_phone_number: str
start_time: typing.Optional[dt.datetime]
end_time: typing.Optional[dt.datetime]
hipaa_compliant: typing.Optional[bool]

def json(self, **kwargs: typing.Any) -> str:
kwargs_with_defaults: typing.Any = {"by_alias": True, "exclude_unset": True, **kwargs}
Expand Down
1 change: 1 addition & 0 deletions src/vocode/types/normalized_call.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ class NormalizedCall(pydantic.BaseModel):
agent_phone_number: str
start_time: typing.Optional[dt.datetime]
end_time: typing.Optional[dt.datetime]
hipaa_compliant: typing.Optional[bool]

def json(self, **kwargs: typing.Any) -> str:
kwargs_with_defaults: typing.Any = {"by_alias": True, "exclude_unset": True, **kwargs}
Expand Down

0 comments on commit 2e511e0

Please sign in to comment.