Embedding Dislab in your app

Pro

Show the whole console, or just screens, media, playlists, signs or menus, in an iframe on your own pages.

A partner app connected with the embed scope (see Connect Dislab) can show Dislab on its own pages. It looks and works like Dislab, signed in as the owner, with no cookies. The owner’s account must be on Pro.

  1. Tell us which websites will show it (scheme and host, such as https://app.yourapp.example). Dislab only appears on those.
  2. For each page view, your server asks for a session with the owner’s access token:
    curl -X POST https://dqeiiqecdxqguwrilond.supabase.co/functions/v1/api/v1/embed/sessions \
      -H "Authorization: Bearer dla_ACCESS_TOKEN" \
      -H "Content-Type: application/json" \
      -d '{"origin": "https://app.yourapp.example", "module": "screens"}'
    module is all, screens, media, playlists, signs or menus.
  3. Put the url from the answer in an iframe. The session lasts an hour (expires_at); ask for a new one on each page load.
    <iframe src="URL_FROM_THE_ANSWER" style="width:100%;border:0"></iframe>

Messages

Dislab posts messages to your page only (never to another website), each with source: "dislab":

  • {type: "ready", module}: it has loaded.
  • {type: "navigated", path}: the owner moved to another page.
  • {type: "resize", height}: set the iframe to this height to avoid a scroll bar inside it.

Send {type: "dislab:navigate", path: "/media"} to the iframe to open a page within its module.

Inside your app, billing, API keys, webhooks, connected apps, phone alerts, people, downloading everything and deleting the account stay in Dislab itself. Opened directly, or on a website not approved, the iframe shows nothing. When the owner disconnects your app, sessions stop at once.

Still stuck?

Email support@dislab.app, or send us a message. If it’s about a screen, tell us its name. We answer within one business day.

Contact us