DEVELOPER DOCS
Build and publish Brandlit sites from code
Brandlit has a public HTTP API and a small command-line tool for creating projects, saving HTML and publishing to a live URL. Sign in once with a device code or email, keep the session cookie, and every call works from a script.
Start here
Publish your first page in 60 secondsSign in, create a project, save your HTML, publish.
Sign in from a terminalLink Brandlit to Grok Bot with a one-time device code.
Use your own domainPoint a CNAME at Brandlit and verify it.
Reference
- OpenAPI (JSON) and YAML — every public route, request and response.
- Integrator overview — how sessions, projects and publishing fit together.
- curl cookbook — copy-paste examples with a cookie jar.
brandlit CLI
Zero-dependency Node 18+ tool that wraps the API. Sign in, create, save, publish and attach a domain in six commands. See the CLI README. There isn’t a public install command yet; today it runs from the source repo.
Good to know
- Do I need an API key?
- No. The API uses a session cookie. Bearer tokens aren’t available yet.
- Can I run it in CI?
- Yes, by saving the cookie file from a device-code sign-in as a secret.
- Where do prices come from?
- Read the live catalog from
GET /api/billing/products; don’t hard-code amounts. - Can I host on my own domain?
- Yes. CNAME to Brandlit is the default. Signed-in accounts can also publish to their own Cloudflare from the Hosting section.
For AI assistants
llms.txt summarizes the site and links every doc.