fimo 2.10.0-staging.1 → 2.10.0-staging.10

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.
Files changed (33) hide show
  1. package/README.md +9 -0
  2. package/assets/skills/fimo/SKILL.md +1 -1
  3. package/assets/skills/fimo-cli/SKILL.md +1 -1
  4. package/assets/skills/fimo-cli/references/account.md +2 -0
  5. package/assets/skills/fimo-cli/references/agent-setup.md +1 -1
  6. package/assets/skills/fimo-cli/references/assets.md +2 -0
  7. package/assets/skills/fimo-cli/references/branches.md +10 -2
  8. package/assets/skills/fimo-cli/references/content.md +11 -1
  9. package/assets/skills/fimo-cli/references/deploy.md +1 -26
  10. package/assets/skills/fimo-cli/references/domains.md +4 -4
  11. package/assets/skills/fimo-cli/references/history.md +1 -1
  12. package/assets/skills/fimo-cli/references/init.md +22 -18
  13. package/assets/skills/fimo-code/references/content/richtext.md +2 -2
  14. package/assets/skills/fimo-migration/SKILL.md +73 -59
  15. package/assets/skills/fimo-migration/references/import-contract.md +1 -1
  16. package/assets/skills/fimo-migration/references/qa.md +14 -3
  17. package/assets/skills/fimo-migration/references/workers/content-planner.md +4 -1
  18. package/assets/skills/fimo-migration/references/workers/validator.md +4 -3
  19. package/assets/skills/fimo-migration/references/workers.md +2 -2
  20. package/assets/skills/fimo-migration/references/workflow.md +14 -24
  21. package/assets/skills/fimo-migration/scripts/check-rendered-guardrails.mjs +102 -1
  22. package/assets/skills/fimo-studio/references/ai-chat.md +5 -5
  23. package/assets/skills/fimo-studio/references/billing-and-credits.md +20 -11
  24. package/assets/skills/fimo-studio/references/integrations.md +5 -3
  25. package/assets/skills/fimo-studio/references/project-creation.md +4 -4
  26. package/dist/cli/bundle.json +1 -1
  27. package/dist/cli/index.js +139 -266
  28. package/package.json +8 -8
  29. package/templates/astro/package.json +3 -3
  30. package/templates/nextjs/package.json +4 -4
  31. package/templates/react-router/package.json +5 -5
  32. package/templates/sveltekit/package.json +3 -3
  33. package/templates/vite/package.json +5 -5
package/README.md CHANGED
@@ -37,6 +37,15 @@ cd my-site
37
37
 
38
38
  Every command runs the same way: **`npx fimo@latest <command>`**. `fimo init` sets up the site, pushes the first commit, and wires it to your Fimo account. Open it in your coding agent and start building.
39
39
 
40
+ ## No account yet?
41
+
42
+ `fimo new` creates a site without signing in; a person claims it within 72 hours through the printed claim link. It is the path for sandboxes, CI, and headless coding agents, where `fimo login` cannot open a browser:
43
+
44
+ ```bash
45
+ npx fimo@latest new my-site # creates the site and prints the claim link
46
+ npx fimo@latest new --instructions # the setup guide for coding agents (the text of https://fimo.new)
47
+ ```
48
+
40
49
  ## AI coding tools
41
50
 
42
51
  Fimo ships skills and rules for your AI coding tools (Claude Code, Cursor, Codex, Gemini, and more) so the agent knows how to work in a Fimo site. `fimo init` installs them for you — add or refresh them any time (`--mode=copy` is required under npx):
@@ -41,7 +41,7 @@ Pick by task:
41
41
  - AI agent setup — connect Claude Code, Codex, Cursor, or another agent → `fimo-cli` (`references/agent-setup.md`)
42
42
  - Integrations — Search Console, Slack, or an MCP server: add, inspect, search, or run its tools → `fimo-cli` (`references/integrations.md`)
43
43
  - The Fimo Studio dashboard / web app UI → `fimo-studio`
44
- - Migrating an existing site into Fimo → `fimo-migration`
44
+ - Migrating an existing site into Fimo, or putting an existing app on Fimo (`fimo link`) → `fimo-migration`
45
45
 
46
46
  For project setup, load `fimo-cli` first. Its `references/init.md` decision tree distinguishes a new or empty
47
47
  project, an existing Fimo site, and an external migration; load `fimo-migration` for the last path.
@@ -111,6 +111,7 @@ Load the matching reference when the user's request fires its trigger. Recipes t
111
111
  - "Create a Branch / feature Branch / switch Branches / merge Branches / diff two Branches / Branch status / what changed on this Branch / sync from parent / cut a release / tag a version / go to prod" → `references/branches.md`
112
112
  - "List my projects / clone an existing project locally / check out a project / delete this project / unpublish / rename the project / manage projects across the org" → `references/projects.md`
113
113
  - "Migrate an existing Webflow / Framer / Squarespace / Wix / Carrd site from only a published URL" → load the `fimo-migration` skill, set the target up with `fimo migrate init <dir>`, and read the published site yourself with a browser — the CLI does not crawl it
114
+ - "Put my existing site or app on Fimo / link or deploy the app in this folder / host the site I built" → load the `fimo-migration` skill and follow its source-backed, same-framework path: `fimo link` keeps every word typed in the code, which Studio cannot edit, until the migration's content pass moves it to labels and the CMS
114
115
  - "Migrate from an exported project, source repository, Webflow code export plus CMS CSVs, Framer CMS CSVs, Squarespace XML/CSV, Wix CSVs, Carrd/static export, or downloaded site files" → load the `fimo-migration` skill and use the source repo/export as the migration source of truth
115
116
  - "How do AI agents read my site / markdown for agents" → `references/deploy.md`
116
117
  - "Modify the URL of the website / change my project's address / connect a custom domain (e.g. blog.example.com) / rename the Fimo-provided `*.fimo.site` subdomain / buy a new domain through Fimo / set up a domain" → `references/domains.md`
@@ -134,7 +135,6 @@ These fire at specific moments in the project lifecycle. **Surface them proactiv
134
135
  - **Right after `fimo init`** → start the app locally with the project's package-manager `dev` script (`pnpm dev` / `npm run dev` / `yarn dev` / `bun dev`) in the background. This localhost server with live reload is your iteration loop — edit, show, repeat. No deploy is needed to see local changes. If the initiating request did not say what to build, ask the developer — after the first preview on the create-new path, never as a blocker before initializing.
135
136
  - **When a user-visible unit of work looks done outside first-time onboarding** → **offer** to deploy (`fimo deploy` for a hosted project preview, `fimo deploy --publish` to go live) and run it only after the developer confirms — or immediately if they ask. Never deploy ordinary edits on your own. See `references/deploy.md`.
136
137
  - **Optional, outside new-project onboarding (its first preview already warms the sandbox), if you already know a deploy is coming** → warm the sandbox early with `fimo deploy -m "chore: init" &` in the background so the one-time ~15-30s provision + dep install happens while you work and the real deploy lands warm (~4-10s). This is a perf optimization, not a requirement. See `references/deploy.md` § Warm the sandbox early in a session.
137
- - **Iterative code-only deploys** → once you are deploying, `fimo deploy --no-restart` skips the sandbox dev-server restart on HMR-safe edits. See `references/deploy.md` § Skipping the dev-server restart for when it's safe.
138
138
  - **You need the current preview URL but haven't changed code** (opening it, screenshotting it, handing it to another tool, the previous URL expired) → `fimo preview url`, never a no-op `fimo deploy`. See `references/preview.md`.
139
139
  - **When the user wants to try something risky / explore a redesign without touching the live site** → suggest a feature Branch: `fimo checkout -b <name>` gives an isolated Branch + DB + preview. Deploy previews there, then `fimo merge` it back and `fimo publish`. See `references/branches.md`.
140
140
  - **After completing or safely preserving the user's main work, when a confirmed Fimo platform failure still materially blocks the task after one safe recovery attempt, or a confirmed missing capability blocks completion or forces a fragile or heavily manual workaround** → use the built-in `supportReport` tool. Do not wait for the user to ask and do not stop after only describing the gap. See `references/support.md`.
@@ -10,6 +10,8 @@ fimo login # opens your browser; the CLI captures the token automatically
10
10
 
11
11
  `fimo login` starts a local loopback server, opens your browser to authorize, and the browser redirects the token back to the CLI — **there's nothing to copy or paste**. After login, the CLI saves the session token and auto-selects an active organization (your session's current org, otherwise the first one) — it never prompts. If you belong to more than one org, change the active one later with `fimo orgs switch` (see below).
12
12
 
13
+ `fimo login` needs a browser on this machine, not a terminal: a coding agent can run it and the user finishes sign-in in the browser that opens. Where no browser can open (a sandbox, CI), it stops at once with `LOGIN_REQUIRES_BROWSER`; create the site without an account instead with `fimo new <dir> --yes --json` (`fimo new --instructions` prints the guide).
14
+
13
15
  ```bash
14
16
  fimo whoami # show the currently signed-in user + active organization
15
17
  fimo logout # revoke the current session and clear local credentials
@@ -84,7 +84,7 @@ Every command that takes agents accepts the same selection inputs:
84
84
  - **Additional** — agents that get the global bootstrap skill installed. The popular ones (`claude-code`, `cursor`, `codex`, `opencode`, `windsurf`, `gemini-cli`, `hermes`) appear at the top of the picker; the full list of supported agents remains available below them. Agents already set up on the machine are pre-checked.
85
85
  - `--agents=none` (only `fimo init`) — skip the global skill entirely.
86
86
 
87
- In headless contexts (CI, agent-spawned commands), pass the flag explicitly. Env-var detection (only Claude Code's `CLAUDECODE` / `CLAUDE_CODE_ENTRYPOINT`) silently targets `claude-code` if the flag is omitted; every other agent must be named explicitly with `--agents` in a headless shell, or the command exits with "No agents detected and no --agents flag passed."
87
+ In headless contexts (CI, agent-spawned commands), pass the flag explicitly. Env-var detection (only Claude Code's `CLAUDECODE` / `CLAUDE_CODE_ENTRYPOINT`) silently targets `claude-code` if the flag is omitted; every other agent must be named explicitly with `--agents` in a headless shell, or the command exits with "No agents detected and no --agents flag passed." `fimo new` takes no agent flags and installs no skill. A non-interactive `fimo init` without `--skills` installs no skill and needs no agent; with `--skills` and no agent found, it still sets up the site and skips the skill install with a warning.
88
88
 
89
89
  ## Always current, never stale
90
90
 
@@ -15,6 +15,8 @@ fimo assets upload ./hero.jpg --name "Hero Image" --parent-id "<folder-uuid>"
15
15
  fimo assets upload ./screenshot.png --folder-path ".agents/<session-id>/screenshots"
16
16
  ```
17
17
 
18
+ Upload options are `--name`, `--parent-id`, and `--folder-path`. Set alt text in the content media field's `alt` value or the rendering component; upload does not accept `--alt`.
19
+
18
20
  Response (JSON) — the full asset object, wrapped in a `data` envelope:
19
21
 
20
22
  ```json
@@ -32,7 +32,7 @@ fimo --branch <name> <command> # peek at another Branch for one command (does n
32
32
  | `fimo branch -d <name>` | `git branch -d` | Delete a Branch — tears down its sandbox, Neon branch, and R2 prefix. Refuses `main` and `prod`. |
33
33
  | `fimo checkout <name>` | `git checkout` | Switch to a Branch (checks out the matching git branch; the app derives its Branch from that branch at startup). `-b` creates + switches; `--from <branch>` sets the parent. |
34
34
  | `fimo switch <name>` | `git switch` | Switch to an existing Branch. Takes only `<name>` (no `-b`/`--from`) — use `fimo checkout -b` to create + switch. |
35
- | `fimo pull` | `git pull` | Sync the current Branch's data plane (DB/assets) down from its parent. `--from <branch>` syncs from an explicit ancestor. |
35
+ | `fimo pull` | `git pull` | Fast-forward the local checkout to the Branch's latest code on Fimo. Never changes the Branch on the server. |
36
36
  | `fimo diff [from] [to]` | `git diff` | Two-Branch diff across all surfaces. Defaults `from` = current Branch, `to` = `main`. `--surface <name>` limits to one; `--json`; `--no-color`. |
37
37
  | `fimo status` | `git status` | Multi-surface status for the current Branch vs its parent. See below. |
38
38
  | `fimo merge <from>` | `git merge` | Merge another Branch into the current one (multi-surface, atomic, interactive conflict resolver). See below. |
@@ -95,7 +95,15 @@ fimo merge feat/seo --allow-direct-merge # override the "don't merge straight
95
95
 
96
96
  ## `fimo pull`
97
97
 
98
- Syncs the current Branch's data plane from its parent (or `--from <ancestor>`). Conflicts currently resolve **parent-wins** automatically (a future release adds per-row picks). Use it to refresh a stale feature Branch with the latest `main` content/schema state.
98
+ Brings the current Branch's latest code from Fimo into the local checkout, like `git pull --ff-only fimo <branch>`. Run it before editing locally when the Branch may have changed elsewhere (Studio, an agent, a teammate's deploy). It only reads from Fimo: it never changes the Branch on the server. To bring `main` into a feature Branch, use `fimo merge main`.
99
+
100
+ It never rebases, merges, or stashes local work. It stops instead:
101
+
102
+ - `ENV_BRANCH_BEHIND_DIRTY` — the checkout is behind and has uncommitted changes. Commit or stash them, then run `fimo pull` again.
103
+ - `ENV_BRANCH_DIVERGED` — local commits and remote commits both exist. Run `git pull --rebase fimo <branch>`, fix any conflicts, then `fimo deploy`.
104
+ - `ENV_BRANCH_MISMATCH` — the git checkout is on another branch, or a detached HEAD. Run `fimo checkout <branch>`.
105
+
106
+ `--json` returns `details.commits_pulled` and `details.head` (the checkout's commit afterwards).
99
107
 
100
108
  ## Publishing — `fimo publish` vs `fimo deploy --publish`
101
109
 
@@ -81,7 +81,17 @@ fimo entries bulk-update <TypeName> (--file <path> | --stdin)
81
81
  fimo entries bulk-delete <TypeName> (--ids <id1>,<id2> | --where '<json>') [--locale es]
82
82
  ```
83
83
 
84
- `--body` is a **required** option on `create` and `update`. Run `fimo skills get fimo-code --ref content/richtext` before constructing an entry payload: slug belongs inside `data`, media has a specific shape, and richtext must be Tiptap JSONContent.
84
+ `create` and `update` require `--body` with a `data` envelope. The content type is positional. For JSON files, use `bulk-create` or `bulk-update` with their documented array formats.
85
+
86
+ ```bash
87
+ fimo entries create BlogPost --body '{"data":{"slug":"hello","title":"Hello"}}'
88
+ fimo entries update BlogPost <id> --body '{"data":{"title":"Updated"}}'
89
+ fimo entries list BlogPost --where '{"slug":"hello"}'
90
+ ```
91
+
92
+ For `get`, `update`, and `delete`, use the UUID returned as `id` by create/list. To find an entry by slug, filter with `list --where` as above, then use its `id`.
93
+
94
+ Run `fimo skills get fimo-code --ref content/richtext` before constructing an entry payload: slug belongs inside `data`, media has a specific shape, and richtext must be Tiptap JSONContent.
85
95
 
86
96
  `entries list` accepts the same read query surface as generated hooks:
87
97
 
@@ -15,7 +15,6 @@ Before deploying, Fimo fast-forwards a clean checkout that is behind and stops o
15
15
  ```bash
16
16
  fimo deploy # preview only (default; reversible)
17
17
  fimo deploy -m "<commit message>" # commit pending + push + sandbox sync
18
- fimo deploy --no-restart # skip dev-server restart (HMR-safe changes only)
19
18
  fimo deploy -m "<commit message>" --publish # also publish a new live version
20
19
  ```
21
20
 
@@ -23,7 +22,6 @@ fimo deploy -m "<commit message>" --publish # also publish a new live version
23
22
  - **`fimo deploy --publish`** — same as above, then triggers a live publish and prints the live URL. Runs from the configured Production source Branch only. **Only use `--publish` when the user signals "ship it"** — first-time site completion, or an explicit "publish" / "go live" request. Otherwise stick to plain `fimo deploy`. (For a _versioned_ prod release, use `fimo publish` instead — see below.)
24
23
  - **`-m`** is the commit message used when there are uncommitted local changes; required in non-interactive shells. Omit if the working tree is already clean.
25
24
  - **`--description "<why>"`** — the commit body for those changes: why they were made. Teammates and agents that later edit the same files read it, for example when a merge conflicts. Pass it with `-m` when the reason is not obvious from the diff.
26
- - **`--no-restart`** — tells the sandbox to skip the dev-server restart and let Vite HMR pick up the change. Shaves ~3s per deploy. A deploy that carries changed variables restarts anyway. See "Skipping the dev-server restart" below for when it's safe.
27
25
 
28
26
  ## Reading deploy destinations
29
27
 
@@ -89,7 +87,7 @@ Redirects, response headers, and URL shape belong in
89
87
 
90
88
  This is a **performance optimization, only worth doing when you already know a deploy is coming** (the developer asked to publish, or you're confident they'll want a hosted preview soon). If you're just iterating locally, skip it — don't deploy pre-emptively. New-project onboarding never needs it: its automatic first preview deploy is the warm-up.
91
89
 
92
- The first deploy of a project's life pays a one-time cost: the sandbox has to provision (create the VM, install the user's deps if they differ from the template's baked ones, start the dev server) — about 15-30s. Every deploy after that lands on a warm sandbox (~10s, or ~4s when you also use `--no-restart` and the lockfile hasn't changed).
90
+ The first deploy of a project's life pays a one-time cost: the sandbox has to provision (create the VM, install the user's deps if they differ from the template's baked ones, start the dev server) — about 15-30s. Every deploy after that lands on a warm sandbox (~4-10s).
93
91
 
94
92
  **To hide that one-time cost, kick off an early deploy in the background while you keep working.** The provisioning happens during your generation work, so by the time the developer wants a hosted preview, the sandbox is already warm and the deploy is fast.
95
93
 
@@ -99,29 +97,6 @@ fimo deploy -m "chore: init" & # background; keep generating code while i
99
97
 
100
98
  There's nothing special about this — it's the same `fimo deploy` you'd run later. The `-m` is the commit message for any files `validate` writes via codegen; pick a sensible conventional-commit string (e.g. `chore: init`, `chore: scaffold`). The point is purely the timing: pay the provisioning tax up front instead of when the user is waiting on a result. **This is also the only path that installs your project's deps on the sandbox** — if you skip it, the first interactive deploy will pay both costs.
101
99
 
102
- ## Skipping the dev-server restart
103
-
104
- `fimo deploy --no-restart` tells the API not to restart the sandbox's dev server after pulling new code. Vite's HMR picks up the change instead, which is what it's designed for — 3+ seconds saved per deploy.
105
-
106
- **Use `--no-restart` when you only touched HMR-safe files:**
107
-
108
- - Anything under `src/**` (components, pages, hooks, styles)
109
- - Fixed-path static files under `public/`, such as favicons or `robots.txt` (images and videos belong in the media library, not the repository; see the `fimo-code` skill's non-negotiable boundaries)
110
- - Content / entries / translations / form definitions (JSON the Fimo runtime hot-loads)
111
-
112
- **Do NOT use `--no-restart` when you touched any of these — they require a fresh dev server:**
113
-
114
- - `vite.config.*` (Vite plugin or config changes)
115
- - `react-router.config.*` (router config)
116
- - `tsconfig.json` (TypeScript compiler)
117
- - `.env` (env vars are read at process start)
118
- - `package.json` or any lockfile (dep changes)
119
- - Anything under `.fimo/` (Fimo's own pre-build / runtime config)
120
-
121
- **When in doubt, omit the flag.** The default (restart) is the safe choice — a wasted restart costs 3 seconds; a missing one costs the user serving stale code until they notice and re-deploy.
122
-
123
- **One case is handled for you:** if the deploy changes the project's route set (a page added, removed, or moved), the API tells the preview to reload regardless of this flag. A router builds its route table once per document, so the new page would otherwise exist but be unreachable — missing from the Studio route selector and 404-ing from the site's own links. This costs a page load, not a restart.
124
-
125
100
  ## Publishing: `fimo deploy --publish` vs `fimo publish`
126
101
 
127
102
  Use `fimo deploy --publish` to push and publish local changes. Use `fimo publish` to publish the revision already on the Fimo remote without pushing. Both target the configured Production source Branch.
@@ -51,7 +51,7 @@ Global flags: `--project <id>` / `-C, --cwd <dir>` for project resolution, `--or
51
51
  When a user says "I want to change my website's URL," ask which case fits:
52
52
 
53
53
  - **"It's fine as-is, just nicer"** → `rename-default` or `suggest-default`. Free, instant, no DNS.
54
- - **"I own example.com already"** → `add example.com`. Pay as you go or higher. They configure CNAME at their registrar.
54
+ - **"I own example.com already"** → `add example.com`. Starter or higher. They configure CNAME at their registrar.
55
55
  - **"I want to buy a domain"** → `search` → `pricing` → `buy`. The registered-domains feature flag and an eligible plan must be on (the flag is not enabled in every environment).
56
56
 
57
57
  If they aren't sure, run `fimo domains suggest-default` first — it's free, takes one step, and a good fallback if they don't want to commit to a domain purchase.
@@ -60,7 +60,7 @@ If they aren't sure, run `fimo domains suggest-default` first — it's free, tak
60
60
 
61
61
  After the automatic first-preview deploy on a newly created project, offer a cleaner free `*.fimo.site` URL before the first public publish when there is no custom domain and the current default slug still looks generated or was never explicitly chosen. Choosing it now lets the first public launch use the clean URL. Skip the offer if the user already chose the default slug, attached a custom domain, or declined.
62
62
 
63
- The default URL is free and needs no DNS. A custom domain uses the Pay as you go (or higher) workflow above. A default slug can be reserved before publication, but it returns "Project Not Found" until the site is published. Renaming changes the address that will become public, so never silently claim a suggestion:
63
+ The default URL is free and needs no DNS. A custom domain needs Starter or higher, as above. A default slug can be reserved before publication, but it returns "Project Not Found" until the site is published. Renaming changes the address that will become public, so never silently claim a suggestion:
64
64
 
65
65
  1. Run `fimo domains suggest-default --base "<brand>" --json` to get candidates.
66
66
  2. Show the candidates and ask the user to choose one explicitly.
@@ -72,7 +72,7 @@ Choosing the slug does not publish the site. The first successful `fimo deploy -
72
72
 
73
73
  The CLI never charges directly. Two distinct money paths:
74
74
 
75
- 1. **Pay as you go or higher** — gates custom-domain operations. A valid card activates Pay as you go through the Fimo web app (Hyperline-hosted checkout). When a Free user runs a gated command they get a 403 with the billing URL; surface it as-is to the user.
75
+ 1. **Starter or higher** — gates custom-domain operations. Starter or Pro is chosen in the Fimo web app (Hyperline-hosted checkout). When a Free user runs a gated command they get a 403 with the billing URL; surface it as-is to the user.
76
76
  2. **Domain registration** — `fimo domains buy` creates a Hyperline invoice with `payment_method_strategy: 'external'` and returns a `checkoutUrl`. The user opens that URL in a browser to pay. **No money moves until they pay the invoice.** That's why `--yes` on `buy` is safe: it queues an invoice; the human still has to consent at checkout.
77
77
 
78
78
  Domain prices come from name.com via the registrar reseller. They vary by TLD and can change. Pricing is in USD (cents in the API, formatted as dollars in CLI output).
@@ -121,7 +121,7 @@ Propagation: typically 15–30 minutes, up to 48 hours rarely.
121
121
  ## Common errors
122
122
 
123
123
  - **"Project Not Found" on a new URL or custom domain.** The route exists but the site was never published — run `fimo deploy --publish`.
124
- - **"Custom domains require Pay as you go or higher."** — add a card at `/app/billing`, then retry. Free users can still run `list`, `rename-default`, `suggest-default`, `search`, and `pricing`.
124
+ - **"Custom domains require Starter or higher."** — choose a plan at `/app/billing`, then retry. Free users can still run `list`, `rename-default`, `suggest-default`, `search`, and `pricing`.
125
125
  - **"Domain purchase is not enabled on this account."** — the registered-domains feature flag is off on this API instance. Contact support.
126
126
  - **"This URL is not available."** — slug or hostname collides with another project or is reserved.
127
127
  - **"That's a Fimo-owned domain."** — user tried `add <something>.fimo.site`. Use `rename-default` instead.
@@ -32,7 +32,7 @@ fimo history list --all-pages
32
32
  ```
33
33
 
34
34
  The list also reports compressed snapshot usage and the current retention period. Restore points expire after 1 day on
35
- Free, 30 days on Pay as you go, or 90 days on Premium and Pro. The expiry is fixed when each point is created.
35
+ Free, 30 days on Starter, or 90 days on Premium and Pro. The expiry is fixed when each point is created.
36
36
 
37
37
  ## Restore safety
38
38
 
@@ -10,30 +10,30 @@ fimo init [dir] [options]
10
10
 
11
11
  `fimo init` runs the full onboarding in one shot:
12
12
 
13
- 1. **Signs in automatically** — if there's no session it opens the browser loopback login. In `--json` / non-TTY with no session it fails with `NOT_AUTHENTICATED` (run `fimo login` first).
13
+ 1. **Signs in automatically** — if there's no session it opens the browser loopback login. In `--json` / non-TTY with no session it fails with `NOT_AUTHENTICATED`: run `fimo login` in a terminal first, or create the site without an account with `fimo new <dir>` (see `account.md`).
14
14
  2. **Resolves the project** — with `--project-id <id>` it sets up the named Fimo site: a project with no code yet is scaffolded as a fresh site, while an existing repository is cloned. Without it, `init` creates a NEW project. An interactive TTY shows a "Create new / Link existing" picker; non-interactive shells default to create-new. New sites use the Next.js App Router by default; `--framework react-router`, `--framework vite`, `--framework astro`, and `--framework sveltekit` select the other minimal framework-native shells.
15
15
  3. **Installs dependencies** — prompts for the package manager, or honor `--package-manager <pm>` / `--no-install`.
16
16
  4. **Optionally sets up Fimo skills** — confirm prompt, or `--skills` / `--no-skills`.
17
17
 
18
18
  Generated pnpm projects pin `pnpm@10.26.0` and carry project-owned `pnpm-workspace.yaml#strictDepBuilds: true` and `#allowBuilds` settings. Generated Bun projects trust the same required packages through `package.json#trustedDependencies`. Keep the selected package manager's policy committed. When adding a dependency with an install script, review it before extending that policy; never replace it with a blanket allow-all install.
19
19
 
20
- | Flag | Required | Purpose |
21
- | ---------------------------- | ----------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- |
22
- | `[dir]` positional | yes in non-TTY for create-new | Target directory (e.g. `my-site`) |
23
- | `--project-id <id>` | no | Set up the named Fimo site: scaffold and push a fresh site when it has no code yet, otherwise clone it. |
24
- | `--org <id>` | no | Target organization **id** when creating (use the `ID` column from `fimo orgs list`, NOT the slug). Picker shown interactively if omitted and TTY. |
25
- | `--branch <name>` | no | Branch to check out when linking an existing project (defaults to `main`). |
26
- | `--env <name>` | no | Rejected as a Branch selector; use `--branch <name>`. |
27
- | `--framework <framework>` | no | New-project scaffold: `nextjs` (App Router, default), `react-router`, `vite` (React SPA), `astro`, or `sveltekit`. Existing repositories are preserved. |
28
- | `--package-manager <pm>` | no | `npm` \| `pnpm` \| `yarn` \| `bun`. |
29
- | `--install` / `--no-install` | yes in non-TTY | Install deps after checkout (or skip it). |
30
- | `--skills` / `--no-skills` | yes in non-TTY | Install the global Fimo skill (or skip it). |
31
- | `--agents <list>` | no | Comma-separated agent IDs (e.g. `claude-code,cursor`). Pass `none` to skip installing the global skill. |
32
- | `-a, --agent <id>` | alternative | Repeatable form: `-a claude-code -a cursor`. |
33
- | `--template-root <path>` | no | Override the bundled template (development only). |
34
- | `-y, --yes` | no | Run non-interactively using defaults (no prompts). |
35
-
36
- In a non-TTY shell the create-new path requires `[dir]`, `--install` / `--no-install`, and `--skills` / `--no-skills` (and `--org` if you have no active org and belong to multiple orgs). Without them the command exits with `Cannot prompt in a non-interactive shell.`
20
+ | Flag | Required | Purpose |
21
+ | ---------------------------- | ----------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
22
+ | `[dir]` positional | yes in non-TTY for create-new | Target directory (e.g. `my-site`) |
23
+ | `--project-id <id>` | no | Set up the named Fimo site: scaffold and push a fresh site when it has no code yet, otherwise clone it. |
24
+ | `--org <id>` | no | Target organization **id** when creating (use the `ID` column from `fimo orgs list`, NOT the slug). Picker shown interactively if omitted and TTY. |
25
+ | `--branch <name>` | no | Branch to check out when linking an existing project (defaults to `main`). |
26
+ | `--env <name>` | no | Rejected as a Branch selector; use `--branch <name>`. |
27
+ | `--framework <framework>` | no | New-project scaffold: `nextjs` (App Router, default), `react-router`, `vite` (React SPA), `astro`, or `sveltekit`. Existing repositories are preserved. |
28
+ | `--package-manager <pm>` | no | `npm` \| `pnpm` \| `yarn` \| `bun`. |
29
+ | `--install` / `--no-install` | no | Install deps after checkout (or skip it). |
30
+ | `--skills` / `--no-skills` | no | Install the global Fimo skill (or skip it). |
31
+ | `--agents <list>` | no | Comma-separated agent IDs (e.g. `claude-code,cursor`). Pass `none` to skip installing the global skill. Non-interactive runs without it use `none`, unless `--skills` is passed. |
32
+ | `-a, --agent <id>` | alternative | Repeatable form: `-a claude-code -a cursor`. |
33
+ | `--template-root <path>` | no | Override the bundled template (development only). |
34
+ | `-y, --yes` | no | Run non-interactively using defaults (no prompts). |
35
+
36
+ In a non-TTY shell (or with `-y` / `--json`) the create-new path requires `[dir]`, and `--org` if you have no active org and belong to multiple orgs. Everything else takes a default: dependencies install with the detected package manager unless you pass `--no-install`, and no skill is installed unless you pass `--skills`.
37
37
 
38
38
  ### Non-interactive setup
39
39
 
@@ -105,6 +105,10 @@ Use `fimo link <projectId>` to adopt the application in the current folder witho
105
105
  fimo link <projectId> --relink
106
106
  ```
107
107
 
108
+ Linking keeps every word typed in the code, where Fimo Studio shows "Nothing to edit". When people will edit the site,
109
+ load `fimo-migration` and follow its source-backed, same-framework path: its content pass moves that
110
+ text to labels and the CMS, and its `editable-text` guardrail proves it.
111
+
108
112
  ## What gets written (create-new path)
109
113
 
110
114
  `fimo init` (create-new path) scaffolds:
@@ -33,7 +33,7 @@ generated client hydration helper where required.
33
33
 
34
34
  ## Entry payload
35
35
 
36
- CLI entry writes put every value, including the collection slug, under `data`:
36
+ `entries create` and `entries update` take `--body` with every field, including the collection slug, under `data`:
37
37
 
38
38
  ```json
39
39
  {
@@ -46,7 +46,7 @@ CLI entry writes put every value, including the collection slug, under `data`:
46
46
  }
47
47
  ```
48
48
 
49
- Do not put `slug` at the top level; unsupported top-level keys are stripped.
49
+ Keep `slug` inside `data`; `entries create` rejects unsupported top-level keys.
50
50
 
51
51
  Slugs should be lowercase, hyphenated, stable, meaningful, and unique per content type. Fimo slugifies the supplied candidate. If omitted, Fimo generates one, which is unsuitable for content with durable public URLs.
52
52
 
@@ -20,11 +20,11 @@ into a real Fimo project without silently dropping source material.
20
20
  > supports the source framework, preserve it explicitly and verify the runtime
21
21
  > before importing data.
22
22
  >
23
- > Use the CLI invocation selected for this flow for every `fimo` command in the migration. Otherwise use `npx fimo@latest`; do not install it globally.
23
+ > Use the pinned CLI invocation selected for this flow for every `fimo` command in the migration (see CLI provenance); do not install it globally.
24
24
 
25
25
  The first pass is a faithful migration, not a framework conversion. Detect the
26
- source framework before creating the target and pass it explicitly to
27
- `fimo migrate init`. For a Next.js source, use `--framework nextjs`; never rely
26
+ source framework before setup. When `fimo migrate init` creates the target, pass
27
+ it explicitly: for a Next.js source, use `--framework nextjs`; never rely
28
28
  on the React Router default. The setup receipt must report the target runtime
29
29
  framework, and a mismatch is a setup failure before any schemas, entries,
30
30
  assets, labels, or forms are imported.
@@ -90,30 +90,43 @@ artifact, and record which one.
90
90
 
91
91
  ## Initialized target precondition
92
92
 
93
- Before workers start, the root process must establish a real Fimo project and
94
- environment, link the migration checkout to it, and prove the data plane is
95
- reachable with a read such as `fimo schemas list -C <target> --branch <branch>` using
96
- the selected pinned CLI. Give workers the project id, environment, exact CLI
97
- invocation, and verification command. Generated `.fimo` JSON without a
98
- successful platform read is not initialization.
99
-
100
- Pick the setup path from the evidence:
101
-
102
- - **Source-backed, same framework** — copy or `git worktree` the source into the
103
- target directory first, then run `fimo link -C <target> --branch <branch>`
104
- (`fimo link <project-id> -C <target> --branch <branch>` when the owner supplied an
105
- id). Link creates or selects the project, keeps the source's code, framework,
106
- git history, and `origin`, initializes a repository when the copy has none,
107
- and adds only the Fimo dependency, `.fimo/project.json`, the `fimo` remote,
108
- and `.fimo/config.json#runtime.framework`. It never overlays a template, so
109
- the target must already contain the source.
110
- - **Empty target, or an explicit framework conversion** — `fimo init` or
111
- `fimo migrate init <dir>` with the chosen `--framework`. Both refuse a
112
- non-empty target and write nothing when they refuse.
113
-
114
- If authentication, organization selection, project creation, environment
115
- resolution, linking, or the verification read fails, stop before workers and
116
- report the exact failed command and setup requirement.
93
+ This is the one setup decision; every other reference points here. Pick the
94
+ row that matches the user's request and the folder's state. When the target is
95
+ genuinely unclear, ask once in the preflight question batch.
96
+
97
+ | Starting point | Setup | Original evidence |
98
+ | -------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
99
+ | The user asked to put this existing folder on Fimo; it is already linked | Reuse it. Verify its project, branch, and framework. Run `fimo link <same-id> -C <folder>` only to repair it. | Keep the baseline below. |
100
+ | The same, but the folder is not linked | Keep the baseline, then run `fimo link -C <folder> --branch <branch>`, with the project id when one was chosen. | Keep the baseline below. Never reset, overwrite, or discard existing work. |
101
+ | The source is read-only input, or the user asked for a separate target; same framework | Copy or clone the source into the target first. If the copy kept a `.fimo/project.json`, reuse that project or resolve it on purpose. Then run `fimo link -C <target> --branch <branch>`. | The original stays read-only. A `git worktree` shares the repository's config and remotes: use an independent copy or clone when adding the `fimo` remote must not touch the original. |
102
+ | An empty or new target with nothing to adopt, or an explicit framework conversion | `fimo migrate init <target> --framework <chosen>` (see Target setup). Never overlay a template on populated source. | The source repository or export stays separate. |
103
+
104
+ The baseline is an exact copy of the folder's pre-migration state, kept outside
105
+ the folder. A commit plus a detached worktree is enough only when the tree is
106
+ clean; otherwise also keep the dirty and untracked files. Never copy secret
107
+ values into evidence.
108
+
109
+ `fimo link` keeps the folder's code, framework, git history, branches, and
110
+ `origin`, initializes a repository when there is none, and adds only the Fimo
111
+ dependency, `.fimo/project.json`, the `fimo` remote, and
112
+ `.fimo/config.json#runtime.framework`. It never overlays a template.
113
+
114
+ Never invent a project or organization id, and never silently relink a folder
115
+ to another project (`fimo link --relink` needs the owner's explicit choice).
116
+ In a non-interactive shell, `fimo link` on an unlinked folder without an id,
117
+ and `fimo migrate init` without `--project-id`, create a new project in the
118
+ active organization, else the only one; `fimo migrate init` also takes `--org`. With several organizations and none
119
+ active, the CLI fails clearly: ask the user which one. Ask only for a selection
120
+ the CLI cannot resolve.
121
+
122
+ Every row ends at the same gate. Before workers start, prove the actual project
123
+ id and branch, a runtime framework that matches the source or the chosen
124
+ conversion, the selected pinned CLI, and a successful data-plane read such as
125
+ `fimo schemas list -C <target> --branch <branch>`. A local marker, generated
126
+ `.fimo` JSON, or a `ready: true` receipt without that read is not
127
+ initialization. Give workers the project id, branch, exact CLI invocation, and
128
+ verification command. If any setup step fails, stop before workers and report
129
+ the exact failed command and setup requirement.
117
130
 
118
131
  ## Core contract
119
132
 
@@ -135,7 +148,9 @@ report the exact failed command and setup requirement.
135
148
  ports the source's APIs, loaders, hardcoded content, integrations, and
136
149
  visible behavior into the new framework unchanged, and Fimo schemas,
137
150
  payloads, imports, and code wiring happen later through the content workers
138
- (`references/workers/content-execution.md`). If the framework or hosting
151
+ (`references/workers/content-execution.md`). That content pass is part of the
152
+ migration, never a follow-up: the `editable-text` guardrail
153
+ (`references/qa.md`) fails while visible text is still typed in the code. If the framework or hosting
139
154
  setup is unclear or unsupported, stop and ask instead of guessing,
140
155
  converting it, or deleting provider-specific files.
141
156
  - Inventory provider-specific files and rules before editing them. Classify each
@@ -247,25 +262,24 @@ report the exact failed command and setup requirement.
247
262
 
248
263
  ## Target setup
249
264
 
250
- The target is its own Fimo project directory. The client source checkout is
251
- read-only evidence: never run setup inside it, never modify it, and never
252
- hand-write a `.fimo/project.json` marker to fake a link.
253
-
254
- `fimo migrate init` is the setup gate for an empty target; a target that
255
- already holds the copied source is set up with `fimo link` instead (see
256
- Initialized target precondition). `fimo migrate init` validates the target and
257
- CLI auth, then delegates project selection and creation to the standard
258
- `fimo init` flow (same options, no separate creation path), and returns a setup
259
- receipt covering auth, the target link, the migration directory, and readiness.
260
- It fails with a structured error when auth is missing, the target is missing or
261
- invalid, or the project or organization is inaccessible. Both forms need a real
262
- ID supplied by the owner — without one, stop with an unresolved owner action
263
- instead of inventing an ID:
264
-
265
- - Link an owner-supplied (empty) project:
265
+ Choose the setup row in "Initialized target precondition". Never modify an
266
+ original that the row keeps read-only, and never hand-write a
267
+ `.fimo/project.json` marker to fake a link.
268
+
269
+ `fimo migrate init` serves the empty-target and conversion row. It validates
270
+ the target and CLI auth, then delegates project selection and creation to the
271
+ standard `fimo init` flow (same options, no separate creation path), and
272
+ returns a setup receipt covering auth, the target link, the migration
273
+ directory, and readiness. It fails with a structured error when auth is
274
+ missing, the target is missing or invalid, the target is populated but not
275
+ linked, or the project or organization is inaccessible:
276
+
277
+ - Use an existing (empty) project:
266
278
  `fimo migrate init <target-dir> --project-id <projectId> --framework <framework> --source-platform <platform>`
267
- - Create a new project in an owner-supplied organization:
268
- `fimo migrate init <target-dir> --org <organizationId> --framework <framework> --source-platform <platform>`
279
+ - Create a new project:
280
+ `fimo migrate init <target-dir> --framework <framework> --source-platform <platform>`,
281
+ adding `--org <organizationId>` when the precondition's organization rule
282
+ needs it.
269
283
 
270
284
  `--source-platform` names what the site is migrated from (`wordpress`, `nextjs`,
271
285
  `astro`, `react-router`, `webflow`, `framer`, `squarespace`, `wix`, `carrd`,
@@ -277,9 +291,11 @@ framework files before starting workers. A Next.js target must still have its
277
291
  Next runtime/configuration (`next.config.*` and the source router shape), not a
278
292
  React Router scaffold.
279
293
 
280
- Setup scaffolds the target and pushes its initial commit; that is the only
281
- remote write it performs — it never pushes schemas, uploads assets, or imports
282
- entries. Setup itself never deploys or publishes; the one new-project preview
294
+ `fimo migrate init` on a new target scaffolds it and pushes its initial
295
+ commit. `fimo link` and reusing a linked folder scaffold and push nothing; the
296
+ first commit waits for `fimo deploy`. Project creation or linking and that
297
+ initial push are the only remote writes setup performs — it never pushes
298
+ schemas, uploads assets, or imports entries. Setup itself never deploys or publishes; the one new-project preview
283
299
  deploy happens only after successful local QA (see Completion and deployment).
284
300
 
285
301
  ## Command surface
@@ -289,20 +305,18 @@ up and nothing else: it never reads, fetches, or renders the source site, and
289
305
  it produces no evidence pack, draft, manifest, or scaffold to inspect. Reading
290
306
  the source is your job, and every finding is yours to prove.
291
307
 
292
- - `fimo migrate init <dir> --project-id <projectId>` — link an owner-supplied
293
- project.
294
- - `fimo migrate init <dir> --org <organizationId>` — create a new project.
308
+ - `fimo migrate init <dir> --project-id <projectId>` — use an existing project.
309
+ - `fimo migrate init <dir> [--org <organizationId>]` — create a new project.
295
310
  - Both accept `--framework`, `--source-platform` (see Target setup),
296
311
  `--install` / `--no-install`, `--agents` / `-a`, `--mode`, `--template-root`,
297
312
  and `--json`; `-C <dir>` replaces the positional for an already-linked target.
298
313
 
299
- The link/creation and its initial commit push are the only remote writes. Data
300
- writes go through the normal commands against the linked target:
314
+ Setup (`fimo migrate init` or `fimo link`, chosen in Initialized target
315
+ precondition) makes only the remote writes listed in Target setup. Data writes
316
+ go through the normal commands against the linked target:
301
317
 
302
318
  - `fimo schemas push`, `fimo assets upload`, `fimo entries create|update`,
303
319
  `fimo singles update`, `fimo labels set|set-many`, `fimo forms push`.
304
- - `fimo link`: project creation or selection plus the in-place adoption of a
305
- copied source target.
306
320
  - `fimo deploy` / `fimo publish` — owner-approved only.
307
321
 
308
322
  ## Migration loop
@@ -312,7 +326,7 @@ writes go through the normal commands against the linked target:
312
326
  edit, or move environment values until the user answers every consent gate.
313
327
  2. Run the setup path from "Initialized target precondition" and inspect the
314
328
  initialized target before any worker edits it. A `fimo link` adoption keeps
315
- the source framework; the `fimo init` / `fimo migrate init` paths choose the
329
+ the source framework; the `fimo migrate init` path chooses the
316
330
  target framework through the same canonical option as
317
331
  `fimo init`: pass the detected source framework for a source-backed
318
332
  migration, the framework the user explicitly chose for a conversion, and —
@@ -404,8 +418,8 @@ Use one final status:
404
418
 
405
419
  Never call a migration complete when CMS entries, media mappings, forms, route
406
420
  coverage, or migration-induced content-delivery regressions are unknown. Local
407
- QA remains the acceptance gate. If
408
- `fimo migrate init` created a new Fimo project, run one `fimo deploy` after QA
421
+ QA remains the acceptance gate. If setup created a new Fimo project
422
+ (`fimo migrate init` or `fimo link`), run one `fimo deploy` after QA
409
423
  and return its preview and dashboard links; skip it when the user said not to
410
424
  deploy or `FIMO_MIGRATION_NO_DEPLOY=1` is set. For an existing linked project,
411
425
  offer the deployment and wait for approval. Never run `fimo publish` without an
@@ -10,7 +10,7 @@ items.
10
10
 
11
11
  Every data-plane write in this contract targets the linked project from
12
12
  workflow Phase 0. Planning and payload authoring need no link; running the
13
- writes does. When no owner-supplied target exists, the writes stay unresolved
13
+ writes does. When setup cannot produce a linked target, the writes stay unresolved
14
14
  owner actions; do not fake a link to make them pass.
15
15
 
16
16
  ## Media Files
@@ -182,6 +182,13 @@ check is the acceptance evidence.
182
182
  or imprint.
183
183
  - `links-resolve`: every internal link rendered on the inventoried routes
184
184
  points at an inventoried route or an explicitly allowed path prefix.
185
+ - `editable-text` (required in every inventory): every visible body text node
186
+ sits inside an element a Fimo primitive renders, so an editor can change it
187
+ in Studio. A faithful port is not editable yet: text still typed in the code
188
+ shows "Nothing to edit". Move it to a label or a CMS field. List in `allow`
189
+ only the exact text the owner keeps in code, such as a brand glyph or a
190
+ legal line, and record why in the migration report. Assistive and hidden
191
+ text does not count.
185
192
 
186
193
  Internal links are resolved against the final document URL and any
187
194
  `<base href>`; query and fragment do not change route identity. An `allow`
@@ -203,14 +210,18 @@ check is the acceptance evidence.
203
210
  "source": "<owner decision>"
204
211
  },
205
212
  { "id": "footer-privacy", "kind": "required-link", "href": "/legal/privacy", "source": "<source navigation>" },
206
- { "id": "nav-resolves", "kind": "links-resolve", "allow": ["/blog"], "source": "<source navigation>" }
213
+ { "id": "nav-resolves", "kind": "links-resolve", "allow": ["/blog"], "source": "<source navigation>" },
214
+ { "id": "editable-text", "kind": "editable-text", "allow": [], "source": "Fimo: visitors' text is editable" }
207
215
  ]
208
216
  }
209
217
  ```
210
218
 
211
219
  2. The validator observes the rendered application, not files in the
212
- repository. For a server-rendered target, run the check with `--base-url`
213
- while the built app serves locally. For a client-rendered target, save each
220
+ repository, with Fimo editing metadata on: build and serve with
221
+ `FIMO_EDITING_METADATA=true`, or observe the dev server. Without it no text is
222
+ marked editable and `editable-text` fails as unmeasured. For a
223
+ server-rendered target, run the check with `--base-url` while the app serves
224
+ locally. For a client-rendered target, save each
214
225
  hydrated document from the browser pass as `<captures>/index.html` and
215
226
  `<captures>/<route>.html` and pass `--captures`. Save a JSON sidecar next to
216
227
  each HTML file, such as `index.html.json` or `legal/privacy.html.json`:
@@ -5,7 +5,10 @@ handoff. Do not import entries or rewrite application consumers.
5
5
 
6
6
  1. Trace active source clients, endpoint/query declarations, frontend types,
7
7
  and every consumer before designing schemas. Then inspect their
8
- content-bearing files, inline values, APIs, or CMS sources.
8
+ content-bearing files, inline values, APIs, or CMS sources, and the visible
9
+ text typed in route and component code: headings, paragraphs, buttons, link
10
+ and navigation text, alt and placeholder text. Each is an item, even when no
11
+ data source holds it.
9
12
  2. Classify each value as collection content, single content, an
10
13
  editor-visible label, or application-owned code. Repetition is evidence,
11
14
  not an automatic collection rule. Assistive text, identifiers, and values