Skip to main content
Glama

Roll back a service

rollback_service
Destructive

Return a website, app, or agent to an earlier release. It publishes that release's files again as a new release, so the service gets the next version number, runs every release policy a publish runs, and keeps the history. Repeating a call that names a release changes nothing; repeating one without release goes back another step. A release published before Valet kept its source cannot be restored. Environment variables, connectors, and access settings are not rolled back. Skills are refused: publish_skill publishes an earlier version. Returns the restored version and the new release's version, or for an app a build_id to follow with get_build. no_changes means the service already runs those files, evaluation that the release waits for its policies, and pending that an agent lacks setup. Requires connecting a Valet account.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "name": "<name>"
    },
    "name": "rollback_service"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesThe website's, app's, or agent's name.
releaseNoWhich earlier release to bring back, as a version list_releases shows, when the person names a point in history. Omit to undo the latest change: Valet returns to the newest earlier release built from different files.
org_nameNoThe Valet organization it belongs to. Omit to use the organization the account joined first.
idempotency_keyNoAn opaque key of your choosing. Repeating a call with the same key returns the first call's result instead of rolling back a second time.

Output Schema

NameRequiredDescriptionDefault
orgYesName of the Valet organization the call acted in.
urlNoURL that serves the website or app. Absent for an agent and while a site or app has no route.
kindYesKind of the service: site, app, or agent.
nameYesName of the website, app, or agent.
pendingNoWhat the organization must set up before the agent deploys. Nothing was rolled back. Set each up with its tool, then call rollback_service again. Absent when the rollback went through.
versionNoVersion number of the new release that went live. Absent when none did: the app builds first (see build_id), the release waits for its policies (see evaluation), or nothing changed.
build_idNoAn app's rollback starts a build. Pass the ID to get_build and poll until deploy_state is up, idle, crashed, superseded, or refused. Absent for other kinds.
restoredYesVersion of the release whose files were restored. A repeat of a keyed call returns the same value.
evaluationNoThe release evaluation. Without version, the release waits for its policies: follow it with get_evaluation. With version, the release is live and this is its monitor-only evaluation. Absent when the release has none.
no_changesNoTrue when the service already runs the release's files, so nothing was published. Absent otherwise.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / release / description
      Previous value: -"The release version from list_releases to return to. Omit to return to the newest earlier release built from different files."New value: +"Which earlier release to bring back, as a version list_releases shows, when the person names a point in history. Omit to undo the latest change: Valet returns to the newest earlier release built from different files."
  2. Changed3 schema fields changed
    • changedOutput schema / properties / evaluation / properties / deploy_message / description
      Previous value: -"The refusal's message when deploy refused the release. Absent otherwise."New value: +"The refusal's message when deploy refused the release, with credentials redacted as [redacted]. Absent otherwise."
    • addedOutput schema / properties / evaluation / properties / redactions
      Added value: +{
      +  "description": "How many credentials were replaced with [redacted] in the text this answer was built from: secret values the service holds, and strings shaped like an API key, a private key, a token, or a password in a URL or header. Redaction is best effort, so 0 does not prove the text holds no credential.",
      +  "type": "integer"
      +}
    • changedOutput schema / properties / evaluation / required
      Previous value: -[
      -  "id",
      -  "status"
      -]New value: +[
      +  "id",
      +  "status",
      +  "redactions"
      +]
  3. Added

TDQS

A4.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations declare destructiveHint=true and idempotentHint=false, and the description goes well beyond them: it explains that the rollback republishes files as a new release, runs every publish policy, preserves history, does not roll back env vars/connectors/access settings, and defines the no_changes/evaluation/pending statuses. The statement that repeating a call with a named release "changes nothing" is consistent with idempotentHint=false, which refers to the no-release form that steps back again, so this is clarification rather than contradiction. It stops short of naming required permissions beyond "requires connecting a Valet account."

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with purpose, then behavior, then return values and error statuses. No filler, but the middle portion is a dense semicolon-chained run of clauses that could be broken up for faster scanning.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a destructive, open-world mutation tool, the description covers side effects, non-rolled-back resources, idempotency behavior, and return shape (restored and new version, or build_id to follow with get_build). With a full schema and output schema present, nothing an agent needs is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds real meaning to the release parameter: omitting it undoes the latest change while naming a release is a no-op on repeat. The org_name and idempotency_key semantics are left entirely to their schema text.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource ("Return a website, app, or agent to an earlier release") and immediately distinguishes itself from publishing and from publish_skill. An agent can tell what this does and what it does not do without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It states when to use it (restoring a point in history, or undoing the latest change by omitting release), names the alternative for skills ("publish_skill publishes an earlier version"), and gives an explicit exclusion (releases published before Valet kept source). The only minor omission is that no sibling is named for inspecting history first, though list_releases is referenced.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources