Skip to main content

Webhook Overview

access911 integrates with ElevenLabs AI voice agents to process real emergency calls. The webhook system captures call transcripts, extracts emergency metadata, and stores the information in AWS services for real-time dashboard updates.

ElevenLabs Configuration

Voice Agent Setup

  1. Create ElevenLabs Account: Sign up at ElevenLabs
  2. Create AI Voice Agent: Set up a voice agent for emergency call handling
  3. Configure Data Collection: Set up fields to collect emergency metadata
  4. Set Webhook URL: Point webhook to DispatchAI endpoint

Data Collection Fields

Configure your ElevenLabs agent to collect these fields during calls:

Webhook Endpoint

Endpoint URL

Webhook Configuration

Set up your ElevenLabs agent webhook with these settings:
  • Event Type: post_call_transcription
  • Method: POST
  • Content-Type: application/json
  • Secret: Optional webhook secret for verification

Webhook Payload

Incoming Webhook Structure

Webhook Processing

The webhook handler processes incoming calls:

Data Storage

DynamoDB Storage

Emergency calls are stored in DynamoDB with this structure:

S3 Storage

Full webhook payloads are stored in S3 for audit and analysis:

Security

Webhook Signature Verification

Optional webhook signature verification for security:

Environment Variables

Configure these environment variables:

Error Handling

Webhook Error Responses

The webhook handler returns appropriate HTTP status codes:
  • 200 OK: Webhook processed successfully
  • 400 Bad Request: Invalid webhook payload
  • 401 Unauthorized: Invalid webhook signature
  • 500 Internal Server Error: Processing error

Error Logging

Comprehensive error logging for debugging:

Testing

Local Testing

Test webhook integration locally:

Webhook Validation

Validate webhook configuration:

Monitoring

Webhook Metrics

Monitor webhook performance:
  • Incoming Requests: Number of webhook requests received
  • Processing Time: Time to process each webhook
  • Success Rate: Percentage of successfully processed webhooks
  • Error Rate: Number of failed webhook processing attempts

Dashboard Updates

Webhook processing triggers real-time dashboard updates:
  1. Call Appears: New emergency call appears on map
  2. Status Updates: Call status updates in real-time
  3. Queue Updates: Call queue refreshes automatically
  4. History Updates: Call history updates immediately

Best Practices

Always use webhook signature verification in production environments.
Process webhooks quickly to ensure real-time dashboard updates.
Store both summarized and full payload data for audit trails.
Monitor webhook performance and error rates continuously.

Troubleshooting

Common Issues

Check ElevenLabs webhook configuration and endpoint URL.
Verify AWS credentials and DynamoDB/S3 permissions.
Check Lambda function timeout and memory configuration.
Verify webhook secret configuration and signature format.
Production Use: Ensure proper security configuration and monitoring before deploying to production emergency response systems.