
# Client connection

AccuWeather's MCP works with many different AI tools. While this page provides instructions for some of the more common options, it is not a comprehensive collection.

:::info

Replace `YOUR_API_KEY` in the examples below with a key from your [subscriptions page](/subscriptions), then [verify the connection](#verify-the-connection).

:::

## Claude

Custom connectors are available on every Claude plan, with limits on how many you can add. On Team and Enterprise, an owner adds the connector for the organization before members can connect to it.

### Custom connector

The same custom connector works in the Claude web app and Claude Desktop, and installs nothing. Add it under **Customize** → **Connectors**, using this URL with your free trial or Elite API key in place of `YOUR_API_KEY`:

```text
https://dataservice.accuweather.com/mcp?apikey=YOUR_API_KEY
```

Then enable AccuWeather in a conversation from the **+** menu.

The key goes in the URL because the connector form has no field for a custom header. Read [send the key](/documentation/weather-mcp-authentication#send-the-key) before you store or share that URL, particularly for an organization-wide connector where more people can see it.

For the current click-by-click flow, see [Anthropic's custom connector documentation](https://support.anthropic.com/en/articles/11175166-getting-started-with-custom-connectors-using-remote-mcp).

:::note{title="Where the connection comes from"}

Remote connectors reach AccuWeather from Anthropic's infrastructure, including when you use Claude Desktop. The MCP remote bridge below connects from your own machine instead. This matters if your network restricts outbound traffic, or if you are diagnosing why one works and the other does not.

:::

### Claude Desktop with the MCP remote bridge

Use this if you need the server defined in `claude_desktop_config.json`, to share one config file across machines for example. `claude_desktop_config.json` cannot point at a remote server directly, so the entry runs [`mcp-remote`](https://www.npmjs.com/package/mcp-remote), a small helper that connects on its behalf.

**Before you begin:** install [Node.js](https://nodejs.org). The helper runs through `npx`, which Node.js provides.

1. In the **Settings** menu, select **Developer**, then select **Edit Config**. This opens the folder containing your configuration file:
   - macOS: `~/Library/Application Support/Claude/claude_desktop_config.json`
   - Windows: `%APPDATA%\Claude\claude_desktop_config.json`
2. Open the file in a text editor and merge the AccuWeather server into any existing `mcpServers` entries, including your free trial or Elite API key where indicated. Both forms below authenticate the same way, and both work on every platform.

   <CodeTabs syncKey="mcp-remote-auth">

   ```json title="Key in an env variable"
   {
     "mcpServers": {
       "accuweather": {
         "command": "npx",
         "args": [
           "-y",
           "mcp-remote",
           "https://dataservice.accuweather.com/mcp",
           "--header",
           "Authorization:${AUTH_HEADER}"
         ],
         "env": {
           "AUTH_HEADER": "Bearer YOUR_API_KEY"
         }
       }
     }
   }
   ```

   ```json title="Key in URL"
   {
     "mcpServers": {
       "accuweather": {
         "command": "npx",
         "args": [
           "-y",
           "mcp-remote",
           "https://dataservice.accuweather.com/mcp?apikey=YOUR_API_KEY"
         ]
       }
     }
   }
   ```

   </CodeTabs>

   The key goes in `env` rather than straight into the `--header` argument because Claude Desktop on Windows mishandles the space in `Bearer YOUR_API_KEY`. The bridge fills the variable in before sending, so AccuWeather still receives the correct header. The "Key in URL" form avoids the space too, since it passes no header at all.

3. Save the file, then quit and relaunch Claude Desktop.
4. Confirm the AccuWeather tools are listed in the tool picker.

On Windows, see [bridge fails to launch](#windows-bridge-fails-to-launch) if the server does not start at all.

### Claude Code

[Claude Code](https://code.claude.com) adds remote MCP servers from the command line.

1. Run the following command, replacing `YOUR_API_KEY` with your free trial or Elite API key:

   ```bash
   claude mcp add --transport http accuweather https://dataservice.accuweather.com/mcp \
     --header "Authorization: Bearer YOUR_API_KEY"
   ```

   Without a scope flag, the server is added for the current project on the current machine only. Add `--scope user` to make it available in every project on your machine.

2. Confirm the server was added:

   ```bash
   claude mcp list
   ```

3. Start a new Claude Code session. Run `/mcp` in the session to check the connection and see the AccuWeather tools.

:::warning{title="Never commit an API key"}

`--scope project` writes the server into a `.mcp.json` that your team commits, so a literal key in that command ends up in version control. Reference an environment variable instead:

```bash title="Bash or zsh"
claude mcp add --transport http --scope project accuweather https://dataservice.accuweather.com/mcp \
  --header "Authorization: Bearer \${ACCUWEATHER_API_KEY}"
```

The backslash stops Bash or zsh expanding the variable, so the placeholder rather than your key is written to the file. Other shells escape differently, so check the file afterwards to confirm it contains `${ACCUWEATHER_API_KEY}` and not your key. Each teammate then sets `ACCUWEATHER_API_KEY` in their own environment.

Give each person their own key. A key belongs to one subscription, so sharing one means sharing an allowance, and rotating it breaks everyone at once.

:::

For the current command reference, see [Claude Code's MCP documentation](https://code.claude.com/docs/en/mcp).

## Cursor

Cursor reads MCP servers from a JSON configuration file.

1. Open `~/.cursor/mcp.json` in a text editor. Create the file if it does not exist.
2. Merge the AccuWeather server into any existing `mcpServers` entries, replacing `YOUR_API_KEY` with your free trial or Elite API key:

   ```json
   {
     "mcpServers": {
       "accuweather": {
         "url": "https://dataservice.accuweather.com/mcp",
         "headers": {
           "Authorization": "Bearer YOUR_API_KEY"
         }
       }
     }
   }
   ```

3. Save the file and restart Cursor.
4. Open **Customize**, find the AccuWeather server, and confirm its tools are listed.

### Sharing the configuration with your team

A workspace `.cursor/mcp.json` works the same way, but it is usually committed to source control. Reference an environment variable instead of a literal key:

```json
{
  "mcpServers": {
    "accuweather": {
      "url": "https://dataservice.accuweather.com/mcp",
      "headers": {
        "Authorization": "Bearer ${env:ACCUWEATHER_API_KEY}"
      }
    }
  }
}
```

Each teammate sets `ACCUWEATHER_API_KEY` themselves, somewhere Cursor can read it.

For the current setup flow, see [Cursor's MCP documentation](https://cursor.com/docs/mcp).

## GitHub Copilot

### VS Code

You can add the server through **MCP: Add Server**, but editing the configuration file directly is the route documented here because it makes the `Authorization` header explicit and easy to check.

1. Run **MCP: Open User Configuration** from the Command Palette to open your user `mcp.json`, or open `.vscode/mcp.json` to configure a single workspace. Create the file if it does not exist.
2. Merge the following into any existing `servers` and `inputs` entries. The `${input:…}` pattern prompts you for the key and stores it securely, so your key is never written into the file:

   ```json
   {
     "inputs": [
       {
         "type": "promptString",
         "id": "accuweather-api-key",
         "description": "AccuWeather free trial or Elite API key",
         "password": true
       }
     ],
     "servers": {
       "accuweather": {
         "type": "http",
         "url": "https://dataservice.accuweather.com/mcp",
         "headers": {
           "Authorization": "Bearer ${input:accuweather-api-key}"
         }
       }
     }
   }
   ```

3. Save the file, then start the server and trust it when VS Code asks.
4. Enter your API key at the prompt.
5. Open the chat input, select **Configure Tools**, and confirm the AccuWeather tools are listed.

For the current setup flow, see [VS Code's MCP documentation](https://code.visualstudio.com/docs/agent-customization/mcp-servers).

### JetBrains IDEs

This applies to IntelliJ IDEA, PyCharm, WebStorm, and other JetBrains IDEs with GitHub Copilot installed. If your organization manages Copilot, MCP servers may need to be enabled for you first.

In Copilot Chat, switch to **Agent** mode and open the MCP server configuration from the tools icon. Merge the following into `mcp.json`, replacing `YOUR_API_KEY` with your free trial or Elite API key. Note that the header goes inside `requestInit`, which differs from the VS Code format above:

```json
{
  "servers": {
    "accuweather": {
      "url": "https://dataservice.accuweather.com/mcp",
      "requestInit": {
        "headers": {
          "Authorization": "Bearer YOUR_API_KEY"
        }
      }
    }
  }
}
```

For the current menu path, see [GitHub's MCP documentation](https://docs.github.com/en/copilot/how-tos/provide-context/use-mcp-in-your-ide/extend-copilot-chat-with-mcp).

## ChatGPT

ChatGPT connects to MCP servers through developer mode on the web, which paid plans include. On a managed workspace, an administrator may need to enable it or grant you access first.

1. In **Settings**, select **Security and login**, then turn on **Developer mode**.
2. Go to **ChatGPT Plugins** and select the plus button.
3. Enter a name and description. These are what you will see when picking the connection in a conversation, so something like `AccuWeather` works well.
4. Under **Connection**, enter the URL below as the MCP server URL, including your free trial or Elite API key where indicated.

   ```text
   https://dataservice.accuweather.com/mcp?apikey=YOUR_API_KEY
   ```

5. Select **No authentication**. The key in the URL authenticates the connection.

   The form also offers **OAuth** and **Mixed authentication**. Neither accepts a custom `Authorization` header, which is why the key goes in the URL. Treat that URL as a secret.

6. Create the connection. It is live once the AccuWeather tools and their descriptions appear on its details page.
7. Open a conversation, select **Developer mode** from the **+** menu in the composer, then select AccuWeather.

When several connections offer similar tools, name the one you want in your prompt: "Use the AccuWeather app's `get_daily_forecast` tool for Boston."

For the current setup flow, see [OpenAI's developer mode documentation](https://developers.openai.com/api/docs/guides/developer-mode).

## MCP Inspector

MCP Inspector is a tool that lists every available tool and lets you call one directly. Use it to confirm your key works before configuring a client.

**Before you begin:** install [Node.js](https://nodejs.org) 22.19.0 or newer, which the current Inspector requires.

1. Run the following command, replacing `YOUR_API_KEY` with your free trial or Elite API key:

   ```bash
   npx @modelcontextprotocol/inspector --web
     --server-url https://dataservice.accuweather.com/mcp
     --transport http
     --header "Authorization: Bearer YOUR_API_KEY"
   ```

2. Open the URL the command prints, then select **Connect**.
3. Select **List Tools** to see the AccuWeather tools, and select any one to call it with your own arguments.

For current options and flags, see the [MCP Inspector repository](https://github.com/modelcontextprotocol/inspector).

## Other clients

The examples above are not a complete list. Any MCP client that supports a remote Streamable HTTP server, and lets you supply an API key as either an `Authorization` header or a URL parameter, can connect using the details in [endpoint and authentication](/documentation/weather-mcp-authentication).

## Verify the connection

Whichever client you set up, confirm it works the same way. Ask your assistant:

> What's the 5-day forecast for New York City?

**Expected result:** a five-day forecast. You will typically see two AccuWeather tool calls, one to look up New York City and one to fetch the forecast for it, though how your assistant sequences them is up to it. Most clients let you expand a tool call to see what was sent.

More than one call for a single question is normal, and each counts against your allowance. See [usage and billing](/documentation/weather-mcp-usage-and-billing).

If nothing happens, or the assistant answers without calling a tool, see [troubleshooting](#troubleshooting) below.

## Troubleshooting

| Issue                       | Resolution                                                                                                                                                              |
| --------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| No AccuWeather tools appear | Restart the client so it reloads the tool list. Reconnect the connector if you used one.                                                                                |
| Tool names look out of date | Your client is showing a cached list. Restart it, and reconnect the connector.                                                                                          |
| `401 Unauthorized`          | Check the key is correct and active on the [subscriptions page](/subscriptions).                                                                                        |
| `403 Forbidden`             | The key is valid but its plan does not include MCP. Only the free trial and Elite plans do. Compare plans on the [pricing page](/pricing).                              |
| `429 Too Many Requests`     | You have hit a rate limit. On the free trial this is usually the daily allowance, which resets daily. Wait and retry, or upgrade on the [pricing page](/pricing).       |
| Only some tools appear      | Your client may be limiting how many tools it sends to the model at once. Check its tool settings, and deselect tools from other servers if you have several connected. |

### Windows: bridge fails to launch

**Symptom:** Claude Desktop does not start the MCP remote bridge, and reports `'C:\Program' is not recognized as an internal or external command`.

**Cause:** Node.js installs to `C:\Program Files\nodejs` by default, and the unquoted space in that path breaks the command when the server is launched. This affects MCP servers generally on Windows, not just AccuWeather's. You only hit it if Node is installed somewhere containing a space, which is why it does not affect every Windows machine.

**Resolution:** run `npx` through `cmd` so it resolves from `PATH`, keeping the rest of the entry as it is:

```json
{
  "mcpServers": {
    "accuweather": {
      "command": "cmd",
      "args": [
        "/c",
        "npx",
        "-y",
        "mcp-remote",
        "https://dataservice.accuweather.com/mcp",
        "--header",
        "Authorization:${AUTH_HEADER}"
      ],
      "env": {
        "AUTH_HEADER": "Bearer YOUR_API_KEY"
      }
    }
  }
}
```

If the `cmd` wrapper causes trouble of its own, point `command` straight at `npx` instead, using either the full path `C:\\Program Files\\nodejs\\npx.cmd` or its short form `C:\\PROGRA~1\\nodejs\\npx.cmd`, and drop `"/c"` and `"npx"` from `args`. Run `where npx` in Command Prompt to confirm the path on your machine.

This is a separate problem from the space in `Bearer YOUR_API_KEY`, which the configuration above already avoids by putting the key in `env`.

## What next?

- [Tools](/documentation/weather-mcp-tools) — what each tool returns
- [Usage and billing](/documentation/weather-mcp-usage-and-billing) — what MCP costs on your plan
- [Endpoint and authentication](/documentation/weather-mcp-authentication) — key handling and the `apikey` parameter
