Connect Domain
Widget SDK

Reference

Host events, token lifecycle, and accessibility behavior.

Host events

These fire both as window CustomEvents (event.detail) and, where noted, as the onSuccess/onClose callbacks you pass to open().

EventFiresdetail
connectdomain:stepon every screen change{ domain, provider, step, jobId }
connectdomain:successwhen the domain reaches live{ domain, success, setupType, provider, jobId } (the onSuccess callback receives { id, domain })
connectdomain:closewhen the modal closes{ domain, success, setupType, provider, lastStatus, jobId, reason } (the onClose callback receives { id, domain, succeeded })

Token lifecycle

Widget tokens expire after 60 minutes. On expiry the widget shows a "session expired" state; your host app should mint a fresh token (see Widget tokens) and reopen. A domain-bound token may only act on the hostname it was minted for.

Accessibility & mobile

Focus trap, aria-modal, a live-region announcer, 44px touch targets, safe-area insets, prefers-reduced-motion, and prefers-color-scheme dark mode are all built in.

On this page