Storm LogoStorm Docs
Getting Started
Guides
Dialer
Quick Start
PlacementExample
Messenger
REST API

Dialer Quick Start

Placement

The dialer requires two <div> tags in your HTML. Placement is up to you.

1<!-- main dialer bar (typically spans the width of the screen) -->
2<div id="storm-dialer-bar"></div>
3
4<!-- mini click-to-call and remaining time widget -->
5<div id="storm-dialer-mini"></div>

Example

1const contacts = [{
2 contactId: '123',
3 numbers: ['8444545111', '5555554321'],
4 name: 'George Costanza',
5 address: '2880 Broadway',
6 city: 'New York',
7}];
8
9// start a dialing campaign
10Storm.startCampaign({ contacts }).then(() =>
11 console.log('Dialing campaign started');
12);
13
14// observe when calls start
15Storm.onCallStarted(({ number }) => {
16 console.log(`Dialing ${number}...`);
17});
18
19// observe when calls end
20Storm.onCallEnded(({ number, duration }) => {
21 console.log(`Call to ${number} ended after ${duration} seconds`);
22});