Visual Studio Code
Connect Visual Studio Code (Github Copilot) to Ternary.
Before you start
You need:
- An existing Ternary account
- Access to at least one Ternary tenant
- VS Code
1.106or later - GitHub Copilot with Agent mode
Earlier VS Code versions may not support the sign-in method Ternary uses without additional manual configuration.
On Copilot Business or Enterprise plans, an administrator may need to enable MCP servers in your organization's Copilot policy.
Step 1: Add the server
- Open the Command Palette:
- macOS: Cmd + Shift + P
- Windows/Linux: Ctrl + Shift + P
- Run MCP: Add Server.
- Choose HTTP.
When VS Code asks for the server URL, paste the URL for your Ternary region:
https://core-api.ternary.app/mcphttps://core-api.eu.ternary.app/mcpThen name the server ternary, and choose whether to save it in the current workspace or in your user profile for all workspaces.
After you finish, VS Code writes a file like this (workspace example):
{
"servers": {
"ternary": {
"type": "http",
"url": "https://core-api.ternary.app/mcp"
}
}
}{
"servers": {
"ternary": {
"type": "http",
"url": "https://core-api.eu.ternary.app/mcp"
}
}
}You can create that file yourself instead of using the Command Palette. For this workspace, put it in .vscode/mcp.json. For all workspaces, use your user MCP configuration.
If the file already has other servers, add the "ternary" block inside "servers". Do not replace the rest of the file.
Step 2: Sign in
- Open the Command Palette.
- Run MCP: List Servers.
- Select
ternary. - Select Start Server.
VS Code opens Ternary in your browser.
Sign in with your normal Ternary credentials and approve access. When authentication completes, MCP: List Servers should show Ternary as running. The sign-in is remembered for normal day-to-day use.
Step 3: Use Ternary in Copilot
- Open Copilot Chat.
- Switch to Agent mode.
- Open the tools selector.
- Confirm that Ternary tools are enabled.
Then ask:
Using Ternary, what did we spend last month by provider?
Show our top five services by spend.
Which budgets are at risk?
List recent cost alerts.
The first time Copilot uses a Ternary tool, VS Code may ask for permission.
Ternary's MCP is predominantly read-only. Creating a private report is the one current write action and should only happen when you explicitly request it.
Troubleshooting
Ternary does not appear in Copilot
Check:
- The MCP server is running
- You are using Copilot Agent mode
- Ternary tools are enabled
- Your organization allows MCP servers
MCP features can be missing entirely if your organization's GitHub Copilot policy disables them. Ask your Copilot administrator to enable MCP servers in Copilot.
VS Code refuses to add the server
Your organization may restrict which MCP servers are allowed, through the chat.mcp.access policy or an allowlist.
If that policy is set to registry, Ternary has to be published in your organization's MCP registry before VS Code will load it. Your IT team owns both settings.
VS Code asks for a client ID
You are likely on a version older than 1.106. Versions 1.102 to 1.105 can support MCP but may require a client ID by hand for the authentication flow Ternary uses.
Cancel the dialog and run Code → Check for Updates. Do not enter a client ID.
Sign-in fails
Confirm that you used the correct regional Ternary URL, with no trailing slash.
No tenants appear
Ask your Ternary administrator to confirm your explicit tenant access.
The agent ignores Ternary
Check that the tools icon shows Ternary tools enabled, make sure the mode is Agent and not Ask, and name Ternary in the question.
See Troubleshooting Ternary MCP for shared issues.
Updated about 5 hours ago
