AI Assistant
Audience: Both.
PageCraft can build and edit sections from a written description, answer questions about the page you are on, and generate images straight into your EE file manager. It is off until you supply an API key.
The short version: get an OpenRouter key, paste it into Advanced Settings, switch on Enable AI Code Chat in Global Settings, then use the sparkles button — tooltip AI Assistant — in the toolbar down the left of the editor.
Turning it on
PageCraft does not resell AI. You bring your own OpenRouter account and are billed by them for what you use.
- Create an OpenRouter account and generate an API key.
- CP → Add-Ons → PageCraft → Advanced Settings → OpenRouter API Key. Paste the key and save.
- CP → Add-Ons → PageCraft → Global Settings → Enable AI Code Chat. Switch on.
- Open any entry with a PageCraft field. A sparkles button, tooltip AI Assistant, appears in the toolbar down the left of the editor.
The key is encrypted before storage and never displayed again — the field reads blank after saving, which is correct, not a failed save. To change it, paste a new one. Requests are proxied through your own server, so the key never reaches the browser and never appears in page source.
Without a key, the panel does nothing useful, which is why the toggle and the key live one click apart.
What it can do
Build and edit sections. Describe what you want and it writes the section into the canvas. Ask it to change what is already there — "make the heading larger and move the image right" — and it edits in place.
Answer questions about the page, in chat, without changing anything.
Generate images. Describe an image and it is generated, uploaded into your configured EE upload directory, and inserted. From that moment it is an ordinary EE file — it appears in the file manager, can be reused, and is referenced portably like any other PageCraft image.
Read images you attach. Attach a screenshot or a reference and ask it to match a layout. All available models accept image input. Attached documents are read in the browser and folded into your prompt rather than uploaded.
Choosing a model
Two lists, because the jobs differ:
| Used for | Default | --- | | --- | --- | Code model | | writing and editing section markup | Gemini 3.7 Flash | Chat model |
The code list runs from Claude Opus 5 and Sonnet 5 through GPT-5.6 Sol to Gemini 3.1 Pro and 3.7 Flash. The chat list is a smaller set chosen for speed and cost.
Cost and quality track each other closely. The Flash-class defaults are the sensible starting point; move up to Opus or GPT-5.6 for a section that is fighting you, not for routine edits.
Image generation defaults to Gemini 2.5 Flash Image, with GPT-5 Image and larger Gemini image models available. The endpoint only accepts models from a fixed list — a tampered request cannot bill your account for an arbitrary model.
Limits and safeguards
- 40 requests per minute per member. Beyond that you get a clear error and the counter resets on the next minute.
- Image prompts are capped at 2,000 characters.
- Only members who can access the control panel can use it. Every AI endpoint checks that independently of the editor UI, so the panel cannot be reached by URL.
- Generated images are uploaded as the member who asked for them, so the file manager shows who created what.
Working with it well
Be specific about structure. "A three-column feature row with an icon, heading and short paragraph in each" produces something usable. "Make it pop" does not.
Iterate on one section at a time. Building a full page in one prompt gives you a lot to check; building section by section gives you something to correct while it is still small.
Read what it writes. It produces real markup in your page, and you are the one shipping it. Check the copy for invented specifics — capacities, dates, client names — which language models will supply confidently and wrongly.
It composes from raw markup, not from the block picker, so AI-built pages tend to contain no plugin blocks. That is fine, but it means such a page exercises different code paths from a hand-built one; if something renders oddly, mention that it was AI-generated.
Troubleshooting
No AI Assistant button. The toggle is off, or no API key is saved. Both are required — check Global Settings and Advanced Settings.
"Unauthorized" or nothing happens on send. Your session is not being seen by the endpoint. Usually the same host mismatch that affects the editor frame — see Installation.
Errors mentioning credit or billing come from OpenRouter, not PageCraft. Check your balance there.
Generated images do not appear in the file manager. Check Global Settings → Upload Directory is set and writable. The image is uploaded through EE's own file handling, so anything blocking a normal upload blocks this too.
Responses cut off mid-section. Raise the model's output limit in the panel's settings, or ask for a smaller piece of work.
Developer Reference