MCP Server
Let an AI assistant drive your account. 52 tools, one per API operation.
Public beta
The MCP server is open in beta. Tools and responses may still change, and every call acts on your real deployments. Give an assistant a scoped key, never a full-access one.
What it is
MCP (Model Context Protocol) is the open standard for giving an AI assistant tools. Point a compatible client (Claude Desktop, Cursor, an in-app agent) at the endpoint below, and it can list, inspect and control your deployments in natural language: "restart my bot", "why did it crash", "show the last logs". Every tool maps to a REST API operation and runs through the exact same permissions, scopes and rate limits.
Connect
The endpoint speaks JSON-RPC over HTTP and authenticates with your bhk_ API key as a Bearer token. Most clients connect through the mcp-remote bridge:
{
"mcpServers": {
"bot-hosting": {
"command": "npx",
"args": [
"-y",
"mcp-remote",
"https://bot-hosting.net/api/mcp",
"--header",
"Authorization: Bearer bhk_your_key"
]
}
}
} Or test it directly with curl (calls a tool the same way the AI would):
curl https://bot-hosting.net/api/mcp \
-H "Authorization: Bearer bhk_your_key" -H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"deployments_list","arguments":{}}}'Auth & scopes
initialize and tools/list are open for discovery; tools/call requires the key, and the key's scopes gate what actually runs. Give an assistant a key with only the scopes it needs, e.g. deployments:read + deployments:power for a support bot that can restart but never delete.
Deployments
Account
Templates
Tools
Deployments
List every deployment the caller can access.
Fetch a single deployment.
Rename a deployment or change its description.
Move a deployment to another of your projects.
Delete a deployment (instant; teardown runs in the background).
Create a deployment (blank, from a public GitHub repo, or a template).
Get the startup config: runtime, version, entry file, start command.
Change runtime / version / entry file / start command (queues a rebuild).
List available runtimes and database engines with their versions.
Get the linked GitHub source: repo, branch, auto-pull.
Toggle auto-pull: re-pull the linked repo on every restart.
Send a power signal (start / stop / restart / kill).
Read the last N lines of the console log.
Live resource usage: CPU, memory, disk, network and uptime.
Send a single command to the server console.
Change RAM / CPU / storage allocation (drawn from your plan pool).
Pull the latest code from the linked GitHub repo (restarts it if it was running).
List a directory inside the deployment volume.
Read the text content of a single file.
Create or overwrite a text file.
Rename or move a file within a directory.
Delete one or more files or folders.
Create a folder.
Decompress an archive in place.
Compress files into a new archive.
Duplicate a file (Wings appends a "copy" suffix).
Change a file mode (e.g. "0755").
Get a one-time signed URL to download a file.
List environment variables. Secret values are masked.
Create or update a user environment variable (applies on next restart).
Update an existing environment variable: rename it (newKey), change its value, or flip its secret flag. Applies on next restart.
Delete a user environment variable (applies on next restart).
List the backups of a deployment.
Start a manual backup of a deployment.
Fetch a single backup by id.
Delete a backup.
Restore a backup onto a deployment (overwrites its files).
List packages in the manifest (npm or pip).
Add or update a package in the manifest.
Remove a package from the manifest.
List the projects you own or collaborate on.
Create a project.
Delete a project and all its deployments (owner only).
Assign a subdomain (activate domains). Idempotent.
Set the subdomain alias (slug).
Remove the subdomain alias.
Attach a custom domain. Returns the DNS verification token.
Check the DNS for the attached custom domain.
Detach the custom domain.
Account
Your profile, credit balance and quota (pool vs used).
Templates
Browse the public template catalogue (any author).
Full details + public stats of a single template by slug.
Prefer raw HTTP?
The same operations are a plain REST API with curl, Python and Node examples.