Variables & Data Fields
Variables and data fields let you capture, store, and reuse information throughout your video flow. Track user responses, personalize content, and create dynamic experiences that adapt to each viewer.
What Are Variables?
Variables are containers that store data during a viewer's journey through your video. They can hold:
User responses to questions
Data from your CRM or database
Calculated values (scores, totals, etc.)
System information (time, date, etc.)
Types of Variables
User Input Variables
Capture responses from interactive elements:
Examples:
user_name— "John Smith"company_size— "Enterprise"budget_range— "$10,000-$50,000"preferred_features— ["Analytics", "Automation"]
Calculated Variables
Derived from user interactions or data processing:
Examples:
quiz_score— 85 (calculated from answers)total_points— 150 (sum of all interactions)time_spent— 245 (seconds in video)completion_percentage— 75%
System Variables
Automatically provided by the platform:
Examples:
current_time— "2024-01-15 14:30:00"viewer_id— "user_12345"session_start— "2024-01-15 14:25:00"device_type— "mobile"
Using Variables in Your Flow
Displaying Variables
Show variable values in your content:
Examples:
"Hello, {{user_name}}!"
"Your score: {{quiz_score}}/100"
"Based on your {{company_size}} needs..."
"You've earned {{total_points}} points"
Conditional Logic
Use variables to control branching:
Examples:
Dynamic Content
Personalize based on stored data:
Examples:
Show different product recommendations based on
preferred_featuresDisplay custom pricing based on
budget_rangeAdjust content length based on
time_spent
Real-World Examples
Customer Onboarding Flow
Product Recommendation Quiz
Advanced Variable Features
Variable Arrays
Store multiple values in a single variable:
Examples:
selected_features— ["Analytics", "Automation", "Reporting"]quiz_answers— ["A", "B", "C", "A", "B"]interaction_history— ["clicked_demo", "viewed_pricing", "downloaded_guide"]
Variable Calculations
Perform math operations on variables:
Examples:
total_cost = base_price + add_onsdiscount_amount = original_price * 0.15final_score = (correct_answers / total_questions) * 100
Variable Persistence
Store variables across sessions:
Examples:
Remember user preferences for future visits
Track cumulative engagement across multiple videos
Build user profiles over time
Best Practices
Variable Naming
Use descriptive names —
user_company_sizeinstead ofvar1Follow consistent conventions — Use underscores for multi-word variables
Avoid reserved words — Don't use system keywords
Document your variables — Keep a list of what each variable stores
Data Management
Validate input — Ensure data is in expected format
Handle missing data — Provide fallbacks for empty variables
Clean data — Remove unnecessary spaces, format consistently
Secure sensitive data — Don't store passwords or personal info in variables
Performance
Limit variable count — Too many variables can slow performance
Use appropriate data types — Text, numbers, dates, etc.
Clean up unused variables — Remove variables you no longer need
Optimize calculations — Keep complex calculations simple
Common Use Cases
Personalized greetings and messaging
Dynamic product recommendations
Quiz scoring and results
Progress tracking and gamification
A/B testing and optimization
Lead qualification and scoring
Customer journey mapping
Ready to personalize your content? Learn about dynamic data fields for advanced personalization.
Last updated

