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

# MCP Server Overview

# MCP Server Overview

The Stackfront MCP (Model Context Protocol) server bridges your AI coding assistant with the full Stackfront ecosystem. Instead of asking your AI tool to guess SDK APIs, the server provides live, structured access to documentation, SDK source reflection, copy-paste-ready code examples, and guided prompts — all from your editor.

## Architecture

```
┌─────────────────────┐       ┌──────────────────────────────┐
│  AI Coding Assistant │ ◄──► │     Stackfront MCP Server    │
│  (Cursor, Claude     │      │                              │
│   Code, VS Code)     │      │  ┌──────────┐ ┌───────────┐  │
└─────────────────────┘      │  │ Stdio     │ │ Workers   │  │
                             │  │ (local)   │ │ (remote)  │  │
                             │  └──────────┘ └───────────┘  │
                             │         │            │        │
                             │         ▼            ▼        │
                             │  ┌───────────────────────┐    │
                             │  │      Core Modules     │    │
                             │  │  ┌─────────────────┐  │    │
                             │  │  │ DocStore        │  │    │
                             │  │  │ (fetches Mintlify│  │    │
                             │  │  │  docs on demand) │  │    │
                             │  │  └─────────────────┘  │    │
                             │  │  ┌─────────────────┐  │    │
                             │  │  │ SdkStore        │  │    │
                             │  │  │ (parses SDK src │  │    │
                             │  │  │  via TS compiler)│  │    │
                             │  │  └─────────────────┘  │    │
                             │  │  ┌─────────────────┐  │    │
                             │  │  │ Code Examples   │  │    │
                             │  │  │ (16 snippets)   │  │    │
                             │  │  └─────────────────┘  │    │
                             │  └───────────────────────┘    │
                             └──────────────────────────────┘
```

The server runs in two modes:

* **Stdio** — connects directly to your local AI tool via standard input/output. No network, no latency.
* **SSE / Workers** — runs on Cloudflare Workers, accessible remotely (useful for team-wide tooling or CI/CD).

## Capabilities

| Category      | Count | Details                                                                |
| ------------- | ----- | ---------------------------------------------------------------------- |
| **Resources** | \~50+ | Documentation pages + SDK reflection (hooks, services, types, GraphQL) |
| **Tools**     | 3     | `search_docs`, `get_sdk_api`, `get_code_example`                       |
| **Prompts**   | 2     | `integrate-sdk`, `build-feature`                                       |

### What Your AI Assistant Can Do

* **Search docs** — find the right documentation page by query, get back links with relevant excerpts.
* **Look up SDK APIs** — get the exact TypeScript signature, parameters, return type, and JSDoc for any hook, service, or type.
* **Fetch code examples** — paste a complete, working component for cart, products, search, auth, push notifications, loyalty, reviews, or engagement features.
* **Follow guided prompts** — run a structured workflow to integrate the SDK into a new project or build a specific feature.

## Location

Source code: [`pkgs/mcp-server/`](https://github.com/GetThumbly/stackfront/tree/main/pkgs/mcp-server)

## Next Steps

* [Setup](/docs/mcp-server/setup) — configure the server for your editor
* [Reference](/docs/mcp-server/reference) — complete tool, resource, and prompt documentation
