For the complete documentation index, see llms.txt. This page is also available as Markdown.

Claude Code

Claude Code is Anthropic's CLI for AI-assisted software engineering. It supports MCP servers at three scopes: local (your machine), project (shared through .mcp.json in a repo), and user (your global ~/.claude.json).

Prerequisites

  • Claude Code installed. For more information, see claude.ai/code.

  • The ionoscloud-mcp binary built and available. For more information, see Quick Start.

  • An IONOS CLOUD API token. For least-privilege access, see Authentication to scope the token to only the tools you need.

Add the MCP server

Use the claude mcp add command to register the server:

claude mcp add ionoscloud /usr/local/bin/ionoscloud-mcp \
  --env IONOS_TOKEN=your-api-token

To also enable Object Storage tools:

claude mcp add ionoscloud /usr/local/bin/ionoscloud-mcp \
  --env IONOS_TOKEN=your-api-token \
  --env IONOS_S3_ACCESS_KEY=your-access-key \
  --env IONOS_S3_SECRET_KEY=your-secret-key

By default, this registers the server at local scope (your machine only). To share the config with a team via source control, use --scope project instead; this writes to a .mcp.json file in the current directory.

Option B: Project config file

Create or edit .mcp.json in your repository root:

Commit this file to share the server configuration with your team. Each team member supplies credentials via their own environment variables; never commit tokens to the file. Use ${env:IONOS_TOKEN} in the config to reference an environment variable instead of hardcoding the value:

Each team member then exports IONOS_TOKEN in their shell profile (~/.zshrc, ~/.bashrc) and the token is never stored in the committed file.

Note: Claude Code prompts you to approve a project-scoped .mcp.json on first use. When the prompt appears, review the command path and env block; confirm the binary path is correct and no unexpected variables are present. Select Allow to proceed or Deny to cancel (the server will not load if denied). For CI/CD environments, use the --allowedTools flag or a pre-approved trust policy instead of interactive approval.

Verify the connection

1

List available MCP servers

ionoscloud appears in the output when the server is registered.

2

Start Claude Code and test

Then type: List my IONOS CLOUD data centers.

Note: All tools are registered at startup by default, so Compute Engine and Object Storage tools appear immediately. To reduce the startup tool count, pass --env IONOS_MCP_LOAD_MODE=lazy when adding the server (or add it to .mcp.json) and call the ionos_load_compute_tools or ionos_load_objectstorage_tools sentinels on demand. For more information, see Selective Tool Loading.

Deploying for a team

The project-scoped .mcp.json file is the recommended way to share the MCP server configuration across a team. In the server's default read-only configuration, sharing access to production account data carries no risk of accidental modifications.

Do not commit IONOS_MCP_TOOL_SCOPE to a shared .mcp.json. Doing so activates write tools for everyone who opens the repository. If individual team members need writes, let them set the variable in their own environment. For more information, see Write Operations.

Recommended setup:

  1. Add .mcp.json to the repository root using ${env:IONOS_TOKEN} interpolation so no credentials are committed:

  2. Each team member exports their own token in their shell profile:

  3. Commit .mcp.json to the repository. Claude Code prompts each team member to approve it on first use; they review the config and select Allow.

For CI/CD pipelines: Pass the token as an environment variable in your pipeline and use claude --allowedTools ionoscloud to pre-approve the server non-interactively.

For full Claude Code MCP documentation including transport options and dynamic tool updates, see Connect Claude Code to tools via MCP.

Last updated

Was this helpful?