Call Ended

The call.ended event is delivered whenever a call is completed between a Surge number you own and another phone number.

Common Use Cases

  • Display calls in a log in your system
  • Trigger follow-up actions
  • Update customer analytics

Payload Structure

account_id
stringRequired

The ID of the account that received the message

type
stringRequired

Always call.ended for this event

data
call
id
string

The unique identifier for the call

contact
contact
id
string

The unique identifier for the contact

first_name
string

The first name of the contact, if it is known

last_name
string

The last name of the contact, if it is known

phone_number
string

The contact’s phone number in E.164 format

duration
integer

The duration of the call in seconds

initiated_at
string

ISO 8601 timestamp of when the call began

status
enum

The status of the call. Can be one of busy, canceled, completed, failed, missed, or no_answer