Cancel an answer
October 12, 2026 (November 16, 2026)
Table of contents
Stop the answer Muse is working on in a chat, like the stop button in the muse.ai app. The stream shows turn.done with status: "interrupted". The chat stays: send the next message with POST /chats/chatId/messages.
https://api.useapi.net/v1/muse/chats/
chatId/cancel
chatIdis URL-encoded in the path (it contains:and@).
Request Headers
Authorization: Bearer {API token}
API tokenis required, see Setup useapi.net for details.
Responses
-
200 OK —
cancelledistruewhen Muse confirmed the stop.{ "chatId": "c-u12345-email:example@gmail.com-chat:272b73f4-6fcb-42c2-9ec7-75cc0c020940-bot:muse", "cancelled": true }cancelledisfalsewhen no answer was running. -
400 Bad Request — the path value is not a Muse
chatId.{ "error": "Path parameter chatId (not-a-chat-id) is not a valid Muse chat id", "code": 400 } -
Invalid API token.
{ "error": "useapi.net ⁝ Unauthorized", "code": 401 } -
403 Forbidden — the
chatIdwas issued to a different API token.{ "error": "This chat id does not belong to this API token", "code": 403 } -
404 Not Found — Muse has no such chat, or the account that holds the chat is not added.
{ "error": "Chat not found", "code": 404 }{ "error": "Account example@gmail.com (from the chat id) is not configured", "code": 404 } -
503 Service Unavailable — Muse could not be reached. Retry shortly.
{ "error": "Could not connect to the Muse workspace of account example@gmail.com (…), please retry shortly", "code": 503 } -
596 Account Error
The account needs your attention, and it is paused until you add it again. You receive an email when this happens. There are three causes.
Meta asks for a security check on the account. Sign in once at muse.ai in a browser, complete the check, then add the account again with POST /accounts using the same email and password. The API keeps using its session, so no new sign-in is needed.
{ "error": "Account example@gmail.com: Meta asks for a security check on account example@gmail.com (\"This account must complete a security checkpoint on the web\"). Sign in once at https://muse.ai in a browser, complete the check, then add the account again with POST /accounts", "code": 596 }Or Muse refused to sign the account in again when its session needed renewing, most often because the password was changed. Add the account again with the current password.
{ "error": "Account example@gmail.com: Muse refused to sign in account example@gmail.com (…). Update its password with POST /accounts, or sign in at https://muse.ai to clear the block, then re-add it", "code": 596 }Or Muse disabled the account’s computer and refuses to start it again. Sign in at muse.ai in a browser to see why, and ask Muse support to restore it with the form Muse shows there. Add the account again only after Muse has restored it.
{ "error": "Account example@gmail.com: Muse has disabled the computer of account example@gmail.com (\"VM wake unavailable\"). Sign in at https://muse.ai in a browser to see why and contact Muse support there, then add the account again with POST /accounts", "code": 596 }
Model
The answer’s cancelled is true when Muse stopped a running answer, and false when none was running.
The cancel result, field by field
{ // TypeScript, all fields are optional
chatId: string
cancelled: boolean // true when Muse confirmed the stop, false when no answer was running
error?: string // errors only
code?: number // errors only
}
Examples
-
CHATID="c-u12345-email:example@gmail.com-chat:272b73f4-6fcb-42c2-9ec7-75cc0c020940-bot:muse" curl -X POST -H "Authorization: Bearer …" \ "https://api.useapi.net/v1/muse/chats/$(python3 -c "import urllib.parse,sys;print(urllib.parse.quote(sys.argv[1],safe=''))" "$CHATID")/cancel" -
const token = "API token"; const chatId = "chatId from POST /chats"; const apiUrl = `https://api.useapi.net/v1/muse/chats/${encodeURIComponent(chatId)}/cancel`; const response = await fetch(apiUrl, { method: "POST", headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", response.status, result); -
import requests from urllib.parse import quote token = "API token" chatId = "chatId from POST /chats" apiUrl = f"https://api.useapi.net/v1/muse/chats/{quote(chatId, safe='')}/cancel" headers = { "Authorization" : f"Bearer {token}" } response = requests.post(apiUrl, headers=headers) print(response, response.json())