Agents
Agents CLI
The official `nativeform` CLI lets you prototype agent reads/submits, exercise parity commands, and replay incidents without wiring a full orchestrator stack. Use it whenever you need a reproducible command line fixture for your assistant.
Installation & authentication
Install once on your workstation or CI runner, then reuse the saved key until you need to rotate it.
Install with bun
bun install --global @theodevs/nativeform-cli`bun install --global` grabs the CLI binary so `nativeform` is on your path. You can also run `node ./packages/cli/bin/nativeform.js --help` from the repo when iterating on the CLI itself.
Log in once
nativeform loginOpens NativeForm API keys so you can copy a key. The CLI saves it in its config (see source for the path) and uses it on every command.
Override per command
Configure `NATIVEFORM_API_KEY`/`NATIVEFORM_BASE_URL` in your environment, or pass `--token`/`--base-url` to avoid writing to disk when debugging an incident.
Command groups
Pick the group that mirrors your agent behavior and copy the corresponding CLI commands into your playbook.
Forms lifecycle
List, create, and mutate forms (publish, pause, update AI settings) to mirror what agents can read and rewrite.
Responses & anomalies
Fetch, inspect, or correct submissions after your agent runs so you can audit behavior or reprocess smart fields.
Webhooks & integrations
Manage downstream notifications while your agent orchestrator kicks off workflows.
Key management
Rotate or revoke keys after incidents to keep CLI automation safe.
Custom calls
When you need an opcode not yet in the CLI, fall back to `api call` with method + path.
Public agent flow
`nativeform public` commands walk through the manifest → draft → submit lifecycle described in public fill docs.
Use `nativeform public manifest` to read field definitions, `draft` to stage answers, and `submit`/`confirm` for human fallback.
Safety
Treat CLI runs like production traffic: keys matter, logs matter, and recovery steps should be repeatable.
Keep CLI tokens scoped
Create keys dedicated to agent smoke tests and revoke them with `nativeform api-keys revoke <keyId>` once the run finishes.
Prefer env vars over login files
Set `NATIVEFORM_API_KEY` and optional `NATIVEFORM_BASE_URL` in the shell so the CLI does not persist secrets locally.
Log to reproducible artifacts
Capture `nativeform --debug ...` output and configs so you can replay the request and troubleshoot agent mistakes later.
Audit `nativeform login`
`nativeform login` writes to your CLI config path (see CLI source). Use `--token`/`--base-url` overrides for ephemeral automation.