Vetro Call Integration
LiveRetell AI answers the phone, this service turns the conversation into a Customer + Job in Omega EDI, and every call is durably recorded in Supabase.
Open leads dashboard →Endpoints
POST
/api/retell-to-omegaMain inbound webhook from Retell. Verifies signature, persists lead to Supabase, then creates Customer + Job in Omega EDI.
GET
/api/test-omegaSmoke test — creates an "APITest DoNotBook" customer in Omega so you can verify credentials without a live call.
POST
/api/omega-webhookReverse webhook — Omega → this app. Receives job.status_changed, appointment.scheduled, etc. for bidirectional sync.
How it works
- Customer calls the Vetro Auto Glass number.
- Retell AI answers, runs the scripted conversation, and extracts 14 structured fields (name, vehicle, insurance, glass issue, urgency…).
- When the call ends, Retell fires a signed `call_analyzed` webhook at `/api/retell-to-omega`.
- This app verifies the HMAC signature, inserts the full lead into Supabase (source of truth), and audits the raw event.
- The app looks up the customer in Omega by phone, creates one if missing, then creates a Job with vehicle, insurance, transcript, and preferred time.
- The lead row is updated with Omega IDs + sync status. Dispatch sees the new job in Omega within seconds.