This chapter covers the core features and capabilities of Event Tracker.
Follow this guide to get Event Tracker up and running in your environment.
# Track an event
python src/event_tracker.py track "signup" --user "user_123" --props '{"plan": "pro"}'
# Track a page view
python src/event_tracker.py track "page_view" --user "user_123" --props '{"page": "/pricing"}'
# Query recent events
python src/event_tracker.py query --last 7d
# Query by event name
python src/event_tracker.py query --event "signup" --limit 50
# View statistics
python src/event_tracker.py stats
# Count events
python src/event_tracker.py count --event "signup" --last 30dfrom event_tracker import SQLiteStore, track_event, track_page_view
store = SQLiteStore("my_events.db")
# Track custom events
track_event("purchase", user_id="user_456", properties={"amount": 49.99}, store=store)
track_page_view("/dashboard", user_id="user_456", store=store)
# Query events
events = store.query(event_name="purchase", limit=10)
stats = store.stats(group_by="event_name")| Backend | Best For | File |
|---|---|---|
| SQLite | Querying, aggregation, production use | events.db |
| JSONL | Streaming, log pipelines, simplicity | events.jsonl |
Get the full Event Tracker and unlock everything.
Get the complete guide with every chapter unlocked, including code samples, diagrams, and best practices.
Access all interactive tools with complete data, all workload profiles, and the full scenario library.
Downloadable source code, configuration files, and working examples from every chapter.
Free updates for life. Every new chapter, tool, and improvement included.