Skip to content

docs: add agent-facing metadata to docs.json - #604

Merged
dangrondahl merged 2 commits into
mainfrom
docs/agent-facing-metadata
Dec 4, 2026
Merged

dangrondahl merged 2 commits into
mainfrom
docs/agent-facing-metadata

Conversation

@dangrondahl

Copy link
Copy Markdown
Contributor

Config-only change to docs.json so Mintlify generates better agent-facing output (llms.txt, page Markdown, JSON-LD, Link header). No content pages, navigation, redirects, or custom llms.txt/robots.txt/skill.md.

Every field was checked against the schema at https://mintlify.com/docs.json and the Mintlify pages on SEO and llms.txt. All four exist in the schema, so nothing was left out.

Fields added

Field What it changes for agents
description Becomes the blockquote summary under the title in /llms.txt, which fixes the "No blockquote summary found" warning from the agent readiness check. The schema also uses it for SEO and AEO. The wording comes from index.mdx and understand_kosli/what_is_kosli.md.
markdown.instructions Shows as an "Agent Instructions" block in /llms.txt. Per the schema, it is also appended to every page served as Markdown. It has four lines: append .md for Markdown, use the docs MCP server (/mcp) to search, read /skill.md for task workflows, and use client_reference/ for exact CLI flags instead of guessing.
seo.organization Sets the Organization (publisher) entity in the JSON-LD on every page: name Kosli, url https://www.kosli.com, logo https://docs.kosli.com/logo/kosli-logo-light-main.svg. The schema needs an absolute URI for logo, so the /logo path is written as a full URL.
contextual.options Adds three options. download-spec sits next to view, and it also makes Mintlify advertise the API catalog in the Link header. assistant sits in front of the external AI chat options. add-mcp sits next to mcp. The existing options keep their relative order.

Verification

  • mint validate: build passed, validation passed
  • mint broken-links: no broken links found
  • pytest tests/: 68 passed

mint score docs.kosli.com --format json (against the live site, before this change)

Overall 97 (A), 31/35 checks passed. These checks did not pass:

Check Status Message
llms-txt-valid warn llms.txt contains parseable links but doesn't fully follow the proposed structure: https://docs.kosli.com/llms.txt: No blockquote summary found
llms-txt-size warn llms.txt is 76,398 characters (between 50,000 and 100,000; consider splitting)
section-header-quality skip 1 page(s) with tabs found, but no section headers inside tab panels to evaluate
auth-alternative-access skip All docs pages are publicly accessible; no alternative access paths needed

content-negotiation (15/15 sampled pages) and markdown-content-parity (all 15 pages, avg 0% missing) both passed, so the score named no page URLs for them.

llms-txt-valid should pass once this is deployed. llms-txt-size is out of scope here. Adding the description and instructions makes llms.txt a little longer, but it stays well under the 100,000-character split limit.

For the reviewer

The llms.txt and JSON-LD changes only show on a deployed site, so mint dev won't show them. Please check the Mintlify preview deployment for this PR:

  • <preview>/llms.txt: there should be a > blockquote summary under # Kosli Documentation, followed by an ## Agent Instructions block
  • any page's .md URL: the instructions should be appended
  • any page's HTML: the JSON-LD Organization entity should have the Kosli name, URL and logo
  • the page context menu: there should be the new Assistant, Add MCP and Download spec options

@mintlify

mintlify Bot commented Dec 4, 2026 •

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated
kosli 🟢 Ready View Preview Dec 4, 2026, 3:18 PM

💡 Tip: Enable Automations to automatically generate PRs for you.

@claude

claude Bot commented Dec 4, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @dangrondahl's task in 55s —— View job


Follow-up review complete

  • Fetch previous review comments
  • Diff BEFORE..AFTER and check status of prior finding
  • Check for new bugs/regressions in the changed lines
  • Post summary comment

Previous finding (client_reference 404 risk): ✅ Resolved — markdown.instructions now points to client_reference/overview.md instead of the bare client_reference/ directory. Verified that page exists and is registered in nav (config/navigation.json:263), so no 404 risk.

No new bugs or regressions introduced by the one-line wording change in docs.json:52. Resolution noted inline, and a summary posted via PR comment.

Comment thread docs.json Resolved
@dangrondahl

dangrondahl commented Dec 4, 2026 •

Copy link
Copy Markdown
Contributor Author

Every page served as Markdown (any .md URL) now also has this block:

> ## Agent Instructions
> Append `.md` to any page URL to get the page as Markdown, for example https://docs.kosli.com/getting_started/install.md.
> To search these docs, use the Kosli docs MCP server at https://docs.kosli.com/mcp.
> For step-by-step task workflows, read https://docs.kosli.com/skill.md.
> For exact CLI commands, flags and defaults, start at https://docs.kosli.com/client_reference/overview.md instead of guessing. The command pages are generated from the CLI source.

@dangrondahl
dangrondahl marked this pull request as ready for review December 4, 2026 15:19
@dangrondahl
dangrondahl requested a review from a team as a code owner December 4, 2026 15:19
Comment thread docs.json Resolved
@claude

claude Bot commented Dec 4, 2026

Copy link
Copy Markdown
Contributor

Follow-up review: commit 1d067c7

Previous finding (client_reference 404 risk): ✅ Resolved. markdown.instructions now points to https://docs.kosli.com/client_reference/overview.md instead of the bare client_reference/ directory. Verified client_reference/overview.md exists and is registered in config/navigation.json:263, so this entry point resolves correctly.

No new issues found in the changed line (docs.json:52) — it's a one-line wording fix with no other side effects.

@dangrondahl
dangrondahl enabled auto-merge (squash) December 4, 2026 15:24
@dangrondahl
dangrondahl merged commit 792bb74 into main Dec 4, 2026
6 checks passed
@dangrondahl
dangrondahl deleted the docs/agent-facing-metadata branch December 4, 2026 15:25

This branch was successfully deployed

1 active deployment
staging — 1d067c74 Deployed Dec 4, 2026 by mintlify[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants