ActessiaBook a 30-day pilot
Documentation

Install the widget

A script tag or an npm package, the site key, the Content-Security-Policy entries, and the attributes you can set.

The widget is a small loader (under 15 KB gzipped, non-blocking) that fetches its configuration from your site key and renders the chat panel in its own shadow root. Nothing on your page is touched; nothing runs until the loader has confirmed the page's origin is one you registered.

Script tag (any site)

<script>window.Actessia=window.Actessia||{q:[]};["identify","track","setContext","escalate","open","close","reset"].forEach(function(m){window.Actessia[m]=function(){window.Actessia.q.push([m,[].slice.call(arguments)])}});</script>
<script async src="https://cdn.actessia.ai/v1/actessia.js" data-site-key="ak_site_…"></script>

The first line is optional: it lets the page call Actessia.identify(...) before the loader has run (calls are queued and replayed in order). data-site-key is a public identifier, not a secret; it only works on the origins you registered in the dashboard.

npm

import { load } from "@actessia/sdk";
const actessia = load({ siteKey: "ak_site_…" });
actessia.identify(payload, signature); // see identify()

React

import { ActessiaWidget } from "@actessia/sdk/react";

<ActessiaWidget siteKey="ak_site_…" user={signed?.payload} signature={signed?.signature} context={{ custom: { screen: "calendar" } }} />

It renders nothing itself; the widget lives in its own shadow root. When user goes away (a logout) the component calls reset(). Put it in the root layout: it is a singleton, not something to mount per route.

Content-Security-Policy

Add script-src https://cdn.actessia.ai and connect-src https://runtime.actessia.ai to your own values. No inline scripts are required unless you use the pre-load stub above ('unsafe-inline', or move it into a file). The iframe render mode uses a same-origin about:blank frame, so no frame-src entry is needed.

The public API

Method What it does
identify(payload, signature) Binds the conversation to a signed end user. Sent on first open, or immediately if the panel is open.
track(event) A conversion signal (purchase, signup, upgrade, or custom) for attribution.
setContext({ page_url?, locale?, custom? }) Flat host-page context attached to every message (current screen, selected record…).
escalate({ reason? }) Hands the conversation to a person, the same as the persistent "Talk to a human" button.
open() / close() Toggle the panel.
reset() Forgets the stored visitor id, session and draft for this site key. Call it on logout.

Loading the tag twice is harmless. Calls made before the loader ran, or before its configuration resolved, are held and applied in order.

What the visitor sees first

The widget discloses that it is an AI assistant on first interaction, and offers a person from the start. It needs no third-party cookie and works when analytics consent is denied.