diff --git a/netlify/edge-functions/markdown-source.js b/netlify/edge-functions/markdown-source.js index 1295e8bc9c..421a18dc04 100644 --- a/netlify/edge-functions/markdown-source.js +++ b/netlify/edge-functions/markdown-source.js @@ -143,6 +143,8 @@ export default async function handler(request, context) { url.pathname.endsWith(".md") || url.pathname.endsWith(".mdx"); + console.log(`Request for markdown version of ${url.pathname}`); + // Pass through requests that don't want Markdown if (!wantsMarkdown) { return; // passthrough @@ -199,6 +201,8 @@ export default async function handler(request, context) { "x-llms-txt": "/docs/llms.txt", }; + if ( !acceptHeader.includes("text/markdown") ) headers["Content-Type"] = "text/plain; charset=utf-8"; + return new Response(body, { status: 200, headers, diff --git a/product_docs/docs/efm/5/index.mdx b/product_docs/docs/efm/5/index.mdx index 7ce86181fe..c9d51c0ba3 100644 --- a/product_docs/docs/efm/5/index.mdx +++ b/product_docs/docs/efm/5/index.mdx @@ -51,6 +51,8 @@ pdf: true Failover Manager (EFM) is a tool for managing Postgres database clusters, enabling high availability of primary-standby deployment architectures using streaming replication. Failover Manager provides a Postgres primary database node automatic failover to a standby database node in the event of a software or hardware failure. You can use Failover Manager with PostgreSQL or EDB Postgres Advanced Server. +--- +For AI assistants: A structured index of all docs pages is at /docs/llms.txt. Each page's markdown source (including frontmatter with title, description, and navigation) is accessible by requesting the page with an `Accept: text/markdown` request header. You'll need to use a tool like `curl` that allows setting a request header to retrieve these, e.g. `curl -H "Accept: text/markdown" https://edb-docs-staging.netlify.app/docs/epas/latest/`. Prefer markdown over HTML for short, accurate content.