> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getsly.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Agent-readable docs (llms.txt)

> Sly publishes machine-readable doc indexes at docs.getsly.ai/llms.txt and llms-full.txt. Use them to feed Sly knowledge into your agent.

The whole public docs portal is also published as plain text for agent consumption, following the [llms.txt convention](https://llmstxt.org).

## What's available

<CardGroup cols={2}>
  <Card title="llms.txt — index" icon="list" href="https://docs.getsly.ai/llms.txt">
    Hierarchical link index of every doc page. Compact (\~30 KB). Best when you want the agent to navigate to specific topics.
  </Card>

  <Card title="llms-full.txt — flattened" icon="file-lines" href="https://docs.getsly.ai/llms-full.txt">
    Every page concatenated as a single document (markdown). Larger (\~1-3 MB depending on size). Best for stuffing the agent's context once and answering many questions.
  </Card>
</CardGroup>

Both are auto-regenerated by Mintlify on every docs deploy — they always reflect the current state of `docs.getsly.ai`.

Each individual page is also available as raw markdown by appending `.md` to its URL:

```
https://docs.getsly.ai/agents/kya-tiers.md
https://docs.getsly.ai/protocols/x402.md
https://docs.getsly.ai/api-reference/openapi
```

## How agents typically use this

### Pattern 1 — knowledge base for support agents

```ts theme={null}
const SLY_KB = await fetch('https://docs.getsly.ai/llms-full.txt').then(r => r.text());

// Pin in the agent's system prompt
const systemPrompt = `
You are a support agent for the Sly platform. Reference the
documentation below when answering integration questions:

${SLY_KB}
`;
```

Refresh once per deploy or on a daily cron.

### Pattern 2 — targeted lookup via index

```ts theme={null}
// 1. Fetch the index
const index = await fetch('https://docs.getsly.ai/llms.txt').then(r => r.text());

// 2. Ask the LLM which page is relevant
const relevantUrl = await llm.ask(`
  Which doc URL is most relevant for the question: "${userQuestion}"?
  Choose from this index:
  ${index}
`);

// 3. Fetch only that page
const page = await fetch(relevantUrl).then(r => r.text());
```

Cheaper on tokens than stuffing all docs upfront.

### Pattern 3 — MCP server consumption

If you're using the [Sly MCP server](/sdks/mcp-server), it exposes documentation lookup as a built-in tool. Agents call `sly_docs_search(query)` and get the relevant page back as a tool result.

## Caching guidance

* **llms.txt** changes when the doc structure changes (rare). Cache for a day.
* **llms-full.txt** changes on every doc deploy. Cache for an hour.
* **Per-page `.md`** changes when that page is edited. Cache for an hour.

Both files are served with appropriate `Cache-Control` headers.

## Related agent surfaces

Sly is agent-first across multiple surfaces:

* **[MCP catalog](/agents/mcp-tool-catalog)** — every Sly capability as an MCP tool, drop-in for Claude Desktop / Cursor / Windsurf
* **[A2A agent card](/agents/a2a-agent-card)** — public, machine-readable identity + skill catalog
* **OpenAPI spec** — `docs.getsly.ai/api-reference/openapi.json` for codegen
* **Function-calling tool definitions** — `GET /v1/capabilities/function-calling` returns OpenAI/Anthropic-compatible tool defs

Use whichever surface fits your runtime.
