SCALE API Helper MCP
Enables secure VM lifecycle management on SCALE HyperCore clusters, including snapshot, clone, export, and state changes, through a Bearer-authenticated FastAPI proxy and MCP tools.
README
SCALE API Helper + MCP
A secure, LLM-ready bridge between your local AI environment and the SCALE Computing HyperCore REST API. Exposes VM management operations as authenticated FastAPI routes and MCP tools — usable from OpenWebUI, Claude Desktop, or cURL.
Built to go beyond API exploration: this is a functional operator tool for taking real actions against a SCALE HyperCore cluster.
Tested against SCALE HyperCore v9.4.30.217736 & v9.6.19.223352
Features
- FastAPI proxy server with Bearer Auth securing all routes
- MCP tool integration for OpenWebUI and Claude Desktop
- Session-based auth against SCALE HyperCore (stored locally in
.pfile) - VM lifecycle management: snapshot, clone, export, state changes
- Swagger UI at
/docswith full OpenAPI schema - RAG-compatible schema querying for LLM-assisted API exploration
File Overview
| File | Purpose |
|---|---|
03_mcpserver_agent+auth.py |
Route definitions, Bearer auth, OpenAPI schema, MCP forwarding |
scale_tools.py |
All SCALE API logic: session lifecycle, VM operations, query forwarding |
models.py |
Pydantic models for use with Swagger UI |
config_alt.py |
Bearer token and cluster host configuration |
scale_api_full_schema.json |
Full HyperCore OpenAPI schema (used for RAG/exploration) |
api_schema.db |
SQLite schema store for LLM-aided endpoint discovery |
01_*.py / 02_*.py / 03_flaskapi.py / 03_llmRAG.py |
Setup and exploration scripts |
Requirements
- Python 3.10+
- MCP runtime via
uvx mcpo - Dependencies:
fastapi,httpx,pydantic,uvicorn - any OpenAI API Compat. Server — tested with
nvidia/NVIDIA-Nemotron-3-Nano-4B-FP8on vLLM (0.18.1)
Setup
1. Clone & Install
git clone https://github.com/Nels2/SCALE-API-Helper-MCP
cd SCALE-API-Helper-MCP
uv pip install -r requirements.txt
2. Configure
Edit config_alt.py:
MCP_BEARER_TOKEN = "your-secret-token"
SCALE_HOST = "your-cluster-ip"
3. Run
uvx mcpo --port 5075 -- uvicorn 03_mcpserver_agent+auth:app --host 0.0.0.0 --port 5075
Optionally, add --reload if you plan to make changes and dont wan't to kill the server.
Swagger UI: http://localhost:5075/docs
MCP Usage
OpenWebUI
uvx mcpo --port 5075 -- uv run fastapi_server.py
Add connection in OpenWebUI:
URL: http://<your-ip>:5075/openapi.json
Auth: Bearer <your-token>
Note: After adding new tools to the MCP server, restart the server process and reconnect in OpenWebUI — tool lists are cached at connection time.
Claude Desktop
Add to your claude_desktop_config.json:
{
"mcpServers": {
"scale-agent": {
"url": "http://<your-ip>:5075",
"headers": {
"Authorization": "Bearer <your-token>"
}
}
}
}
Available Tools
Session Management
| Tool | Description |
|---|---|
generate_session |
Authenticate against SCALE and store session |
get_session |
Retrieve current session info (validates 12hr window) |
kill_session |
Invalidate active session |
Read Operations
| Tool | Description |
|---|---|
ping_read |
Check connectivity and session validity |
cluster_read |
Retrieve cluster node information |
clusterSpec_read |
Retrieve cluster spec/configuration |
condition_read |
List all active conditions/alerts |
user_read |
List all users on the system |
iso_read |
List all ISOs |
drive_read |
List all physical drives |
virtualDisk_read |
List all virtual disks |
vmNetDevices_read |
List all virtual network devices |
vmSnapshots_read |
List all VM snapshots |
taskTagStatus_read |
List all task/status tags |
taskTagStatusFilter |
Get status for a specific task tag by ID |
VM Operations
| Tool | Description |
|---|---|
fetch_vm |
Search VMs by name or user (via NMAPX Dash) |
getVM_details |
Fetch full VM configuration by UUID |
getVM_sysStats |
Retrieve live CPU, memory, disk, and network stats |
changeVM_state |
Take action on a VM: START, SHUTDOWN, STOP, PAUSE, REBOOT, RESET, LIVEMIGRATE, NMI |
snapshotVM |
Take a named snapshot of a VM |
delete_snapshotVM |
Delete a snapshot by UUID |
cloneVM |
Clone a VM |
exportVM |
Export a VM to the configured SMB archive target |
Raw Access
| Tool | Description |
|---|---|
run_api |
Direct proxy call — any endpoint, method, and payload |
query_api |
Search the local schema DB for matching endpoints |
Architecture
OpenWebUI / Claude Desktop
│
▼
fastapi_server.py ←── Bearer Auth
│
▼
scale_tools.py ←── Session (.p file)
│
▼
SCALE HyperCore REST API
Notes
- This is a personal developer tool but it IS technically production-hardened since it is secured by Bearer Auth.
- The SCALE API uses session cookies, not per-request tokens; the
.pfile persists this between calls, it is only valid based on the SCALE Permissions, but the script sets a hard time of 12 hours to auto refresh token. run_apigives you a raw escape hatch for any endpoint not yet wrapped as a named tool... but your model has to be smart enough to handle embedded JSON within JSON.
License
MIT. Use and adapt freely.
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.