Ask your Agents how people use your app
Ask a question about your app's AirTraffic data in plain words and get numbers or a chart back: counts over time, split by a property, two periods side by side, or on a schedule.
The AirTraffic tab shows your app’s main numbers: people, sessions, the screens they visit, the events your app sends and who comes back. For a question the tab doesn’t answer, ask an Agent in plain words, such as “How many people used the timer each day last week?” The Agent reads the same events with workers traffic and answers with numbers, or a chart.
Ask a question
Ask in the Project’s chat, for example:
How many people used the timer each day last week?- The Agent looks up what your app sends with
workers traffic definitionsand finds the events that match your words. - It reads them with
workers traffic trends: which events (--event, one or several, orall), what to count (--math), how to group the time (--interval:hour,day,weekormonth) and the dates (--fromand--to). - It replies with the numbers. It may also draw them as a chart card: see Read a chart or a check report an Agent sends.
Check which events the Agent used. If one isn’t what you meant, say which screen or action you had in mind. Nothing changes in your app: these commands only read.
Dates can be relative, such as the last 24 hours, 7 days, 3 months or year, or run between two dates. The reads also take a time zone (--timezone), so say yours if days should follow your clock.
What you can ask for
Say it in your own words. The Agent picks the way of counting, for example:
| You ask | What the Agent counts |
|---|---|
| How many people did it each day | People active per day (--math dau) |
| How many people did it each week | People active per week (--math weekly_active) |
| A total of a number the event carries, such as the items in an order | The sum of that property (--math sum with --property) |
| Several things at once, such as sign-ups and purchases | Several events in one read (--event, separated by commas) |
The workers help lists more ways of counting than these. For questions the counts don’t cover, the Agent can write its own query over the events with workers traffic sql or workers traffic query.
To learn who comes back after doing something, such as finishing onboarding, ask that too. The Agent uses workers traffic retention, which starts from one event and counts who returns by day, week or month. The tab’s Retention starts from everyone first seen in each period instead.
Split by a property
Events can carry properties, such as the screen, the app’s version or the platform, when your app sends them. People can carry properties too, such as their plan. Ask, for example:
How many photos did people export last month, by app version?The Agent splits the count with --breakdown: by a property of the event, or of the person (person: before the property’s name).
Compare two periods
Name both periods, for example:
How many people opened the editor this month, against last month?The Agent reads each period and puts them side by side. In the tab, Compare does the same for the dashboard’s numbers.
Count something your app doesn’t send yet
If no event matches your question, ask for one, for example:
Send an event when someone shares a recipe, with the recipe's category.The Agent adds it to your app’s code. Events only arrive from people who use a version of the app that sends them, so counts start from there. For an app on the App Store, that means after your next update: see Ship an update to your app.
Get it on a schedule
Ask the Agent in its chat or in the Project’s chat, for example:
Every Monday at 9 AM, post last week's daily active people and sign-ups here, against the week before.The Agent can set up a Schedule on itself. It doesn’t post a card for this, so it usually says so in its reply. You can also add the Schedule yourself:
- Open the Agent’s profile and tap Schedules, then Add Schedule. See Schedule work for an Agent.
- Type a Title, for example “Weekly usage”.
- Under Instructions, write the question and where to post the answer, for example “Post last week’s daily active people and sign-ups in the Project’s chat, against the week before.”
- In Repeat, choose how often, for example Every Week, and set the day and Time.
- Check Time Zone, then tap Save.
When a Schedule runs, nothing shows in the chat by itself: the Agent gets the instructions and posts what it finds. If your Team’s Agents run on your Mac, the Schedule’s page says “Schedules in this workspace run only while its Mac is on.” See Choose where your Agents run.