dograh/api/routes
Abhishek d8cd34e8d2
feat: add vici dial controls from UI (#563)
* ViciDial Working

* feat(telephony): add FreeSWITCH provider to upstream-PBX seam

Generalize the upstream-PBX capture and control paths to dispatch by
provider. FreeSWITCH bridges in with X-PBX-* headers and is driven over
the Event Socket Library (uuid_kill / uuid_transfer) by the channel UUID,
alongside the existing VICIdial ra_call_control path.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* add vici specific configs

* feat(telephony): env-based VICIdial config + address3 post-call routing

Move VICIdial agent/non-agent API and FreeSWITCH ESL connection settings
out of hardcoded POC values into environment variables so the same image
works against a PBX on another server.

Add VICIdial update_lead forwarding: X-VICI-UPDATE-LEAD_* extracted
variables are mapped to lead columns and pushed via the non-agent API
before a transfer, with reserved API-control params dropped.

Add hardcoded address3 disposition routing (Y/N -> in-group transfer,
else hang up) and a synchronous final variable extraction so the
transfer path sees the freshest conversation state. Skip upstream_pbx
capture on non-PJSIP channels to avoid Asterisk 500s.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* chore: run formatter

* feat: make vici configurable from UI

* chore: clean up PR

* fix: incorporate review comments

* chore: incorporate review comments

* chore: generate client

* chore: incporporate review comments

* chore: incorporate review comments

---------

Co-authored-by: Dograh POC <payment@dograh.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 21:57:34 +05:30
..
__init__.py Initial Commit 🚀 🚀 2025-09-09 14:37:32 +05:30
agent_stream.py fix: scope workflow run to org rather than user 2026-07-10 16:52:43 +05:30
auth.py feat(auth): gate OSS signup behind ENABLE_SIGNUP flag (#514) 2026-07-13 14:08:25 +05:30
campaign.py fix(api): validate pagination bounds on run-list endpoints (#553) (#554) 2026-07-18 16:29:28 +05:30
credentials.py feat: refactor node spec and add mcp tools (#244) 2026-04-21 07:56:16 +05:30
folder.py feat: add google stt and tts. add folders to organize agents 2026-05-22 14:36:50 +05:30
knowledge_base.py fix: fix org scoped access for resources (#517) 2026-07-09 23:04:33 +05:30
main.py feat(auth): gate OSS signup behind ENABLE_SIGNUP flag (#514) 2026-07-13 14:08:25 +05:30
node_types.py feat: refactor node spec and add mcp tools (#244) 2026-04-21 07:56:16 +05:30
organization.py feat: add vici dial controls from UI (#563) 2026-07-20 21:57:34 +05:30
organization_usage.py fix: fix org scoped access for resources (#517) 2026-07-09 23:04:33 +05:30
public_agent.py fix: scope workflow run to org rather than user 2026-07-10 16:52:43 +05:30
public_download.py feat: persist split user and bot audio 2026-06-16 15:19:49 +05:30
public_embed.py fix: fix org scoped access for resources (#517) 2026-07-09 23:04:33 +05:30
reports.py Initial Commit 🚀 🚀 2025-09-09 14:37:32 +05:30
s3_signed_url.py feat: persist split user and bot audio 2026-06-16 15:19:49 +05:30
service_keys.py Initial Commit 🚀 🚀 2025-09-09 14:37:32 +05:30
superuser.py fix: fix superadmin impersonation 2026-07-11 15:51:36 +05:30
telephony.py fix: scope workflow run to org rather than user 2026-07-10 16:52:43 +05:30
tool.py feat: add vici dial controls from UI (#563) 2026-07-20 21:57:34 +05:30
turn_credentials.py feat: add coturn configurations (#143) 2026-02-03 13:52:50 +05:30
user.py fix: fix org scoped access for resources (#517) 2026-07-09 23:04:33 +05:30
webrtc_signaling.py fix: fix org scoped access for resources (#517) 2026-07-09 23:04:33 +05:30
workflow.py feat: add vici dial controls from UI (#563) 2026-07-20 21:57:34 +05:30
workflow_embed.py feat: add posthog events (#231) 2026-04-10 17:52:21 +05:30
workflow_recording.py feat: refactor node spec and add mcp tools (#244) 2026-04-21 07:56:16 +05:30
workflow_text_chat.py fix: fix org scoped access for resources (#517) 2026-07-09 23:04:33 +05:30