Skip to main content
DELETE
Cancel a message
  • Credential: an API key. A trial key returns 401 unauthorized.
  • Line-scoped keys: a line-scoped key gets 404 not_found for a message on a line outside its list.
  • Idempotency-Key: not honored. A repeat of a cancel that succeeded returns 409 too_late_to_cancel.
  • Events: sends message.cancelled.
  • Personal data: the response carries the handles in to and from, the text in body, the attachment file names and your metadata. Request it only when needed, do not copy it into logs, tickets or other tools, and refer to a contact by an id of your own.
  • What can be canceled: a message whose status is queued or scheduled, and that the line’s device has not taken. See Canceling a message.
  • Sending limits: a canceled message that had counted against the limits of the line stops counting against them.

Errors

The errors that every operation shares are in Errors.

Authorizations

Authorization
string
header
required

An API key created in the iSnap dashboard, or a trial key, sent as Authorization: Bearer <key>. An API key starts with isnap_live_ or isnap_test_; both act on the same account, lines and billing. A trial key acts on its trial only.

Path Parameters

id
string
required

Message id: msg_ followed by 25 letters or digits.

Pattern: ^msg_[0-9A-Za-z]{25}$

Response

The canceled message, with status: cancelled.

success
enum<boolean>
required

Always true on a success response.

Available options:
true
data
object
required

A message sent or received by a line. The response of POST /v1/messages, the reads, the list items, the cancel response and the message field of the message.* events all carry this object. It has no chat id: the chat id is given by GET /v1/chats and by events. It carries personal data: the handles in to and from, the text in body, the file names of attachments, and what you put in metadata. Timestamps are ISO 8601 in UTC.

trace_id
string
required

Trace id of the request that produced this response: 32 lowercase hexadecimal characters. Quote it when you report a problem to iSnap.

request_id
string
required

Id of the request that produced this response: req_ followed by 25 letters or digits.