Setup flowcharts
npm run setup runs interactively. It asks grouped questions, derives defaults from previous answers, then writes only the instance-owned files needed for the chosen options.
Use this page when you want to understand the installer flow before running it, or when you want to improve a question group without guessing how the surrounding prompts behave.
Happy path
The happy path keeps optional areas disabled during first setup. It creates a plain instance, writes the core files, and runs verification.
flowchart TD A["Run
npm run setup"] --> C["Core instance
questions"] C --> A0{"Configure
analytics now?"} A0 -->|"No"| I["Access, languages,
and timezone"] I --> L{"Configure jurisdiction
and related pages?"} L -->|"No"| E{"Review public
contact emails?"} E -->|"Yes"| T["Trust, safety,
and security contacts"] E -->|"No"| T T --> B{"Configure
branding now?"} B -->|"No"| W["Write instance
files"] W --> V["Run npm run check"] V --> F["Print next steps"]
Core instance
Core questions identify the short-link service and prepare values used by later groups.
flowchart LR A["Core instance
questions"] --> D["Short domain"] D --> W["Worker name"] W --> O["Owner label"] O --> S["Seed missing
random slug length
as 3"]
The installer does not ask for random slug length. Existing links.random_slug_length values are preserved; missing values are written as 3.
Analytics
Analytics starts as a decision, not a required provider choice. No stays on the happy path.
flowchart TD
A{"Configure
analytics now?"}
A -->|"No"| N["Use disabled
analytics default"]
A -->|"Yes"| P["Analytics provider"]
P --> O["Operator analytics
disclosure"]
O --> R["Operator analytics
retention"]
N --> C["Continue setup"]
R --> CUse Analytics during customization when you are ready to choose providers and retention language.
Access and localization
These questions support protected operational pages, generated language variants, and scheduled-link timestamps.
flowchart LR A["Cloudflare Access
team domain"] --> L["Supported
languages"] L --> T["Operator timezone"] T --> N["Next:
jurisdiction decision"]
The timezone must be an IANA timezone name, such as America/Toronto.
Jurisdiction and contacts
Legal pages can stay disabled during the first setup. The installer still asks for the operator legal name and public reporting contacts so generated pages have accountable defaults.
flowchart TD
A{"Configure jurisdiction
and related pages?"}
A -->|"No"| N["Operator legal
name only"]
A -->|"Yes"| J["Jurisdiction"]
J --> G["Governing law"]
G --> P["Operator and privacy
contacts"]
N --> E{"Review public
contact emails?"}
P --> E
E -->|"Yes"| D["Operator email
domain"]
E -->|"No"| C["Use existing/default
contacts"]
D --> T["Trust & Safety
contact"]
C --> T
T --> R["Response window"]
R --> S["Security contact"]
S --> U["Last updated date"]Use Jurisdiction when you are ready to enable and tune the public legal pages.
Branding
Branding can stay disabled during first setup. If you configure it, text-logo colors are independent from copying full public pages into custom/public.
flowchart TD
A{"Configure
branding now?"}
A -->|"No"| D["Use defaults
from defaults/public"]
A -->|"Yes"| S{"Add slogan
line?"}
S -->|"Yes"| L["Brand slogan
per language"]
S -->|"No"| N["No slogan"]
L --> W["Text logo
first-color portion"]
N --> W
W --> G["Text logo
accent-color portion"]
G --> P{"Advanced:
copy all default pages
to custom/public?"}
P -->|"No"| D
P -->|"Yes"| C["Copy defaults/public
for manual HTML editing"]Choose the advanced copy only when you intend to edit public HTML pages manually.
Write and verify
The last group writes the instance-owned files and verifies the result.
flowchart TD A["Resolved setup
answers"] --> L["custom/v8s-links.txt
created if missing"] L --> C["custom/v8s-site-config.json
updated"] C --> W["wrangler.toml
updated"] W --> V{"Verification
enabled?"} V -->|"Yes"| R["Run npm run check"] V -->|"No or dry-run"| N["Print next steps"] R --> N