MCP connections for developers
Connect the Climatiq MCP server to code editors, agent frameworks and automated workflows.
Summary
This guide covers Claude Code, Cursor, VS Code (including GitHub Copilot) and agents that run without a person present.
The Intro to the Climatiq MCP server explains what it is, when to use it and what the free trial includes.
Prerequisites
- A Climatiq account. Sign up if you don’t have one.
- For OAuth: one login to app.climatiq.io before you connect. This first login creates the link between your account and the MCP server.
- For API key authentication: an API key.
Every setup below uses the same address: https://mcp.climatiq.io
Authentication
The MCP server needs to know which Climatiq account to use. There are two ways to authenticate:
| OAuth (sign in) | API key | |
|---|---|---|
| How it works | Your client opens a Climatiq login page and you sign in with your normal Climatiq login. | You send an API key in the Authorization header. |
| Best for | Interactive use in code editors. | Scripts, agents and other software that runs without a person present. |
| Which project is used | A project named ‘OAuth Project (Automatically created)’. Climatiq creates it the first time you sign in. | The project the API key belongs to. |
Usage and saved product footprints belong to the project used.
Connect your editor
Claude Code
OAuth: add the server, then run /mcp in Claude Code and choose Authenticate to sign in:
claude mcp add --transport http climatiq https://mcp.climatiq.ioAPI key: add the key as a header:
claude mcp add --transport http climatiq https://mcp.climatiq.io \
--header "Authorization: Bearer <YOUR_API_KEY>"See the Claude Code MCP docs for more options.
Automated and programmatic use
For agents, scripts and other software that run without a person present, nobody can complete the OAuth login. Use an API key instead:
- Send the header
Authorization: Bearer <YOUR_API_KEY>with every request tohttps://mcp.climatiq.io. Most MCP client libraries and agent frameworks let you set this header. - Keep the key on your server. Don’t put it in browser code, prompts or shared files.
- If you serve several customers, create one project and API key per customer. This keeps their usage and saved results apart.
- The server accepts any key when it connects and checks it on the first tool call. An invalid key lists the tools but fails as soon as one is used.
How to confirm it worked
- Check that your client lists Climatiq as connected, with tools such as
mapping_agent,energyandretrieve_emission_factors. - Ask: “What are the emissions of 500 kWh of electricity in Germany?”
- The answer should state that it used Climatiq and give a CO2e value with the emission factor and source behind it.
- Optional: check API usage in the Climatiq dashboard . The calculation appears there.
Troubleshooting
My API key is rejected
Check that the key is active in API Toolkit → API Keys in the dashboard and that it was copied in full. The header must start with Bearer . An invalid key still shows the tool list, so the error appears on the first calculation.
My client doesn’t support OAuth
Some clients can’t open a login page. Connect with an API key instead.
Where do my usage and saved product footprints go?
It depends on how you connected. If you signed in with your Climatiq login, they go to a project named ‘OAuth Project (Automatically created)’, which Climatiq creates the first time you sign in. If you connected with an API key, they go to the project that key belongs to.
For other issues, see Available tools and troubleshooting.