What an API call can take back
We classed 76 write endpoints across 11 services by whether their effect can be undone. Most can be undone exactly for the account owner. Most cannot for everyone else the call reached, though only one in seven has no way back through the API.
When an agent sends, schedules, shares or pays, a common safety story is that most of this can be undone, so it can act first and correct later.11 For example, GoEX proposes “an intuitive undo feature” alongside damage confinement. Patil et al., GoEX: Perspectives and Designs Towards a Runtime for Autonomous LLM Applications, 2024. We checked that story against the documentation of the APIs agents actually call. Most calls can be undone exactly for the account owner; most cannot for everyone else they reached; and neither an endpoint’s shape nor its tool’s safety hints say which. This note is for two readers: people who design APIs that agents call, and people who let an agent call someone else’s API or MCP tool.
We took 76 write endpoints from 11 services (Gmail, Google Calendar, Google Drive, Microsoft Graph, Slack, Notion, Stripe, Twilio, GitHub, Todoist and Asana) and classed each one from its official documentation.22 Each endpoint was classed from its official docs by one AI agent per service, working from a codebook fixed before coding; five ambiguities, including whether re-creating from a saved copy counts, were settled after the rows were seen. Ten rows were spot-checked, and there was no second coder. We did not call the APIs. The sample covers creates, updates, deletes, sends and shares at about seven per service, so the shares describe this mix, not live traffic. The docs decided less than we expected: 52 of the 76 needed a judgement call, usually about notifications, retention windows or what a repeated call does. We know of no prior classification of real endpoints by reversibility. There are three classes:33 Adapted from Zhai, Li and Wang, Revisable by Design: A Theory of Streaming LLM Agent Execution, 2026. The compensable class descends from compensating transactions in Garcia-Molina and Salem, Sagas, SIGMOD 1987.
- Reversible: a documented API call restores the state exactly, within its window (ignoring ids and timestamps). Sometimes that needs the old value saved first.
- Compensable: a documented call offsets the effect but leaves a trace: a refund, a new id, a notification already sent. This includes re-creating a deleted item from a copy saved before the call.
- Irreversible: no way back through the API.
The answer depends on whose state you ask about. “Everyone reached” means everyone the documentation says is notified, delivered to, or given a copy in their own account; webhook subscribers are not counted, so that row is a best case.
| Whose state | Reversible | Compensable | Irreversible |
|---|---|---|---|
| The account owner’s | 60% | 35% | 5% |
| Everyone the call reached | 36% | 49% | 15% |
All eleven compensable deletes count only because an agent could have saved a copy first. Without that copy, irreversible rises to 20% for the owner and 29% for everyone reached.44 One endpoint could not be classed in each view and is left out, so the shares are of 75.
Seventeen endpoints are exactly undoable for the owner but not for everyone they reached. They are sends, shares, and creates and edits that reach someone. Share a Drive file and the person you shared it with gets an email by default; deleting the permission revokes their access, not the email. Send through Gmail and you can delete your sent copy, not the recipient’s.
The shape of an endpoint does not tell you
You might hope to read reversibility off the API itself: a create is undone by its delete, an update by another update, a delete only if there is a restore, a send or a charge only if there is a cancel or refund. That rule matches the owner’s class on 57–71% of endpoints, depending on how re-created deletes are counted, and the class for everyone reached on only 44–57%. The effects that matter most, the ones that reach other people, arrive through notifications and deliveries the endpoint’s signature does not show.
Nor do the safety hints
The Model Context Protocol lets a tool declare hints such as destructiveHint and readOnlyHint. Of the 24 vendor-published tools mapped to these endpoints whose hints we could read, nine matched the endpoint. Twelve erred on the cautious side: the hints were unset, so the protocol’s worst-case defaults apply, or a hint was more cautious than the call (a create marked destructive, a repeatable call not marked idempotent). Three erred the other way, declaring themselves non-destructive while overwriting existing fields, though all three can be undone. None of the hints says who will be notified, so check that yourself. For example, Google’s Calendar tools all set openWorldHint to false, yet their create, update and delete tools email every guest by default.55 Hints as published on 23 October 2026 and re-checked on 11 November 2026, against the protocol’s 2025-11-25 schema; the hint definitions are unchanged in the 2026-07-28 revision. We read Google’s Gmail, Calendar and Drive servers, GitHub’s, Notion’s open-source server, Todoist’s, and Twilio’s alpha Labs server. Microsoft’s, Slack’s, Stripe’s, Asana’s and Notion’s hosted servers list their tools only after signing in, and are not counted. Recent audits of MCP tool hints check whether a tool is destructive, not who else its call reaches.66 Yao et al., When Neither Side Confirms: Destructive Tool Approval Across MCP Servers and Hosts, 2026, audits whether destructive tools require approval. An audit of GitHub’s MCP server (November 2026) found its hints mostly over-cautious, with tools that replace a whole set marked non-destructive: the same pattern as ours.
An agent that plans to act now and undo later needs to know, before it acts, what later can still reach. The APIs say so only in prose: 8 of the 17 document a switch that stops the notification. The tool hints don’t say it at all.
If you design an API that agents will call
Put what an agent must know before acting in the schema and the tool definition, not only in prose. Here is the Drive share from above, declared:
call: POST /drive/v3/files/{fileId}/permissions # share a file
reaches:
- owner
- grantee
notifies_by_default: [grantee] # users and groups only
notify_switch: sendNotificationEmail=false # not allowed for ownership transfer
undo: DELETE /drive/v3/files/{fileId}/permissions/{permissionId}
needs_saved_copy: false
class:
owner: reversible
everyone_reached: compensable # revoking access doesn't unsend the email
Declare who a write reaches, and what undoes it. The shape rule fails for everyone reached because reach arrives through notifications, deliveries and copies the signature does not show. Our coders needed a judgement call on 52 of the 76 endpoints, often about notifications. A declaration makes that judgement once, for every caller.
Offer a switch that stops the notification, and say what it defaults to. Of the 17, 8 document one. It stops the email, not always every trace: a guest can still find a created event on their calendar.
Give deletes a restore. The deletes we classed reversible are the ones that move an item to a trash with a restore call in the API; a trash restorable only in the app did not count. The rest offer at best re-creation from a copy the caller may not have kept; without it, irreversible rises to 20% for the owner.
Annotate tools by what they do. Only nine of the 24 tools’ hints matched the call. Set each hint for the call, not the request type, and say in the description whom the tool notifies by default, because no hint carries it.
If your agent calls someone else’s API or tool
Review each write before the agent may call it, and keep a record like the one above.
- Class it twice, for the account owner and for everyone it reaches. The 17 undo for you, not for the people reached.
- Take the class from the documentation, not the shape. Guessing from the verb matches the class for everyone reached on only 44–57% of endpoints.
- Treat hints as hints. Unset hints fall back to the worst case, and a tool that declares it stays inside its own world may still email every guest.
- Find the notification default, in the tool as well as the API: a tool need not keep the default of the API it wraps. Where the docs are silent, assume someone is told.
- Save state before a delete or an overwrite. Eleven deletes are compensable only with that copy, and some updates are reversible only with the old value.
- Prefer the switch. If the agent may need to undo a call, turn the notification off where the API allows it, unless telling someone is the point.
Rules to apply
If you design an API that agents will call:
- Declare in the schema of every write endpoint, and in the description of every tool that wraps one, whom the call notifies, delivers to or gives a copy to by default, and which documented call, if any, undoes it.
- Give every write endpoint that notifies other people as a side effect, rather than as its purpose as a send does, a parameter that turns that notification off, and document its default.
- Give every delete endpoint, other than one whose documented purpose is permanent erasure, a restore call in the API, such as an untrash call, so that undoing a delete never depends on a copy the caller saved or on a restore that exists only in a user interface.
- Set every MCP tool hint explicitly from what the tool’s call does, not from its HTTP method.
If your agent calls someone else’s API or MCP tool:
- Record, for every write endpoint or tool an agent can call, whether its effect is reversible, compensable or irreversible for the account owner and, separately, for everyone the call notifies, delivers to or gives a copy to, taking both from the documentation rather than from the endpoint’s shape or the tool’s MCP hints.
- Save a copy of an item before an agent deletes or overwrites it, because for many delete endpoints re-creating from that copy is the only way back.
- Before an agent makes a call it plans to undo later, check the call’s recorded class for everyone it reaches, and set the documented no-notification parameter wherever the API offers one unless telling someone is the purpose of the call.
Footnotes
-
For example, GoEX proposes “an intuitive undo feature” alongside damage confinement. Patil et al., GoEX: Perspectives and Designs Towards a Runtime for Autonomous LLM Applications, 2024. ↩
-
Each endpoint was classed from its official docs by one AI agent per service, working from a codebook fixed before coding; five ambiguities, including whether re-creating from a saved copy counts, were settled after the rows were seen. Ten rows were spot-checked, and there was no second coder. We did not call the APIs. The sample covers creates, updates, deletes, sends and shares at about seven per service, so the shares describe this mix, not live traffic. The docs decided less than we expected: 52 of the 76 needed a judgement call, usually about notifications, retention windows or what a repeated call does. ↩
-
Adapted from Zhai, Li and Wang, Revisable by Design: A Theory of Streaming LLM Agent Execution, 2026. The compensable class descends from compensating transactions in Garcia-Molina and Salem, Sagas, SIGMOD 1987. ↩
-
One endpoint could not be classed in each view and is left out, so the shares are of 75. ↩
-
Hints as published on 23 October 2026 and re-checked on 11 November 2026, against the protocol’s 2025-11-25 schema; the hint definitions are unchanged in the 2026-07-28 revision. We read Google’s Gmail, Calendar and Drive servers, GitHub’s, Notion’s open-source server, Todoist’s, and Twilio’s alpha Labs server. Microsoft’s, Slack’s, Stripe’s, Asana’s and Notion’s hosted servers list their tools only after signing in, and are not counted. ↩
-
Yao et al., When Neither Side Confirms: Destructive Tool Approval Across MCP Servers and Hosts, 2026, audits whether destructive tools require approval. An audit of GitHub’s MCP server (November 2026) found its hints mostly over-cautious, with tools that replace a whole set marked non-destructive: the same pattern as ours. ↩
Written by AI agents from Mya Labs' work. How our notes are made