Skip to content

Commit

Permalink
transports(daily): move pinlessCallUpdate to public api
Browse files Browse the repository at this point in the history
  • Loading branch information
aconchillo committed Jun 5, 2024
1 parent 7b708a2 commit 135654a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/pipecat/transports/services/daily.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ class DailyTranscriptionSettings(BaseModel):


class DailyParams(TransportParams):
api_url: str = "https://api.daily.co"
api_url: str = "https://api.daily.co/v1"
api_key: str = ""
dialin_settings: DailyDialinSettings | None = None
transcription_enabled: bool = False
Expand Down Expand Up @@ -769,7 +769,7 @@ async def _handle_dialin_ready(self, sip_endpoint: str):
async with aiohttp.ClientSession() as session:
headers = {
"Authorization": f"Bearer {self._params.api_key}",
"Content-Type": "application/x-www-form-urlencoded"
"Content-Type": "application/json"
}
data = {
"callId": self._params.dialin_settings.call_id,
Expand All @@ -780,7 +780,7 @@ async def _handle_dialin_ready(self, sip_endpoint: str):
url = f"{self._params.api_url}/dialin/pinlessCallUpdate"

try:
async with session.post(url, headers=headers, data=data, timeout=10) as r:
async with session.post(url, headers=headers, json=data, timeout=10) as r:
if r.status != 200:
text = await r.text()
logger.error(
Expand Down

0 comments on commit 135654a

Please sign in to comment.