@mimeticinc/mim-cli
v0.1.8
Published
Mimetic CLI — growth context for Claude Code, Codex, and shell workflows
Downloads
1,370
Maintainers
Readme
mim , the Mimetic CLI
Mimetic in your terminal: pull your site audits, prioritized findings, code-fix PRs, and session-replay insights straight into your shell , and into AI coding agents like Claude Code and Codex.
# authenticate this machine (opens the browser, device-code flow)
npx -y --package @mimeticinc/mim-cli mim auth login
# then pull a growth-context pack for one of your projects
mim context --project yourstore.comCredentials are stored in ~/.mim/config.json (chmod 600), scoped to the projects your account
owns. Requires Node 20+.
Install
Run on demand with npx (no global install):
npx -y --package @mimeticinc/mim-cli mim <command>…or install the mim binary globally:
npm install -g @mimeticinc/mim-cli
mim auth loginCommands
| Command | What it does |
|---|---|
| mim auth login | Device-code login (opens the browser). --token <t> stores an existing token. |
| mim auth status / mim auth logout | Show / clear local credentials. |
| mim projects | List the projects/sites on your account. |
| mim context | Print a growth-context pack for a project , ready to paste into an AI agent. |
| mim recordings | Recent session-replay summaries: what users did and where they hit friction. |
| mim replay [session_id] | One replay's issues + a redacted narrative. Defaults to the latest. |
| mim findings | The audit's prioritized findings and backlog. |
| mim query-ga4 --metrics sessions | Read-only GA4 report over your connected property. |
| mim query-gsc | Read-only Search Console query (top queries/pages). |
| mim setup-analytics [--wait] | One-click hosted analytics setup: GA4 property + tag install (PR or Shopify pixel) + Search Console verification. --wait polls to completion. |
| mim setup-analytics --status | Hosted setup progress; also retries the Search Console verification/sitemap followups. |
| mim setup-analytics --channel agent | For coding agents already in the site's repo: server provisions GA4 + Search Console, you apply the returned snippet yourself. No GitHub App or PR pipeline. |
| mim ads setup | Create a Google Ads account for the site under Mimetic's manager account: linked to GA4, auto-tagging on, owner invited as ADMIN. |
| mim ads status | The project's linked Google Ads account and latest setup event. |
| mim ads query [--gaql <q>] | Read-only GAQL report over the linked account (default: campaign performance, 30 days). |
| mim posthog connect | Connect PostHog over OAuth (opens the approval URL; read-only scopes). |
| mim posthog query [--hogql <q>] | Read-only HogQL over the connected project (default: daily events + unique users, 14 days). |
| mim klaviyo connect | Connect Klaviyo over OAuth (opens the approval URL; read-only scopes). |
| mim klaviyo query [--resource <r>] | Read-only Klaviyo queries: listings, performance reports (campaign_performance, flow_performance), and checks (abandoned_cart_status, dead_links). |
| mim audit start <url> [--wait] | Start an audit (reuses a running/completed one). --wait polls to completion. |
| mim audit rerun <url> | Force a fresh audit. |
| mim audit status <id> / mim audit wait <id> | Check / poll an audit. |
| mim fixes list | List fixable findings + PR/review state. |
| mim fixes start <rank> | Queue a code fix , Mimetic opens a PR with a preview link. |
| mim fixes open <rank> | Open the PR, preview, diff, or workflow for a fix. |
| mim billing status / checkout / portal | Stripe billing for a project. |
| mim mcp install claude / mim mcp install codex | Wire Mimetic into Claude Code / Codex. |
Common options
| Option | |
|---|---|
| --project <key> | Project/site key. Defaults to MIM_PROJECT or your saved default. |
| --format <json\|markdown> | Output format (--json is an alias for --format json). |
| --limit <n> | Items to request, up to 100 (default 20). |
| --mode <slim\|full> | Audit depth. slim (default, fast) or full (deeper, adds SDK intel). |
| --wait | With audit start/rerun or setup-analytics, poll until completion. |
| --api-base-url <url> | API origin. Defaults to MIM_API_BASE_URL or https://trymimetic.com. |
MCP (Claude Code / Codex)
Mimetic ships a read-only MCP server, so your coding agent can see what's broken and why , redacted session narratives and findings, never raw replay payloads.
mim mcp install claude # or: mim mcp install codexEnvironment
MIM_API_TOKEN, MIM_API_BASE_URL, MIM_PROJECT, MIM_CONFIG_DIR (default ~/.mim),
MIM_TELEMETRY=0 to disable usage telemetry.
Links
- Docs: https://trymimetic.com/api
- Agentic / x402 API: https://trymimetic.com/x402
MIT © Mimetic Inc
