server4agent26.1 KB
View saved version →
---
name: server4agent
description: Build and host web pages, sites, apps, APIs, bots and scheduled jobs at a live URL on a persistent server that keeps them running after the conversation ends. Use when the user asks to put something online, publish or share a page, deploy to a live URL, host an app or API, keep a bot running, run a script on a schedule, or delegate building to an on-server agent. Works through the Server4Agent MCP tools, or over HTTP with an API key.
when_to_use: Triggers on requests like "make a page and put it online", "deploy this to a live URL", "host this app", "spin up a server", "create a project", "run this script remotely", "provision some compute", or "delegate this task to a server agent".
---
Use Server4Agent's MCP tools (the `server4agent` MCP server) to build and host
web pages, sites and apps at a live URL: provision servers, manage projects, and
write and run the code on the box yourself. An agent that runs there can also
build for you, when the user asks for it.
## Connection
In ChatGPT the Server4Agent tools come with the plugin. The person you are
working for signs in to their Server4Agent account once, in the browser, and
the tools reach only that account's servers and projects.
Secret values are never taken in the conversation. The owner adds them on the
dashboard's Secrets page at https://www.server4agent.com/secrets, and you bind
one to a server or project by its name with `attach_secret`. A project's link
is protected the same way: the owner sets that up on the project's page in the
dashboard.
## Tools
36 tools. `[read-only]` never writes; `[destructive]` may delete or
overwrite, so confirm with the user before calling one.
### Servers
A server is a sized compute box. Projects live inside it and share its resources.
- `create_server(task?, tier?, kind?, region?, project_sharing?)`
Provision a sized server box. Servers hold projects; each project gets a stable URL that serves once you make it public. One server holds several projects, so check list_servers for one with room before creating another. Pass `secrets` to set server-wide env vars (shared by every project on the server); values are write-only. Pass `kind: "browser"` for a box with a screen and a browser on it. Returns the server id. A new server takes about a minute to start: poll get_server until provisioning reads ready before writing files or starting apps.
- `list_servers()` `[read-only]`
List your servers with their tier, kind, status, project sharing, and current project count. kind is standard for a headless box or browser for one with a screen and a browser on it.
- `get_server(server_id)` `[read-only]`
Get a server's tier, kind, status, capacity, project count, and project sharing. kind is standard for a headless box or browser for one with a screen and a browser on it.
- `update_server(server_id, task?, region?, project_sharing?)` `[destructive]`
Update a server's nickname, region, or how much its projects may see of each other.
- `control_server(server_id, action)` `[destructive]`
Pause a server (stop), resume it (start), or reboot it (restart). A paused server stays down until it is started again: its projects are offline, it does not bill, and tools that reach it (prompt, exec, start_app, the file tools, start_build) answer that it is paused instead of waking it.
- `delete_server(server_id)` `[destructive]`
Tear down a server and every project on it.
- `get_usage()` `[read-only]`
Get the account's AI spend and budget: how much has been spent this billing period, the plan's included credits, any budget cap, and whether new tasks are blocked (with the reason). Call this before a long series of prompts to check remaining budget, since dispatch fails once a spend ceiling is reached. Only agent runs stop: write_file, exec, start_app and deploy keep working, so the code can still be written and run by hand.
### Projects
A project is a workspace plus an app inside a server, with its own slug and
Preview of the first 4,000 characters. Read full instructions →