← Server4AgentCONTENT HISTORY

Update to Server4Agent

Snapshot Nov 25, 2026 · 00:19 UTC · version 1.0.7

Collection source: downloaded plugin package.

WHAT CHANGED

Instructions updated for server4agent

Full description — Now says: key.

Observed in instructions or declared skills. Runtime behavior has not been tested.

Save Server4Agent and check future changes in Following.

Up to 3 plugins free · no card required.

All fields and original values.

Full description

Before

Nov 24, 2026 · 01:48 UTC

key; a static page can be published without an account.

After

Nov 25, 2026 · 00:19 UTC

key.

Skill instructions

Before

Nov 24, 2026 · 01:48 UTC

key; a static page can be published without an account.

After

Nov 25, 2026 · 00:19 UTC

key.

Compare saved observations

Download comparison JSON

SKILL.md text changes

− removed · + added

--- before
+++ after
@@ -1,6 +1,6 @@
 ---
 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; a static page can be published without an account.
+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".
 ---
 
Full technical diff · 2 changed fields

changed /description

BEFORE
"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; a static page can be published without an account."
AFTER
"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."

changed /skill_md_contents

BEFORE
"---\nname: server4agent\ndescription: 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; a static page can be published without an account.\nwhen_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\".\n---\n\nUse Server4Agent's MCP tools (the `server4agent` MCP server) to build and host\nweb pages, sites and apps at a live URL: provision servers, manage projects, and\nwrite and run the code on the box yourself. An agent that runs there can also\nbuild for you, when the user asks for it.\n\n## Connection\n\nIn ChatGPT the Server4Agent tools come with the plugin. The person you are\nworking for signs in to their Server4Agent account once, in the browser, and\nthe tools reach only that account's servers and projects.\n\nSecret values are never taken in the conversation. The owner adds them on the\ndashboard's Secrets page at https://www.server4agent.com/secrets, and you bind\none to a server or project by its name with `attach_secret`. A project's link\nis protected the same way: the owner sets that up on the project's page in the\ndashboard.\n\n## Tools\n\n36 tools. `[read-only]` never writes; `[destructive]` may delete or\noverwrite, so confirm with the user before calling one.\n\n### Servers\n\nA server is a sized compute box. Projects live inside it and share its resources.\n\n- `create_server(task?, tier?, kind?, region?, project_sharing?)`\n  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.\n- `list_servers()` `[read-only]`\n  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.\n- `get_server(server_id)` `[read-only]`\n  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.\n- `update_server(server_id, task?, region?, project_sharing?)` `[destructive]`\n  Update a server's nickname, region, or how much its projects may see of each other.\n- `control_server(server_id, action)` `[destructive]`\n  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.\n- `delete_server(server_id)` `[destructive]`\n  Tear down a server and every project on it.\n- `get_usage()` `[read-only]`\n  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.\n\n### Projects\n\nA project is a workspace plus an app inside a server, with its own slug and URL. New projects are private: the URL only serves once you make it public.\n\n- `list_templates()` `[read-only]`\n  List the available project starters. Each template has an id, a human label, a one-line description, default visibility/lifecycle, and a source_kind. The first entries are import templates (source_kind \"git\" or \"archive\") that seed a project from your own code; the rest are ordinary starters (source_kind null). Pass the id as `template` to create_project to pre-pick sensible defaults for that use case.\n- `create_project(server_id, name?, description?, visibility?, access?, lifecycle?, template?, source?)`\n  Create a project on a server: the home for one web page, site, app, API or bot, with its own URL at <slug>.apps.server4agent.com. Projects default to private; set visibility to \"public\" to expose that URL. Use lifecycle=\"ephemeral\" for one-shot work that should be cleaned up when done (call cleanup_project after); default is \"persistent\" for long-lived monitors / dashboards / tools. Pass `template` (see list_templates) to apply a starter's defaults, or a `source` to seed the workspace from your own code (kind git/archive); name is derived from the repo/archive when omitted. Explicit fields override the template. Fails if the server is at its tier's project cap. Returns `listen_port`, the port inside the box that this project's URL is routed to: a project serves only while a process is listening there, so bind that rather than a port of your own choosing.\n- `list_projects(server_id?)` `[read-only]`\n  List projects. Optionally filter by server_id to see what's already on a particular server before creating a new one.\n- `get_project(project_id)` `[read-only]`\n  Get a single project: name, slug, description, public URL, listen port, run plan, timestamps. listen_port is the port inside the box that this project's URL is routed to, so an app here binds that rather than a port of its own choosing, and has to be running for the URL to answer. listen_port is null on a project created before the field existed, and on a box old enough to predate the in-pod proxy the published port (8080) is reached directly instead, so treat those two as the fallback when an app that binds listen_port still cannot be reached. url_status covers only whether the address and its certificate are ready, so it reads \"active\" for a public project with nothing listening; it is not a health check. run_plan is how bring-up installs and starts it, or null if no plan has been settled yet; a run_plan whose port is null means the project isn't a server.\n- `update_project(project_id, name?, description?, visibility?, access?, lifecycle?, run_plan?)` `[destructive]`\n  Rename a project, update its description, change visibility, link access or lifecycle, or correct its run plan. The slug + URL stay the same. Setting run_plan only records how the project should be brought up; call init_project when you want it rebuilt.\n- `init_project(project_id, proceed?)` `[destructive]`\n  Start or resume bring-up for a project seeded from a git/archive source: the on-server agent installs dependencies, starts the app, and confirms it responds. Returns a run_id to poll with get_run. Set proceed to true to continue past still-missing optional secrets. Not for a project whose files you wrote yourself: start that one with start_app.\n- `export_project(project_id, ttl_seconds?)`\n  Package a project into a portable bundle and return a time-limited download link. The bundle carries the project's source tree, its settings, its run plan, and the NAMES of the env vars it needs. Left out: dependency caches, git history, and any .env or credential file in the workspace, so the bundle never carries a secret value. Hand the file to import_project on this deployment or any other Server4Agent deployment to recreate the project there.\n- `import_project(server_id, bundle, name?)`\n  Recreate a project on a server from a bundle that export_project produced, here or on another Server4Agent deployment. Pass the bundle base64 encoded in `bundle`; large bundles are better uploaded from the dashboard, since the request body has a size limit. The new project is always private, gets its own slug and URL, and starts bringing itself up right away (the bundle only reaches the server as part of that run). Env vars the bundle names are bound only where this account already holds a value, and no .env file travels: the result lists what is still missing in `missing_env`, and the app will not run until the owner adds those on the dashboard's Secrets page and attach_secret binds them.\n- `cleanup_project(project_id)` `[destructive]`\n  Clean up an ephemeral project once its task is done. Deletes the workspace, retires the slug, and frees the project slot. Errors on persistent projects; use delete_project for those.\n- `delete_project(project_id)` `[destructive]`\n  Delete a project. The public URL stops working immediately.\n\n### Secrets\n\nEnv vars for servers and projects. The owner adds them, values and all, on the dashboard's Secrets page; these tools list them, bind them by name and delete them. No tool ever reads a value back.\n\n- `list_secrets()` `[read-only]`\n  List the account's secrets: keys, notes, and where each is bound (servers/projects). Never returns a value, or any part of one.\n- `attach_secret(key, server_id, project_id?)` `[destructive]`\n  Bind a secret to a scope so runs there see it as an env var. Server-wide when only server_id is given; project-scoped when project_id is also given. The secret has to be on the account already: the owner adds secrets, and enters their values, on the dashboard's Secrets page (https://www.server4agent.com/secrets), never in the conversation. list_secrets shows the keys that are there. A key has one value on the account, shared everywhere it is bound.\n- `delete_secret(secret_id)` `[destructive]`\n  Delete a secret and all of its bindings.\n\n### Agent runtime\n\nStart and keep your app running, drive the shell yourself, or, when the user asks for it, hand work to the agent running on the server.\n\n- `start_app(project_id, command, name?)` `[destructive]`\n  Start a project's app and keep it running: the step that puts a project online after its files are written. Runs `command` in the project folder as a background process with PORT set to the project's routed port (the app must listen on PORT), records it so it comes back after a restart, and waits up to about 10 seconds for the port to answer. Calling it again with the same name restarts it, which is how you pick up changed code. Returns whether the app is answering, its log tail, and the URL. A project's URL serves only while its visibility is public, so set that with update_project when the app should be reachable. For static files, put them under public/ and serve that folder, e.g. \"python3 -m http.server $PORT --bind 0.0.0.0 --directory public\". Never serve the project folder itself, which holds the project's secrets in .server4agent/env.\n- `prompt(server_id, prompt, project_id?, follow_up_of?)` `[destructive]`\n  Send a freeform prompt to the on-server agent. It plans, writes code, runs commands, and ships whatever the prompt asks for. It spends the account's AI budget, so use it when the user asks for the on-server agent or to continue a run it started; to build something yourself, write_file, exec, start_app and deploy cost nothing. Returns a run_id to poll with get_run. Each call starts a new conversation unless you pass follow_up_of: the run_id of an earlier run to continue, so the agent remembers what it did there. Use it to answer a run that is awaiting_input, or to ask for changes to what a run built. Pass project_id to work inside one project's workspace, or omit it to work across the whole server workspace (e.g. scaffolding a new project).\n- `exec(server_id, command, project_id?)` `[destructive]`\n  Run a shell command on the server and return its output. Pass project_id to run inside that project's workspace folder, with PORT set to the project's routed port; omit it to run at the server workspace root. For one-off work: installing dependencies, building, inspecting files. Runs as the workspace user, the same one the agent and the apps run as, so what it creates stays editable by both; prefix a command with sudo when it needs root. A project command also gets the project's secrets as env. The command's session ends with the call, so do not use it to start an app or any other long-running process: use start_app, which keeps it running, brings it back after a restart, and tells you whether it answered. Output comes back for about 20 seconds: a command that runs longer keeps going on the server, but its output does not return, and the server's other commands wait for it. Start long work (a big install, a long build) in the background with its output in a file, then read the file.\n- `get_run(server_id, run_id)` `[read-only]`\n  Get a run's status, its latest progress note, the agent's final response, and what it changed in the workspace (commit, branch, files). Poll this with the run_id returned by prompt or init_project.\n- `get_logs(server_id, project_id?, lines?)` `[read-only]`\n  Read the latest log tails from a server: one entry per log file that a project's processes have written (each long-running process appends to .server4agent/<name>.log in its project folder). Read live from the server at the moment you call. If the server does not answer in time (starting, restarting, or paused), you get the tails saved earlier with stale: true and a note saying how old they are. An app keeps the same log file across restarts. Pass project_id to get only that project's logs. Use this to debug a crashing app or check what a background process is doing.\n\n### File workspace\n\nRead and write the project's files directly when you do not need the agent.\n\n- `list_files(server_id, project_id?)` `[read-only]`\n  List paths in the server's workspace. Pass project_id to list only that project's folder (paths come back relative to the project); omit it to list the whole server workspace.\n- `read_file(server_id, path, project_id?, encoding?)` `[read-only]`\n  Read a file from the server's workspace. With project_id, path is resolved inside that project's folder; without it, path is relative to the server workspace root. Use encoding:\"base64\" for binary files (e.g. .xlsx, images); plain text mode will corrupt non-text bytes.\n- `write_file(server_id, path, content, project_id?, encoding?)` `[destructive]`\n  Write or overwrite a file in the server's workspace. With project_id, path is resolved inside that project's folder; without it, path is relative to the server workspace root. Use encoding:\"base64\" to write binary content (e.g. a generated .xlsx); plain text mode assumes UTF-8 and will corrupt binary bytes. One call carries up to 512 KB of content; write anything larger in pieces, or fetch it on the server with exec. Writing a file does not serve it: a project's URL is answered by a running app, so after writing the files call start_app (a changed server needs start_app again to pick the change up).\n- `delete_file(server_id, path, project_id?)` `[destructive]`\n  Delete a file from the server's workspace. With project_id, path is resolved inside that project's folder; without it, path is relative to the server workspace root.\n- `get_download_url(server_id, path, project_id?, ttl_seconds?)`\n  Mint a time-limited link to download one file from the server's workspace, e.g. after generating a report or converting a file, hand this URL back to the user instead of the raw content. With project_id, path is resolved inside that project's folder. The link needs no login and works for anyone who has it, so only mint it for files that are OK to share.\n\n### Build and deploy\n\nPut a running project online with deploy, or, when the user asks for one, start an agent run that builds from a goal.\n\n- `start_build(server_id, goal, project_id?)` `[destructive]`\n  Have the on-server agent build a web page, site, app or API from a plain-language goal. Use it only when the user asks for that agent: it counts against the AI budget like prompt, and you can write the code yourself with write_file, exec and start_app, then deploy. Starts an agent run that works through each stage in order: plan, scaffold, write the code, install, build and test, then start it on the project's port. Returns a build_id to poll with get_build, and the run_id of the run doing the work. Pass project_id to build inside that project's workspace folder, then deploy it to put the result online; omit project_id to build at the server workspace root.\n- `get_build(server_id, build_id)` `[read-only]`\n  Get a build's status. The steps move together: running while the run works, done when it finished, failed when it did not (status still reads completed, and error says why). url is the project's address once it is built and public. run_id is the run doing the work: get_run shows its live progress, and when run_status is awaiting_input, answer its question with prompt and follow_up_of set to that run_id.\n- `deploy(server_id, project_id?)`\n  Deploy a project to its live public URL at <slug>.apps.server4agent.com: the last step in putting a web page, site, app or API online. Checks that something in the project is listening on its `listen_port`, makes the project public, and checks its URL answers, then returns that URL with status live (or publishing, when it is public but has not answered yet). It builds and starts nothing: when nothing is listening it refuses and leaves the project as it was, so start the app first with start_app (after write_file, for code you write yourself), or have the on-server agent build and start it with start_build or prompt. Pass project_id; a server with exactly one project deploys that one without it.\n\n### Custom domains\n\nServe a public project at a domain the user owns, with HTTPS issued automatically. On paid plans. The user adds two DNS records; check_domain switches the domain on once both are found.\n\n- `add_domain(project_id, domain)`\n  Connect a custom domain the user owns to a project, so the app also answers at that address over HTTPS. Returns the two DNS records the user adds at their DNS provider: a CNAME that points the domain at the project's address, and a TXT record that proves they own it. Nothing is served on the domain until check_domain finds both. Custom domains are on paid plans; the allowance is counted across the account. The project still has to be public (deploy) for the domain to serve.\n- `check_domain(project_id, domain)`\n  Look up a custom domain's DNS records now and, when both are right, switch it on: the certificate is issued automatically and the domain starts serving within a few minutes. Returns the domain's status (pending, verified, active or cert_failed) and, while pending, what is still wrong with the records. DNS changes can take a while to spread, so a pending result is normal right after adding the records; call it again later.\n- `remove_domain(project_id, domain)` `[destructive]`\n  Disconnect a custom domain from a project. It stops serving and its certificate is removed; the project keeps its own address. The DNS records stay at the user's DNS provider until they delete them.\n\n## Common workflows\n\n**Build and deploy a project: you write the code**\nThis is the way to build anything, from one page to an API: you write the\ncode, and these tools put it on the server and online. Nothing here serves a\ndirectory. A project's URL is routed to one port inside the box, so a page or a\nserver is only live once a process is answering on that port.\n\n1. `list_servers` and reuse a running one with room for another project, or\n   `create_server` when there is none. Either gives you a `server_id`. A new\n   server takes about a minute to start: poll `get_server` until\n   `provisioning` reads `ready` before writing files.\n2. `create_project(server_id, name, visibility=\"public\")` returns `project_id`\n   and `listen_port`.\n3. `write_file(server_id, \"public/index.html\", \"<html>...\", project_id)`, and\n   the same for each other file. Static pages go under `public/`: the\n   project folder itself holds\n   `.server4agent/env`, the secrets bound to this project, and a file server\n   rooted at the project would publish them.\n4. `exec` installs dependencies (`npm install`,\n   `pip install -r requirements.txt`) and waits for them.\n5. `start_app(project_id, command)`. It runs the command in the background\n   with `PORT` set to the project's port, records it so the app comes back\n   after a restart, and waits for the port to answer.\n\n```\nstart_app  project_id, command: \"node server.js\"\nstart_app  project_id, command: \"python3 -m http.server $PORT --bind 0.0.0.0 --directory public\"\n```\n\n6. The result says whether the app is answering, with its log tail and the\n   URL. If it exited, the log says why: fix that and call `start_app` again.\n   Calling it again with the same `name` is also how a changed server picks\n   up new code.\n7. `deploy(server_id, project_id)`. It checks the app is listening, makes the\n   project public if it is not, and returns the URL once it answers.\n\nYour app has to listen on `$PORT`, not a port of its own.\n\n**Hand a build to the on-server agent, when the user asks for it**\nAn agent on the server can write and start the code instead. It spends the\naccount's AI budget, so use it when the user asks for that agent, not as the\nway to build.\n1. `create_project` as above.\n2. `prompt(server_id, \"Build and serve ...\", project_id)`, or `start_build`\n   with the goal. Poll `get_run` or `get_build` until it finishes.\n3. `deploy(server_id, project_id)` once the run finishes.\n\n**Follow up on a run**\nEvery `prompt` call starts a new conversation. To change what a run built, or\nto answer a run whose status is `awaiting_input`, pass its id:\n`prompt(server_id, \"Add a login page\", follow_up_of=run_id)`. The agent picks\nup that conversation in the same folder and project, so it knows what it did.\n\n**Ephemeral one-shot task**\n1. `create_project(server_id, name, lifecycle=\"ephemeral\")`.\n2. `exec` to do the work, or `prompt` when the user asks for the on-server agent.\n3. `cleanup_project(project_id)` frees the slot when done.\n\n**Check capacity before creating**\n`get_server(server_id)` reports projects used against the tier cap. At the cap,\nfree a slot or move the server up a tier before calling `create_project`,\nwhich otherwise fails.\n\n**Watch spend before a long run**\n`get_usage()` reports spend for the period, the budget cap, and whether new\ntasks are blocked. Worth a call before a series of `prompt` invocations.\n\n## Notes that save a round trip\n\n- **Some questions are for people, not tools.** The Business or Enterprise\n  plan, running in your own cloud, a security questionnaire, or an account\n  problem no tool can fix: write to hello@server4agent.com for the person you\n  are helping (the form at https://www.server4agent.com/contact ends with a\n  human check). A person answers within one business day.\n- Projects are **private by default**. A newly created project's `url` is\n  `null` until you set `visibility=\"public\"`. The slug and URL do not change\n  when you toggle visibility.\n- A project URL is answered by **a process, not a folder**. Bind the project's\n  `listen_port` (from `create_project` or `get_project`) rather than a port of\n  your own: an in-pod proxy owns the one published port and routes each public\n  project's hostname to its own `listen_port`. On a box old enough to predate\n  that proxy there is no demux and 8080 is published directly, so if the URL\n  will not answer on `listen_port`, that is the fallback worth trying.\n- **What the URL answers tells you which thing is wrong.** A redirect to a\n  \"Nothing found\" page means nothing is routed to that slug: the project is\n  private, or it does not exist (the two are deliberately indistinguishable).\n  A 200 reading \"server4agent: unknown project\" or \"server4agent: no project\n  routed to this server yet\" means the request reached the box but the in-pod\n  proxy has no route for it yet, so give reconciliation a moment. A 503\n  \"Temporarily unavailable\" means the routing is right and nothing is\n  listening on `listen_port`, which is the one your own app causes. A sign-in\n  page means the project's `access` is `team`, so it is serving fine and only\n  the account's members get in (an allowlist can narrow it further still). A\n  prompt for a passcode means the owner protected the link on the project's\n  page in the dashboard: also serving fine, for the people the owner gave it\n  to. It is set and changed there, never in the conversation.\n- A process started through `exec` **dies with the call**. Start anything\n  long-running with `start_app`, which also records it in the project's\n  `.server4agent/start.sh` so a restart, a pause and a resume bring it back.\n  Other lines in that file are left alone. If you edit it by hand, keep it to\n  plain, self-contained commands, one per line: boot and resume do not replay\n  it the same way, so a line that leans on a `cd` or an `export` from an\n  earlier line works in one and not the other.\n- `deploy` **publishes, it does not build**. It refuses when nothing is\n  listening on the project's port, so start the app first (`start_app`, or\n  `prompt`). On success it returns the project's URL with status `live`,\n  or `publishing` when the URL has not answered yet: call it again shortly.\n- `create_project` **fails at the tier cap**: small holds 3 projects, medium 10,\n  large is unlimited. Moving a server down a tier is refused when the smaller\n  cap would not fit the projects already there.\n- `prompt` and `start_build` are **asynchronous**. They return an id, and you\n  poll `get_run` or `get_build` for progress.\n- Secret **values are write-only**. `list_secrets` returns keys, notes, and\n  bindings, never a value.\n- **Email needs no provider key.** An app that should email the people on the\n  account (an alert, a report) can POST to the URL in its `S4A_EMAIL_URL` env\n  var, sending `S4A_EMAIL_TOKEN` as a bearer token, with a JSON body of\n  `subject`, `text` and, optionally, `to`. A project's `exec` commands and its\n  `start_app` apps get both variables, and `start_app` keeps them in\n  `.server4agent/env.sh` for a cron job to source. It reaches only the\n  account's own people at confirmed addresses (the owner when `to` is left\n  out), so there is nothing to ask the user for. Mail to anyone else needs\n  their own provider, which the owner sets up on the dashboard's Secrets page.\n- Argument details beyond the signatures above are in each tool's own JSON\n  schema, which your MCP host already has once connected.\n"
AFTER
"---\nname: server4agent\ndescription: 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.\nwhen_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\".\n---\n\nUse Server4Agent's MCP tools (the `server4agent` MCP server) to build and host\nweb pages, sites and apps at a live URL: provision servers, manage projects, and\nwrite and run the code on the box yourself. An agent that runs there can also\nbuild for you, when the user asks for it.\n\n## Connection\n\nIn ChatGPT the Server4Agent tools come with the plugin. The person you are\nworking for signs in to their Server4Agent account once, in the browser, and\nthe tools reach only that account's servers and projects.\n\nSecret values are never taken in the conversation. The owner adds them on the\ndashboard's Secrets page at https://www.server4agent.com/secrets, and you bind\none to a server or project by its name with `attach_secret`. A project's link\nis protected the same way: the owner sets that up on the project's page in the\ndashboard.\n\n## Tools\n\n36 tools. `[read-only]` never writes; `[destructive]` may delete or\noverwrite, so confirm with the user before calling one.\n\n### Servers\n\nA server is a sized compute box. Projects live inside it and share its resources.\n\n- `create_server(task?, tier?, kind?, region?, project_sharing?)`\n  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.\n- `list_servers()` `[read-only]`\n  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.\n- `get_server(server_id)` `[read-only]`\n  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.\n- `update_server(server_id, task?, region?, project_sharing?)` `[destructive]`\n  Update a server's nickname, region, or how much its projects may see of each other.\n- `control_server(server_id, action)` `[destructive]`\n  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.\n- `delete_server(server_id)` `[destructive]`\n  Tear down a server and every project on it.\n- `get_usage()` `[read-only]`\n  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.\n\n### Projects\n\nA project is a workspace plus an app inside a server, with its own slug and URL. New projects are private: the URL only serves once you make it public.\n\n- `list_templates()` `[read-only]`\n  List the available project starters. Each template has an id, a human label, a one-line description, default visibility/lifecycle, and a source_kind. The first entries are import templates (source_kind \"git\" or \"archive\") that seed a project from your own code; the rest are ordinary starters (source_kind null). Pass the id as `template` to create_project to pre-pick sensible defaults for that use case.\n- `create_project(server_id, name?, description?, visibility?, access?, lifecycle?, template?, source?)`\n  Create a project on a server: the home for one web page, site, app, API or bot, with its own URL at <slug>.apps.server4agent.com. Projects default to private; set visibility to \"public\" to expose that URL. Use lifecycle=\"ephemeral\" for one-shot work that should be cleaned up when done (call cleanup_project after); default is \"persistent\" for long-lived monitors / dashboards / tools. Pass `template` (see list_templates) to apply a starter's defaults, or a `source` to seed the workspace from your own code (kind git/archive); name is derived from the repo/archive when omitted. Explicit fields override the template. Fails if the server is at its tier's project cap. Returns `listen_port`, the port inside the box that this project's URL is routed to: a project serves only while a process is listening there, so bind that rather than a port of your own choosing.\n- `list_projects(server_id?)` `[read-only]`\n  List projects. Optionally filter by server_id to see what's already on a particular server before creating a new one.\n- `get_project(project_id)` `[read-only]`\n  Get a single project: name, slug, description, public URL, listen port, run plan, timestamps. listen_port is the port inside the box that this project's URL is routed to, so an app here binds that rather than a port of its own choosing, and has to be running for the URL to answer. listen_port is null on a project created before the field existed, and on a box old enough to predate the in-pod proxy the published port (8080) is reached directly instead, so treat those two as the fallback when an app that binds listen_port still cannot be reached. url_status covers only whether the address and its certificate are ready, so it reads \"active\" for a public project with nothing listening; it is not a health check. run_plan is how bring-up installs and starts it, or null if no plan has been settled yet; a run_plan whose port is null means the project isn't a server.\n- `update_project(project_id, name?, description?, visibility?, access?, lifecycle?, run_plan?)` `[destructive]`\n  Rename a project, update its description, change visibility, link access or lifecycle, or correct its run plan. The slug + URL stay the same. Setting run_plan only records how the project should be brought up; call init_project when you want it rebuilt.\n- `init_project(project_id, proceed?)` `[destructive]`\n  Start or resume bring-up for a project seeded from a git/archive source: the on-server agent installs dependencies, starts the app, and confirms it responds. Returns a run_id to poll with get_run. Set proceed to true to continue past still-missing optional secrets. Not for a project whose files you wrote yourself: start that one with start_app.\n- `export_project(project_id, ttl_seconds?)`\n  Package a project into a portable bundle and return a time-limited download link. The bundle carries the project's source tree, its settings, its run plan, and the NAMES of the env vars it needs. Left out: dependency caches, git history, and any .env or credential file in the workspace, so the bundle never carries a secret value. Hand the file to import_project on this deployment or any other Server4Agent deployment to recreate the project there.\n- `import_project(server_id, bundle, name?)`\n  Recreate a project on a server from a bundle that export_project produced, here or on another Server4Agent deployment. Pass the bundle base64 encoded in `bundle`; large bundles are better uploaded from the dashboard, since the request body has a size limit. The new project is always private, gets its own slug and URL, and starts bringing itself up right away (the bundle only reaches the server as part of that run). Env vars the bundle names are bound only where this account already holds a value, and no .env file travels: the result lists what is still missing in `missing_env`, and the app will not run until the owner adds those on the dashboard's Secrets page and attach_secret binds them.\n- `cleanup_project(project_id)` `[destructive]`\n  Clean up an ephemeral project once its task is done. Deletes the workspace, retires the slug, and frees the project slot. Errors on persistent projects; use delete_project for those.\n- `delete_project(project_id)` `[destructive]`\n  Delete a project. The public URL stops working immediately.\n\n### Secrets\n\nEnv vars for servers and projects. The owner adds them, values and all, on the dashboard's Secrets page; these tools list them, bind them by name and delete them. No tool ever reads a value back.\n\n- `list_secrets()` `[read-only]`\n  List the account's secrets: keys, notes, and where each is bound (servers/projects). Never returns a value, or any part of one.\n- `attach_secret(key, server_id, project_id?)` `[destructive]`\n  Bind a secret to a scope so runs there see it as an env var. Server-wide when only server_id is given; project-scoped when project_id is also given. The secret has to be on the account already: the owner adds secrets, and enters their values, on the dashboard's Secrets page (https://www.server4agent.com/secrets), never in the conversation. list_secrets shows the keys that are there. A key has one value on the account, shared everywhere it is bound.\n- `delete_secret(secret_id)` `[destructive]`\n  Delete a secret and all of its bindings.\n\n### Agent runtime\n\nStart and keep your app running, drive the shell yourself, or, when the user asks for it, hand work to the agent running on the server.\n\n- `start_app(project_id, command, name?)` `[destructive]`\n  Start a project's app and keep it running: the step that puts a project online after its files are written. Runs `command` in the project folder as a background process with PORT set to the project's routed port (the app must listen on PORT), records it so it comes back after a restart, and waits up to about 10 seconds for the port to answer. Calling it again with the same name restarts it, which is how you pick up changed code. Returns whether the app is answering, its log tail, and the URL. A project's URL serves only while its visibility is public, so set that with update_project when the app should be reachable. For static files, put them under public/ and serve that folder, e.g. \"python3 -m http.server $PORT --bind 0.0.0.0 --directory public\". Never serve the project folder itself, which holds the project's secrets in .server4agent/env.\n- `prompt(server_id, prompt, project_id?, follow_up_of?)` `[destructive]`\n  Send a freeform prompt to the on-server agent. It plans, writes code, runs commands, and ships whatever the prompt asks for. It spends the account's AI budget, so use it when the user asks for the on-server agent or to continue a run it started; to build something yourself, write_file, exec, start_app and deploy cost nothing. Returns a run_id to poll with get_run. Each call starts a new conversation unless you pass follow_up_of: the run_id of an earlier run to continue, so the agent remembers what it did there. Use it to answer a run that is awaiting_input, or to ask for changes to what a run built. Pass project_id to work inside one project's workspace, or omit it to work across the whole server workspace (e.g. scaffolding a new project).\n- `exec(server_id, command, project_id?)` `[destructive]`\n  Run a shell command on the server and return its output. Pass project_id to run inside that project's workspace folder, with PORT set to the project's routed port; omit it to run at the server workspace root. For one-off work: installing dependencies, building, inspecting files. Runs as the workspace user, the same one the agent and the apps run as, so what it creates stays editable by both; prefix a command with sudo when it needs root. A project command also gets the project's secrets as env. The command's session ends with the call, so do not use it to start an app or any other long-running process: use start_app, which keeps it running, brings it back after a restart, and tells you whether it answered. Output comes back for about 20 seconds: a command that runs longer keeps going on the server, but its output does not return, and the server's other commands wait for it. Start long work (a big install, a long build) in the background with its output in a file, then read the file.\n- `get_run(server_id, run_id)` `[read-only]`\n  Get a run's status, its latest progress note, the agent's final response, and what it changed in the workspace (commit, branch, files). Poll this with the run_id returned by prompt or init_project.\n- `get_logs(server_id, project_id?, lines?)` `[read-only]`\n  Read the latest log tails from a server: one entry per log file that a project's processes have written (each long-running process appends to .server4agent/<name>.log in its project folder). Read live from the server at the moment you call. If the server does not answer in time (starting, restarting, or paused), you get the tails saved earlier with stale: true and a note saying how old they are. An app keeps the same log file across restarts. Pass project_id to get only that project's logs. Use this to debug a crashing app or check what a background process is doing.\n\n### File workspace\n\nRead and write the project's files directly when you do not need the agent.\n\n- `list_files(server_id, project_id?)` `[read-only]`\n  List paths in the server's workspace. Pass project_id to list only that project's folder (paths come back relative to the project); omit it to list the whole server workspace.\n- `read_file(server_id, path, project_id?, encoding?)` `[read-only]`\n  Read a file from the server's workspace. With project_id, path is resolved inside that project's folder; without it, path is relative to the server workspace root. Use encoding:\"base64\" for binary files (e.g. .xlsx, images); plain text mode will corrupt non-text bytes.\n- `write_file(server_id, path, content, project_id?, encoding?)` `[destructive]`\n  Write or overwrite a file in the server's workspace. With project_id, path is resolved inside that project's folder; without it, path is relative to the server workspace root. Use encoding:\"base64\" to write binary content (e.g. a generated .xlsx); plain text mode assumes UTF-8 and will corrupt binary bytes. One call carries up to 512 KB of content; write anything larger in pieces, or fetch it on the server with exec. Writing a file does not serve it: a project's URL is answered by a running app, so after writing the files call start_app (a changed server needs start_app again to pick the change up).\n- `delete_file(server_id, path, project_id?)` `[destructive]`\n  Delete a file from the server's workspace. With project_id, path is resolved inside that project's folder; without it, path is relative to the server workspace root.\n- `get_download_url(server_id, path, project_id?, ttl_seconds?)`\n  Mint a time-limited link to download one file from the server's workspace, e.g. after generating a report or converting a file, hand this URL back to the user instead of the raw content. With project_id, path is resolved inside that project's folder. The link needs no login and works for anyone who has it, so only mint it for files that are OK to share.\n\n### Build and deploy\n\nPut a running project online with deploy, or, when the user asks for one, start an agent run that builds from a goal.\n\n- `start_build(server_id, goal, project_id?)` `[destructive]`\n  Have the on-server agent build a web page, site, app or API from a plain-language goal. Use it only when the user asks for that agent: it counts against the AI budget like prompt, and you can write the code yourself with write_file, exec and start_app, then deploy. Starts an agent run that works through each stage in order: plan, scaffold, write the code, install, build and test, then start it on the project's port. Returns a build_id to poll with get_build, and the run_id of the run doing the work. Pass project_id to build inside that project's workspace folder, then deploy it to put the result online; omit project_id to build at the server workspace root.\n- `get_build(server_id, build_id)` `[read-only]`\n  Get a build's status. The steps move together: running while the run works, done when it finished, failed when it did not (status still reads completed, and error says why). url is the project's address once it is built and public. run_id is the run doing the work: get_run shows its live progress, and when run_status is awaiting_input, answer its question with prompt and follow_up_of set to that run_id.\n- `deploy(server_id, project_id?)`\n  Deploy a project to its live public URL at <slug>.apps.server4agent.com: the last step in putting a web page, site, app or API online. Checks that something in the project is listening on its `listen_port`, makes the project public, and checks its URL answers, then returns that URL with status live (or publishing, when it is public but has not answered yet). It builds and starts nothing: when nothing is listening it refuses and leaves the project as it was, so start the app first with start_app (after write_file, for code you write yourself), or have the on-server agent build and start it with start_build or prompt. Pass project_id; a server with exactly one project deploys that one without it.\n\n### Custom domains\n\nServe a public project at a domain the user owns, with HTTPS issued automatically. On paid plans. The user adds two DNS records; check_domain switches the domain on once both are found.\n\n- `add_domain(project_id, domain)`\n  Connect a custom domain the user owns to a project, so the app also answers at that address over HTTPS. Returns the two DNS records the user adds at their DNS provider: a CNAME that points the domain at the project's address, and a TXT record that proves they own it. Nothing is served on the domain until check_domain finds both. Custom domains are on paid plans; the allowance is counted across the account. The project still has to be public (deploy) for the domain to serve.\n- `check_domain(project_id, domain)`\n  Look up a custom domain's DNS records now and, when both are right, switch it on: the certificate is issued automatically and the domain starts serving within a few minutes. Returns the domain's status (pending, verified, active or cert_failed) and, while pending, what is still wrong with the records. DNS changes can take a while to spread, so a pending result is normal right after adding the records; call it again later.\n- `remove_domain(project_id, domain)` `[destructive]`\n  Disconnect a custom domain from a project. It stops serving and its certificate is removed; the project keeps its own address. The DNS records stay at the user's DNS provider until they delete them.\n\n## Common workflows\n\n**Build and deploy a project: you write the code**\nThis is the way to build anything, from one page to an API: you write the\ncode, and these tools put it on the server and online. Nothing here serves a\ndirectory. A project's URL is routed to one port inside the box, so a page or a\nserver is only live once a process is answering on that port.\n\n1. `list_servers` and reuse a running one with room for another project, or\n   `create_server` when there is none. Either gives you a `server_id`. A new\n   server takes about a minute to start: poll `get_server` until\n   `provisioning` reads `ready` before writing files.\n2. `create_project(server_id, name, visibility=\"public\")` returns `project_id`\n   and `listen_port`.\n3. `write_file(server_id, \"public/index.html\", \"<html>...\", project_id)`, and\n   the same for each other file. Static pages go under `public/`: the\n   project folder itself holds\n   `.server4agent/env`, the secrets bound to this project, and a file server\n   rooted at the project would publish them.\n4. `exec` installs dependencies (`npm install`,\n   `pip install -r requirements.txt`) and waits for them.\n5. `start_app(project_id, command)`. It runs the command in the background\n   with `PORT` set to the project's port, records it so the app comes back\n   after a restart, and waits for the port to answer.\n\n```\nstart_app  project_id, command: \"node server.js\"\nstart_app  project_id, command: \"python3 -m http.server $PORT --bind 0.0.0.0 --directory public\"\n```\n\n6. The result says whether the app is answering, with its log tail and the\n   URL. If it exited, the log says why: fix that and call `start_app` again.\n   Calling it again with the same `name` is also how a changed server picks\n   up new code.\n7. `deploy(server_id, project_id)`. It checks the app is listening, makes the\n   project public if it is not, and returns the URL once it answers.\n\nYour app has to listen on `$PORT`, not a port of its own.\n\n**Hand a build to the on-server agent, when the user asks for it**\nAn agent on the server can write and start the code instead. It spends the\naccount's AI budget, so use it when the user asks for that agent, not as the\nway to build.\n1. `create_project` as above.\n2. `prompt(server_id, \"Build and serve ...\", project_id)`, or `start_build`\n   with the goal. Poll `get_run` or `get_build` until it finishes.\n3. `deploy(server_id, project_id)` once the run finishes.\n\n**Follow up on a run**\nEvery `prompt` call starts a new conversation. To change what a run built, or\nto answer a run whose status is `awaiting_input`, pass its id:\n`prompt(server_id, \"Add a login page\", follow_up_of=run_id)`. The agent picks\nup that conversation in the same folder and project, so it knows what it did.\n\n**Ephemeral one-shot task**\n1. `create_project(server_id, name, lifecycle=\"ephemeral\")`.\n2. `exec` to do the work, or `prompt` when the user asks for the on-server agent.\n3. `cleanup_project(project_id)` frees the slot when done.\n\n**Check capacity before creating**\n`get_server(server_id)` reports projects used against the tier cap. At the cap,\nfree a slot or move the server up a tier before calling `create_project`,\nwhich otherwise fails.\n\n**Watch spend before a long run**\n`get_usage()` reports spend for the period, the budget cap, and whether new\ntasks are blocked. Worth a call before a series of `prompt` invocations.\n\n## Notes that save a round trip\n\n- **Some questions are for people, not tools.** The Business or Enterprise\n  plan, running in your own cloud, a security questionnaire, or an account\n  problem no tool can fix: write to hello@server4agent.com for the person you\n  are helping (the form at https://www.server4agent.com/contact ends with a\n  human check). A person answers within one business day.\n- Projects are **private by default**. A newly created project's `url` is\n  `null` until you set `visibility=\"public\"`. The slug and URL do not change\n  when you toggle visibility.\n- A project URL is answered by **a process, not a folder**. Bind the project's\n  `listen_port` (from `create_project` or `get_project`) rather than a port of\n  your own: an in-pod proxy owns the one published port and routes each public\n  project's hostname to its own `listen_port`. On a box old enough to predate\n  that proxy there is no demux and 8080 is published directly, so if the URL\n  will not answer on `listen_port`, that is the fallback worth trying.\n- **What the URL answers tells you which thing is wrong.** A redirect to a\n  \"Nothing found\" page means nothing is routed to that slug: the project is\n  private, or it does not exist (the two are deliberately indistinguishable).\n  A 200 reading \"server4agent: unknown project\" or \"server4agent: no project\n  routed to this server yet\" means the request reached the box but the in-pod\n  proxy has no route for it yet, so give reconciliation a moment. A 503\n  \"Temporarily unavailable\" means the routing is right and nothing is\n  listening on `listen_port`, which is the one your own app causes. A sign-in\n  page means the project's `access` is `team`, so it is serving fine and only\n  the account's members get in (an allowlist can narrow it further still). A\n  prompt for a passcode means the owner protected the link on the project's\n  page in the dashboard: also serving fine, for the people the owner gave it\n  to. It is set and changed there, never in the conversation.\n- A process started through `exec` **dies with the call**. Start anything\n  long-running with `start_app`, which also records it in the project's\n  `.server4agent/start.sh` so a restart, a pause and a resume bring it back.\n  Other lines in that file are left alone. If you edit it by hand, keep it to\n  plain, self-contained commands, one per line: boot and resume do not replay\n  it the same way, so a line that leans on a `cd` or an `export` from an\n  earlier line works in one and not the other.\n- `deploy` **publishes, it does not build**. It refuses when nothing is\n  listening on the project's port, so start the app first (`start_app`, or\n  `prompt`). On success it returns the project's URL with status `live`,\n  or `publishing` when the URL has not answered yet: call it again shortly.\n- `create_project` **fails at the tier cap**: small holds 3 projects, medium 10,\n  large is unlimited. Moving a server down a tier is refused when the smaller\n  cap would not fit the projects already there.\n- `prompt` and `start_build` are **asynchronous**. They return an id, and you\n  poll `get_run` or `get_build` for progress.\n- Secret **values are write-only**. `list_secrets` returns keys, notes, and\n  bindings, never a value.\n- **Email needs no provider key.** An app that should email the people on the\n  account (an alert, a report) can POST to the URL in its `S4A_EMAIL_URL` env\n  var, sending `S4A_EMAIL_TOKEN` as a bearer token, with a JSON body of\n  `subject`, `text` and, optionally, `to`. A project's `exec` commands and its\n  `start_app` apps get both variables, and `start_app` keeps them in\n  `.server4agent/env.sh` for a cron job to source. It reaches only the\n  account's own people at confirmed addresses (the owner when `to` is left\n  out), so there is nothing to ask the user for. Mail to anyone else needs\n  their own provider, which the owner sets up on the dashboard's Secrets page.\n- Argument details beyond the signatures above are in each tool's own JSON\n  schema, which your MCP host already has once connected.\n"
Full snapshot data
{
  "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.",
  "included_files": [],
  "name": "server4agent",
  "skill_md_contents": "---\nname: server4agent\ndescription: 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.\nwhen_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\".\n---\n\nUse Server4Agent's MCP tools (the `server4agent` MCP server) to build and host\nweb pages, sites and apps at a live URL: provision servers, manage projects, and\nwrite and run the code on the box yourself. An agent that runs there can also\nbuild for you, when the user asks for it.\n\n## Connection\n\nIn ChatGPT the Server4Agent tools come with the plugin. The person you are\nworking for signs in to their Server4Agent account once, in the browser, and\nthe tools reach only that account's servers and projects.\n\nSecret values are never taken in the conversation. The owner adds them on the\ndashboard's Secrets page at https://www.server4agent.com/secrets, and you bind\none to a server or project by its name with `attach_secret`. A project's link\nis protected the same way: the owner sets that up on the project's page in the\ndashboard.\n\n## Tools\n\n36 tools. `[read-only]` never writes; `[destructive]` may delete or\noverwrite, so confirm with the user before calling one.\n\n### Servers\n\nA server is a sized compute box. Projects live inside it and share its resources.\n\n- `create_server(task?, tier?, kind?, region?, project_sharing?)`\n  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.\n- `list_servers()` `[read-only]`\n  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.\n- `get_server(server_id)` `[read-only]`\n  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.\n- `update_server(server_id, task?, region?, project_sharing?)` `[destructive]`\n  Update a server's nickname, region, or how much its projects may see of each other.\n- `control_server(server_id, action)` `[destructive]`\n  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.\n- `delete_server(server_id)` `[destructive]`\n  Tear down a server and every project on it.\n- `get_usage()` `[read-only]`\n  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.\n\n### Projects\n\nA project is a workspace plus an app inside a server, with its own slug and URL. New projects are private: the URL only serves once you make it public.\n\n- `list_templates()` `[read-only]`\n  List the available project starters. Each template has an id, a human label, a one-line description, default visibility/lifecycle, and a source_kind. The first entries are import templates (source_kind \"git\" or \"archive\") that seed a project from your own code; the rest are ordinary starters (source_kind null). Pass the id as `template` to create_project to pre-pick sensible defaults for that use case.\n- `create_project(server_id, name?, description?, visibility?, access?, lifecycle?, template?, source?)`\n  Create a project on a server: the home for one web page, site, app, API or bot, with its own URL at <slug>.apps.server4agent.com. Projects default to private; set visibility to \"public\" to expose that URL. Use lifecycle=\"ephemeral\" for one-shot work that should be cleaned up when done (call cleanup_project after); default is \"persistent\" for long-lived monitors / dashboards / tools. Pass `template` (see list_templates) to apply a starter's defaults, or a `source` to seed the workspace from your own code (kind git/archive); name is derived from the repo/archive when omitted. Explicit fields override the template. Fails if the server is at its tier's project cap. Returns `listen_port`, the port inside the box that this project's URL is routed to: a project serves only while a process is listening there, so bind that rather than a port of your own choosing.\n- `list_projects(server_id?)` `[read-only]`\n  List projects. Optionally filter by server_id to see what's already on a particular server before creating a new one.\n- `get_project(project_id)` `[read-only]`\n  Get a single project: name, slug, description, public URL, listen port, run plan, timestamps. listen_port is the port inside the box that this project's URL is routed to, so an app here binds that rather than a port of its own choosing, and has to be running for the URL to answer. listen_port is null on a project created before the field existed, and on a box old enough to predate the in-pod proxy the published port (8080) is reached directly instead, so treat those two as the fallback when an app that binds listen_port still cannot be reached. url_status covers only whether the address and its certificate are ready, so it reads \"active\" for a public project with nothing listening; it is not a health check. run_plan is how bring-up installs and starts it, or null if no plan has been settled yet; a run_plan whose port is null means the project isn't a server.\n- `update_project(project_id, name?, description?, visibility?, access?, lifecycle?, run_plan?)` `[destructive]`\n  Rename a project, update its description, change visibility, link access or lifecycle, or correct its run plan. The slug + URL stay the same. Setting run_plan only records how the project should be brought up; call init_project when you want it rebuilt.\n- `init_project(project_id, proceed?)` `[destructive]`\n  Start or resume bring-up for a project seeded from a git/archive source: the on-server agent installs dependencies, starts the app, and confirms it responds. Returns a run_id to poll with get_run. Set proceed to true to continue past still-missing optional secrets. Not for a project whose files you wrote yourself: start that one with start_app.\n- `export_project(project_id, ttl_seconds?)`\n  Package a project into a portable bundle and return a time-limited download link. The bundle carries the project's source tree, its settings, its run plan, and the NAMES of the env vars it needs. Left out: dependency caches, git history, and any .env or credential file in the workspace, so the bundle never carries a secret value. Hand the file to import_project on this deployment or any other Server4Agent deployment to recreate the project there.\n- `import_project(server_id, bundle, name?)`\n  Recreate a project on a server from a bundle that export_project produced, here or on another Server4Agent deployment. Pass the bundle base64 encoded in `bundle`; large bundles are better uploaded from the dashboard, since the request body has a size limit. The new project is always private, gets its own slug and URL, and starts bringing itself up right away (the bundle only reaches the server as part of that run). Env vars the bundle names are bound only where this account already holds a value, and no .env file travels: the result lists what is still missing in `missing_env`, and the app will not run until the owner adds those on the dashboard's Secrets page and attach_secret binds them.\n- `cleanup_project(project_id)` `[destructive]`\n  Clean up an ephemeral project once its task is done. Deletes the workspace, retires the slug, and frees the project slot. Errors on persistent projects; use delete_project for those.\n- `delete_project(project_id)` `[destructive]`\n  Delete a project. The public URL stops working immediately.\n\n### Secrets\n\nEnv vars for servers and projects. The owner adds them, values and all, on the dashboard's Secrets page; these tools list them, bind them by name and delete them. No tool ever reads a value back.\n\n- `list_secrets()` `[read-only]`\n  List the account's secrets: keys, notes, and where each is bound (servers/projects). Never returns a value, or any part of one.\n- `attach_secret(key, server_id, project_id?)` `[destructive]`\n  Bind a secret to a scope so runs there see it as an env var. Server-wide when only server_id is given; project-scoped when project_id is also given. The secret has to be on the account already: the owner adds secrets, and enters their values, on the dashboard's Secrets page (https://www.server4agent.com/secrets), never in the conversation. list_secrets shows the keys that are there. A key has one value on the account, shared everywhere it is bound.\n- `delete_secret(secret_id)` `[destructive]`\n  Delete a secret and all of its bindings.\n\n### Agent runtime\n\nStart and keep your app running, drive the shell yourself, or, when the user asks for it, hand work to the agent running on the server.\n\n- `start_app(project_id, command, name?)` `[destructive]`\n  Start a project's app and keep it running: the step that puts a project online after its files are written. Runs `command` in the project folder as a background process with PORT set to the project's routed port (the app must listen on PORT), records it so it comes back after a restart, and waits up to about 10 seconds for the port to answer. Calling it again with the same name restarts it, which is how you pick up changed code. Returns whether the app is answering, its log tail, and the URL. A project's URL serves only while its visibility is public, so set that with update_project when the app should be reachable. For static files, put them under public/ and serve that folder, e.g. \"python3 -m http.server $PORT --bind 0.0.0.0 --directory public\". Never serve the project folder itself, which holds the project's secrets in .server4agent/env.\n- `prompt(server_id, prompt, project_id?, follow_up_of?)` `[destructive]`\n  Send a freeform prompt to the on-server agent. It plans, writes code, runs commands, and ships whatever the prompt asks for. It spends the account's AI budget, so use it when the user asks for the on-server agent or to continue a run it started; to build something yourself, write_file, exec, start_app and deploy cost nothing. Returns a run_id to poll with get_run. Each call starts a new conversation unless you pass follow_up_of: the run_id of an earlier run to continue, so the agent remembers what it did there. Use it to answer a run that is awaiting_input, or to ask for changes to what a run built. Pass project_id to work inside one project's workspace, or omit it to work across the whole server workspace (e.g. scaffolding a new project).\n- `exec(server_id, command, project_id?)` `[destructive]`\n  Run a shell command on the server and return its output. Pass project_id to run inside that project's workspace folder, with PORT set to the project's routed port; omit it to run at the server workspace root. For one-off work: installing dependencies, building, inspecting files. Runs as the workspace user, the same one the agent and the apps run as, so what it creates stays editable by both; prefix a command with sudo when it needs root. A project command also gets the project's secrets as env. The command's session ends with the call, so do not use it to start an app or any other long-running process: use start_app, which keeps it running, brings it back after a restart, and tells you whether it answered. Output comes back for about 20 seconds: a command that runs longer keeps going on the server, but its output does not return, and the server's other commands wait for it. Start long work (a big install, a long build) in the background with its output in a file, then read the file.\n- `get_run(server_id, run_id)` `[read-only]`\n  Get a run's status, its latest progress note, the agent's final response, and what it changed in the workspace (commit, branch, files). Poll this with the run_id returned by prompt or init_project.\n- `get_logs(server_id, project_id?, lines?)` `[read-only]`\n  Read the latest log tails from a server: one entry per log file that a project's processes have written (each long-running process appends to .server4agent/<name>.log in its project folder). Read live from the server at the moment you call. If the server does not answer in time (starting, restarting, or paused), you get the tails saved earlier with stale: true and a note saying how old they are. An app keeps the same log file across restarts. Pass project_id to get only that project's logs. Use this to debug a crashing app or check what a background process is doing.\n\n### File workspace\n\nRead and write the project's files directly when you do not need the agent.\n\n- `list_files(server_id, project_id?)` `[read-only]`\n  List paths in the server's workspace. Pass project_id to list only that project's folder (paths come back relative to the project); omit it to list the whole server workspace.\n- `read_file(server_id, path, project_id?, encoding?)` `[read-only]`\n  Read a file from the server's workspace. With project_id, path is resolved inside that project's folder; without it, path is relative to the server workspace root. Use encoding:\"base64\" for binary files (e.g. .xlsx, images); plain text mode will corrupt non-text bytes.\n- `write_file(server_id, path, content, project_id?, encoding?)` `[destructive]`\n  Write or overwrite a file in the server's workspace. With project_id, path is resolved inside that project's folder; without it, path is relative to the server workspace root. Use encoding:\"base64\" to write binary content (e.g. a generated .xlsx); plain text mode assumes UTF-8 and will corrupt binary bytes. One call carries up to 512 KB of content; write anything larger in pieces, or fetch it on the server with exec. Writing a file does not serve it: a project's URL is answered by a running app, so after writing the files call start_app (a changed server needs start_app again to pick the change up).\n- `delete_file(server_id, path, project_id?)` `[destructive]`\n  Delete a file from the server's workspace. With project_id, path is resolved inside that project's folder; without it, path is relative to the server workspace root.\n- `get_download_url(server_id, path, project_id?, ttl_seconds?)`\n  Mint a time-limited link to download one file from the server's workspace, e.g. after generating a report or converting a file, hand this URL back to the user instead of the raw content. With project_id, path is resolved inside that project's folder. The link needs no login and works for anyone who has it, so only mint it for files that are OK to share.\n\n### Build and deploy\n\nPut a running project online with deploy, or, when the user asks for one, start an agent run that builds from a goal.\n\n- `start_build(server_id, goal, project_id?)` `[destructive]`\n  Have the on-server agent build a web page, site, app or API from a plain-language goal. Use it only when the user asks for that agent: it counts against the AI budget like prompt, and you can write the code yourself with write_file, exec and start_app, then deploy. Starts an agent run that works through each stage in order: plan, scaffold, write the code, install, build and test, then start it on the project's port. Returns a build_id to poll with get_build, and the run_id of the run doing the work. Pass project_id to build inside that project's workspace folder, then deploy it to put the result online; omit project_id to build at the server workspace root.\n- `get_build(server_id, build_id)` `[read-only]`\n  Get a build's status. The steps move together: running while the run works, done when it finished, failed when it did not (status still reads completed, and error says why). url is the project's address once it is built and public. run_id is the run doing the work: get_run shows its live progress, and when run_status is awaiting_input, answer its question with prompt and follow_up_of set to that run_id.\n- `deploy(server_id, project_id?)`\n  Deploy a project to its live public URL at <slug>.apps.server4agent.com: the last step in putting a web page, site, app or API online. Checks that something in the project is listening on its `listen_port`, makes the project public, and checks its URL answers, then returns that URL with status live (or publishing, when it is public but has not answered yet). It builds and starts nothing: when nothing is listening it refuses and leaves the project as it was, so start the app first with start_app (after write_file, for code you write yourself), or have the on-server agent build and start it with start_build or prompt. Pass project_id; a server with exactly one project deploys that one without it.\n\n### Custom domains\n\nServe a public project at a domain the user owns, with HTTPS issued automatically. On paid plans. The user adds two DNS records; check_domain switches the domain on once both are found.\n\n- `add_domain(project_id, domain)`\n  Connect a custom domain the user owns to a project, so the app also answers at that address over HTTPS. Returns the two DNS records the user adds at their DNS provider: a CNAME that points the domain at the project's address, and a TXT record that proves they own it. Nothing is served on the domain until check_domain finds both. Custom domains are on paid plans; the allowance is counted across the account. The project still has to be public (deploy) for the domain to serve.\n- `check_domain(project_id, domain)`\n  Look up a custom domain's DNS records now and, when both are right, switch it on: the certificate is issued automatically and the domain starts serving within a few minutes. Returns the domain's status (pending, verified, active or cert_failed) and, while pending, what is still wrong with the records. DNS changes can take a while to spread, so a pending result is normal right after adding the records; call it again later.\n- `remove_domain(project_id, domain)` `[destructive]`\n  Disconnect a custom domain from a project. It stops serving and its certificate is removed; the project keeps its own address. The DNS records stay at the user's DNS provider until they delete them.\n\n## Common workflows\n\n**Build and deploy a project: you write the code**\nThis is the way to build anything, from one page to an API: you write the\ncode, and these tools put it on the server and online. Nothing here serves a\ndirectory. A project's URL is routed to one port inside the box, so a page or a\nserver is only live once a process is answering on that port.\n\n1. `list_servers` and reuse a running one with room for another project, or\n   `create_server` when there is none. Either gives you a `server_id`. A new\n   server takes about a minute to start: poll `get_server` until\n   `provisioning` reads `ready` before writing files.\n2. `create_project(server_id, name, visibility=\"public\")` returns `project_id`\n   and `listen_port`.\n3. `write_file(server_id, \"public/index.html\", \"<html>...\", project_id)`, and\n   the same for each other file. Static pages go under `public/`: the\n   project folder itself holds\n   `.server4agent/env`, the secrets bound to this project, and a file server\n   rooted at the project would publish them.\n4. `exec` installs dependencies (`npm install`,\n   `pip install -r requirements.txt`) and waits for them.\n5. `start_app(project_id, command)`. It runs the command in the background\n   with `PORT` set to the project's port, records it so the app comes back\n   after a restart, and waits for the port to answer.\n\n```\nstart_app  project_id, command: \"node server.js\"\nstart_app  project_id, command: \"python3 -m http.server $PORT --bind 0.0.0.0 --directory public\"\n```\n\n6. The result says whether the app is answering, with its log tail and the\n   URL. If it exited, the log says why: fix that and call `start_app` again.\n   Calling it again with the same `name` is also how a changed server picks\n   up new code.\n7. `deploy(server_id, project_id)`. It checks the app is listening, makes the\n   project public if it is not, and returns the URL once it answers.\n\nYour app has to listen on `$PORT`, not a port of its own.\n\n**Hand a build to the on-server agent, when the user asks for it**\nAn agent on the server can write and start the code instead. It spends the\naccount's AI budget, so use it when the user asks for that agent, not as the\nway to build.\n1. `create_project` as above.\n2. `prompt(server_id, \"Build and serve ...\", project_id)`, or `start_build`\n   with the goal. Poll `get_run` or `get_build` until it finishes.\n3. `deploy(server_id, project_id)` once the run finishes.\n\n**Follow up on a run**\nEvery `prompt` call starts a new conversation. To change what a run built, or\nto answer a run whose status is `awaiting_input`, pass its id:\n`prompt(server_id, \"Add a login page\", follow_up_of=run_id)`. The agent picks\nup that conversation in the same folder and project, so it knows what it did.\n\n**Ephemeral one-shot task**\n1. `create_project(server_id, name, lifecycle=\"ephemeral\")`.\n2. `exec` to do the work, or `prompt` when the user asks for the on-server agent.\n3. `cleanup_project(project_id)` frees the slot when done.\n\n**Check capacity before creating**\n`get_server(server_id)` reports projects used against the tier cap. At the cap,\nfree a slot or move the server up a tier before calling `create_project`,\nwhich otherwise fails.\n\n**Watch spend before a long run**\n`get_usage()` reports spend for the period, the budget cap, and whether new\ntasks are blocked. Worth a call before a series of `prompt` invocations.\n\n## Notes that save a round trip\n\n- **Some questions are for people, not tools.** The Business or Enterprise\n  plan, running in your own cloud, a security questionnaire, or an account\n  problem no tool can fix: write to hello@server4agent.com for the person you\n  are helping (the form at https://www.server4agent.com/contact ends with a\n  human check). A person answers within one business day.\n- Projects are **private by default**. A newly created project's `url` is\n  `null` until you set `visibility=\"public\"`. The slug and URL do not change\n  when you toggle visibility.\n- A project URL is answered by **a process, not a folder**. Bind the project's\n  `listen_port` (from `create_project` or `get_project`) rather than a port of\n  your own: an in-pod proxy owns the one published port and routes each public\n  project's hostname to its own `listen_port`. On a box old enough to predate\n  that proxy there is no demux and 8080 is published directly, so if the URL\n  will not answer on `listen_port`, that is the fallback worth trying.\n- **What the URL answers tells you which thing is wrong.** A redirect to a\n  \"Nothing found\" page means nothing is routed to that slug: the project is\n  private, or it does not exist (the two are deliberately indistinguishable).\n  A 200 reading \"server4agent: unknown project\" or \"server4agent: no project\n  routed to this server yet\" means the request reached the box but the in-pod\n  proxy has no route for it yet, so give reconciliation a moment. A 503\n  \"Temporarily unavailable\" means the routing is right and nothing is\n  listening on `listen_port`, which is the one your own app causes. A sign-in\n  page means the project's `access` is `team`, so it is serving fine and only\n  the account's members get in (an allowlist can narrow it further still). A\n  prompt for a passcode means the owner protected the link on the project's\n  page in the dashboard: also serving fine, for the people the owner gave it\n  to. It is set and changed there, never in the conversation.\n- A process started through `exec` **dies with the call**. Start anything\n  long-running with `start_app`, which also records it in the project's\n  `.server4agent/start.sh` so a restart, a pause and a resume bring it back.\n  Other lines in that file are left alone. If you edit it by hand, keep it to\n  plain, self-contained commands, one per line: boot and resume do not replay\n  it the same way, so a line that leans on a `cd` or an `export` from an\n  earlier line works in one and not the other.\n- `deploy` **publishes, it does not build**. It refuses when nothing is\n  listening on the project's port, so start the app first (`start_app`, or\n  `prompt`). On success it returns the project's URL with status `live`,\n  or `publishing` when the URL has not answered yet: call it again shortly.\n- `create_project` **fails at the tier cap**: small holds 3 projects, medium 10,\n  large is unlimited. Moving a server down a tier is refused when the smaller\n  cap would not fit the projects already there.\n- `prompt` and `start_build` are **asynchronous**. They return an id, and you\n  poll `get_run` or `get_build` for progress.\n- Secret **values are write-only**. `list_secrets` returns keys, notes, and\n  bindings, never a value.\n- **Email needs no provider key.** An app that should email the people on the\n  account (an alert, a report) can POST to the URL in its `S4A_EMAIL_URL` env\n  var, sending `S4A_EMAIL_TOKEN` as a bearer token, with a JSON body of\n  `subject`, `text` and, optionally, `to`. A project's `exec` commands and its\n  `start_app` apps get both variables, and `start_app` keeps them in\n  `.server4agent/env.sh` for a cron job to source. It reaches only the\n  account's own people at confirmed addresses (the owner when `to` is left\n  out), so there is nothing to ask the user for. Mail to anyone else needs\n  their own provider, which the owner sets up on the dashboard's Secrets page.\n- Argument details beyond the signatures above are in each tool's own JSON\n  schema, which your MCP host already has once connected.\n"
}

SHA-256 of public snapshot: 2969de384cb13eaf9ad9ef62922f03143b780a626f2ac2f4d2890b4fdc613563