mirror of
https://github.com/dograh-hq/dograh.git
synced 2026-06-07 07:55:16 +02:00
fix: fix inbound for Cloudonix with softphone
This commit is contained in:
parent
c4da6d6537
commit
e695436fb3
1 changed files with 5 additions and 1 deletions
|
|
@ -699,12 +699,16 @@ class CloudonixProvider(TelephonyProvider):
|
|||
if "Twilio-AccountSid" in trunk_headers:
|
||||
underlying_provider = "twilio"
|
||||
|
||||
direction = webhook_data.get("Direction", "inbound").lower()
|
||||
if direction in {"inbound", "subscriber"}:
|
||||
direction = "inbound"
|
||||
|
||||
return NormalizedInboundData(
|
||||
provider=CloudonixProvider.PROVIDER_NAME,
|
||||
call_id=call_id,
|
||||
from_number=webhook_data.get("From", ""),
|
||||
to_number=webhook_data.get("To", ""),
|
||||
direction=webhook_data.get("Direction", "inbound").lower(),
|
||||
direction=direction,
|
||||
call_status=webhook_data.get("CallStatus", "in-progress"),
|
||||
account_id=account_id,
|
||||
from_country=webhook_data.get("FromCountry"),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue