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

# VS Code

> Set up VS Code with TrueFoundry AI Gateway using the setup wizard.

Connect VS Code to your organization's gateway. The wizard configures its models and optional MCP servers and Skills.

## Run setup

With VS Code installed, [install the setup tool](https://www.truefoundry.com/docs/ai-gateway/personal-setup.md#install-the-setup-tool), then run:

```bash theme={"dark"}
tfy-local-ai-setup personal vscode
```

Sign in to your organization, choose the models recommended by your administrator and any MCP servers or Skills you need, then review and approve the changes. You can skip MCP servers and Skills. See the [overview](https://www.truefoundry.com/docs/ai-gateway/personal-setup.md#connect-your-agents) for the shared wizard walkthrough.

![VS Code setup wizard showing available models and the default model](https://mintcdn.com/truefoundry/WDjROyMkpUZ8WZAf/images/ai-gateway/personal-setup/vscode-models.png?fit=max\&auto=format\&n=WDjROyMkpUZ8WZAf\&q=85\&s=586cdc49a7a0f1246bf34f0caad18277)

Example model settings for VS Code; use your organization's model IDs.

## Finish in VS Code

1. Open or restart VS Code. Open the Command Palette and run **Chat: Manage Language Models**.
2. If a configured model needs an API key, run `tfy-local-ai-setup token` in your terminal. Paste the result through the model row's **Update API Key** action.
3. Open a new chat and select your gateway model.

## Optional: authorize MCP servers

Complete sign-in for selected MCP servers inside VS Code. See [Connect MCP from your IDE](https://www.truefoundry.com/docs/ai-gateway/mcp/connect-mcp-from-ide.md).

## Verify the connection

Select your configured model in a new conversation and ask: `Reply exactly TFY-CHAT-OK. Do not use tools.` Confirm that a response arrives without an authentication or model error. Then [verify the request in the gateway](https://www.truefoundry.com/docs/ai-gateway/personal-setup.md#verify-the-connection).

For manual configuration and advanced options, see the [VS Code integration guide](https://www.truefoundry.com/docs/ai-gateway/vscode.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.