Claude Code is Anthropic’s command-line coding assistant. It supports remote HTTP MCP servers through its CLI configuration. This guide covers adding the PlantDemand MCP server so Claude Code can query plant data while you work.

Before you start

  • An active PlantDemand account with at least one plant configured
  • A Server-Api-Key generated for your account (see SOP 4.1)
  • Claude Code installed and working with at least one MCP server already (or this is your first MCP setup — that is fine too)
  • Verify the curl examples in the quickstart work from your network before configuring the client

Configuration

Add the following configuration to Claude Code:

claude mcp add --transport http plantdemand https://plantdemand.com/mcp \
  --header "Server-Api-Key: ${PLANTDEMAND_SERVER_API_KEY}"

Step-by-step setup

  1. Set the PLANTDEMAND_SERVER_API_KEY environment variable in your shell profile (~/.zshrc, ~/.bashrc, or your Windows environment variables).
  2. Run the claude mcp add command shown above. Claude Code will register the PlantDemand MCP server in its configuration.
  3. Verify by running claude mcp list. You should see plantdemand in the list.
  4. Start a Claude Code session with claude. The PlantDemand tools will be available automatically.
  5. Ask Claude Code something like “list the plants I have access to in PlantDemand” to confirm the connection is working.

Verifying the connection

After connecting, ask Claude Code:

“List the plants I have access to in PlantDemand.”

If the assistant returns a list of plants, the connection is working. Try a follow-up:

“What is on the schedule for plant [your plant ID] tomorrow?”

Troubleshooting

  • Command not recognized: Make sure you have the latest version of Claude Code installed: npm install -g @anthropic-ai/claude-code or your equivalent install method.
  • Authentication errors: Confirm the environment variable is set in the same shell where you run claude. Run echo $PLANTDEMAND_SERVER_API_KEY to verify.
  • Claude Code does not call the tools: Add a short instruction in your prompt: “Use the PlantDemand MCP server to look up plant data.” Claude Code chooses tools based on the prompt.

Where to go next