@anythingai/cli 0.1.4 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@anythingai/cli",
3
- "version": "0.1.4",
3
+ "version": "0.1.5",
4
4
  "homepage": "https://anything.com/",
5
5
  "license": "MIT",
6
6
  "bin": {
@@ -20,6 +20,7 @@
20
20
  "scripts": {
21
21
  "gen": "npx @hey-api/openapi-ts",
22
22
  "gen:spec": "tsx scripts/generate-spec.mts",
23
+ "gen:skill": "tsx scripts/generate-skill.mts",
23
24
  "check:spec": "tsx scripts/check-spec.mts",
24
25
  "build": "tsdown --no-dts --out-dir dist/js",
25
26
  "prepublishOnly": "yarn build",
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: anything-cli
3
- description: Use when an agent needs to build, inspect, or manage an Anything app from the CLI. Covers auth, account and org checks, project creation, follow-up generations, secrets, publishing, domains, databases, deployments, members, and compound workflows. Best for OpenClaw, Claude Code, Codex, Cursor, or any agent that should drive Anything non-interactively.
3
+ description: Use when an agent needs to build web or mobile apps. Covers auth, orgs, project creation, follow-up generations, secrets, publishing, domains, databases, deployments, and members. Built for non-interactive use by OpenClaw, Hermes, Claude Code, Codex, Cursor, or any agent.
4
4
  allowed-tools:
5
5
  - Bash(anything:*)
6
6
  - Read
@@ -8,255 +8,320 @@ allowed-tools:
8
8
 
9
9
  # Anything CLI
10
10
 
11
- Use `anything` as the control-plane CLI for Anything apps. Prefer this skill when the user wants to build or manage an Anything app without depending on the web UI.
12
-
13
- ## Core Rules
14
-
15
- - Prefer `ANYTHING_API_KEY` for non-interactive auth. Use `anything auth login --api-key <key>` for key-based login.
16
- - Start with `anything user --json` for account, org, plan, and credit checks.
17
- - Use the resource-first shape everywhere: `anything projects ...`, `anything domains ...`.
18
- - **Always use `--json`** when another tool or agent will read the output. The JSON envelope format is: `{ "ok": true, "command": "...", "data": { ... }, "meta": { "duration_ms": 142 } }`.
19
- - **Use `--quiet`** to get only the primary ID or URL for chaining: `PROJECT_ID="$(anything projects create --quiet --prompt "...")"`
20
- - Capture `projectId` from create output and pass it explicitly on later commands.
21
- - Pass flags for all inputs. Do not rely on prompts or hidden local state.
22
- - `--non-interactive` is auto-enabled when `CLAUDECODE`, `CODEX`, `CI`, or `OPENCLAW` env vars are detected.
23
- - Use `--dry-run` on state-modifying commands to preview actions before executing.
24
- - If the user asks for something outside the known surface area, run `anything introspect` or `anything <subcommand> --help`.
25
-
26
- ## Output Modes
27
-
28
- | Flag | Behavior |
29
- | ------------------- | ---------------------------------------------------------------------------------------------------------------- |
30
- | `--json` | Returns JSON envelope: `{ ok, command, data, meta }` or `{ ok: false, command, error: { code, message, hint } }` |
31
- | `--quiet` | Prints only the primary identifier (ID or URL) — one per line for list commands |
32
- | `--dry-run` | Outputs planned actions as JSON without executing |
33
- | `--non-interactive` | Hard-fails instead of prompting; emits `ActionRequired` JSON to stderr |
34
-
35
- ## Exit Codes
36
-
37
- | Code | Meaning | Agent action |
38
- | ---- | ------------------ | ------------------------------------------ |
39
- | 0 | Success | Continue |
40
- | 1 | General error | Inspect error |
41
- | 2 | Invalid arguments | Fix command syntax |
42
- | 3 | Resource not found | Check ID |
43
- | 4 | Auth failure | Re-authenticate |
44
- | 5 | Conflict | Resource exists |
45
- | 6 | Timeout | Retry (also used for publish wait timeout) |
46
- | 7 | Server error | Retry with backoff |
47
-
48
- ## Quick Start
11
+ `anything` is the command-line control plane for Anything — create, iterate on, and publish AI-built web and mobile apps without the web UI. Use it whenever the user wants to build or manage an Anything app programmatically.
12
+
13
+ ## Rules for agents
14
+
15
+ - **Always pass `--json`** when the output will be read by a tool or agent. Parse the envelope; never scrape text.
16
+ - **Capture `projectId` from `projects create`** and pass it explicitly to every later command.
17
+ - **Pass every input as a flag.** Don't rely on interactive prompts or hidden local state.
18
+ - `--non-interactive` is auto-enabled under `CLAUDECODE`, `CODEX`, `CI`, or `OPENCLAW`, so commands fail fast on ambiguity instead of hanging.
19
+ - Use `--dry-run` to preview any state-changing command before running it.
20
+ - Unsure what exists? Run `anything introspect` (full command tree as JSON) or `anything <command> --help`.
21
+
22
+ ## Authenticate
49
23
 
50
24
  ```bash
51
- anything user --json
52
- anything projects create --org <org-id> --prompt "Build a CRM for a roofing company" --json
53
- anything projects generate <project-id> --prompt "Add auth and billing" --json
54
- anything projects messages <project-id> --json
55
- anything projects get <project-id> --json
56
- anything projects publish <project-id> --json # waits for deploy
25
+ anything auth login --api-key <key> # or set ANYTHING_API_KEY
26
+ anything user --json # account, orgs, plan, credits
57
27
  ```
58
28
 
59
- ## Async Generation (recommended for agents)
29
+ Start with `anything user --json` — it returns the orgs you can build in. You pass `--org <org-id>` when creating a project.
30
+
31
+ ## Build and publish an app
60
32
 
61
- The default `--wait` mode uses WebSocket subscriptions which can be unreliable. Use `--no-wait` and poll `projects status` for a robust HTTP-only alternative:
33
+ The fastest path one command creates, generates, and publishes:
62
34
 
63
35
  ```bash
64
- # Start generation (returns immediately)
65
- REVISION=$(anything projects generate <id> --prompt "..." --no-wait --quiet)
66
-
67
- # Poll until terminal state (VALID or INVALID)
68
- while true; do
69
- STATUS=$(anything projects status <id> --json | jq -r '.data.status')
70
- case "$STATUS" in
71
- VALID) echo "Done"; break ;;
72
- INVALID) echo "Failed"; break ;;
73
- INVALID_PROMPT) echo "Bad prompt"; break ;;
74
- *) sleep 5 ;;
75
- esac
76
- done
36
+ anything ship --org <org-id> --prompt "Build a todo app with auth" --json
77
37
  ```
78
38
 
79
- Terminal statuses: `VALID` (success), `INVALID` (generation failed), `INVALID_PROMPT` (bad prompt).
80
- Non-terminal: `CREATED`, `BUILDING`.
39
+ `ship` returns the live URL. Pass `--project <project-id>` to iterate on an existing app, `--skip-publish` to stop after generation, or `--no-wait` to return before the deploy finishes.
81
40
 
82
- ## One-Shot Workflow
41
+ For more control, run the steps separately:
83
42
 
84
43
  ```bash
85
- anything ship --prompt "Build a todo app with auth" --json
44
+ # 1. Create returns data.projectId
45
+ anything projects create --org <org-id> --prompt "Build a CRM for roofers" --json
46
+
47
+ # 2. Iterate (repeat as needed)
48
+ anything projects generate <project-id> --prompt "Add auth and billing" --json
49
+
50
+ # 3. Publish — returns the live URL
51
+ anything projects publish <project-id> --json
86
52
  ```
87
53
 
88
- The `ship` command creates (or generates on existing), then publishes and waits for the deployment to finish. It streams progress as NDJSON in `--json` mode, or `[init]`/`[progress]`/`[done]` markers in text mode. `--no-wait` only skips waiting for the deployment to finish — generation still blocks via WebSocket. If you want fully HTTP-only async behavior, use the two-step `projects generate --no-wait` + `projects publish` pattern above instead.
54
+ To chain in a shell, capture the id with `--quiet`: `PID=$(anything projects create --org <org-id> --prompt "..." --quiet)`, then pass `"$PID"` to later commands.
55
+
56
+ ### Long generations
57
+
58
+ Generation can take several minutes. Both paths are safe — pick by how much control you want:
59
+
60
+ **Blocking (`--wait`, the default — and `ship`)** waits as long as the server is making progress; there's no fixed timeout. If it stops waiting while the build is still running, it does **not** fail — it returns a resumable result and you continue from there:
61
+
62
+ ```json
63
+ {
64
+ "ok": false,
65
+ "error": { "code": "still_building", "projectId": "...", "hint": "..." }
66
+ }
67
+ ```
68
+
69
+ On `still_building`, poll `projects status` until `VALID`, then `projects publish`. (Genuine failures still come back as `INVALID` / `INVALID_PROMPT`.)
70
+
71
+ **Non-blocking (`--no-wait`) + poll** gives an agent the most control — kick off generation and drive the status yourself:
89
72
 
90
73
  ```bash
91
- anything ship --project pg_123 --prompt "Add a settings page" --json
92
- anything ship --project pg_123 --skip-publish --prompt "Add dark mode"
93
- anything ship --no-wait --prompt "Build a landing page" --json
74
+ anything projects generate <project-id> --prompt "..." --no-wait --json
75
+ while :; do
76
+ case "$(anything projects status <project-id> --json | jq -r '.data.status')" in
77
+ VALID) break ;; # done
78
+ INVALID|INVALID_PROMPT) exit 1 ;; # failed
79
+ *) sleep 5 ;; # CREATED / BUILDING — keep waiting
80
+ esac
81
+ done
94
82
  ```
95
83
 
96
- ## Workflow
84
+ Statuses: `VALID` (success), `INVALID` / `INVALID_PROMPT` (failure), `CREATED` / `BUILDING` (in progress).
85
+
86
+ ## Output
97
87
 
98
- 1. Run `anything user --json`.
99
- 2. Pick the recommended org if one is available. Otherwise use the org the user specifies.
100
- 3. Create the project and store `projectId`.
101
- 4. Iterate with `projects generate`, `projects messages`, and `projects get`.
102
- 5. Add secrets before publish when the app needs third-party credentials.
103
- 6. Publish once the project is ready.
88
+ | Flag | Behavior |
89
+ | ------------------- | ---------------------------------------------------------------------- |
90
+ | `--json` | Structured output (see below). Use whenever output is parsed. |
91
+ | `--quiet` | Just the primary id or URL, one per line — ideal for shell capture. |
92
+ | `--dry-run` | Prints the planned actions as JSON; changes nothing. |
93
+ | `--non-interactive` | Fails fast instead of prompting. Auto-on for known agent environments. |
104
94
 
105
- ## Command Reference
95
+ Most commands return a single envelope:
106
96
 
107
- ### Account and org discovery
97
+ ```json
98
+ { "ok": true, "command": "...", "data": { ... }, "meta": { "duration_ms": 142 } }
99
+ { "ok": false, "command": "...", "error": { "code": "...", "message": "...", "hint": "..." } }
100
+ ```
101
+
102
+ **Streaming commands emit NDJSON, not one envelope.** `projects create`, `projects generate`, `projects publish`, and `ship` print one JSON object per line: `{"type":"progress",...}` lines, then exactly one final `{"type":"result","ok":...}` line. Read line-by-line and act on the `result` line — don't `jq .` the whole stream.
108
103
 
109
104
  ```bash
110
- anything user --json
111
- anything orgs --json
112
- anything orgs get <org-id> --json
113
- anything orgs members <org-id> --json
114
- anything status --json
115
- anything switch # interactive org/project picker
116
- anything llm-context --json # combined agent context
117
- anything introspect # full command tree as JSON
118
- anything skill # print SKILL.md
119
- anything update --check --json # is a newer CLI version available?
120
- anything update --json # self-update to the latest version
121
- anything update 0.0.3 --json # install a specific published version
105
+ anything ship --prompt "Build a todo app" --json | while IFS= read -r line; do
106
+ [ "$(jq -r .type <<<"$line")" = result ] && jq '{ ok, data, error }' <<<"$line"
107
+ done
122
108
  ```
123
109
 
124
- ### Project creation and iteration
110
+ ### Exit codes
111
+
112
+ | Code | Meaning | Do |
113
+ | ---- | ------------- | ----------------------- |
114
+ | 0 | Success | continue |
115
+ | 1 | General error | inspect `error` |
116
+ | 2 | Bad arguments | fix the command |
117
+ | 3 | Not found | check the id |
118
+ | 4 | Auth failure | re-authenticate |
119
+ | 5 | Conflict | resource already exists |
120
+ | 6 | Timeout | retry |
121
+ | 7 | Server error | retry with backoff |
122
+
123
+ ## Inspect a project
125
124
 
126
125
  ```bash
127
- anything projects create --org <org-id> --prompt "<prompt>" --json
128
- anything projects generate <project-id> --prompt "<prompt>" --json
129
- anything projects messages <project-id> --limit 20 --json
130
- anything projects get <project-id> --json # `data.files[]` lists modules with `path`/`pathSegment`
131
- anything projects files list <project-id> --json
126
+ anything projects get <project-id> --json # name, slug, published URL, files
127
+ anything projects status <project-id> --json # build status + latest deployment
128
+ anything projects messages <project-id> --json # the build conversation
129
+ anything projects files list <project-id> --json # every file in the project
132
130
  anything projects files get <project-id> app/page.tsx --json
133
- anything projects rename <project-id> --name "New Name" --json
134
- anything projects duplicate <project-id> --json
135
131
  ```
136
132
 
137
- ### Secrets and publish
133
+ `projects messages` returns turns in `data.messages[]`. Each turn has `userMessage` (the prompt) and `assistantText` (a readable summary of what was built — use this when displaying assistant output). The raw `assistantMessage` field is also present, but `assistantText` is the clean version to show a user. Turns also include `action`, `status`, `id`, `threadId`, and `createdAt`. These are **not** OpenAI-style `role`/`content` fields.
134
+
135
+ ## Add secrets, then publish
136
+
137
+ Apps that call third-party APIs need their keys as secrets before they'll work when published:
138
138
 
139
139
  ```bash
140
- anything projects secrets add <project-id> --name "OPENAI_API_KEY" --value "$OPENAI_API_KEY" --json
140
+ anything projects secrets add <project-id> --name OPENAI_API_KEY --value "$OPENAI_API_KEY" --json
141
141
  anything projects secrets list <project-id> --json
142
- anything projects publish <project-id> --json # waits for deploy
143
- anything projects publish <project-id> --no-wait --json # fire-and-forget
142
+ anything projects publish <project-id> --json # waits for the deploy
143
+ anything projects publish <project-id> --no-wait --json # return immediately
144
144
  anything projects publish status <project-id> <deployment-id> --json
145
145
  anything projects unpublish <project-id> --yes --json
146
146
  ```
147
147
 
148
- ### Domains
148
+ ## Command reference
149
149
 
150
- ```bash
151
- anything domains list <org-id> --json
152
- anything domains add app.example.com --project pg_123 --json
153
- anything domains remove dom_123 --yes --json
154
- anything domains verify dom_123 --json
155
- ```
150
+ Run `anything <command> --help` or `anything introspect` for flags and detail.
156
151
 
157
- ### Databases
152
+ <!-- BEGIN GENERATED COMMANDS -->
158
153
 
159
- ```bash
160
- anything databases list --org <org-id> --json
161
- anything databases get <database-id> --json
162
- anything databases create --project pg_123 --name "My Database" --json
163
- anything databases query <database-id> "SELECT * FROM users LIMIT 5" --json
164
- anything databases connect <database-id>
165
- anything databases connect <database-id> --mask # redact the password
166
- anything databases reset <database-id> --yes --json
167
- ```
154
+ ### `anything assets`
168
155
 
169
- ### Deployments
156
+ Manage project assets (images)
170
157
 
171
- ```bash
172
- anything deployments list <project-id> --json
173
- anything deployments get <deployment-id> --json
174
- anything deployments logs <deployment-id> --json
175
- anything deployments rollback <project-id> --yes --json
176
- anything deployments rollback <project-id> <deployment-id> --yes --json
177
- ```
158
+ - `anything assets upload <project-id> <file>` — Upload an image asset to a project
159
+ - `anything assets list <project-id>` — List assets for a project
160
+ - `anything assets remove <project-id> <asset-id>` — Remove an asset from a project
178
161
 
179
- ### Members
162
+ ### `anything auth`
180
163
 
181
- ```bash
182
- anything members list --org <org-id> --json
183
- anything members invite user@example.com --org <org-id> --json
184
- anything members remove user@example.com --org <org-id> --yes --json
185
- anything members role user@example.com admin --org <org-id> --json
186
- ```
164
+ Manage authentication
187
165
 
188
- ### Assets
166
+ - `anything auth login` — Log in via browser or API key
167
+ - `anything auth logout` — Remove stored credentials
168
+ - `anything auth status` — Show current authentication state
189
169
 
190
- ```bash
191
- anything assets upload <project-id> ./logo.png --json
192
- anything assets list <project-id> --json
193
- anything assets remove <project-id> <asset-id> --json
194
- ```
170
+ ### `anything databases`
195
171
 
196
- ### Logs (with streaming)
172
+ Manage databases
197
173
 
198
- ```bash
199
- anything projects logs <project-id> --json
200
- anything projects logs <project-id> --since 1h --json
201
- anything projects logs <project-id> --follow --json # NDJSON stream
202
- anything projects logs <project-id> --follow --level error # tail errors only
203
- ```
174
+ - `anything databases list` — List databases you can access
175
+ - `anything databases get <database-id>` — Inspect a database
176
+ - `anything databases create` Create a new database for a project
177
+ - `anything databases query <database-id> <sql>` Run a read-only SQL query against a database
178
+ - `anything databases connect <database-id>` Print the connection string for a database
179
+ - `anything databases reset <database-id>` — Reset a database (destructive)
180
+ - `anything databases delete <database-id>` — Delete a database (destructive)
204
181
 
205
- ### Project context
182
+ ### `anything deployments`
206
183
 
207
- ```bash
208
- anything projects set <project-id> # set active project
209
- anything projects unset # clear active project
210
- anything orgs set <org-id> # set active org
211
- anything orgs unset # clear active org
212
- anything link <project-id> # link directory to project (.anything/)
213
- anything unlink # remove directory link
214
- anything pull # pull files + secret names
215
- anything pull --files # pull project files only
216
- anything pull --env # write secret names to .env.example
217
- ```
184
+ Manage deployments
218
185
 
219
- ### Watch
186
+ - `anything deployments list <project-id>` — List deployments for a project
187
+ - `anything deployments get <deployment-id>` — Get deployment details
188
+ - `anything deployments logs <deployment-id>` — Get deployment build logs
189
+ - `anything deployments rollback <project-id>` — Roll a project back to its previous deployment
220
190
 
221
- ```bash
222
- anything watch <project-id> # stream all events
223
- anything watch <project-id> --events generation
224
- anything watch <project-id> --json # stream events as NDJSON
225
- ```
191
+ ### `anything domains`
226
192
 
227
- ## Chaining with --quiet
193
+ Manage custom domains
228
194
 
229
- ```bash
230
- PROJECT_ID="$(anything projects create --quiet --prompt "Build a todo app")"
231
- anything projects generate "$PROJECT_ID" --prompt "Add dark mode" --quiet
232
- PUBLISH_URL="$(anything projects publish "$PROJECT_ID" --quiet)"
233
- echo "Published to: $PUBLISH_URL"
234
- ```
195
+ - `anything domains list <organization-id>` — List domains for an organization
196
+ - `anything domains add <domain>` Add a custom domain to a project
197
+ - `anything domains remove <domain-id>` Remove a custom domain
198
+ - `anything domains verify <domain-id>` — Check DNS configuration for a custom domain
199
+
200
+ ### `anything introspect`
201
+
202
+ Output the full command tree as JSON for agent discovery
203
+
204
+ ### `anything link`
205
+
206
+ Link current directory to an Anything project
207
+
208
+ ### `anything unlink`
209
+
210
+ Remove project link from current directory
211
+
212
+ ### `anything llm-context`
213
+
214
+ Return auth state, active project, capabilities, and workflows as a single JSON document for agent bootstrapping
215
+
216
+ ### `anything members`
217
+
218
+ Manage organization members
219
+
220
+ - `anything members list` — List organization members and pending invites
221
+ - `anything members invite <email>` — Invite a member to the organization
222
+ - `anything members remove <email>` — Remove a member from the organization
223
+ - `anything members role <email> <role>` — Change a member's role
224
+
225
+ ### `anything orgs`
226
+
227
+ Manage organizations
228
+
229
+ - `anything orgs get <organization-id>` — Inspect a single organization
230
+ - `anything orgs list` — List your organizations
231
+ - `anything orgs set <org-id>` — Set the active organization for future commands
232
+ - `anything orgs unset` — Clear the active organization
233
+ - `anything orgs members <organization-id>` — Inspect collaborators and pending invites for an organization
234
+
235
+ ### `anything projects`
236
+
237
+ Manage Anything projects
238
+
239
+ - `anything projects list` — List projects you can access
240
+ - `anything projects create` — Create a new app and start initial generation
241
+ - `anything projects duplicate <project-id>` — Duplicate an existing app
242
+ - `anything projects generate <project-id>` — Send a prompt to an existing app
243
+ - `anything projects get <project-id>` — Get app info and dev server status
244
+ - `anything projects rename <project-id>` — Rename a project
245
+ - `anything projects messages <project-id>` — Read conversation history for an app
246
+ - `anything projects status <project-id>` — Show the latest revision status and deployment summary (lightweight, for polling)
247
+ - `anything projects files` — Inspect app files
248
+ - `anything projects files list <project-id>` — List files for an app
249
+ - `anything projects files get <project-id> <path>` — Read one file from an app
250
+ - `anything projects auth` — Inspect project auth provider configuration
251
+ - `anything projects auth providers <project-id>` — Inspect auth provider configuration for a project
252
+ - `anything projects logs <project-id>` — Read development logs for an app (supports tailing)
253
+ - `anything projects secrets` — Manage app secrets
254
+ - `anything projects secrets list <project-id>` — List secrets for an app
255
+ - `anything projects secrets add <project-id>` — Add a secret to an app
256
+ - `anything projects secrets remove <project-id> <secret-id>` — Remove a secret from an app
257
+ - `anything projects publish <project-id>` — Publish an app to production
258
+ - `anything projects publish status <project-id> <deployment-id>` — Check the status of a publish deployment
259
+ - `anything projects submit <project-id>` — Start an App Store submission for an app
260
+ - `anything projects submit status <project-id> <submission-id>` — Check the status of an App Store submission
261
+ - `anything projects unpublish <project-id>` — Unpublish an app from production
262
+ - `anything projects delete <project-id>` — Delete a project permanently (gated behind the project-delete-enabled flag; returns 403 when disabled)
263
+ - `anything projects set <project-id>` — Set the current project for future commands
264
+ - `anything projects unset` — Clear the current project
265
+ - `anything projects settings` — Inspect and update project settings
266
+ - `anything projects settings auth` — Manage auth-related project settings
267
+ - `anything projects settings auth get [project-id]` — Read project auth settings
268
+ - `anything projects settings auth set [project-id]` — Update project auth settings for a provider
269
+
270
+ ### `anything pull`
271
+
272
+ Pull project files and secret names into .anything/
273
+
274
+ ### `anything ship`
275
+
276
+ Create or update + generate + publish in one shot
277
+
278
+ ### `anything skill`
279
+
280
+ Print the packaged anything-cli skill or show its installed path
281
+
282
+ ### `anything status`
283
+
284
+ Show current org, project, user, and auth state
285
+
286
+ ### `anything switch`
287
+
288
+ Interactive org/project picker
289
+
290
+ ### `anything update`
291
+
292
+ Update the CLI to the latest (or a specific) published version
293
+
294
+ ### `anything user`
295
+
296
+ Show current user and organization context
297
+
298
+ ### `anything watch`
299
+
300
+ Watch a project for changes and stream events
301
+
302
+ <!-- END GENERATED COMMANDS -->
303
+
304
+ ## Dry run
235
305
 
236
- ## Dry Run
306
+ Preview any state-changing command without executing it:
237
307
 
238
308
  ```bash
239
- anything projects create --dry-run --org org_1 --prompt "test" --json
240
- # Returns: { ok: true, command: "projects create", dry_run: true, planned_actions: [...] }
241
-
242
- anything projects generate pg_123 --dry-run --prompt "Add auth" --json
243
- anything projects rename pg_123 --dry-run --name "New Name" --json
244
- anything databases create --dry-run --project pg_123 --name "My Database" --json
245
- anything domains add app.example.com --dry-run --project pg_123 --json
246
- anything deployments rollback pg_123 --dry-run --json
247
- anything projects submit pg_123 --store app-store --dry-run --json
248
- anything projects settings auth set pg_123 --provider google --enabled --dry-run --json
309
+ anything projects create --dry-run --org <org-id> --prompt "test" --json
310
+ anything projects generate <project-id> --dry-run --prompt "Add auth" --json
311
+ anything databases create --dry-run --project <project-id> --name "My Database" --json
312
+ anything domains add app.example.com --dry-run --project <project-id> --json
313
+ anything deployments rollback <project-id> --dry-run --json
249
314
  ```
250
315
 
251
- ## Failure Handling
316
+ ## Failure handling
252
317
 
253
- - Missing auth: set `ANYTHING_API_KEY` or run `anything auth login --api-key <key>`.
254
- - Missing org context: rerun `anything user --json` and choose an explicit org ID.
255
- - Zero credits: switch to an org with credits or ask the user to top up before generating.
256
- - Command uncertainty: run `anything introspect` or `anything <subcommand> --help`.
257
- - Exit code 6 (timeout): retry the command.
258
- - Exit code 7 (server error): retry with exponential backoff.
318
+ - **Auth (exit 4):** set `ANYTHING_API_KEY` or run `anything auth login --api-key <key>`.
319
+ - **No org context:** run `anything user --json` and pass an explicit `--org <id>`.
320
+ - **No credits:** switch to an org with credits, or ask the user to top up before generating.
321
+ - **Timeout (exit 6):** retry the command.
322
+ - **Server error (exit 7):** retry with exponential backoff.
323
+ - **Unsure of a command or flag:** run `anything introspect` or `anything <command> --help`.
259
324
 
260
325
  ## References
261
326
 
262
- - For agent-specific installation in OpenClaw, Claude Code, Codex, and Cursor, see `references/setup.md`.
327
+ - Agent-specific install steps for OpenClaw, Claude Code, Codex, and Cursor: `references/setup.md`.