Last updated 2026-09-14
Snippet
<script>
window.AllAtOnceConfig = {
workspaceHandle: "yourbusiness",
mode: "bubble", // "bubble" or "inline" (full-page)
position: "bottom-right", // "bottom-right" or "bottom-left"
theme: "auto", // "auto", "light", "dark"
containerId: null, // only for mode: "inline" — id of the container div
pageOfferId: null, // optional canonical offering id for this page
pageOfferPrompt: null, // optional contextual launcher/welcome prompt (max 80 chars)
offsetX: 20, // optional distance from the side (8–160px)
offsetY: 20, // optional distance from the bottom (8–160px)
};
</script>
<script src="https://allatonce.app/widget.js" defer></script>Config fields
| Field | Required | Default | Notes | |---|---|---|---| | workspaceHandle | yes | — | Your workspace handle (no @) | | mode | no | bubble | bubble or inline | | position | no | bottom-right | bottom-right or bottom-left | | theme | no | auto | auto, light, or dark | | containerId | only if mode=inline | allatonce-chat | DOM id of the container <div> | | pageOfferId | no | — | Exact published offering to preload on this page; prefer the marker generated by Studio | | pageOfferPrompt | no | — | Contextual launcher prompt; without pageOfferId, it also becomes the passive welcome for multi-offer pages; maximum 80 characters | | offsetX | no | 20 | Side spacing in pixels, clamped between 8 and 160; safe-area insets are added automatically | | offsetY | no | 20 | Bottom spacing in pixels, clamped between 8 and 160; safe-area insets are added automatically |
The widget is configured via window.AllAtOnceConfig (set BEFORE the script tag).The older data-* attributes on the script tag are no longer supported — copy the snippetstraight from Integrations → Website assistant to stay current.
>
Greeting copy, theme color, and the launcher icon are configured server-side
in Integrations → Website assistant and propagated automatically — there is no
client-side welcomeMessage option.Analytics events
Pro and Team owners can enable the conversion bridge in Integrations → Website assistant. Configuration is remote, so the installed snippet stays unchanged. Each enabled event is pushed to <code>window.dataLayer</code> and dispatched as an <code>allatonce:analytics</code> CustomEvent.
| Event | Meaning | Recommended use | |---|---|---| | <code>allatonce_request_saved</code> | Request durably saved by the server | Primary conversion | | <code>allatonce_booking_confirmed</code> | Booking confirmed by the server | Primary conversion | | <code>allatonce_assistant_opened</code> | Visitor opened the assistant | Funnel diagnostic | | <code>allatonce_intake_started</code> | Visitor interacted with an intake | Funnel diagnostic | | <code>allatonce_intake_submitted</code> | Browser submitted an intake attempt | Funnel diagnostic |
The versioned payload may include an opaque event ID, offering ID, surface, and entry source. It never includes visitor contact details, messages, answers, page URLs, or campaign parameters. Configure those page-level variables and consent rules inside your own tag manager.
Contextual offering page marker
Studio generates this value with the real opaque offering id. Place it only on the matching page:
<span hidden
data-allatonce-page-offer="offer_123"
data-allatonce-page-prompt="Check availability for this service"></span>The id is always revalidated by the public profile and availability services. An invalid, draft, private, expired, or plan-excluded offering exposes no offering facts. Do not infer ids from page text.
Offering Action embed
After installing the Website assistant script once, place the marker generated by an offering's Share & embed dialog where the action should appear:
<div
data-allatonce-action="offer_123"
data-allatonce-action-label="Book a consultation"></div>The script validates the current host against the workspace allowlist before it mounts. The focused iframe reuses the canonical offering projection and public action flow; the marker does not define availability, fields, pricing, payment, or booking behavior. Multiple offering Action embeds may appear on one page and may coexist with the floating assistant. Rendering and availability prefetch do not create a conversation; the first real visitor interaction does.
Public API
loads the exact server-validated offering.
active FAQ answer without creating a conversation. The canonical FAQ id is validated against public workspace data; a miss navigates to fallbackUrl.
AllAtOnce.open()opens the assistant.AllAtOnce.close()closes the floating assistant.AllAtOnce.openOffering(offerId)opens or scrolls to the assistant andAllAtOnce.openQuestion(question, { faqId, fallbackUrl })opens one exact
Links generated by Share & embed include data-allatonce-offer. Ordinary left-clicks open them inside an installed widget; modified clicks and sites where the widget is unavailable retain normal full-page navigation.
An information link can use the same behavior declaratively:
<a href="/delivery-details"
data-allatonce-faq="00000000-0000-4000-8000-000000000000"
data-allatonce-question="Which documents are required?">
Which documents are required?
</a>Keep the ordinary href. The widget reveals only the active FAQ identified by data-allatonce-faq; it never treats host-page prose as an approved answer. Repeated clicks reuse the current iframe and answer card. If the FAQ is missing, inactive, draft, or unavailable, the link follows its original destination instead. Opening the answer is passive and does not persist a conversation; persistence begins only after a real visitor submission.
CSP
If your site has a strict Content Security Policy, allowlist:
- frame-src https://allatonce.app
script-src https://allatonce.appconnect-src https://*.supabase.co https://allatonce.app