Documentation
Deploy static sites from your framework of choice, edit verified HTML and annotated content, manage domains and mail, and use the TagWork workspace suite.
Quick start
Publish a built static site from the browser, CLI or REST API. Hosting supports plain HTML and compiled frontend frameworks; editing capabilities depend on the source format.
1Option 1: Browser Ingestion Bay
Go to TagHost Storefront, drop a single .html file or your compiled dist/ folder, and receive a private sandboxed link instantly.
2Option 2: Terminal CLI
Create a project in Console, build your static site, then upload its output. The React SDK and tag init are optional for this workflow:
npm i -g @taghost/cli tag login # Build your site with its own build command first. # Replace dist with your actual static output folder. tag deploy --dir dist --project YOUR_PROJECT_ID # Plain HTML: use a folder containing index.html and assets.
3Option 3: Edge REST API
curl -X POST https://api.taghost.io/projects \
-H "Authorization: Bearer tag_live_your_token_here" \
-H "Content-Type: application/json" \
-d '{"name": "my-site", "slug": "my-site"}'Frameworks and hosting boundaries
TagHost hosts built static sites from plain HTML, React, Vue, Astro, Svelte, Nuxt, Next.js static exports and other static generators. Hosting does not require the React SDK. Build your site first, then deploy the folder containing its entry HTML and assets.
| Project | Typical static output | Requirement |
|---|---|---|
| Plain HTML | site/ | Upload the folder containing index.html and its assets. |
| React / Vue / Svelte with Vite | dist/ | Run the project build first. |
| Astro | dist/ | Use static output; server output requires a separate runtime. |
| Next.js | out/ | Configure output: export. Request-time SSR/API routes are not hosted. |
| Nuxt | .output/public/ | Generate a static site. |
| SvelteKit | build/ | Configure the static adapter; use its actual output path. |
Hosting and editing are different capabilities. Uploaded, verified plain HTML supports source-based canvas editing. Annotated data-tag text/images can be rewritten at the edge on any static stack; in-preview annotation editing also needs the TagHost runtime. The @taghost/react components and hooks are React-specific conveniences, not a hosting prerequisite.
Compiled framework source editing is limited to exact-lockfile adapter profiles for React + Vite, Vue + Vite and Next.js static export. Those profiles remain unqualified prototypes. Other versions and frameworks retain preview and supported annotated content editing; arbitrary component logic and compiled structure are not generally visually editable.
TagHost does not currently provide general Node.js/SSR hosting or arbitrary customer serverless functions. A working static build does not qualify a framework for source editing.
Tag your content
Annotate text and image elements with data-tag and include the TagHost runtime for in-preview editing. Published content is replaced at the edge. Annotated content works on any static stack; source-level editing remains a gated prototype for exact-lockfile React + Vite, Vue + Vite and Next.js static-export profiles; all profiles are currently unqualified.
<!-- Plain HTML; the same attributes work in JSX or Vue templates. --> <header> <h1 data-tag="hero.title">Ship the code. Hand over the words.</h1> <p data-tag="hero.subtitle">Deploy. Edit supported content. Own your source.</p> </header>
Supported Attributes & Props
data-tagstringUnique dot-notated key binding (e.g. "hero.title", "pricing.badge")data-tag-tokenstringLock mutations to design token palettes (e.g. "colors.brand")<TagForm>componentNative lead capture form with honeypot spam shield and CRM webhookVisual Studio
One visual editor for the whole platform. From any project in the Console, the Visual Studio tab loads the live editor in place — the exact same Studio you get at TagHost Studio.
Click any data-tag node on the canvas to edit copy, swap imagery, or lock a value to a design token.
Toggle desktop and mobile frames with fluid iPhone-style scaling, or detach to a focused full-canvas mode.
Fine-tune colors, typography, spacing, and border radii globally instead of element-by-element.
Edit verified HTML with Code/Split, durable file drafts, responsive styling and publish review. SEO and integrations live in Console → Project settings.
Editing scope: annotated content works on any static stack; uploaded plain-HTML sites get the full canvas (text, styles, structure, pages); source-level editing remains a gated prototype for exact-lockfile React + Vite, Vue + Vite and Next.js static-export profiles, all currently unqualified. Everything else stays preview plus content editing.
Console deep-link
The Console passes the active project straight into the editor. Open the same project with bookmarked context:
https://studio.taghost.io/?project=<id>&name=<name>&slug=<slug>&domain=<domain>&embed=true
With embed=true the editor signals "Studio Exit" back to the Console and returns you to the project overview. Open it without embed=true (or via "Open in Full Studio") for a standalone full-window workspace.
Console
Every project's control surface at console.taghost.io — deploys, domains, content, forms, environment variables and workspace administration. Sign in to an authorized workspace; features and quotas follow its plan.
Your account can belong to multiple workspaces. Projects have their own slug, deploy history and environment variables; customer records are stored in workspace-isolated databases and scoped by project.
Overview, Deploys, Visual Studio, Content, Domains, Forms, Env Vars, Data, Web Security, Analytics, Build & Git and Project settings. Some operational destinations are honest empty states.
Team (members & roles — membership is free on every plan, invitations expire after 14 days and can be resent), Builds (global build log), DNS, and Billing sit at the workspace level and apply across projects.
Owner, Admin, Developer, Editor and Viewer roles gate actions. SEO editing and content authoring follow their API permissions; access settings and billing have stricter role checks.
Deploys & rollbacks
Every build is a versioned artifact. TagHost keeps the build visitors are getting in an Active state and warms up newer builds as Promoting — so you promote, preview, or roll back in one click, or straight from the CLI.
The build marked Active is what visitors receive in every region. A new deploy, say v2.4.1, lands as Promoting while it warms up — it never serves traffic until you promote it.
Click Promote to switch the new build to Active; the previous build is retained so a single click rolls traffic back with no redeploy.
--preview / env-scoped deploys get an isolated URL that production visitors never reach — safe for staging, review, and client sign-off.
The Deploys tab keeps the full history with commit/blame context; any previous build can become the new Active in a click.
# Show the last ten deployments with their states tag rollback --list # 1. v2.4.1 (Promoting) d5f2a1c9 # 2. v2.4.0 (Active) 4f8ab2e6 # 3. v2.3.1 (Previous) bd90c4f1 # Promote a specific build back to Active across all regions tag rollback 4f8ab2e6 # ✓ v2.4.0 promoted to Active
Accounts & API keys
Sign in with Google, GitHub, GitLab, or secure email & password. Every request authenticates with either a cryptographically signed 30-day session or a scoped workspace token.
First-party OpenID Connect & OAuth 2.0 integration. Auto-provisions accounts, verifies emails, and syncs avatars across all TagHost services.
Logging in writes a secure session cookie across .taghost.io, providing single sign-on across Marketing, Console, Studio, and Admin.
WebCrypto PBKDF2-SHA256 with 100,000 iterations and per-user random salts. Single-use hashed tokens for verification, magic links, and password resets.
Generate high-entropy tag_live_* tokens for CI/CD and integrations, scoped to send, read, admin or deploy — no scopes grants full access. Mint and revoke from Console → Account & Settings, or with tag key create|list|rm; revoke compromised keys instantly.
# 1. Authenticate with an API token from Console settings tag login # 2. Check current identity tag whoami # 3. Mint a deploy-scoped key for CI tag key create "GitHub Action" -s deploy # 4. Authenticate REST API with Bearer Token curl -X GET https://api.taghost.io/auth/me \ -H "Authorization: Bearer tag_live_your_token_here"
Onboarding & Workspaces
After signup, users complete a quick onboarding wizard that tailors their dashboard, domain suggestions, and platform tiers to their workload.
Captures whether you are building as an individual developer, professional agency, enterprise team, or student.
Configures recommendations for static hosting, lead capture & email, or visual content editing.
Automatically provisions an isolated managed SQLite database instance dedicated strictly to your workspace.
Teams & roles
Invite collaborators under least-privilege roles. Editors polish copy visually, developers ship deploys and infrastructure, owners manage billing and access.
Platform Operator Admin
Dedicated operator console at admin.taghost.io for platform owners, superadmins, and infrastructure engineers.
Live inspection of all customer workspaces. Instant cryptographic killswitch to quarantine abusive sites or spammers with reason tracking.
Track Stripe MRR, reconcile wire transfers, record manual enterprise invoices, and issue verifiable receipts.
Monitor all apex domains purchased across Name.com and custom hostnames provisioned with managed SSL.
Immutable tamper-evident log of all administrative actions, promotions, token generations, and membership alterations.
SEO & integrations
Open Console → Project → Project settings → SEO & integrations. These are persisted project settings applied by the edge router, not Studio-local draft controls. Build & Git remains a separate destination.
Configure site title/description, social share image, page-specific metadata, canonical/social tags, Google Search Console verification, GA4, Google Tag Manager, Meta Pixel and Plausible. Bounded custom head HTML is validated before injection. Use the settings available in the current editor rather than assuming support for every third-party pixel or arbitrary body scripts.
Settings are synchronized to project-host routing metadata. Published pages receive configured tags and integrations at the edge; generated robots.txt and sitemap.xml are fallbacks where the site does not already provide them. Protected and preview hosts are not intended for indexing.
GET /projects/:id/site-settings PUT /projects/:id/site-settings Authorization: Bearer YOUR_API_TOKEN
Owner/admin/developer/editor can edit SEO settings. Site passwords and access settings require owner/admin. Review the live page after saving and obtain visitor consent where required before loading analytics or marketing integrations. There is no dedicated CLI SEO/pixel command.
Git deploy
Connect a repository and production branch in Build & Git. Authorized GitHub connections can access private repositories; CI can also build and upload private or public projects without giving TagHost a public repository URL.
How it works
- Connect: Project → Build & Git → configure the repository, authorized connection and production branch.
- Push auto-deploy: add the project's webhook (Project → Build & Git) so a push to the production branch deploys.
- Real builds / private repos: build in CI (
npm run build) and deploy the output. - Static output only: TagHost serves the built static output. Dependency installation and framework builds use the configured CI/build integration; serving static output does not provide a Node.js server runtime.
Early access: GitHub write-back
Projects linked to a GitHub repository through the TagHost GitHub App can commit Studio edits on publish. Commit-on-publish is the supported mode; live sync is experimental, and TagHost never force-pushes. A project can also stay inbound only, where TagHost deploys from Git but Studio edits remain TagHost-only until write-back is connected. Three-way conflict resolution and PR review are not available yet.
Safe mode & previews
Renovations happen in a sandbox, never on the live site. Previews are isolated, password-protectable, and every publish is an explicit, diffed decision.
Every draft is applied on top of the last published state. Nothing mutates production until you open the publish review — so a half-finished hero swap never leaks to visitors.
Generate a shareable preview URL for stakeholder sign-off. Add a password when the preview shouldn't be public, then revoke it after approval. Leaving with unstaged edits prompts a discard guard so nothing is lost accidentally.
Multi-Device Responsive Viewports
Test your website across form factors with 1-click device switching in the Studio header:
Full widescreen canvas with desktop navigation and multi-column grid layouts.
768px iPad viewport frame testing medium-screen column breaks and tablet typography scale.
Native mobile bezel with speaker notch, status bar, single-column stacked grids, and mobile nav menu.
Color Style Editor
A live color palette editor in the Styles tab lets you customise every surface color without touching code:
Set page background, section fill, card/inset panel background — all with native color pickers.
Override heading color, body text, nav background, and the site accent / button color. Reset to defaults in one click.
Drop the Embed element from the element library into any section to inject arbitrary HTML — iframes, map widgets, form embeds, third-party scripts. Click the element to open the code editor and paste your snippet. A live preview renders inline in the Studio canvas. The full code renders on the production edge at publish time.
Before going live, Studio walks you through the exact diff between the published state and your draft — content, tokens, SEO, and section order — so "go live" is a conscious click, not a default.
Drop hosting & One-Step ZIP Uploads
Not every site needs a git repository. Drag a single HTML file or your compiled production archive directly onto TagHost to get a live global edge link immediately.
In-Console One-Step Upload
Under Console > Projects, select the Upload ZIP / HTML tab. Drop your compiled bundle or single HTML file:
- Automatic Framework Sniffing: Server-side heuristics detect Next.js, Astro, Nuxt, SvelteKit, Vite, Hugo, Jekyll, or static HTML.
- Directory Normalization: Automatically unpacks nested folders like dist/ or promotes standalone HTML files to index.html.
- Permanent Production Hosting: Uploads directly to object storage bucket taghost-assets and updates edge routing in milliseconds.
Anonymous Ephemeral Dropzone
Visitors on the marketing homepage can test edge hosting without signing up:
- Zero-Account Required: Instantly deploys to a temporary *.taghost.io preview URL.
- 2-Hour TTL: Unclaimed sites automatically expire after 2 hours to conserve edge storage.
- 1-Click Claim: Signing in or creating an account lets you claim the ephemeral deployment permanently into your workspace.
# Upload a ZIP bundle to create a live project in one request curl -X POST https://api.taghost.io/projects/upload \ -H "Authorization: Bearer tag_live_your_token" \ -F "bundle=@build.zip" \ -F "name=My Marketing Site"
Forms & CRM
Use the React <TagForm> convenience component, or a standard HTML form posting to /_tag/forms/:name on a hosted site. Lead capture is not restricted to React.
import { TagForm } from '@taghost/react';
export function ContactSection() {
return (
<TagForm
name="lead-capture"
onSuccess={() => alert('Thanks! We will reply within 24h.')}
className="space-y-4 max-w-md"
>
<input type="text" name="name" required placeholder="Jane Doe" />
<input type="email" name="email" required placeholder="jane@company.com" />
<button type="submit">Send note</button>
</TagForm>
);
}An invisible field traps bots before a submission is stored — no CAPTCHA, no friction for real visitors.
The _utm payload is persisted with every lead so campaign attribution survives the submit.
Each accepted lead fires your subscribed webhooks (default lead.captured) with delivery confirmation.
View and filter every lead — spam score, UTM, webhook status — in the Console Forms tab, or export via GET /projects/:id/forms/submissions.
Domain Management & DNS — bring, buy, or transfer
Three ways to put a domain on a project: connect one you own (BYOD), buy at wholesale via our registrar integration, or transfer an existing registration's registrar of record to TagHost. Domains bought from or transferred to TagHost never count against your plan's domain limit.
Point your apex or subdomain via CNAME to cname.taghost.io. Managed SSL validates ownership and provisions SSL after ownership and DNS validation; timing depends on propagation.
Search and register .com, .io, .ai at registrar cost via Name.com API v4. Includes ICANN WHOIS privacy, Stripe checkout, and instant ledger receipts.
Move an existing domain's registrar of record to TagHost with its EPP authorization code. Takes ~5–7 days at the registry; the fee extends registration by a year, and the domain stops counting against your plan limit.
Manage authoritative DNS records (A, AAAA, CNAME, MX, TXT, SPF, CAA, SRV) in the console — each registered domain runs on its own managed zone.
# 1. Custom Hostname CNAME Delegation (Subdomain or Apex CNAME Flattening) Type: CNAME Name: @ (or www / app) Value: cname.taghost.io Proxy: DNS Only (Grey Cloud) # 2. Registered/transferred domains Nameservers: assigned automatically when TagHost registers or transfers the domain (managed zone in the console).
Plan limits and mailbox allowances are shown in workspace Billing and on the current pricing page. Domain purchases, transfers, mailboxes and hosting have distinct quotas; use the live allowance rather than an older documentation table. DNS/SSL activation is asynchronous and depends on validation and propagation.
TagMail — email on your own domain
TagMail is one mailbox on your domain, and it has two legs. Inbound mail is routed by Cloudflare and filed straight into your mailbox. Outbound mail is signed and sent by Cloudflare. You turn both on and check both from Settings → Domains.
TagMail is a full mailbox on your domain, not just forwarding. Sign in at mail.taghost.io for a three-pane inbox with folders, search, labels, a rich-text composer and attachments. Workspace and mailbox selection control the active mail context; thread messages and details collapse independently.
Install the TagWork app (mail, notes, tasks, calendar) from work.taghost.io on iOS/Android, or download the Android app.
Use a client that explicitly supports JMAP. Standard IMAP/POP3/SMTP account setup is not available.
New-Inbox alerts on your phone or browser; mute or set quiet hours per mailbox.
Send and receive as you@yourdomain.com.
Mail to info@yourdomain.com is accepted by Cloudflare, handed to TagHost, and filed into the matching mailbox or alias. No mail server of your own to run.
Messages use Cloudflare Email Sending after domain verification. Delivery and recipient authentication verdicts still depend on correct DNS and the receiving provider; sending is subject to quotas and suppression checks.
Managing email verification (MX, SPF, DKIM, DMARC) in TagHost
Add your domain in Settings → Domains, point its nameservers at TagHost, then press Check email records. TagHost reads your public DNS and tells you, per record, what is there and what is missing.
- MX — Published for you when routing is enabled. Points inbound mail at Cloudflare.
- SPF — Published for you with routing. Authorises Cloudflare to send as your domain.
- DKIM — The signing key Cloudflare generates is returned by sending-domain setup; publish the required DNS value and verify it before sending.
- DMARC — Yours to choose. TagHost can publish p=none for you, or you can copy the value into your own DNS and tighten it to quarantine or reject later.
If your domain's DNS is not on TagHost, the check still runs — it just reports instead of fixing, and shows you the exact record to add at your registrar.
Sending from Gmail: what is and isn't possible
Gmail's Send mail as feature only accepts an authenticated SMTP relay. TagHost does not publish an SMTP relay: outbound mail is sent through Cloudflare's HTTP sending API, which is not an SMTP endpoint, so there are no SMTP host, port or password credentials we could hand you. We would rather tell you that plainly than give you server details that do not work.
What to use instead:
- Compose in TagMail — the web inbox at mail.taghost.io, the installed app, or a client with explicit JMAP support. Do not assume Apple Mail, Outlook or Gmail can use JMAP account settings.
- Keep Gmail for its own address and use a filter that files mail from your domain into a TagMail forward or alias.
- Need send-as in Gmail specifically? That requires an SMTP relay from a provider you choose and pay for — we do not bundle or recommend one.
# 1. Email routing MX records Type: MX | Name: @ | Priority: 43 | Target: route3.mx.cloudflare.net Type: MX | Name: @ | Priority: 63 | Target: route1.mx.cloudflare.net Type: MX | Name: @ | Priority: 73 | Target: route2.mx.cloudflare.net # 2. SPF Record for Inbound Anti-Spam Verification Type: TXT | Name: @ | Value: v=spf1 include:_spf.mx.cloudflare.net ~all
Collections and Content Studio
Create schema-defined collections in Console → Content for articles, products, directories, portfolios and other structured content. The content workspace includes rich-text authoring, images, item fields, drafts, publishing, unpublishing and live preview. Published items are mirrored to the edge.
Read published content from the site’s own origin, without a React dependency:
const response = await fetch('/_tag/collections/posts');
if (!response.ok) throw new Error('Content could not be loaded');
const content = await response.json();
// One item: /_tag/collections/posts/my-postHTML templates can use data-tag-collection repeaters and item bindings such as data-tag="post.title". Collection routes support generated listing/detail pages and dynamic metadata. React projects can also use useTagCollection or TagCollection. Publishing, unpublishing and deletion can trigger collection webhooks and connected static builds.
Schema and item management use /projects/:id/collections and its item/publish routes. There is no CLI collection-authoring command. tag eject --collections exports Markdown with YAML frontmatter and JSON in current source, but is not included in published CLI 3.1.1.
Commerce and orders
TagCommerce turns static websites into headless storefronts with 0% platform fees, location-based shipping zones, multi-currency pricing, and turnkey merchant handoff.
Merchant Portal (store.taghost.io): Hand over store management to clients at store.taghost.io. It provides a distraction-free dashboard for Products & Stock, Orders & Fulfillment, Customers CRM, Storefront Design, and Settings without exposing DNS, Git deploys, or secrets. Single sign-on uses the shared .taghost.io session cookie.
Modes & Currencies: Stores operate in Catalog Inquiry mode (for bespoke artisans and quote/WhatsApp ordering without a gateway) or Gateway Checkout mode (unlocking automated 1-page edge checkout and the Orders ledger). Supports 10 currencies (USD, EUR, GBP, NGN, KES, GHS, CAD, AUD, ZAR, INR).
0% Platform Fees (BYOK): Connect Stripe (cards, Apple/Google Pay), Paystack (African cards, bank transfer, mobile money), or Flutterwave credentials. Secret keys and webhooks are encrypted at rest with AES-GCM; payouts settle directly to your merchant account.
Shipping Zones: Set flat rates for physical goods by country ISO code or wildcard (*), regional rules (state-level rates), free-shipping thresholds, and blocked delivery zones. Fees are recalculated server-side. Digital products, courses, and services bypass shipping.
Product SEO: Product pages receive canonical URLs, social cards, and Schema.org Product JSON-LD with real-time stock availability. Merchants can customize SEO titles, descriptions, share images, or toggle noindex to hide items from search engines and /sitemap.xml.
Frontend Integration: Trigger checkout via data-tag="buy" on HTML buttons, or call POST /projects/:id/collections/:name/checkout from custom frontends.
TagWork workspace suite
work.taghost.io is the workspace suite: Dashboard, Mail, Calendar, Tasks, Notes, Chat and Meetings. mail.taghost.io remains the focused webmail surface. Both share account identity; workspace access remains membership-scoped.
Use the workspace selector to change between workspaces you belong to. Workspace choice determines which mailboxes, tasks, events, notes and chats are loaded. Shared inboxes support mailbox membership, assignment, status and internal notes. Chat supports direct/group messages, channels, attachments, replies and guest links requiring a TagHost account.
The dashboard surfaces today’s tasks and agenda. Calendar supports events and ICS export; tasks support due dates, priority and teammate assignment; notes support rich text. These operations have app and REST surfaces, but no dedicated CLI commands or CLI workspace-switch command.
TagWork owns the installable PWA and Android app with launcher shortcuts and the Today widget. Browser push and Android alerts require notification permissions; per-mailbox mute and quiet hours apply.
TagMeet meetings
TagMeet provides workspace meetings with a pre-call device check, guest/admission controls, camera/microphone selection, screen sharing, chat, reactions and host moderation. TagWork links meetings from the workspace suite.
Capabilities include plan-gated recording, meeting minutes written into Notes, action-item tasks, polls, whiteboard, and breakout rooms. Recording uses client capture and requires an active host browser. Meeting entitlements are separate add-ons rather than automatic hosting-plan upgrades.
There are no CLI meeting commands. Use TagMeet or the permission-gated meeting REST routes. Calls/TURN provisioning and real-device/network acceptance remain release requirements; a successful web build alone does not verify media reliability. Simulcast and per-breakout recording are not general availability promises.
Data & runtime boundaries
TagHost isolates customer records by workspace, with project/workspace checks on data access. The Console Data explorer lists permitted tables and supports read-only SQL. This is not a promise of a separate physical database for every project.
GET /projects/:id/sql/tables POST /projects/:id/sql/query
There is no general customer database-migration CLI, arbitrary function deployment, or SSR runtime today. Compute and Agent Runs navigation does not imply those products exist. Use static output plus the platform’s supported content/forms/mail APIs, or an external backend for application-specific server logic.
Environment variables
Per-project key/value configuration with production, preview and all-environment targets. Management responses mask values. Keep secrets out of client-exposed variables and generated static assets.
Production and preview scopes keep staging keys, test tokens, and mocks out of prod builds — filter and search by scope.
Secret values render as •••••••• and reveal only per click; the Env Vars tab never dumps values into logs.
tag env set STRIPE_SECRET sk_live_xxx tag env list # STRIPE_SECRET •••••••••••••• production, preview tag env rm STRIPE_SECRET
Webhooks
Push your site's events to your own infrastructure. Subscribe to lead capture, deploys, and content updates, then debug delivery from a per-project log.
Subscribe per webhook to lead.captured (default) along with deploy, content, and asset events. Payloads POST as JSON to your URL.
Successful relays flip the lead's webhookDelivered flag so you can reconcile CRM sync in the Forms inbox.
Fire a test event from the Console, then inspect the delivery log — status, latency, and response — for each endpoint.
curl -X POST https://api.taghost.io/projects/proj_xxx/webhooks \
-H "Authorization: Bearer tag_live_your_token_here" \
-H "Content-Type: application/json" \
-d '{"name":"crm","url":"https://hooks.example.test/lead","events":["lead.captured"]}'Model Context Protocol (MCP) & Autonomous AI Agents
Empower autonomous coding agents (Cursor Composer, Claude Desktop, Antigravity, Cline, ChatGPT / OpenAI Codex, Windsurf) to build, configure, deploy, and operate web applications on TagHost without human intervention.
tag mcp setup all # or: antigravity | cursor | claude | windsurf | zed | vscode | cline
{
"mcpServers": {
"taghost": {
"command": "tag",
"args": [
"mcp"
],
"env": {
"TAGHOST_API_TOKEN": "YOUR_TAGHOST_API_TOKEN",
"TAGHOST_PROJECT_ID": "YOUR_PROJECT_ID",
"TAGHOST_API_URL": "https://api.taghost.io"
}
}
}
}Environment variables: TAGHOST_API_TOKEN (required), TAGHOST_PROJECT_ID (optional default project scope), TAGHOST_API_URL (defaults to https://api.taghost.io).
deploy_bundle, publish_files, rollback, set_expiry
collection_create, item_upsert, item_publish
content_list, content_patch, canvas_patch_html
sql_query, sql_introspect_schema
mail_threads_list, thread_get, send, create_mailbox
domain_check, search, checkout, attach, dns_manage
commerce_config, orders_list, fulfill, coupon_manage
forms_get_submissions, sequence_create, enroll_lead
task_create, task_list, task_update, task_delete
schedule_event, meet_create_room, note_create, quota_check
CLI reference
The tag CLI is a Node tool with bundled dependencies. Requires Node 20+; developing this monorepo requires Node 22.5+.
-p, --previewflagDeploy to an ephemeral branch preview URL-b, --branch <branch>stringSpecify the Git branch--project <projectId>stringOverride the local project binding--dir <path>stringUpload built static files from this directory (defaults: dist, build, out, public)Published npm version: 3.1.1 (registry checked 25 October 2026). The current source is ahead of npm. Commands marked Source only require a future CLI release or a locally built checkout; installing 3.1.1 does not provide them.
tag login [--token <token>]Authenticate with a Console API token; TAGHOST_TOKEN is supported in CI.
tag logoutRemove locally stored CLI credentials.
tag whoamiShow the authenticated account and workspace.
tag init [--project <id>]Create local configuration and link a package-based project. The published initializer uses React/Vite metadata; source adds framework detection.
tag deploy [--dir <folder>] [--project <id>] [--preview] [--branch <branch>]Upload built static output, or request a connected repository deployment when local output is absent.
tag rollback [deploymentId] [--list] [--project <id>]List deployments or promote an existing deployment.
tag env list|set|rm [key] [value] [--target production|preview|all] [--project <id>]Manage project environment variables.
tag eject [--project <id>] [--yes]Export published content and detach supported static JSX bindings; unsupported bindings fail before writes.
tag mail mailboxesList mailboxes in the authenticated workspace.
tag mail send --mailbox <id> --to <address> --subject <subject> [--text <body>] [--html <body>]Send from an existing mailbox, subject to permissions, sending setup and quotas.
tag expiry [1d|7d|30d|never] [--project <id>]Read or set site lifetime. Available in source; not in npm 3.1.1.
Source only
tag key create [name] [-s send|read|admin|deploy] [--all]Create an API key. Available in source; not in npm 3.1.1.
Source only
tag key listList workspace API keys. Available in source; not in npm 3.1.1.
Source only
tag key rm <id>Revoke an API key. Available in source; not in npm 3.1.1.
Source only
tag mcp [setup <target>] [--print-config]Start the TagHost Model Context Protocol (MCP) server or configure IDE agents (Cursor, Claude, Antigravity, Windsurf, Zed, VS Code, Cline).
tag eject --collections is also source-only. Production login uses a Console API token; browser/device-code login is not generally available in the published CLI. Use tag --help and subcommand --help to verify your installed version.
CLI coverage and app/API alternatives
The CLI does not expose every platform feature. It is a deployment and integration tool, not a full replacement for Console, Studio, TagMail, TagWork, TagMeet or Operator Admin. A feature having a REST endpoint does not imply a dedicated tag command.
| Feature | CLI coverage | Where to do the rest |
|---|---|---|
| Authentication | login, logout, whoami | OAuth/MFA and device/session administration use account settings. |
| Hosting and deploys | init, deploy, rollback; expiry in source | Project deletion, domain setup and build configuration use Console or REST. |
| Environment variables | env list/set/rm | Project-scoped; permissions and the local project binding still apply. |
| API keys | key create/list/rm in source | Use Console → Account & Settings with published CLI 3.1.1. |
| Domains and DNS | No dedicated command | Console domain purchase/transfer/DNS flows and REST endpoints. |
| Studio and GitHub write-back | No dedicated editing/sync command | Studio controls visual edits, publish review, GitHub linking and sync status. |
| Collections and commerce | eject --collections in source only | Content authoring, publishing, schemas, checkout and orders use Console/REST. |
| Forms, webhooks and analytics | No dedicated command | Console/REST manage submissions, webhooks and measured traffic. |
| TagMail | mail mailboxes, mail send | Inbox reading, mailbox creation, aliases, rules, delegation and DNS use TagMail/REST/JMAP. |
| TagWork | No dedicated command | Workspaces, calendar, tasks, notes and chat use TagWork/REST; no CLI workspace switcher. |
| TagMeet | No dedicated command | Meeting creation/join, moderation, recording and minutes use TagMeet/REST. |
| Teams, billing and administration | No dedicated command | Console/Admin and permission-gated REST; no CLI purchases or plan management. |
| Data and compute | No dedicated command | Console supports read-only workspace SQL inspection; arbitrary customer functions/SSR are not generally available. |
REST automation uses https://api.taghost.io, an authorized Bearer token and the relevant project/workspace routes. Workspace membership, API-key scopes and role checks still apply. API calls should not be presented as built-in CLI commands.
taghost.config.ts
Declare design tokens, collections, and build options in your project root.
export default {
projectId: 'proj_live_89172',
publishDir: 'dist',
designTokens: {
colors: {
brand: '#FF2636',
dark: '#07080E',
},
fonts: {
heading: 'Plus Jakarta Sans',
body: 'Inter',
},
},
collections: {
blog: {
schema: {
title: 'string',
content: 'markdown',
date: 'date',
},
},
},
};Collections are managed in Console → Content with a draft→publish flow; published items are served at /_tag/collections/:name and readable from useTagCollection. In-page collection bindings and commerce are implemented. Collection export is available as tag eject --collections in the newer CLI source, not published npm 3.1.1. Creating a collection in this local config does not provision its schema; use Console or the collections API.
Eject & zero lock-in
You are never trapped. Run tag eject anytime to detach cleanly.
tag eject first exports published content, materializes supported static JSX text and image bindings, then removes local configuration. Export failures, dynamic bindings, nested content and plain HTML bindings abort before writes. The JSON is retained as a backup; forms and collection integrations retain their SDK dependency until you replace their services. Verify the resulting build before moving hosts.
Edge architecture
Dynamic dispatch mesh, isolated database sharding, and streaming HTML rewriting.
The edge router resolves project hostnames and serves static assets with platform services; it is not a general customer-code runtime.
Mutates [data-tag] nodes on the fly in memory with <2ms latency overhead.
Control Plane REST API
Programmatic access to mutate site copy, trigger builds, and export form leads.
Full reference
Update live copy for any data-tag key without a redeployment cycle.
Trigger a build from the linked repository.
Upload a dist ZIP directly to the edge as a new build.
List deploy history with Active / Promoting states.
Promote a build to Active across all regions.
Export accepted form leads, spam scores, and UTM metadata.
Manage environment variables and secrets.
Create, test, and audit webhook endpoints.
Create project & deploy live from ZIP/HTML in 1 step with framework sniffing.
Returns active auth mechanisms (Google, GitHub, GitLab, password, magic link).
Initiate & exchange OpenID Connect credentials for Google, GitHub, or GitLab.
Read and mutate authoritative tenant DNS records (A, CNAME, MX, TXT, SPF).
Start the available billing checkout or open the billing portal; use live Billing for prices and gateway availability.
Superadmin overview across all tenants, revenue, domains, and email outbox.
Create and revoke workspace API tokens.
Public submission endpoint used by <TagForm>.
Resolve the identity behind the current bearer token.
Mint single-use magic login link for partner launcher handoff into TagMail, TagStudio, or Console.
Decouple partner-managed project into direct TagHost workspace tenancy.