AgentHog
Web and mobile analytics built to be read by an agent as easily as by a person. Autocapture collects the boring stuff — pageviews, clicks, forms, scroll depth — and every number in the dashboard is also available as a dense terminal table or --json from the ah CLI.
Collect
One script tag for the web, the React Native SDK for Expo apps, the Capacitor SDK for hybrid apps, or the Unity package for games. Autocapture handles pageviews, clicks, forms, and scroll depth with no hand-instrumentation.
Explore
Sessions, funnels, retention, campaigns, and a changelog you can line traffic up against.
Ask
The ah CLI is the read surface agents use. No MCP server, no plugin — just a command your agent already knows how to run.
Start here
Pick the path that matches who is doing the work.
Install the agent skill
One command teaches Claude Code (or any Agent Skills–compatible tool) how to integrate AgentHog correctly — the right SDK, the event-naming contract, and how to verify data arrived. Then just ask it to add analytics.
Integrate by hand
The same instructions, written out: web script tag, React Native / Expo SDK, Capacitor SDK, Unity package, and what to check when events do not show up.
See every event
The full autocapture matrix per platform, the props on every event, what the server derives on top, what is deliberately never collected, and how to extend it with custom events.
Send events from a backend
Webhooks, jobs, and history backfills go straight to /ingest with a write token — no SDK, no browser. Plus the HTTP read API for services that need the numbers back.
Turn purchases into revenue
Map the amount prop on an event you already send and get net revenue, ARPU, AOV, revenue by channel or plan, and cohort LTV — applied retroactively over everything you have ever sent.
Set up the ah CLI
Install, ah login, and the CLAUDE.md block that gets your agent querying analytics instead of guessing.
The 60-second version
Create a project to get a key, drop in the tracker, then read it back from the terminal.
# 1. create a project at http://agenthog.io/projects/new → you get a key shaped ah_xxxxxxxx # 2. web: paste before </head> in your site-wide layout <script src="http://agenthog.io/ah.js" data-project="ah_xxxxxxxx" defer></script> # 3. read it back npm i -g @brightmotion/agenthog ah login ah digest
Concepts worth knowing early
Event names are a contract
Autocapture emits deterministic, human-readable names — pageview: /pricing, click: Join the waitlist, form_submit: waitlist. That is what lets an agent compose a question without first re-deriving your schema. Custom events keep your name verbatim, so keep varying values in props rather than baked into the name.
Bots are excluded by default
Sessions are classified as human, unknown, suspected bot, or crawler from behavioral and environmental signals. Aggregates count humans and unknowns; pass --all to include bots or --bots to see only them. Traffic from your own devices can be labelled test — see ah test-ips — which is likewise excluded by default and readable with --test.
Projects, orgs, and tokens
A project is one ah_ key, owned by an organization — your website, app, and game can all report into it. Read tokens expose exactly what you can already see in the dashboard and any member can mint one; write tokens are admin-only. Unattended agents and CI should use AH_TOKEN rather than a browser login.