Remove an action added on request
POST
/sites/{siteId}/actions/{issueId}/remove- Berechtigung
actions:write- MCP-Tool
remove_action
Remove an action added on request Like Ignore in the app: the action leaves the list, with the reason shown on it. Only actions added on request (keyword, AI answer and FAQ tasks, by hand or through the API); an audit finding leaves the list when a recheck no longer finds it. Adding the keyword again brings the action back. Recorded in the website's Activity as the key owner.
Die Beschreibungen kommen aus dem OpenAPI-Dokument und sind auf Englisch.
Parameter
| Name | Ort | Details |
|---|---|---|
siteIdPflicht | Pfad | stringWebsite id, from GET /sites. |
issueIdPflicht | Pfad | stringAction id (issueId), from GET /sites/{siteId}/actions or POST /sites/{siteId}/actions. |
Anfrage (Body)
| Feld | Details |
|---|---|
reason | string · at most 300 characters; Why, shown on the action (default: Removed through the API) |
{
"reason": "Test action"
}Antwort
200 · application/json
| Feld | Details |
|---|---|
removed | true or false · required; Always true |
action | object · required |
action.id | string · required; Action id |
action.ruleId | string · required; Rule of the task, for example KW-OPP-001 |
action.title | string · required; Action title |
action.status | ignored · required; Now ignored |
action.link | address (URL) · required; The action in the app |
action.reason | string · required; The reason kept on it |
Fehler
| Status | Bedeutung |
|---|---|
400 | Bad request. Codes: not_removable, bad_reason, reason_too_long. |
401 | Missing, unknown or revoked key. Codes: missing_key, invalid_key. |
403 | The key lacks the scope, covers another website, or its owner lost access. Codes: missing_scope, other_site, owner_left, no_owner, forbidden. |
404 | Not found. Codes: not_found. |
429 | Too many requests this hour for this key. Codes: rate_limited. |
Beispielanfrage
curl -X POST \
-H "Authorization: Bearer mr_ws_…" \
-H "Content-Type: application/json" \
-d '{"reason":"Test action"}' \
"https://app.monoranks.com/api/v1/sites/SITE_ID/actions/ISSUE_ID/remove"const res = await fetch("https://app.monoranks.com/api/v1/sites/SITE_ID/actions/ISSUE_ID/remove", {
method: "POST",
headers: { Authorization: "Bearer mr_ws_…", "Content-Type": "application/json" },
body: JSON.stringify({
"reason": "Test action"
}),
});
if (!res.ok) throw new Error((await res.json()).error.message);
const data = await res.json();import requests
res = requests.post(
"https://app.monoranks.com/api/v1/sites/SITE_ID/actions/ISSUE_ID/remove",
headers={"Authorization": "Bearer mr_ws_…"},
json={
"reason": "Test action",
},
)
res.raise_for_status()
data = res.json()<?php
$ch = curl_init("https://app.monoranks.com/api/v1/sites/SITE_ID/actions/ISSUE_ID/remove");
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => ["Authorization: Bearer mr_ws_…", "Content-Type: application/json"],
CURLOPT_POSTFIELDS => '{"reason":"Test action"}',
CURLOPT_RETURNTRANSFER => true,
]);
$data = json_decode(curl_exec($ch), true);import axios from "axios";
const { data } = await axios.post(
"https://app.monoranks.com/api/v1/sites/SITE_ID/actions/ISSUE_ID/remove",
{
"reason": "Test action"
},
{ headers: { Authorization: "Bearer mr_ws_…" } },
);Beispielantwort
{
"removed": true,
"action": {
"id": "b2e4c6a8-1d3f-4a5b-9c7d-0e2f4a6b8c1d",
"ruleId": "KW-OPP-001",
"title": "New content: tubeless gravel tires",
"status": "ignored",
"link": "https://app.monoranks.com/sites/3f6c2a1e-8b4d-4c7a-9e21-5d0b7a6f4c13/actions/b2e4c6a8-1d3f-4a5b-9c7d-0e2f4a6b8c1d",
"reason": "Test action"
}
}{
"error": {
"code": "not_removable",
"message": "Only actions added by hand or through the API can be removed. An audit finding leaves the list when a recheck no longer finds it."
}
}{
"error": {
"code": "missing_key",
"message": "Send the key as Authorization: Bearer mr_site_…"
}
}{
"error": {
"code": "missing_scope",
"message": "This key does not have the scope this call needs."
}
}{
"error": {
"code": "not_found",
"message": "Action not found."
}
}{
"error": {
"code": "rate_limited",
"message": "More than 1200 requests this hour for this key."
}
}Der MCP-Server macht dasselbe mit dem Tool remove_action.