Segment Integration
Send HoloStep events to Segment and forward them to 300+ analytics and marketing tools from a single integration.
Overview
Segment is a customer data platform that acts as a universal data pipeline. Instead of integrating each analytics tool separately, you connect HoloStep to Segment once, then route events to any destination.
Why Use Segment?
- One integration, many destinations - Connect to GA4, Mixpanel, Amplitude, HubSpot, and 300+ more
- Consistent data - Same event schema across all tools
- Easy management - Add/remove destinations without code changes
- Data quality - Built-in validation and transformation
Tracked Events
| HoloStep Event | Segment Event | Description |
|---|---|---|
| 3D Viewer Open | 3D Viewer Opened | User opens 3D viewer |
| 3D Interaction | 3D Model Interacted | User rotates/zooms |
| AR Mode Open | AR Mode Opened | User launches AR |
| Measurement Tool | Measurement Tool Opened | User opens measurements |
| Variant Select | Product Variant Selected | User changes variant |
| Add to Cart | Product Added | Standard e-commerce event |
| Purchase | Order Completed | Standard e-commerce event |
Prerequisites
- A Segment account
- A JavaScript source created in Segment
- A HoloStep account with an active subscription
Step 1: Create a JavaScript Source
1.1 Add a Source
- Log in to Segment
- Go to Connections → Sources
- Click Add Source
- Search for JavaScript
- Click Add Source
1.2 Get Your Write Key
- In your new source, go to Settings → API Keys
- Copy the Write Key
WARNING
Keep your Write Key secure. While it's designed for client-side use, avoid exposing it unnecessarily.
Step 2: Configure HoloStep Integration
2.1 Open Integration Settings
- Log in to your HoloStep Dashboard
- Go to Settings → Integrations
- Click Add Integration
2.2 Select Segment
- Choose Segment from the list
- Enter a name (e.g., "Production Segment")
2.3 Enter Your Write Key
| Field | Value |
|---|---|
| Write Key | Your Segment source Write Key |
2.4 Save and Enable
- Click Create Integration
- Toggle the integration ON
INFO
Segment doesn't have a validation endpoint, so the integration validates the Write Key format only. Events will appear in Segment once you interact with your 3D viewer.
Step 3: Verify in Segment
Debugger
- Go to your JavaScript source in Segment
- Click the Debugger tab
- Open your website with HoloStep
- Interact with a 3D viewer
- Events should appear in real-time
Event Structure
HoloStep events in Segment look like this:
{
"type": "track",
"event": "3D Viewer Opened",
"properties": {
"scene_id": "12345",
"scene_name": "Modern Chair",
"content_name": "Modern Chair",
"domain": "yourshop.com",
"session_id": "abc123",
"holostep_source": "client"
}
}Step 4: Add Destinations
Once events are flowing to Segment, add destinations:
Popular Destinations
| Destination | Use Case |
|---|---|
| Google Analytics 4 | Web analytics |
| Mixpanel | Product analytics |
| Amplitude | Behavioral analytics |
| HubSpot | CRM & marketing |
| Klaviyo | Email marketing |
| Intercom | Customer messaging |
| BigQuery | Data warehouse |
Adding a Destination
- Go to Connections → Destinations
- Click Add Destination
- Search for your tool
- Click Configure
- Select your JavaScript source
- Enter the destination's credentials
- Enable the destination
Event Mapping
Standard E-commerce Events
HoloStep uses Segment's E-commerce Spec:
| HoloStep | Segment Spec | Notes |
|---|---|---|
addToCart | Product Added | Includes product details |
purchase | Order Completed | Includes order value |
viewItem | Product Viewed | Product page view |
Custom Events
Other HoloStep events use human-readable names:
| HoloStep | Segment Event |
|---|---|
3dButtonClick | 3D Viewer Opened |
arButtonClicked | AR Mode Opened |
variantSelected | Product Variant Selected |
configurationSaved | Configuration Saved |
Event Properties
All events include these properties:
| Property | Type | Description |
|---|---|---|
holostep_source | string | Always "client" |
scene_id | string | HoloStep scene identifier |
scene_name | string | Product/scene name |
content_name | string | Same as scene_name (Segment standard) |
domain | string | Website domain |
url | string | Full page URL |
session_id | string | HoloStep session ID |
E-commerce Properties
For cart and purchase events:
| Property | Type | Description |
|---|---|---|
value | number | Product/order value |
revenue | number | Same as value (Segment standard) |
price | number | Unit price |
currency | string | Currency code (e.g., USD) |
product_id | string | Product identifier |
name | string | Product name |
User Identification
HoloStep can identify users in Segment if you pass user information:
// If you have user data, HoloStep will include it
window.analytics.identify('user-123', {
email: 'user@example.com',
name: 'John Doe'
});INFO
User identification is handled by your existing Segment implementation. HoloStep events will be associated with identified users automatically.
Troubleshooting
Events Not Appearing
| Issue | Solution |
|---|---|
| No events in Debugger | Check Write Key format (alphanumeric, 10+ chars) |
| Events blocked | Ad blockers may block Segment; test in incognito |
| Integration disabled | Verify toggle is ON in HoloStep |
Debug Checklist
- Browser Console: Look for
[HoloStep] Segment initialized - Network Tab: Filter for
api.segment.iorequests - Segment Debugger: Real-time event stream
Events in Debugger but not in Destination
Check that your destination is enabled and properly configured. Some destinations have a delay before events appear.
"Write Key invalid" error
Segment Write Keys are alphanumeric and typically 20+ characters. Make sure there are no extra spaces.