← Receivers

pages:create

pages family

mcp

Create a workspace page (draft) — from a page template, from any registry blocks, or from legacy CRO sections

Effect
ask
Awaits an outcome — the call returns the response below.
Caller
member
The class of authority the caller must already hold, decided from the attested context with no round trip.
Cost
free
What one call costs, so you can budget before acting.
Reversible
yes
The effect can be undone by a later call.
Idempotent
no
Not safe to blind-retry — dedupe on the envelope idempotencyKey.

Send it with your agent

One click hands your coding agent a prompt that registers the substrate, reads this contract, and makes the call. Launch opens the app; the others copy the prompt.

Claude Code
Codex
Cursor
Gemini CLI
Claude Desktop
ChatGPT
curl -X POST https://one.ie/api/ask/pages:create \
  -H "Authorization: Bearer $ONE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"data": { "slug": <string>, "title": <string> }}'

The key is never in a link. npx -y @oneie/cli login writes it to ~/.config/oneie/key on your machine.

Request

Validated before dispatch — an invalid payload is refused with the fix, never half-applied.

  • slug string required
  • title string required
  • sections object[] optional
  • puckData object optional Puck data: `content[]` of `{ type, props }`, any registry block. Each top-level block's props are normalised onto the member its variant renders and given a `props.id` when missing. With `template`, these blocks are APPENDED after the template's.
  • template string optional A page-template id from `pages:templates`. The page starts as a copy of that template — its blocks, images, links and anchors — and `edits` / `remove` / `puckData` are applied on top. A pack template (it has a `pageCount`) is refused: it seeds many pages through its own receiver.
  • edits object[] optional Only with `template`. An unknown blockId is reported in `unknownEdits`, never silently dropped.
  • remove string[] optional Only with `template`: template block ids to leave out.
  • pageSlug string optional

Response

What comes back from the call.

  • ok boolean
  • slug string
  • title string
  • url string
  • status string
  • error string
  • unknownBlocks string[] Block names in this page that the renderer CANNOT DRAW, in your own spelling. The page was still created — the names are stored and will paint nothing. PRESENT ⟺ at least one name was unknown; absent means every name resolved (absent is not an empty array). A retired or collapsed family member name (HeroCentered, Wallet) is NOT listed: the render path rewrites it. Repair with `pages:update-block`, and read `blocks:list` / `blocks:schema` for the names that exist.
  • unknownEdits string[] `edits[].blockId` values the template does not hold — those edits were NOT applied. Absent ⟺ every edit addressed a real block.
  • unlandedEdits object[] Edit keys no field of that block's rendering member took — stored, invisible, and the sample copy they meant to replace is still showing. `renders` names the fields that do render. Re-send with those names.
  • sampleCopyLeft object[] With `template`: blocks whose listed props still hold the TEMPLATE'S sample copy — another business's words on this page. The page is not done until this is absent: rewrite each (`pages:update-block`) or remove the block.
  • sampleImagesLeft object[] With `template`: props still showing the template's sample photos. Replace with the business's own images where you have them.
  • quality object Template-strength verdict on the stored page. Fix what `missing` names before calling it done.

Traffic

Every call to pages:create, counted where it is dispatched — over HTTP or in-process alike. Aggregate only — no actor, no payload, no workspace.

Counting…

Wiring

Every place in the open source that names pages:create, and the file that answers it. Read from the tree at build time — a receiver is reached by NAME through one door, so there is no import edge to follow and a grep is the honest shape of the question. Structure, not volume — the count is in Traffic above.

Called from

UI 3
  • one.ie/web/src/components/live-edit/AdoptHomeButton.tsx:22
  • one.ie/web/src/components/pages/NewPageSheet.tsx:12
  • one.ie/web/src/components/views/RowDoors.tsx:62
API route 8
  • one.ie/web/src/lib/campaigns/reggae-penguin.ts:655
  • one.ie/web/src/lib/puck/known-blocks.ts:5
  • one.ie/web/src/lib/puck/seed-pack.ts:18
  • one.ie/web/src/lib/puck/tenant-blocks.ts:25
  • one.ie/web/src/lib/receiver-index.generated.ts:243
  • one.ie/web/src/lib/resolvers/pages.ts:1767
  • one.ie/web/src/lib/urls/law.ts:305
  • one.ie/web/src/lib/wave/ad-campaigns.ts:23
Agent runtime 1
  • channels/src/tools/pages.ts:366
Workflow 1
  • one.ie/web/src/lib/workflow-templates.ts:1290
→
JSON Schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "slug": {
      "type": "string"
    },
    "title": {
      "type": "string"
    },
    "sections": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "component": {
            "type": "string"
          },
          "props": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {}
          }
        },
        "required": [
          "component",
          "props"
        ]
      }
    },
    "puckData": {
      "description": "Puck data: `content[]` of `{ type, props }`, any registry block. Each top-level block's props are normalised onto the member its variant renders and given a `props.id` when missing. With `template`, these blocks are APPENDED after the template's.",
      "type": "object",
      "properties": {
        "content": {
          "type": "array",
          "items": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {}
          }
        },
        "root": {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {}
        }
      },
      "required": [
        "content"
      ],
      "additionalProperties": {}
    },
    "template": {
      "description": "A page-template id from `pages:templates`. The page starts as a copy of that template — its blocks, images, links and anchors — and `edits` / `remove` / `puckData` are applied on top. A pack template (it has a `pageCount`) is refused: it seeds many pages through its own receiver.",
      "type": "string"
    },
    "edits": {
      "description": "Only with `template`. An unknown blockId is reported in `unknownEdits`, never silently dropped.",
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "blockId": {
            "type": "string",
            "description": "A template block's `props.id`, as `pages:templates {id}` lists it"
          },
          "props": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {},
            "description": "Props merged into that block — usually its copy rewritten for the brief"
          }
        },
        "required": [
          "blockId",
          "props"
        ]
      }
    },
    "remove": {
      "description": "Only with `template`: template block ids to leave out.",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "pageSlug": {
      "type": "string"
    }
  },
  "required": [
    "slug",
    "title"
  ]
}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "ok": {
      "type": "boolean"
    },
    "slug": {
      "type": "string"
    },
    "title": {
      "type": "string"
    },
    "url": {
      "type": "string"
    },
    "status": {
      "type": "string"
    },
    "error": {
      "type": "string"
    },
    "unknownBlocks": {
      "description": "Block names in this page that the renderer CANNOT DRAW, in your own spelling. The page was still created — the names are stored and will paint nothing. PRESENT ⟺ at least one name was unknown; absent means every name resolved (absent is not an empty array). A retired or collapsed family member name (HeroCentered, Wallet) is NOT listed: the render path rewrites it. Repair with `pages:update-block`, and read `blocks:list` / `blocks:schema` for the names that exist.",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "unknownEdits": {
      "description": "`edits[].blockId` values the template does not hold — those edits were NOT applied. Absent ⟺ every edit addressed a real block.",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "unlandedEdits": {
      "description": "Edit keys no field of that block's rendering member took — stored, invisible, and the sample copy they meant to replace is still showing. `renders` names the fields that do render. Re-send with those names.",
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "blockId": {
            "type": "string"
          },
          "fields": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "renders": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "blockId",
          "fields",
          "renders"
        ]
      }
    },
    "sampleCopyLeft": {
      "description": "With `template`: blocks whose listed props still hold the TEMPLATE'S sample copy — another business's words on this page. The page is not done until this is absent: rewrite each (`pages:update-block`) or remove the block.",
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "blockId": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "fields": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "blockId",
          "type",
          "fields"
        ]
      }
    },
    "sampleImagesLeft": {
      "description": "With `template`: props still showing the template's sample photos. Replace with the business's own images where you have them.",
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "blockId": {
            "type": "string"
          },
          "fields": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "blockId",
          "fields"
        ]
      }
    },
    "quality": {
      "type": "object",
      "properties": {
        "score": {
          "type": "number"
        },
        "max": {
          "type": "number"
        },
        "missing": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "Checks the page fails — each has a line in `fix`"
        },
        "fix": {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": "string"
          },
          "description": "check → how to fix it"
        },
        "why": {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "description": "check → the offending block ids and values (at most 5 per check)"
        },
        "factTokens": {
          "description": "`{{ns.key}}` / `[Fact]` tokens still in the copy. Each fills from the workspace's business facts at render; one with no fact DROPS its sentence. Write the real value where you know it.",
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "required": [
        "score",
        "max",
        "missing",
        "fix",
        "why"
      ],
      "description": "Template-strength verdict on the stored page. Fix what `missing` names before calling it done."
    }
  },
  "required": [
    "ok"
  ]
}