Connect Anthropic's Messages API to 2,500+ apps via Mushroom MCP
#
Overview
Mushroom is viaSocket's MCP server platform. Connect Anthropic's Messages API to your Mushroom MCP server to call your connected apps programmatically from anywhere.
#
Get an Anthropic API Key
First, make sure that you have a valid Anthropic API key.
To view or generate a new Anthropic API key, go to the Anthropic developer console API Keys page.
Export your API key as an environment variable:
bash
export ANTHROPIC_API_KEY="sk-..."#
MCP Server Information
Copy your MCP Endpoint URL directly from your Mushroom cluster dashboard and use it in the code example below.
⚠️
Caution: Treat your MCP Endpoint URL like a password! It can be used to run tools attached to this server and access your data.
#
Using Anthropic's Messages API
Anthropic's Messages API can be used to call Mushroom MCP from anywhere.
#
Code Example
curl https://api.anthropic.com/v1/messages \
-H "Content-Type: application/json" \
-H "X-API-Key: $ANTHROPIC_API_KEY" \
-H "anthropic-version: 2023-06-01" \
-H "anthropic-beta: mcp-client-2025-04-04" \
-d '{
"model": "claude-sonnet-4-20250514",
"max_tokens": 1000,
"messages": [{"role": "user", "content": "What tools do you have available?"}],
"mcp_servers": [
{
"type": "url",
"url": "https://mcp.viasocket.com/mcp/your-unique-id",
"name": "mushroom",
"authorization_token": "viasocket"
}
]
}'Was this helpful?