AI / GEO: - feat(content): lexicalToMarkdown, blocksToMarkdown, createMarkdownRenderer (+markdownResponse) — per-page Markdown for AI agents - feat(content): markdown content negotiation + discovery (prefersMarkdown, markdownHref) - feat(seo): buildRobots aiBots policy (allow/block-training/disallow) - feat(seo): llms-full.txt mode in buildLlmsTxt/createLlmsTxtRoute - feat(mcp): createMcpRoute — read-only MCP server (search_content, get_page) - feat(content): searchContent + createSearchRoute — shared JSON search - feat(seo): buildSpeakableJsonLd + buildSummaryField (aiSummary, auto-fill) Forms: - feat(forms): useForm/useContactForm + validators (logic-only, no markup) - feat(forms): honeypot anti-spam (honeypotInputProps, isHoneypotTripped) Helpers / hardening: - feat(i18n): resolveLocalized — replaces ad-hoc getSafeString - feat(hooks): buildCrossLocaleFieldSync — locales from config, no hardcoded list - feat(seo): buildNoindexField — checkbox → meta.noindex, no - feat(content): resolveRedirect — 301/308 from slugHistory - feat(env): assertEnv + ipalEnvRules — fail-fast env validation - feat(consent): ConsentScript — load third-party only after consent - feat(health): createHealthRoute — Coolify/Docker DB liveness Fixes: - fix(seo): wrap getCachedPayload in try/catch in createManifestHandler (Docker/CI build no longer crashes when DB unreachable) docs: migration.md (20 sections), new env.md/mcp.md, updated agents.md, AGENTS-TEMPLATE.md, forms/hooks/content/seo/consent/deployment/richtext
27 lines
1.1 KiB
TypeScript
27 lines
1.1 KiB
TypeScript
import type { BasePayload } from 'payload';
|
|
import type { ContentOption } from '../content/index.js';
|
|
import type { I18nConfig } from '../i18n/index.js';
|
|
type CreateMcpRouteArgs = {
|
|
/** Absolute origin for building result URLs. */
|
|
baseUrl?: string;
|
|
/** Pages collection. Default 'pages'. */
|
|
collection?: string;
|
|
config: I18nConfig;
|
|
/** Archive-backed collections (same as the plugin option) for get_page. */
|
|
content?: ContentOption;
|
|
getCachedPayload: () => Promise<BasePayload>;
|
|
/** Server name advertised in `initialize`. Default 'ipal-site'. */
|
|
serverName?: string;
|
|
/** Server version advertised in `initialize`. Default '1.0.0'. */
|
|
serverVersion?: string;
|
|
/** SiteSettings slug. Default 'site-settings'. */
|
|
settingsSlug?: string;
|
|
/** Field holding a richer AI summary (buildSummaryField) to prefer in search results. */
|
|
summaryField?: string;
|
|
};
|
|
export declare function createMcpRoute(args: CreateMcpRouteArgs): {
|
|
GET: () => Promise<Response>;
|
|
POST: (req: Request) => Promise<Response>;
|
|
};
|
|
export {};
|