CLI Usage
The fyrn CLI (@fyrn/cli) is the primary tool for creating, testing, deploying, and managing integration flows from your terminal. When invoked with no arguments, it launches an interactive AI-powered assistant.
Installation and login
Section titled “Installation and login”# Installnpm install -g @fyrn/cli
# Log in (opens browser for Auth0 PKCE)fyrn login
# Check auth statusfyrn auth status
# Log outfyrn logoutFor CI/CD environments:
fyrn auth api-key --api-key sk-your-key --api-url https://api.fyrn.devConfig files
Section titled “Config files”| File | Purpose |
|---|---|
~/.fyrn/credentials.json | Auth tokens from fyrn login |
~/.fyrn/config.json | API key and URL from fyrn auth api-key |
~/.fyrn/history | Interactive mode history (max 500 lines) |
fyrn.config.json | Per-project config (API URL, account ID) |
fyrn.config.local.json | Local overrides (gitignored) |
Authentication — fyrn auth
Section titled “Authentication — fyrn auth”fyrn auth login
Section titled “fyrn auth login”Log in via Auth0 (opens browser).
fyrn auth loginStores access token and refresh token to ~/.fyrn/credentials.json. Verifies by calling /api/v1/auth/me.
fyrn auth logout
Section titled “fyrn auth logout”Clear stored credentials.
fyrn auth logoutfyrn auth status
Section titled “fyrn auth status”Show current authentication status — method, token validity, expiration, source.
fyrn auth statusfyrn auth api-key
Section titled “fyrn auth api-key”Authenticate with an API key for CI/CD environments.
| Flag | Description |
|---|---|
--api-key <key> | API key (or enter interactively if omitted) |
--api-url <url> | Control plane URL |
fyrn auth api-key --api-key sk-abc123 --api-url https://api.fyrn.devfyrn auth api-key # interactive promptProject — fyrn init, fyrn pull, fyrn push, fyrn diff
Section titled “Project — fyrn init, fyrn pull, fyrn push, fyrn diff”fyrn init
Section titled “fyrn init”Initialize a fyrn project in the current directory.
fyrn initCreates fyrn.config.json, flows/ directory, and adds fyrn.config.local.json to .gitignore.
fyrn pull [flow-name]
Section titled “fyrn pull [flow-name]”Pull flow configs from the server to local YAML files.
| Argument | Description |
|---|---|
[flow-name] | Optional — pulls all flows if omitted |
| Flag | Description |
|---|---|
--force | Overwrite local changes without warning |
fyrn pull # pull all flowsfyrn pull my-flow # pull one flowfyrn pull --force # overwrite localfyrn push [flow-name]
Section titled “fyrn push [flow-name]”Push local YAML files to the server as drafts.
| Argument | Description |
|---|---|
[flow-name] | Optional — pushes all flows if omitted |
fyrn push # push all flowsfyrn push my-flow # push one flowfyrn diff [flow-name]
Section titled “fyrn diff [flow-name]”Compare local YAML files against deployed versions. Shows colored unified diff.
| Argument | Description |
|---|---|
[flow-name] | Optional — diffs all flows if omitted |
fyrn diff # diff all flowsfyrn diff my-flow # diff one flowFlows — fyrn flow
Section titled “Flows — fyrn flow”All flow subcommands accept --env <environment> to target a specific environment (defaults to current).
fyrn flow list
Section titled “fyrn flow list”List all flows with name, status, version, and description.
fyrn flow listfyrn flow list --env stagingfyrn flow show <flow-id>
Section titled “fyrn flow show <flow-id>”Show details of a flow — ID, status, version, description, timestamps, webhook URL, and YAML config.
fyrn flow show abc123fyrn flow create <description>
Section titled “fyrn flow create <description>”Create a flow from a natural language description. AI generates the YAML, you review and confirm.
| Flag | Description | Default |
|---|---|---|
--error-handling <level> | conservative, standard, or aggressive | standard |
fyrn flow create "Sync Shopify orders to NetSuite"fyrn flow create "Forward webhook events to Slack" --error-handling conservativefyrn flow deploy <flow-id>
Section titled “fyrn flow deploy <flow-id>”Deploy a flow. Validates, compiles, and activates it. Outputs the flow ID, version, and webhook URL (if applicable).
fyrn flow deploy abc123fyrn flow test <flow-file>
Section titled “fyrn flow test <flow-file>”Test a flow locally with sample data. Parses the YAML, compiles the flow, and applies the mapping to the sample data.
| Flag | Description | Required |
|---|---|---|
--sample-data <file> | Path to sample JSON data file | Yes |
fyrn flow test flows/my-flow.yaml --sample-data sample.jsonfyrn flow clone <flow-id>
Section titled “fyrn flow clone <flow-id>”Clone an existing flow to another environment.
| Flag | Description | Required |
|---|---|---|
--to <env> | Target environment | Yes |
--env <environment> | Source environment | No |
fyrn flow clone abc123 --to stagingfyrn flow clone abc123 --to production --env developmentfyrn flow diff <flow-a> <flow-b>
Section titled “fyrn flow diff <flow-a> <flow-b>”Compare two flows side-by-side. Shows a colored unified diff of their YAML configs.
fyrn flow diff abc123 def456fyrn flow diff abc123 def456 --env productionfyrn flow delete <flow-id>
Section titled “fyrn flow delete <flow-id>”Soft-delete a flow. The flow is marked as deleted and can be restored by support if needed.
fyrn flow delete abc123fyrn flow delete abc123 --env stagingConnectors — fyrn connector
Section titled “Connectors — fyrn connector”fyrn connector list
Section titled “fyrn connector list”List all connectors with name, type, status, and flow count.
fyrn connector listfyrn connector catalog
Section titled “fyrn connector catalog”Browse the connector catalog with name, type, auth method, and description.
fyrn connector catalogfyrn connector instances
Section titled “fyrn connector instances”List all connector instances with name, status, config summary, and last tested time.
fyrn connector instancesfyrn connector test <id>
Section titled “fyrn connector test <id>”Test a connector instance connection.
fyrn connector test abc123fyrn connector build [url-or-description]
Section titled “fyrn connector build [url-or-description]”Build a private connector from API documentation using AI. Point it at an API docs URL or describe the API in plain text.
| Flag | Description |
|---|---|
--name <name> | Connector name |
--spec <path> | Path to an OpenAPI/Swagger spec file |
fyrn connector build "https://docs.acme.com/api"fyrn connector build "Acme CRM REST API with OAuth2" --name acme-crmfyrn connector build --spec ./openapi.yaml --name acme-crmfyrn connector connect <instance>
Section titled “fyrn connector connect <instance>”Start OAuth authorization for a connector instance. Opens a browser to complete the OAuth flow.
fyrn connector connect shopify-mainfyrn connector status <instance>
Section titled “fyrn connector status <instance>”Show OAuth connection status for a connector instance — token validity, expiration, and scopes.
fyrn connector status shopify-mainLogs — fyrn logs
Section titled “Logs — fyrn logs”fyrn logs tail <flow-id>
Section titled “fyrn logs tail <flow-id>”Stream live message logs via SSE. Press Ctrl+C to stop.
| Flag | Description |
|---|---|
--status <status> | Filter by delivery status |
fyrn logs tail abc123fyrn logs tail abc123 --status failedfyrn logs search <flow-id>
Section titled “fyrn logs search <flow-id>”Search message logs.
| Flag | Description | Default |
|---|---|---|
--status <status> | Filter by delivery status | |
--since <duration> | Messages since (e.g., 1h, 30m, 7d) | |
--search <text> | Search in payload content | |
--limit <n> | Max results | 20 |
Duration strings: s (seconds), m (minutes), h (hours), d (days). Non-matching values are treated as ISO date-time strings.
fyrn logs search abc123fyrn logs search abc123 --status failed --since 1hfyrn logs search abc123 --search "order_id" --limit 50fyrn logs replay <message-id>
Section titled “fyrn logs replay <message-id>”Replay a message through the full pipeline.
fyrn logs replay msg-abc123Schedules — fyrn schedules
Section titled “Schedules — fyrn schedules”fyrn schedules list
Section titled “fyrn schedules list”List all schedules with flow, cron expression, timezone, enabled state, next run, and last status.
fyrn schedules listfyrn schedules trigger <flow-name>
Section titled “fyrn schedules trigger <flow-name>”Manually trigger a scheduled flow. Accepts flow name (case-insensitive) or flow ID.
fyrn schedules trigger my-flowfyrn schedules trigger abc123Adapters — fyrn adapters
Section titled “Adapters — fyrn adapters”Custom code adapters run JavaScript in sandboxed V8 isolates for non-standard data transformations.
fyrn adapters list
Section titled “fyrn adapters list”List all adapters with name, type, AI-generated flag, last test, and created date.
fyrn adapters listfyrn adapters generate <description>
Section titled “fyrn adapters generate <description>”Generate an adapter with AI from a natural language description.
| Flag | Description | Default |
|---|---|---|
--type <type> | request_transform, response_transform, auth, enrichment, full | request_transform |
--sample <json> | Sample input JSON |
fyrn adapters generate "Convert XML order to JSON format"fyrn adapters generate "Add HMAC signature header" --type authfyrn adapters generate "Flatten nested address fields" --sample '{"address":{"street":"123 Main"}}'fyrn adapters test <adapter-id>
Section titled “fyrn adapters test <adapter-id>”Test an adapter with sample input.
| Flag | Description | Required |
|---|---|---|
--input <json> | JSON input payload | Yes |
fyrn adapters test abc123 --input '{"order_id": "12345"}'fyrn adapters templates
Section titled “fyrn adapters templates”List available pre-built adapter templates.
fyrn adapters templatesLookup tables — fyrn lookup
Section titled “Lookup tables — fyrn lookup”fyrn lookup list
Section titled “fyrn lookup list”List all lookup tables with name, description, version, and created date.
fyrn lookup listfyrn lookup show <id>
Section titled “fyrn lookup show <id>”Show a lookup table and its entries.
| Flag | Description | Default |
|---|---|---|
-s, --search <query> | Search entries by key or value | |
-l, --limit <n> | Max entries to display | 20 |
fyrn lookup show abc123fyrn lookup show abc123 --search "US" --limit 50fyrn lookup create <name>
Section titled “fyrn lookup create <name>”Create a new lookup table.
| Flag | Description |
|---|---|
-d, --description <text> | Table description |
fyrn lookup create country-codesfyrn lookup create country-codes --description "ISO country code mappings"fyrn lookup delete <id>
Section titled “fyrn lookup delete <id>”Delete a lookup table.
fyrn lookup delete abc123fyrn lookup set <id> <key> <value>
Section titled “fyrn lookup set <id> <key> <value>”Add or update an entry in a lookup table.
fyrn lookup set abc123 US "United States"fyrn lookup remove <id> <key>
Section titled “fyrn lookup remove <id> <key>”Delete an entry from a lookup table.
fyrn lookup remove abc123 USfyrn lookup import <id> <file>
Section titled “fyrn lookup import <id> <file>”Import entries from a CSV file. Requires key and value columns.
fyrn lookup import abc123 country-codes.csvfyrn lookup export <id>
Section titled “fyrn lookup export <id>”Export a lookup table as CSV to stdout.
fyrn lookup export abc123fyrn lookup export abc123 > countries.csvBundles — fyrn bundle
Section titled “Bundles — fyrn bundle”Export and import flow bundles as ZIP files for backup or cross-environment migration.
fyrn bundle export <flow-name>
Section titled “fyrn bundle export <flow-name>”Export a flow as a ZIP bundle.
| Flag | Description |
|---|---|
-o, --output <file> | Output file path (default: <flow-name>.zip) |
fyrn bundle export my-flowfyrn bundle export my-flow --output /tmp/my-flow-bundle.zipfyrn bundle import <file>
Section titled “fyrn bundle import <file>”Import a flow from a ZIP bundle. Displays imported flow, lookup tables, and warnings.
fyrn bundle import my-flow.zipSelf-healing — fyrn healing
Section titled “Self-healing — fyrn healing”Manage self-healing events. When fyrn detects an API schema change, it auto-generates a fix and creates a healing event for review.
fyrn healing list
Section titled “fyrn healing list”List healing events.
| Flag | Description |
|---|---|
--status <status> | Filter by status (pending, approved, rejected) |
--flow <flow-id> | Filter by flow |
fyrn healing listfyrn healing list --status pendingfyrn healing list --flow abc123fyrn healing show <id>
Section titled “fyrn healing show <id>”Show full details of a healing event — the detected change, proposed fix, and diff.
fyrn healing show heal-abc123fyrn healing approve <id>
Section titled “fyrn healing approve <id>”Approve a healing event and apply the proposed fix.
fyrn healing approve heal-abc123fyrn healing reject <id>
Section titled “fyrn healing reject <id>”Reject a healing event. The flow remains unchanged.
fyrn healing reject heal-abc123Governance — fyrn governance
Section titled “Governance — fyrn governance”Manage governance policies. Alias: fyrn gov.
fyrn governance list
Section titled “fyrn governance list”List all governance policies.
fyrn governance listfyrn gov listfyrn governance show <id>
Section titled “fyrn governance show <id>”Show details of a governance policy.
fyrn governance show policy-abc123fyrn governance check [flow-id]
Section titled “fyrn governance check [flow-id]”Run governance checks against a flow, or all flows.
| Flag | Description |
|---|---|
--all | Check all flows |
fyrn governance check abc123fyrn gov check --allAI agents — fyrn agents
Section titled “AI agents — fyrn agents”Manage AI agent API keys and monitor agent activity.
fyrn agents keys list
Section titled “fyrn agents keys list”List all agent API keys.
fyrn agents keys listfyrn agents keys create
Section titled “fyrn agents keys create”Create a new agent API key.
| Flag | Description |
|---|---|
--name <name> | Key name |
--tier <tier> | Access tier |
--rate-limit <n> | Requests per minute |
--daily-quota <n> | Daily request quota |
--sandbox | Restrict to sandbox environment |
--approval | Require approval for destructive actions |
fyrn agents keys create --name "CI bot" --tier standard --rate-limit 60fyrn agents keys create --name "Dev agent" --sandbox --approval --daily-quota 1000fyrn agents keys update <key-id>
Section titled “fyrn agents keys update <key-id>”Update an existing agent API key.
| Flag | Description |
|---|---|
--name <name> | Update key name |
--tier <tier> | Update access tier |
--approval | Toggle approval requirement |
fyrn agents keys update ak-abc123 --tier premiumfyrn agents keys update ak-abc123 --name "Production bot" --approvalfyrn agents keys revoke <key-id>
Section titled “fyrn agents keys revoke <key-id>”Revoke an agent API key. This is immediate and irreversible.
fyrn agents keys revoke ak-abc123fyrn agents activity
Section titled “fyrn agents activity”View recent agent activity.
| Flag | Description |
|---|---|
--key <key-id> | Filter by key |
--tool <tool> | Filter by tool used |
--status <status> | Filter by status |
--limit <n> | Max results |
fyrn agents activityfyrn agents activity --key ak-abc123 --limit 50fyrn agents activity --tool flow.create --status failedPublished APIs — fyrn apis
Section titled “Published APIs — fyrn apis”Manage APIs published through fyrn.
fyrn apis list
Section titled “fyrn apis list”List all published APIs.
fyrn apis listfyrn apis docs <name>
Section titled “fyrn apis docs <name>”Open interactive API documentation for a published API.
fyrn apis docs orders-apifyrn apis spec <name>
Section titled “fyrn apis spec <name>”Output the OpenAPI spec for a published API.
| Flag | Description | Default |
|---|---|---|
-f, --format <format> | Output format (json or yaml) | yaml |
-o, --output <file> | Write to file instead of stdout |
fyrn apis spec orders-apifyrn apis spec orders-api -f json -o openapi.jsonEnvironments — fyrn env
Section titled “Environments — fyrn env”Manage environments.
fyrn env list
Section titled “fyrn env list”List all environments.
fyrn env listfyrn env switch <name-or-slug>
Section titled “fyrn env switch <name-or-slug>”Switch the active environment.
fyrn env switch stagingfyrn env switch prodfyrn env current
Section titled “fyrn env current”Show the current active environment.
fyrn env currentfyrn env create <name>
Section titled “fyrn env create <name>”Create a new environment.
| Flag | Description |
|---|---|
--color <hex> | Environment color for the dashboard |
fyrn env create stagingfyrn env create qa --color "#f59e0b"Accounts — fyrn accounts
Section titled “Accounts — fyrn accounts”Manage accounts (for users with access to multiple accounts).
fyrn accounts list
Section titled “fyrn accounts list”List all accounts you have access to.
fyrn accounts listfyrn accounts switch <name-or-id>
Section titled “fyrn accounts switch <name-or-id>”Switch the active account.
fyrn accounts switch acme-corpfyrn accounts switch acc-abc123fyrn accounts current
Section titled “fyrn accounts current”Show the current active account.
fyrn accounts currentBilling — fyrn billing
Section titled “Billing — fyrn billing”Manage billing and subscription.
fyrn billing status
Section titled “fyrn billing status”Show current billing status — plan, usage, and renewal date.
fyrn billing statusfyrn billing upgrade <plan>
Section titled “fyrn billing upgrade <plan>”Upgrade to a new plan.
| Flag | Description |
|---|---|
--annual | Switch to annual billing |
fyrn billing upgrade profyrn billing upgrade enterprise --annualfyrn billing portal
Section titled “fyrn billing portal”Open the billing portal in your browser to manage payment methods and invoices.
fyrn billing portalUsage and plan — fyrn usage, fyrn plan
Section titled “Usage and plan — fyrn usage, fyrn plan”fyrn usage
Section titled “fyrn usage”Show current usage vs plan limits — flows, messages, connectors, and API calls.
fyrn usagefyrn plan
Section titled “fyrn plan”Show current plan details — name, limits, features, and renewal date.
fyrn planInteractive mode
Section titled “Interactive mode”Run fyrn with no arguments to launch an AI-powered conversational assistant (powered by Claude). The assistant can list flows, create flows, deploy, manage connectors, search message logs, and more — all through natural language.
fyrnHistory is stored at ~/.fyrn/history (max 500 lines).
Common workflows
Section titled “Common workflows”Generate → validate → deploy
Section titled “Generate → validate → deploy”fyrn flow create "Sync orders from Shopify to my ERP system"# Review the generated YAML, confirmfyrn flow deploy <flow-id>Pull → edit → push → deploy
Section titled “Pull → edit → push → deploy”fyrn pull my-flow# Edit flows/my-flow.yaml in your editorfyrn diff my-flow # review changesfyrn push my-flow # upload as draftfyrn flow deploy <flow-id> # activateTest locally before deploying
Section titled “Test locally before deploying”fyrn flow test flows/my-flow.yaml --sample-data test-data.jsonMonitor a running flow
Section titled “Monitor a running flow”fyrn flow list # see all flows and statusfyrn flow show <flow-id> # flow detailsfyrn logs tail <flow-id> # live log streamfyrn logs search <flow-id> --status failed # find failuresfyrn logs replay <message-id> # replay a failed messageManage lookup tables
Section titled “Manage lookup tables”fyrn lookup create country-warehouses --description "Maps countries to warehouse IDs"fyrn lookup set <id> US warehouse-east-01fyrn lookup set <id> FI warehouse-eu-01fyrn lookup import <id> countries.csvfyrn lookup export <id> > backup.csv