Quickstart
Get the Clarm AI sales agent and tracking running on your website in under 5 minutes.
1. Get your API key
Log in to the Clarm Dashboard, navigate to Settings → API Keys, and create a new key. Copy it — you will need it for the next step.
2. Add the widget snippet
Paste this script tag before the closing </body> tag of your website:
index.htmlhtml
<script>
(function(c,l,a,r,m){
c['__CLARM_CONFIG__']={apiKey:r,agentId:m};
var s=l.createElement('script');
s.async=true;s.src=a;
l.head.appendChild(s);
})(window,document,'https://cdn.clarm.com/widget/clarm-widget.min.js',
'YOUR_API_KEY','YOUR_AGENT_ID');
</script>Replace YOUR_API_KEY and YOUR_AGENT_ID with values from your dashboard.
3. Add tracking
The widget automatically tracks page_view events. To identify users and track purchases, add these calls:
Identify a visitorjavascript
window.ClarmTrack('identify', {
email: 'jane@acme.com',
name: 'Jane Smith',
company: 'Acme Inc'
});Track a purchasejavascript
window.ClarmTrack('purchase', {
amount: 99.00,
currency: 'USD',
plan: 'growth'
});*
For type-safe tracking in TypeScript projects, install the @clarm/widget SDK instead of using the script tag.
4. Verify installation
Open your site — you should see the Clarm chat bubble in the bottom-right corner. Click it, send a message, and verify in the Dashboard → Conversations tab that it appears.