NOTE: Replace YOUR_SITE_API_KEY with the embed key copied from your dashboard and yourstore.businessplus.co.ke with your store subdomain or connected custom domain.
Credential Architecture Notice
In the current release, the embed widget script reads data-api-key to authenticate public chat and widget-assisted order placement. Because this snippet is placed in public HTML source code, anyone inspecting the browser source can view this key.
Supported Configuration Attributes
The widget loader script reads custom data-* attributes to configure styling, identity, and behavior:
WordPress & CMS Integration
For WordPress, Webflow, Squarespace, or Shopify sites:
WordPress: Install the free "Insert Headers and Footers" (WPCode) plugin. Paste the snippet into the "Footer Scripts" section and save changes.
Webflow: Navigate to Project Settings -> Custom Code -> Footer Code. Paste the snippet and publish your project.
Shopify / Liquid: Navigate to Online Store -> Themes -> Edit code -> theme.liquid. Paste the snippet immediately before the closing tag.
Authorized External Domains (CORS Security)
To prevent unauthorized websites from embedding your store assistant, configure domain allowlisting in the dashboard:
1. Open Domain Settings: Navigate to Dashboard -> Settings -> Domains (/dashboard/settings/site/:id/domains).
2. Add Authorized External Domains: Under "Authorized External Domains", add your website origins (e.g. blog.yourbrand.com, www.yourbrand.com, or localhost for local testing).
Content Security Policy (CSP)
If your host website uses strict Content Security Policy headers, ensure the following origins are permitted in your policy: