Types of Queries
zinzu supports three types of queries: Sequence Behavior, Any-Order Behavior, and Funnel.
All three analyze events belonging to the same EventOwner, but each answers a different question: Did events happen in a particular order? Did all required events occur? Or how far did an EventOwner progress through a process?
1. Sequence Behavior
Find events that occur in a specific order, with the conditions you define.
Sequence Behavior lets you identify a series of events in the order you specify. You can control what happens between steps, how many times an event can repeat, how much time is allowed between events, and whether certain events must not occur.
Example: Payment recovery
You want to find payment requests where:
- A payment failed.
- A retry was attempted.
- The payment succeeded.
- The entire sequence completed within 30 seconds.
Pattern: Payment Failed → Retry → Payment Succeeded
zinzu examines each payment request's timeline and finds sequences that match these conditions.
You can also create more flexible patterns. For example, allow multiple retries before success or exclude requests where the payment was cancelled.
When to use: When you need to understand the order of events, the conditions between them, and how a process unfolded.
2. Any-Order Behavior
Find a set of required events, regardless of the order in which they occur.
Any-Order Behavior checks whether all specified events occurred within an EventOwner's timeline. Unlike Sequence Behavior, you don't need to define which event comes first.
You can require the same event more than once and apply supported timing conditions.
Example: Application verification
Before an application can be approved, three actions must occur:
- Identity Verified
- Address Verified
- Consent Received
These actions can happen in any order.
Pattern: Identity Verified + Address Verified + Consent Received
zinzu finds applications where all three actions occurred, regardless of which happened first. You can also require that all three occur within 24 hours.
When to use: When all required events must occur, but their order is not important.
3. Funnel
Track how far EventOwners progress through a series of milestones and identify where they drop off.
A Funnel measures progression through a defined set of steps. It helps you understand how many EventOwners reach each milestone, where they stop progressing, and how long it takes to move between steps.
Events unrelated to the funnel can occur between milestones without interrupting progression. You don't need to explicitly allow these intermediate events.
Example: Product activation
You want to understand how new users progress from signing up to using your product.
Funnel: Signup → Email Verified → Workspace Created → First Query Run
zinzu analyzes each user's activity and helps answer questions such as:
- How many users signed up?
- How many verified their email?
- How many created a workspace?
- How many ran their first query?
- Where did users drop off?
- How long did users take to move between milestones?
For example, a user who signs up, verifies their email, and creates a workspace but never runs a query has reached the third milestone, but not the fourth.
When to use: When you want to measure progression, conversion, and drop-off through a process.
Choosing the Right Query Type
Sequence Behavior: Did these events happen in the required order, under the specified conditions?
Any-Order Behavior: Did all the required events occur, regardless of order?
Funnel: How far did EventOwners progress, and where did they stop?

