Event Tasks

Overview

An event task waits for something to happen on your hotline and then does something about it. A caller leaves a message and you get an email with the recording attached. A transcription finishes and the text is emailed on. A conference recording is saved into an audio player automatically. Unlike Scheduled Tasks, which run on a clock, these run the moment the event occurs.

Find them in the sidebar under Advanced → Tasks. (The Advanced group is collapsed by default; click it to open.)


How It Works

Every task is one sentence made of three parts:

  1. A source — the audio player, forward call, conference, or merchant being watched.
  2. An event — what has to happen on it.
  3. An action — what to do when it happens.

The actions on offer change with the source and the event, so you can only build combinations that make sense.


Task Information


Trigger Configuration


Action Configuration

Action to Perform is required, and the list depends on the source and event you picked:

Source Event Actions available
Library new library Recording send email with recording · transcript · send to a URL
Message box new message recorded (saved or not) send email with recording · send to a URL
Library transcription completed send email with transcript · send to a URL
Transfer to Number started new call send email · send to a URL
Conference new conference recording send email with recording · create a library recording · send to a URL
Merchant new payment received credit callmagic balance · send to a URL

What each one does:

Action Options

These appear only for the actions that need them:


Sending to a URL

The send to a URL action turns any event into an HTTP request to a system of yours. You build the request the way you would in Postman or Twilio Studio, and placeholders fill in the details of the event.

Request

Authentication

None, a Bearer token, Basic (enter user:password) or an API key header where you name the header, for example X-API-KEY. The value is stored encrypted and never shown again in full. Do not put credentials into the URL.

Headers

Add as many as you need, for example Accept: application/json. Values accept placeholders.

Body

Two ways, pick one:

GET requests send no body; put what you need into the URL.

Placeholders

Write them as {{name}}. The Placeholders panel on the task lists exactly what the chosen event offers; click one to copy it. Every event has:

Placeholder Meaning
{{event}} / {{event_at}} The event name and when it happened (UTC)
{{hotline_name}} / {{account_uuid}} / {{task_name}} Which hotline and task sent it; the account ID is the one on your Settings page
{{caller_number}} The caller's number, digits only
{{caller_name}} / {{contact_id}} / {{contact_email}} / {{contact_labels}} Filled when the number matches one of your contacts

Per event:

Event Extra placeholders
new library Recording recording_id, recording_name, recording_url, duration, library_id, library_name, recorded_at
new message recorded recording_url, duration, recorded_at, box_id, box_name, saved (true/false), plus recording_id, library_id, library_name when saved
transcription completed the above plus transcript, summary, keywords, word_count, transcribed_at
new conference recording recording_id, recording_url, duration, conference_id, conference_name, call_sid, recorded_at
started new call forward_id, forward_name, dialed_number
new payment received amount, currency, card_brand, card_last_four, confirmation_code, charge_id, call_sid, paid_at

Delivery

The task list shows the Last run: ok or failed, the HTTP status, and when. Hover for the error. Open the task and switch to the Runs tab for the full history: every attempt with its status, HTTP code, how long it took, the request that was sent (header names only, never your secrets), the response, and the event values it had. Runs are kept for 90 days, at most 200 per task. On the task's edit page, Send test request sends one request with sample values so you can see what your system receives before the first real event; test runs are marked as such.


Tasks the builder creates for you

Some tasks appear that you never created. That is normal, and it is the message box doing it for you.

When you set Email each new message to on a Message box (in the ⚙ panel on My Hotline, or on the Message Box page), the app creates a task behind the scenes:

If you change the addresses, that task is updated. If you clear them, it is deleted. If you point the message box at a different audio player, the task moves with it. You can open it in this list and adjust it like any other task, but the simplest place to change it stays the message box itself.


Managing tasks

The list shows Task Name (with the name of the source underneath), Trigger Source, Trigger Event, and Action, newest first.

It can be filtered by:

Created, Last Updated, and Deleted are hidden columns you can switch on from the column menu.

Deleting a task is a soft delete, so nothing is lost outright. The bulk actions menu holds Delete, Force delete, and Restore. Unlike Scheduled Tasks, this list has no Trashed filter, so a deleted task drops out of view; ask support if you need one brought back.


Common Patterns


Tips