RevenueCat CLI for coding agents
How coding agents discover RevenueCat CLI commands, parse their output, and run without a human
The RevenueCat CLI is built so a coding agent can use it without a person translating each step. You don't have to configure anything to allow this. This article covers the properties agents rely on: runtime discovery, structured output, non-interactive execution, browserless signup, and the command that installs your agent's RevenueCat knowledge.
How agents discover commands
The CLI describes its own surface, so an agent enumerates what's available at runtime instead of depending on a command list baked into its training data:
rc commands --json # the full command tree with capabilities
rc commands --schemas # the same tree with every command's schema inlined
rc schema <cmd> # flags, arguments, and examples for any command
Two annotations in that output matter for agents. Commands marked "experimental": true are hidden from rc --help until their feature ships but are still runnable, so an agent can detect them and choose to skip them. Commands marked requires_human carry a requires_human_reason explaining why a person has to run them: the store credential flows sign in to Apple or Google with two-factor authentication in a local terminal, and Apple credentials should never be collected in chat. rc setup is the special case: interactively it launches a local AI agent, but run non-interactively (rc setup --json) it returns the setup prompt for your own agent to follow directly.
For anything the CLI doesn't cover, rc api calls any RevenueCat API v2 endpoint with the CLI's credentials:
rc api GET /projects/proj_abc/customers
rc api POST /projects/proj_abc/offerings --body '{"lookup_key":"sale"}'
Structured output
Every command supports --json, so a caller parses a result rather than scraping formatted text:
rc customers list --json | jq '.data.items[].id'
Errors come back as JSON in --json mode too, with stable types and exit codes, so the same parser handles both transport and CLI errors:
{
"error": {
"type": "resource_missing",
"message": "Could not find entitlement 'entl_nope' within this project",
"exit_code": 5,
"request_id": "fc53f50e-…",
"doc_url": "https://errors.rev.cat/resource-missing"
},
"schema_version": 1
}
The global --format flag applies a jq expression to --json output directly, without a separate jq install. Exit codes are stable and enumerated in the command reference.
Running without prompts
Interactive prompts hang automation, so the CLI can refuse them:
--no-inputmakes any command fail rather than prompt.--yesskips confirmation prompts on destructive commands.RC_API_KEYandRC_PROJECT_IDenvironment variables replace the on-disk login and project selection entirely.
RC_API_KEY=sk_... RC_PROJECT_ID=proj_abc rc entitlements list --json --no-input
Creating an account from an agent
An agent can create a RevenueCat account and receive renewable credentials without opening a browser:
rc auth signup \
--email dev@example.com \
--name "Example Developer" \
--generate-password \
--save-password \
--accept-terms \
--no-input --json
Three rules keep this safe:
- Consent is explicit. Pass
--accept-termsonly after the user authorizes accepting the Terms of Service and Privacy Policy, and add--marketing-emailsonly on a separate opt-in. - Passwords stay out of the shell.
--generate-password --save-passwordcreates a one-time password in memory and stores it in the macOS login Keychain without printing it. Prefer theRC_PASSWORDenvironment variable over--password, which can leak via shell history and process listings. - Verify the result. Check that
account_created,authenticated, andpassword_saved_to_keychainaretruein the response.
Installing skills for your agent
The CLI installs the AI Toolkit skills, the playbooks that give your agent the right order of operations for RevenueCat workflows:
rc skills install # global; installs the core project-setup skills
rc skills install --project # repository-local instead
rc skills install --all # the full skill catalog
By default the skills install for the coding agents RevenueCat supports; pass --agent (for example --agent codex) to target a specific one, or --skill to install a single skill by name.
rc delegates to the Skills CLI (npx skills add RevenueCat/ai-toolkit), so the workflows update in one place rather than shipping a stale copy. Re-run rc skills install to update, then reload your agent to pick up changes.
Skills don't run on install; the agent selects one when a request matches its description. Run rc skills prompts for copy-ready starter prompts.
If you'd rather install through a plugin marketplace, see Plugins, which sets up the skills and the MCP server together.
CLI or MCP server?
The CLI and the MCP Server both let an agent act on your RevenueCat account, and their capabilities overlap:
- The MCP server fits inside a coding assistant, where the agent already holds a connection to your projects and is working in your codebase.
- The CLI fits scripted or repeatable setup, CI, and environments where the agent runs shell commands rather than MCP tools. It's also the only path for the local store credential flows (
rc setup apple,rc setup google), which have to run on your machine.
You don't have to choose one: the plugin configures the MCP server, and the skills it installs use the CLI when a workflow calls for it.