Your First MCP
Create your first Model Context Protocol server using MCPHub. This guide imports the National Weather Service API to demonstrate the complete OpenAPI import workflow.
Prerequisites
- MCPHub running locally (Quick Install)
- Access to MCP Studio at http://localhost:3000 (if deployed using Docker) or your Render.com URL
Step 1: Access MCP Studio
-
Open your web browser
-
Navigate to:
http://localhost:3000 -
First Time Setup: If this is your first time accessing MCPHub Studio, you'll see a Welcome dialog that guides you through initial configuration:
- Backend URL: Should be auto-detected and preloaded. In case of "mcphub-all" image deployed locally in Docker, the backend URL needs to be
http://localhost:3000. Test the connection by clicking the Test button - Set up tenant ID (auto-generated UUID)
- Configure AI model settings (optional)
See: Initial Configuration: Welcome Workflow for detailed setup instructions.
- Backend URL: Should be auto-detected and preloaded. In case of "mcphub-all" image deployed locally in Docker, the backend URL needs to be
-
Verify: After setup, you'll see the MCPHub Studio homepage with available MCPs
Step 2: Import National Weather Service OpenAPI Specification
We'll import the National Weather Service API using the import wizard:
- Click the "Create New MCP" button
- Select "REST API"
- Select "Import from Specification"
- Select "JSON Format" tab (should be selected by default)
- Get the Weather API specification:
- Visit:
https://api.weather.gov/openapi.json - Copy the entire JSON content from your browser
- Visit:
- Paste the JSON content into the "Or Paste Specification Content" textarea
- Click "Configure" to preview the API name and information
- Review the auto-detected API information:
- MCP Name (e.g.,
weather-gov-api) - Description: "weather.gov API" (auto-extracted from OpenAPI spec)
- MCP Name (e.g.,
- Click "Preview" to preview the endpoints
- Review the imported endpoints (weather alerts, forecasts, observations, etc.)
- Click "Import" to complete the import
- Click "Save Configuration" to save your MCP configuration
Step 3: Deploy Your MCP
Now that your MCP configuration is created, you need to deploy it to the MCP Bridge:
- Click the "Action" button dropdown
- Select "Deploy" from the dropdown menu
- In the deployment dialog, click "Deploy"
- Wait for deployment confirmation (green checkmark or success message)
Step 4: Test Your Deployed MCP with Claude Desktop
Now let's test the deployed weather API configuration with Claude Desktop:
Get Your MCP Configuration URL
- Click the "Action" button dropdown
- Select "Copy URL" option
- Note the MCP URL format:
http://base_url/{tenant}/{mcp-name}/mcp- Example:
http://localhost:3000/system/weather-gov-api/mcp - The URL includes your tenant ID and MCP name
- Example:
- Get the API key (Base64-encoded credentials) as defined in the Quick Install section
- Use your username and password from the installation
- Example:
admin:admin123encodes toYWRtaW46YWRtaW4xMjM=
Download and Install Claude Desktop
- Download Claude Desktop from claude.ai/download
- Install the application on your computer
- Launch Claude Desktop
Configure MCP Server
- Open Claude Desktop settings
- Navigate to the "Developer" section
- Click "Edit Config"
- Add your MCP configuration to the
claude_desktop_config.jsonfile:
{
"mcpServers": {
"Weather-api": {
"command": "npx",
"args": [
"mcp-remote",
"http://localhost:3000/system/weather-gov-api/mcp",
"--header",
"Authorization: Basic YWRtaW46YWRtaW4xMjM="
]
}
}
}
Note: Replace
YWRtaW46YWRtaW4xMjM=with your Base64-encoded credentials (admin:your_password). You can generate this using:echo -n "admin:admin123" | base64
- Save the configuration file
- Restart Claude Desktop to load the MCP server
Test the Weather API
- Ask Claude a weather-related question, such as:
- "What are the current weather alerts for California?"
- "Get weather forecast information for New York City"
- "Are there any weather alerts in Texas?"
- Observe Claude using the weather MCP tools to retrieve real-time data
- Verify the MCP integration is working correctly