Skip to main content
Documentation

Comms

comms.cancel_scheduled_message

Pull a scheduled message back before it is sent
WritesWrite budget

REST

Shipping
POST /api/v1/comms/cancel_scheduled_message

MCP tool

Live
comms.cancel_scheduled_message

Exposed on: REST API · Shop MCP server · Claude connector · Dash (in-app copilot) · Zapier. Part of the Comms domain.

Operating contract

Cancels one queued message so the sweep does not send it. The row stays and its status becomes canceled, because 'we had this queued and pulled it' is part of the record and the queue is what tells staff the message is not coming.

IT ONLY WORKS BEFORE IT FIRES. A message that has already gone cannot be recalled by anything — this refuses, and the honest next step is another message, not a retry. comms.list_scheduled_messages shows what is still scheduled.

This is the one write in this domain that removes a customer-facing side effect rather than adding one, which is why it is safe to reach for whenever a plan changes: cancelling a follow-up that is no longer right costs nothing, and letting it go out costs the shop's credibility.

Cancelling something already cancelled or already sent reports that it is gone rather than pretending to have done something.

Who may call it

Permission
inbox.accessThe caller must hold Inbox at the ACT level. A read-only dashboard grant on the same section is refused.
Plan
Every planNo plan gate. Available on every Service VIN plan.
Retries
naturalNaturally idempotent — running it twice leaves the same world as running it once. A retrying integration needs no key.
Rate class
writeCounted against the write budget, which is tighter than a read.

Input

FieldTypeDescription
scheduled_messagerequiredstringuuid

The queued message to pull, as returned by comms.list_scheduled_messages.

Output

FieldTypeDescription
idstring

statusstring

Examples

Built from this capability's own schema — required fields and the ones carrying a default, and nothing invented. Paste one and it validates.

curl
export SERVICEVIN_API_KEY=svk_live_…

curl -X POST https://www.servicevin.com/api/v1/comms/cancel_scheduled_message \
  -H "Authorization: Bearer $SERVICEVIN_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"scheduled_message":"Left a voicemail about Friday."}'

TypeScript (fetch)
const res = await fetch("https://www.servicevin.com/api/v1/comms/cancel_scheduled_message", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.SERVICEVIN_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    "scheduled_message": "Left a voicemail about Friday."
  }),
});

// Success and failure are both envelopes. Switch on error.code, never
// on error.message — the codes are stable, the messages are for people.
const payload = await res.json();
if (!res.ok) throw new Error(payload.error.code);
const data = payload.data;

Python (requests)
import os, requests

res = requests.post(
    "https://www.servicevin.com/api/v1/comms/cancel_scheduled_message",
    headers={"Authorization": f"Bearer {os.environ['SERVICEVIN_API_KEY']}"},
    json={
    "scheduled_message": "Left a voicemail about Friday."
},
    timeout=30,
)
payload = res.json()
if not res.ok:
    raise RuntimeError(payload["error"]["code"])
data = payload["data"]

MCP tools/call — https://www.servicevin.com/api/mcp
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "comms.cancel_scheduled_message",
    "arguments": {
      "scheduled_message": "Left a voicemail about Friday."
    }
  }
}

Refusals

The four gates run in this order on every surface, and the order is not arbitrary — see Authentication.

StatusCodeWhen
404not_foundThe id is unknown, or the feature is not enabled for this account. Deliberately the same answer for both.
403forbiddenThis login does not hold inbox.access.
403insufficient_scopeThe credential is read-only and this capability writes.
422validation_errorAn argument was wrong. The message names the field.
429rate_limitedToo many write calls. Back off and retry.
500internal_errorSomething failed on our side. Nothing was changed.