Developer docs
Using AI to build a theme
In short
Either describe the theme (style, categories, colors) in the developer dashboard and let the platform's AI generate a valid package you then refine, or run npx @dispenseflow/theme-cli init and give your own coding agent the folder: THEME-SPEC.md is the contract, AGENTS.md tells the agent how to work, and dftheme check runs the platform's checks offline so the agent can test its own work.
In the dashboard
Write a brief: who the theme is for, its style, the categories it targets and two brand colors. The generator writes every required page and a pattern per category, already passing the checks. Developers get a monthly AI allowance for this.
With your own agent
The starter folder is built for agents. Ask yours to read AGENTS.md and THEME-SPEC.md, then iterate with dftheme dev open in a browser and dftheme check after every change.
npx @dispenseflow/theme-cli init apothecary
cd apothecary
# In Claude Code or Cursor:
# "Read AGENTS.md and THEME-SPEC.md. Make this an apothecary-style theme
# for skin and hair-loss brands: warm paper background, serif headings,
# a topical product card for creams and foams. Run dftheme check until it passes."
npx dftheme dev
What to check yourself
Agents are good at structure and weak at taste and claims. Read every line of sample copy for health claims, try the theme with three very different brand colors, and test it at 360 px wide.
Questions
Does my agent need access to the platform?
No. The spec, the sample data and the checks are all in the folder; it only needs the internet to push.