MCP tools
Ten tools, kept small on purpose. deploy does almost everything; the rest are for looking, fixing and cleaning up. Every tool returns JSON text, and every failure is an error your agent can act on.
The remote server (https://api.rivtor.com/mcp) and the local server (npx -y rivtor mcp) expose the same ten tools. A few arguments differ; the Server column says where each one applies. The biggest difference is the source for deploy: the local server takes a path and uploads the folder, the remote server takes git_url, starter or inline files. See remote or local.
At a glance
| Tool | What it does |
|---|---|
deploy | Detect, plan, provision, build, migrate and release in one call, and return live URLs. Creates the project if the name is new. The only tool most agents need. The source arguments differ between servers. |
status | Current state of every service (status, URL, framework, release), each data service with its size against the limit, custom domains and the last deployment. |
logs | Runtime logs of the running services, summarised by default (repeats collapsed, errors kept), or the build/deploy log of one deployment. Rarely needed: failed deploys already return the cause and fix. |
env_set | Set and/or remove env vars and secrets, then restart the services with the new values. No rebuild, a few seconds. Credentials Rivtor manages (database, cache, storage) are read-only. |
rollback | Point traffic back at the previous release, or a specific one, in seconds without rebuilding. |
db | Work with the project's Postgres. The actions differ slightly between servers. |
domain_add | Attach a custom domain such as app.example.com to a public service. HTTPS is issued automatically once DNS resolves. |
destroy | Permanently delete a project, its services, database, cache and files. Two calls: the first returns a confirm_token; ask the user to confirm explicitly, then call again with it. Agents must never confirm on the user's behalf. |
upgrade | Return a payment link to upgrade the plan. Show it to the user; the plan changes as soon as they pay. Only call it when the user asks. |
list_projects | List the user's projects, owned and shared, with URLs, status and role. |
deploy
Detect, plan, provision, build, migrate and release in one call, and return live URLs. Creates the project if the name is new. The only tool most agents need. The source arguments differ between servers.
| Argument | Type | Server | Required | Description |
|---|---|---|---|---|
path | string | Local | Yes | Project root to deploy (absolute, or relative to the server's working directory). Packed as a tarball, respecting .gitignore; .env files are never uploaded. |
project | string | Both | Remote only | Project slug, e.g. my-app. Required on the remote server. On the local server it defaults to rivtor.json in the working directory, else the folder name. |
git_url | string | Remote | No | Public https Git URL, e.g. https://github.com/user/repo. One of git_url, starter or files. |
ref | string | Remote | No | Branch, tag or commit for git_url (default: the repo's default branch). |
starter | string | Remote | No | Starter template name, e.g. nextjs-fastapi-postgres. |
files | object | Remote | No | Inline source as { relative/path: content }, at most 2 MB in total. For agents without a filesystem; for a local folder use the local server instead. |
dry_run | boolean | Both | No | Only detect and return the plan; nothing is built or changed. |
env | object | Both | No | Env vars and secrets to set before building, e.g. { STRIPE_SECRET_KEY: "..." }. Never echoed back. |
wait | boolean | Remote | No | Wait for the result (default true). false returns a deploymentId to follow with status and logs. The local server always waits. |
Returns: A DeployResult: status is live (see urls), failed (read error.cause, error.file, error.fix, fix, deploy again) or needs_input (missing secrets in error.missing: ask the user, call env_set, deploy again). Static sites take about 30 s, container apps up to about 3 minutes.
status
Current state of every service (status, URL, framework, release), each data service with its size against the limit, custom domains and the last deployment.
| Argument | Type | Server | Required | Description |
|---|---|---|---|---|
project | string | Both | Remote only | Project slug, e.g. my-app. Required on the remote server. On the local server it defaults to rivtor.json in the working directory, else the folder name. |
Returns: Status JSON for the project.
logs
Runtime logs of the running services, summarised by default (repeats collapsed, errors kept), or the build/deploy log of one deployment. Rarely needed: failed deploys already return the cause and fix.
| Argument | Type | Server | Required | Description |
|---|---|---|---|---|
project | string | Both | Remote only | Project slug, e.g. my-app. Required on the remote server. On the local server it defaults to rivtor.json in the working directory, else the folder name. |
deployment_id | string | Both | No | Return this deployment's build/deploy log instead of runtime logs. |
service | string | Both | No | Service name, e.g. api. |
since | string | Both | No | Time window such as 15m, 2h, 2d, or an ISO timestamp. |
level | enum | Both | No | Remote: error | warn | info. Local: debug | info | warn | error. |
limit | integer | Both | No | Maximum lines. Remote: 1–2000, default 200. Local: 1–1000. |
summary | boolean | Both | No | Default true (grouped summary); false returns raw lines. |
Returns: Log lines or a summary.
env_set
Set and/or remove env vars and secrets, then restart the services with the new values. No rebuild, a few seconds. Credentials Rivtor manages (database, cache, storage) are read-only.
| Argument | Type | Server | Required | Description |
|---|---|---|---|---|
project | string | Both | Remote only | Project slug, e.g. my-app. Required on the remote server. On the local server it defaults to rivtor.json in the working directory, else the folder name. |
set | object | Remote | No | Variables to set: { KEY: value }. |
vars | object | Local | No | Variables to set: { KEY: value }. (Same as set on the remote server.) |
remove | string[] | Both | No | Variable names to remove. |
service | string | Both | No | Limit to one service; default applies to every service. |
Returns: The key names that changed. Values are encrypted and never returned.
rollback
Point traffic back at the previous release, or a specific one, in seconds without rebuilding.
| Argument | Type | Server | Required | Description |
|---|---|---|---|---|
project | string | Both | Remote only | Project slug, e.g. my-app. Required on the remote server. On the local server it defaults to rivtor.json in the working directory, else the folder name. |
release_id | string | Both | No | Release to return to (default: the one before current). |
Returns: The release now serving traffic.
db
Work with the project's Postgres. The actions differ slightly between servers.
| Argument | Type | Server | Required | Description |
|---|---|---|---|---|
project | string | Both | Remote only | Project slug, e.g. my-app. Required on the remote server. On the local server it defaults to rivtor.json in the working directory, else the folder name. |
action | enum | Both | Yes | query: read-only SQL (5 s timeout, 500 rows). connection: temporary connection string valid 1 hour. Remote only: tables lists tables with row counts and sizes; export_url returns a 15-minute download link for a pg_dump. Local only: export writes the dump to output on your machine. |
sql | string | Both | No | SQL for action query (read-only, up to 20,000 characters). |
output | string | Local | No | File path for action export, e.g. ./backup.dump. |
Returns: Rows, a connection string, a download link or the written file path, depending on the action.
domain_add
Attach a custom domain such as app.example.com to a public service. HTTPS is issued automatically once DNS resolves.
| Argument | Type | Server | Required | Description |
|---|---|---|---|---|
project | string | Both | Remote only | Project slug, e.g. my-app. Required on the remote server. On the local server it defaults to rivtor.json in the working directory, else the folder name. |
hostname | string | Both | Yes | Fully qualified domain, e.g. www.example.com. |
service | string | Both | No | Service to route to (default: the primary web service). |
Returns: The DNS records the user must create at their DNS provider.
destroy
Permanently delete a project, its services, database, cache and files. Two calls: the first returns a confirm_token; ask the user to confirm explicitly, then call again with it. Agents must never confirm on the user's behalf.
| Argument | Type | Server | Required | Description |
|---|---|---|---|---|
project | string | Both | Yes | Project slug to delete. Required on both servers; never inferred. |
confirm_token | string | Both | No | Token from the first call, valid about 10 minutes. |
Returns: A confirm_token on the first call; the deletion result on the second.
upgrade
Return a payment link to upgrade the plan. Show it to the user; the plan changes as soon as they pay. Only call it when the user asks.
| Argument | Type | Server | Required | Description |
|---|---|---|---|---|
plan | enum | Both | No | hobby | pro | team. Remote default: the next plan above the current one. Local default: hobby. |
interval | enum | Both | No | month | year. Remote default: year (2 months free). Local default: month. |
currency | enum | Remote | No | usd (Stripe, card) or inr (Razorpay, UPI autopay or card). Default usd. |
Returns: A checkout URL.
list_projects
List the user's projects, owned and shared, with URLs, status and role.
No arguments.
Returns: The current plan and the project list.
Example calls
{ "name": "deploy", "arguments": { "path": "/Users/me/code/my-app", "dry_run": true } }{
"name": "deploy",
"arguments": {
"project": "my-app",
"git_url": "https://github.com/me/my-app",
"ref": "main"
}
}{
"name": "db",
"arguments": {
"project": "my-app",
"action": "query",
"sql": "select id, email from users order by created_at desc limit 5"
}
}Failures from any tool use the same shape. See Errors.