Publish Page
publish_pagePublish a static HTML page to your Lindo AI website by specifying the URL path, page title, and HTML content.
Instructions
Publish a static page with HTML content.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| website_id | Yes | The website ID | |
| path | Yes | URL path (e.g. /about) | |
| page_content | Yes | Page content in HTML | |
| page_title | Yes | Page title for SEO |
Implementation Reference
- server/index.js:629-637 (handler)The handler function that executes the publish_page tool logic. It takes website_id, path, page_content, and page_title as input, constructs a body object with SEO info, makes a POST request to /v1/workspace/website/{website_id}/pages/create, and returns the result.
async ({ website_id, path, page_content, page_title }) => { const body = { path, page_content, seo: { page_title }, }; const data = await apiCall(`/v1/workspace/website/${website_id}/pages/create`, "POST", body); return { content: [{ type: "text", text: JSON.stringify(data?.result ?? data, null, 2) }] }; } - server/index.js:621-626 (schema)The input schema for the publish_page tool, defining required parameters: website_id, path, page_content, and page_title, all validated as strings via Zod.
inputSchema: { website_id: z.string().describe("The website ID"), path: z.string().describe("URL path (e.g. /about)"), page_content: z.string().describe("Page content in HTML"), page_title: z.string().describe("Page title for SEO"), }, - server/index.js:616-638 (registration)The full registration of the publish_page tool using server.registerTool() with its name, metadata (title, description, annotations), input schema, and handler function.
server.registerTool( "publish_page", { title: "Publish Page", description: "Publish a static page with HTML content.", inputSchema: { website_id: z.string().describe("The website ID"), path: z.string().describe("URL path (e.g. /about)"), page_content: z.string().describe("Page content in HTML"), page_title: z.string().describe("Page title for SEO"), }, annotations: { readOnlyHint: false, destructiveHint: false, openWorldHint: true }, }, async ({ website_id, path, page_content, page_title }) => { const body = { path, page_content, seo: { page_title }, }; const data = await apiCall(`/v1/workspace/website/${website_id}/pages/create`, "POST", body); return { content: [{ type: "text", text: JSON.stringify(data?.result ?? data, null, 2) }] }; } );