Skip to main content

AI Agents

The Micropage markup is small, structured, and predictable — which makes it an excellent substrate for AI-authored landing pages, both inside the editor and from your own automation.

Why the markup is agent-friendly

  • Fixed element vocabulary. Headings, paragraphs, images, buttons, columns, sections, form fields — a closed set, no surprises.
  • Line-oriented syntax. Every line is one element. No nested HTML soup.
  • Constrained design tokens. Colors and typography are configured in [site], not freely styled inline.
  • No free-form HTML by default. Agents can't accidentally inject scripts, weird ARIA, or broken components. Free-form HTML is opt-in via /// html fences.

The grammar is small enough that Claude, GPT, and other LLMs produce correct markup on the first try, and small enough that they can edit an existing page without breaking it.

In-editor: the AI tab

Open any project and switch to the AI tab.

Example prompt:

Build a landing page for a Postgres backup-as-a-service tool. Pricing tiers, FAQ, big CTA.

The editor generates Micropage markup, previews it, and lets you apply it to your project or discard it.

Outside Micropage: pointing your own agent at a project

Every Micropage project includes a PROJECT_AGENT.md file describing the layout and constraints. Point Claude, Cursor, Aider, or any other coding agent at the project directory; they'll find it automatically.

Example Claude prompt:

Here's my landing page (.page file attached). Add an FAQ section with these four questions: [...]. Keep the existing style.

The agent edits the file. Push the change with micropage publish.

CI-driven AI updates

You can set up a workflow where an agent reads a source-of-truth (a Notion doc, Google Sheet, database) and re-emits your .page file on changes, then pushes via a project-scoped deploy token.

Pattern:

  1. Cron trigger in GitHub Actions
  2. Agent reads source, generates updated .page markup
  3. micropage publish --token $DEPLOY_TOKEN pushes the new build

Result: your site stays in sync with its source-of-truth without anyone opening the editor.

Markup constraints to teach your agent

When prompting an agent that hasn't seen Micropage before, include:

  • The closed element vocabulary (headings h1h5, p:, img:, btn:/button:, columns via col:, sections via /// section).
  • Allowed section modifiers (bg:muted, align:center, etc.).
  • The site-level color/typography tokens in [site].
  • Image syntax: img: width:600 height:400 <- hero.png.
  • The constraint that free-form HTML must live inside /// html fences.

A short PROJECT_AGENT.md covering the above is usually enough for a strong agent to produce correct markup first try.

See also