HowdyGo SDK (Pro & Enterprise Only)
The HowdyGo SDK enables seamless integration with HowdyGo demos on your website. It automatically detects demos on your page and allows you to personalize them with user data.
Quick Start
Include the SDK snippet on your page and start personalizing your demos:
<script>
// You will need a snippet provided by support@howdygo.com to get started.
</script>
<script>
// These functions can be called at any time after the snippet above has been included.
// Identify the current user
howdygo.identify({
userId: 'userEmail@company.com',
name: 'Jane Smith',
company: 'Acme Corp',
phone: '+1234567890',
replacements: [
{ token: 'token1', value: 'Acme Corp' },
{ token: 'token2', value: 'Jane Smith' }
]
});
// Personalize demos with custom content
howdygo.personalize([
{ token: 'token1', value: 'Acme Corp' },
{ token: 'token2', value: 'Jane Smith' }
]);
</script>
Core Methods
The SDK provides a simple API through the global howdygo
object with direct method calls:
identify(userInfo)
Tell the SDK who the current user is. This information will be sent to all HowdyGo demos on the page.
howdygo.identify({
userId: 'user@example.com', // User's email
name: 'John Doe', // Display name
company: 'Acme Corp', // Company name
phone: '+1234567890' // Phone number (optional)
});
personalize(replacements)
Replace placeholder text in your demos with real user data.
howdygo.personalize([
{ token: 'token1', value: 'Acme Corp' },
{ token: 'token2', value: 'Jane Smith' }
]);
Usage Examples
Basic Personalization
// Set user identity once, usually after login
howdygo.identify({
userId: 'jane@techcorp.com',
name: 'Jane Smith',
company: 'Tech Corp'
});
// Personalize all demos on the page
howdygo.personalize([
{ token: 'token1', value: 'Acme Corp' },
{ token: 'token2', value: 'Jane Smith' }
]);
Dynamic Updates
// Update personalization when user data changes
function updateDemoPersonalization(userData) {
howdygo.identify(userData);
howdygo.personalize([
{ token: 'token1', value: 'Acme Corp' },
{ token: 'token2', value: 'Jane Smith' }
]);
}
Listening for Demo Events
// Listen for events from demos (optional)
howdygo.on('demo-interaction', (event) => {
console.log('User interacted with demo:', event);
});
Advanced Methods
These methods are available but not required for most use cases:
getStoredIdentity()
Get the currently stored user information.
clearIdentity()
Clear stored user data.
setOptOut(true/false)
Allow users to opt out of data storage.
Legacy API Support
For backward compatibility, all methods are also available through the invoke
pattern:
// Legacy format (still supported)
howdygo.invoke('identify', {
userId: 'user@example.com',
name: 'John Doe'
});
howdygo.invoke('personalize', [
{ token: 'token1', value: 'Acme Corp' }
]);
howdygo.invoke('on', 'demo-interaction', callback);
How It Works
- Auto-Detection: The SDK automatically finds HowdyGo demos on your page
- Queuing: All method calls are queued until the SDK fully loads
- Personalization: User data and replacements are sent to all detected demos
- Persistence: User identity persists across page loads
Best Practices
- Call
identify()
once when you know who the user is (e.g., after login) - Call
personalize()
whenever you want to update demo content - The SDK handles multiple demos automatically - no need to manage them individually
- All methods are safe to call before the SDK fully loads
Support
Need help? Contact support@howdygo.com or check your account dashboard for integration guides.