window.postMessage.
This is the same mechanism behind the HubSpot and Salesforce panels, opened up so any product can use it.
Access is granted per website. Email [email protected] with the domains you want to embed from, and we activate them. Until a domain is activated, the iframe shows a “dialer not activated” screen.
What you can do
- Add a click-to-call button anywhere in your app that opens the Allo dialer with a number prefilled
- React to calls in your own interface: log them, open the matching record, start a timer
- Keep your users in one tab instead of switching to a separate calling app
How to embed the dialer
1
Add the iframe
allow="microphone; autoplay" attribute is required. Calling needs microphone access, and the browser only grants it to an iframe whose parent page allows it. If your page is itself inside another iframe, every ancestor has to pass the permission down.2
Sign in
Your teammate signs in to Allo inside the iframe on first use, or reuses an existing
web.withallo.com session. The dialer emits a login event once a user is authenticated.3
Listen for events
Add a
message listener to react to calls (see below).4
Send a number to dial
Post a
dial command to prefill the keypad from your own click-to-call button (see below).Listen for events from the dialer
Every message from the dialer has the shape{ source: "allo-dialer", type, payload }.
Events the dialer emits
Send commands to the dialer
Post a{ source: "allo-host", type, payload } message to the iframe. Always target https://web.withallo.com, never *.
Commands the dialer accepts
dial prefills the keypad only, it never starts a call on its own. The browser requires a click from your teammate to unlock the microphone, so the call starts when they press the call button.Example
Security
- Give the iframe at least about 600px of height so the full keypad and in-call screen fit. The panel is a fixed width of about 376px.
- The dialer only accepts commands from activated domains, and only posts events back to your verified origin.
event.originis set by the browser and cannot be forged. Always check it on your side, as shown in the examples.
Troubleshooting
The iframe shows a 'dialer not activated' screen
The iframe shows a 'dialer not activated' screen
Your domain is not activated yet. Email [email protected] with the exact origins you embed from (for example
https://app.yourcompany.com) and we activate them.Calls fail or the microphone does not work
Calls fail or the microphone does not work
Make sure the iframe has
allow="microphone; autoplay". If your page is itself nested inside another iframe, every parent frame has to pass the same permission down.I sent a dial command but nothing happens
I sent a dial command but nothing happens
Check that you target
https://web.withallo.com (not *) and that the message shape is { source: "allo-host", type: "dial", payload: { phone_number } }. Send an init first if you added your listener after the iframe loaded.I am not receiving events
I am not receiving events
Confirm your
message listener checks event.origin === "https://web.withallo.com" and source === "allo-dialer". Events only flow once your domain is activated.Need help?
Activate your domain
Ask the Allo team to activate your embedding domains
Webhooks
Get server-side notifications for calls and messages