.md URL extension
Add.md to any page’s URL to view a Markdown version.
Accept header
Send a request withAccept: text/markdown or Accept: text/plain to any page URL to receive the Markdown version instead of HTML. This is useful for AI tools and integrations that programmatically fetch documentation content.
Audience-specific content
Use the visibility component to customize content for human and AI audiences. Content wrapped in<Visibility for="humans"> appears on the web page, but not in Markdown output. Content wrapped in <Visibility for="agents"> appears in Markdown output, but not on the web page.
API reference pages
By default, Markdown exports of API reference pages include the full OpenAPI or AsyncAPI specification so AI tools have complete context about each endpoint. If you prefer to omit the spec from Markdown output, setmarkdown.schema to false in your docs.json:
Custom agent instructions
To append your own guidance to the Markdown that Mintlify serves to AI agents, setmarkdown.instructions in your docs.json. Use it for site-wide directions like citing an API version, preferring a specific SDK, or following your terminology.
Provide a single string:
Example agent instructions string
Example agent instructions array
Agent Instructions block in the Markdown output:
Example rendered agent instructions
- The Markdown export of every page, including API reference pages.
- Your
llms.txtfile, after the site title and description. - Your
llms-full.txtfile.
Agent feedback
If you enable agent feedback, Mintlify appends an<AgentInstructions> block to each page’s Markdown export that tells agents how to submit feedback about the page’s content.
Agents submit feedback by posting to the endpoint with the page path and feedback text.
Use agent feedback to improve your pages for agents based on what they find incorrect, outdated, or confusing.
Authentication
Markdown export respects the same authentication rules as the HTML version of each page.| Authentication mode | Behavior |
|---|---|
| No authentication | All .md URLs are publicly accessible. |
| Partial authentication | .md URLs for public pages are publicly accessible. .md URLs for protected pages require authentication and respect user group restrictions. |
| Full authentication | All .md URLs require authentication and respect user group restrictions. |