文档首页

Channels

Web widget embed

Install the FlexyAgents widget on your site: script tag, configuration, domains, CSP headers, and performance considerations.

embedjavascriptwidgetchat

The web widget is the default customer entry point: a launcher plus chat panel that calls FlexyAgents with your agent id and embed key.

Host the snippet near the end of body for faster initial paint; defer non-critical analytics until after interactive.

Embed snippet and keys

Copy the snippet from the dashboard deployment section; it references your environment host and public embed key. Rotate keys if exposed accidentally.

For SPAs, ensure the script initializes once per route change strategy your framework uses.

CSP and third-party scripts

Update Content-Security-Policy to allow FlexyAgents script and connect-src endpoints for chat APIs and websockets if used.

Test in staging with the same CSP as production to avoid silent blocks.

Performance

Lazy load the widget on first interaction if LCP is sensitive; balance against discoverability.

Monitor Core Web Vitals after embed; large custom fonts in the host page affect both host and iframe surfaces.

在你的技术栈上构建

准备上线有依据的助手了吗?

开始试用,或与我们沟通上线、治理和企业级要求。