Ragenta Docs
Connections

Embedded chat — put an agent on your website

Publish a chat widget that runs on your site, restrict it to your domains, cap its spend, identify signed-in visitors and watch activity.

Settings → Embedded chat. Needs widget.manage (Owner/Admin). Widgets per plan: Free 0, Starter and Pro 1, Team 5, Enterprise unlimited.

Publish a chat

FieldNotes
NameInternal name.
AgentThe agent that answers visitors. Must be active.
Sites it may run onOrigins (1–20), e.g. https://example.com; wildcard subdomains https://*.example.com supported. The widget refuses to run anywhere else.
Header, ColourThe chat panel title and accent colour (default #7c3aed).
First messageThe greeting shown on open.
Messages per visitor per hourDefault 20.
Credits it may spend in a dayDefault 50,000; resets at midnight UTC. At the ceiling the widget stops answering until the next day.

Embed it

After publishing, EmbedSnippet gives you a script tag with the publishable key rgpk_… (public, not a secret):

<script src="https://app.example.com/widget.js" data-key="rgpk_..."></script>

Paste it before the closing body tag. The script has no dependencies and renders inside a shadow root, so it does not touch your page's CSS.

Identify signed-in visitors (optional)

IdentitySnippet lets you attach a visitor identity so the agent and Your APIs know who is asking ({{visitor.id}}, {{visitor.email}}). Your server computes an HMAC-SHA256 of the user id with the widget's identity secret and puts it on the script tag:

<script src="https://app.example.com/widget.js"
  data-key="rgpk_..."
  data-user-id="42"
  data-user-email="ana@example.com"
  data-user-hash="<hmac-sha256 hex>"></script>

Without a valid hash the identity is ignored — the visitor is only known anonymously by a browser token.

Activity

Activity opens a dialog: today's spend against the ceiling, totals over 7/30/90 days, a Messages per day chart, and a Recent conversations table (what the visitor asked, what the agent answered, credits, time). These runs also appear in the agent's History with trigger widget.

Edit changes the configuration; the live/paused switch pauses it; Remove deletes the widget and makes the script on your page go inert.

On this page