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

# VS Code

> Connect XentFi agent tools to VS Code (Copilot agent mode and other MCP-aware extensions).

VS Code's built-in MCP support (used by GitHub Copilot Chat's agent mode and other MCP-aware extensions) reads from a workspace `.vscode/mcp.json` or your user settings.

## Workspace config

Create `.vscode/mcp.json`:

```json theme={null}
{
    "servers": {
        "xentfi": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "@xentfi/mcp-server"
            ],
            "env": {
                "XENTFI_AGENT_KEY": "${input:XENTFI_AGENT_KEY}",
            }
        }
    },
    "inputs": [
        {
            "id": "XENTFI_AGENT_KEY",
            "type": "promptString",
            "description": "XentFi Agent API Key",
            "password": true
        },
        {
            "id": "xentfi_org_id",
            "type": "promptString",
            "description": "XentFi Organization ID (optional, needed for market-data tools)",
            "password": false
        }
    ]
}
```

Using `inputs` means VS Code prompts you for the key the first time (and stores it securely) instead of writing it in plain text into a file you might commit.

## User settings (all workspaces)

Command Palette → **MCP: Open User Configuration**, and add the same `xentfi` entry under your VS Code version's MCP servers section in `settings.json`.

## Enabling it

<Steps>
  <Step title="List servers">
    Command Palette → **MCP: List Servers** → confirm `xentfi` shows as running.
  </Step>

  <Step title="Use agent mode">
    Open Copilot Chat, switch to **Agent** mode — XentFi tools are offered automatically when relevant.
  </Step>

  <Step title="Debug if needed">
    Command Palette → **MCP: Show Server Output**, look for `[xentfi-mcp]` lines.
  </Step>
</Steps>

<Note>
  VS Code's MCP integration has changed across releases. If `.vscode/mcp.json` isn't picked up, check the Command Palette for the current MCP commands in your installed version and use **MCP: Add Server** to generate a stub, then fill in the `command`/`args`/`env` from the snippet above.
</Note>

## Next steps

<CardGroup cols={2}>
  <Card title="Tools Reference" icon="list" href="/agent/tools-reference">
    See every available tool.
  </Card>

  <Card title="Codex / Agents SDK" icon="puzzle" href="/agent/codex">
    Another way to build with these tools programmatically.
  </Card>
</CardGroup>
