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

# MCP

> Tools for agents to vibe check themselves.

Kyoto MCP empowers your AI agents to evaluate and improve their vibe coding; enabling faster, higher-quality iteration and more productive outcomes.

<Tabs>
  <Tab title="Auto Setup">
    Run the command below to setup the MCP integration in your IDE.

    ```sh theme={null}
    kyoto setup mcp
    ```
  </Tab>

  <Tab title="Manual Setup">
    <Steps>
      <Step title="Register Kyoto's MCP">
        Add the following configuration to `.cursor/mcp.json`:

        <Note>
          Click here to [add to Cursor](cursor://anysphere.cursor-deeplink/mcp/install?name=kyoto\&config=eyJjb21tYW5kIjoia3lvdG8gbWNwIC0tY3dkICR7d29ya3NwYWNlRm9sZGVyfSJ9)
        </Note>

        ```json .cursor/mcp.json theme={null}
        {
          "mcpServers": {
            "kyoto": {
              "command": "kyoto",
              "args": ["mcp", "--cwd", "${workspaceFolder}"]
            }
          }
        }
        ```
      </Step>

      <Step title="Add agent rules">
        Create a rule file at `.cursor/rules/kyoto.mdc`:

        <Note>
          Click here to [add to Cursor](cursor://anysphere.cursor-deeplink/rule?name=kyoto\&text=---%0Adescription%3A+Kyoto+MCP+rules+for+vibe+checking+AI+code%0AalwaysApply%3A+true%0A---%0A%0AUse+the+Kyoto+MCP+tool+to+vibe+check+once+your+work+is+complete+to+ensure+the+code+aligns+with+our+best+coding+practices.%0A%0A)
        </Note>

        ```md .cursor/rules/kyoto.mdc theme={null}
        ---
        description: Kyoto MCP rules for vibe checking AI code
        alwaysApply: true
        ---

        Use the Kyoto MCP tool once your work is complete to ensure it aligns with best coding practices.
        ```
      </Step>
    </Steps>
  </Tab>
</Tabs>

## Tools

Kyoto MCP provides the following tools for code review and quality checking:

### `code-review`

Run all code review agents on unstaged changes. This comprehensive tool executes all individual agents in parallel and returns a combined summary of findings.

### Individual Agent Tools

<CardGroup cols={2}>
  <Card title="bug-detection" icon="bug">
    Detect bugs, logic errors, and potential runtime issues within the scope
  </Card>

  <Card title="code-organization" icon="folder">
    Find functions and components that should be moved to other packages or
    extracted into helper functions to reduce file sizes
  </Card>

  <Card title="function-consolidation" icon="merge">
    Highlight opportunities to merge or extract shared helpers from similar
    functions
  </Card>

  <Card title="library-usage" icon="book">
    Check library usage against documentation to ensure best practices and avoid
    reinventing the wheel
  </Card>

  <Card title="secret-detection" icon="key">
    Scan code changes for leaked secrets, API keys, passwords, and other sensitive
    information
  </Card>

  <Card title="stale-code-detection" icon="trash">
    Detect unused code that was added in scope or became unreachable due to
    changes
  </Card>

  <Card title="browser-test" icon="browser">
    Run browser tests on code changes using an AI agent. Analyzes changes, generates
    test suggestions, and executes them automatically
  </Card>
</CardGroup>

<Tip>
  Use the `code-review` tool to run all checks at once, or call individual agent
  tools for specific analysis. All tools analyze unstaged changes by default.
</Tip>
