VS Code
Connect the AstroWay API to VS Code over MCP. The config is read by Copilot Chat in Agent mode.
Prerequisites
Section titled “Prerequisites”Get an API key in the dashboard. For free testing use a sandbox aw_test_* key — it doesn’t spend credits.
Create .vscode/mcp.json in your project root. Note: in VS Code the key is servers (not mcpServers), and each server needs a type field. Paste one of the blocks below and restart VS Code.
Hosted (HTTP) — zero install, Bearer-token auth:
{"servers": { "astroway": { "type": "http", "url": "https://mcp.astroway.info/mcp", "headers": { "Authorization": "Bearer aw_live_YOUR_KEY" } }}}Stdio (npx) — local subprocess, env-var auth, offline-ready:
{"servers": { "astroway": { "type": "stdio", "command": "npx", "args": ["-y", "@astroway/mcp"], "env": { "ASTROWAY_API_KEY": "aw_live_YOUR_KEY" } }}}Verify
Section titled “Verify”In Copilot Chat (Agent mode), type: “List the AstroWay tools” — or ask it to call a free reference tool, such as fetching the list of zodiac signs. If a result comes back, the connection works.
Troubleshooting
Section titled “Troubleshooting”- 401 / invalid key — make sure the key is prefixed
aw_live_*oraw_test_*and isn’t revoked. Check it in the dashboard. - Tools don’t appear — fully restart VS Code and verify the
.vscode/mcp.jsonpath (keyservers, fieldtype). -32602validation errors (stdio) — update the package:npm i @astroway/mcp@latest. Schemas are regenerated from the live spec.
See all clients — Agent setup.
Was this helpful?
Thanks for the feedback.