MetriBeacon
Menu

POST Apply reviewed actions to selected monitors

/api/v1/monitors/bulk/apply

Send the same selection and operation UUID with the preview version and confirmed=true. Existing HTTP checks that can change targets additionally require actions_confirmed=true. A configuration, allowance or selection change requires a new preview. All selected monitors change together or none change; retries do not repeat the action. External client intervals and cron schedules use their individual settings.

On this page

Access and permissions

Send the same selection and operation UUID with the preview version and confirmed=true. Existing HTTP checks that can change targets additionally require actions_confirmed=true. A configuration, allowance or selection change requires a new preview. All selected monitors change together or none change; retries do not repeat the action. External client intervals and cron schedules use their individual settings.

Browser session: __Host-mb_session cookie.

Machine management credentials in Authorization: Bearer. Check the permissions (scopes) required by the operation.

When using a browser session for a mutation, send the current CSRF token in X-CSRF-Token with the same-site cookie. OAuth consent uses its documented form field.

Parameters and headers

No path, query or additional request-header parameters.

Request body

FieldType and limitsRequiredMeaning
$MonitorBulkApplyYes—
$.workspace_idstring; {"format":"uuid"}Yes—
$.device_idsarray<string; {"format":"uuid"}>; {"minItems":1,"maxItems":100}Yes—
$.device_ids[]string; {"format":"uuid"}Yes—
$.operation_idstring; {"format":"uuid"}YesA stable UUID for this operation. Keep it when retrying, including after a lost response. An Idempotency-Key may additionally bind the request; a reused key or operation with different data fails.
$.actionstring; {"enum":["pause","resume","groups","interval"]}Yes—
$.interval_secondsinteger; {"minimum":1,"maximum":86400}No—
$.group_idsarray<string; {"format":"uuid"}>; {"maxItems":100}No—
$.group_ids[]string; {"format":"uuid"}Yes—
$.group_modestring; {"enum":["add","remove","replace"]}No—
$.versionstring; {"pattern":"^[a-f0-9]{64}$"}Yes—
$.confirmedbooleanYes—
$.actions_confirmedbooleanNo—

Responses

application/json

FieldType and limitsRequiredMeaning
$MonitorBulkResultYes—
$.operation_idstring; {"format":"uuid"}Yes—
$.device_idsarray<string; {"format":"uuid"}>Yes—
$.device_ids[]string; {"format":"uuid"}Yes—
$.actionstringYes—
$.afterobjectYes—
$.after.itemsnumber; {"minimum":0}Yes—
$.after.eventsnumber; {"minimum":0}Yes—
$.after.bytesnumber; {"minimum":0}Yes—
$.after.event_bytesnumber; {"minimum":0}Yes—
Stable error codes
csrf
insufficient_scope
invalid_origin
HeaderType and limitsMeaning
Cache-Controlstring; {"pattern":"(?:^|,\\s*)no-store(?:,|$)"}Private API responses prohibit storage. Public OAuth metadata is cached for 300 seconds; live streams additionally prohibit transformation.
Content-Languagestring; {"enum":["en","de"]}Language of human-readable response text, resolved from Accept-Language or the documented browser preference. Technical codes and identifiers remain stable.
Referrer-PolicyJSON; {"enum":["strict-origin-when-cross-origin","no-referrer"]}The default referrer policy is strict-origin-when-cross-origin. Provider-login responses use no-referrer to protect login parameters.
VarystringResponses vary by Accept-Language; browser-rendered responses can also vary by the preference cookie.
X-Content-Type-OptionsJSON; {"const":"nosniff"}The browser must use the declared content type.
X-Frame-OptionsJSON; {"const":"DENY"}The response must not be embedded in a frame.
X-Request-IDstringServer-generated request identifier. Include this when reporting an error; inbound values are not trusted.

application/problem+json

FieldType and limitsRequiredMeaning
$ProblemYes—
$.codestringYesStable machine-readable error code
$.detailstringYesShort localized explanation without internal error details
$.instancestringYesUnique relative identifier /api/v1/requests/{request_id}; not a retrievable resource
$.messagestringYesTemporarily identical to detail for existing clients
$.message_keystringYesStable translation key for changing the displayed language without another request
$.message_paramsobject; {"additionalProperties":true}YesNamed, safely rendered message parameters; never arbitrary HTML
$.request_idstring; {"pattern":"^[0-9a-f]{32}$"}YesServer-generated diagnostic identifier. It contains no login token or credential.
$.statusinteger; {"maximum":599,"minimum":400}Yes—
$.titlestringYesLocalized HTTP status title
$.typestring; {"const":"about:blank"}Yes—
json
{
  "code": "demo",
  "detail": "Demo error detail; inspect the documented code.",
  "instance": "demo",
  "message": "Demo error detail; inspect the documented code.",
  "message_key": "errors.requestFailed",
  "message_params": {},
  "request_id": "00000000000000000000000000000000",
  "status": 403,
  "title": "Demo error",
  "type": "about:blank"
}

application/problem+json

FieldType and limitsRequiredMeaning
$ProblemYes—
$.codestringYesStable machine-readable error code
$.detailstringYesShort localized explanation without internal error details
$.instancestringYesUnique relative identifier /api/v1/requests/{request_id}; not a retrievable resource
$.messagestringYesTemporarily identical to detail for existing clients
$.message_keystringYesStable translation key for changing the displayed language without another request
$.message_paramsobject; {"additionalProperties":true}YesNamed, safely rendered message parameters; never arbitrary HTML
$.request_idstring; {"pattern":"^[0-9a-f]{32}$"}YesServer-generated diagnostic identifier. It contains no login token or credential.
$.statusinteger; {"maximum":599,"minimum":400}Yes—
$.titlestringYesLocalized HTTP status title
$.typestring; {"const":"about:blank"}Yes—

application/problem+json

FieldType and limitsRequiredMeaning
$ProblemYes—
$.codestringYesStable machine-readable error code
$.detailstringYesShort localized explanation without internal error details
$.instancestringYesUnique relative identifier /api/v1/requests/{request_id}; not a retrievable resource
$.messagestringYesTemporarily identical to detail for existing clients
$.message_keystringYesStable translation key for changing the displayed language without another request
$.message_paramsobject; {"additionalProperties":true}YesNamed, safely rendered message parameters; never arbitrary HTML
$.request_idstring; {"pattern":"^[0-9a-f]{32}$"}YesServer-generated diagnostic identifier. It contains no login token or credential.
$.statusinteger; {"maximum":599,"minimum":400}Yes—
$.titlestringYesLocalized HTTP status title
$.typestring; {"const":"about:blank"}Yes—

Retries and asynchronous work

This change does not have a general retry guarantee. If the response is unclear, read the affected resource before trying again. Follow Retry-After waiting times and request new sign-in or action codes when they expire.

Request examples

Replace demo IDs, timestamps and placeholders with your own values. For a retry, keep the same IDs, time and content. These examples do not run requests on this page.

Keep login links, codes, cookies and keys private. Do not print them in logs or share them in support requests.

shell
curl --request POST --cookie '__Host-mb_session=SESSION; __Host-mb_csrf=CSRF' --header 'X-CSRF-Token: CSRF' --header 'Content-Type: application/json' --data '{"workspace_id":"11111111-1111-4111-8111-111111111111","device_ids":["22222222-2222-4222-8222-222222222222"],"operation_id":"33333333-3333-4333-8333-333333333333","action":"pause","version":"COPY_VERSION_FROM_PLAN","confirmed":true,"actions_confirmed":false}' 'https://metribeacon.com/api/v1/monitors/bulk/apply'
python
import requests
response = requests.post('https://metribeacon.com/api/v1/monitors/bulk/apply', cookies={"__Host-mb_session":"SESSION","__Host-mb_csrf":"CSRF"}, headers={"X-CSRF-Token":"CSRF"}, json={'workspace_id': '11111111-1111-4111-8111-111111111111', 'device_ids': ['22222222-2222-4222-8222-222222222222'], 'operation_id': '33333333-3333-4333-8333-333333333333', 'action': 'pause', 'version': 'COPY_VERSION_FROM_PLAN', 'confirmed': True, 'actions_confirmed': False})
response.raise_for_status()
javascript
const response = await fetch("https://metribeacon.com/api/v1/monitors/bulk/apply", {method:"POST", credentials:"same-origin", headers:{"Content-Type":"application/json","X-CSRF-Token":csrf}, body:JSON.stringify({"workspace_id":"11111111-1111-4111-8111-111111111111","device_ids":["22222222-2222-4222-8222-222222222222"],"operation_id":"33333333-3333-4333-8333-333333333333","action":"pause","version":"COPY_VERSION_FROM_PLAN","confirmed":true,"actions_confirmed":false})});
if (!response.ok) throw new Error(String(response.status));
go
package main
import("net/http";"strings";"time")
func main() { req,err:=http.NewRequest("POST","https://metribeacon.com/api/v1/monitors/bulk/apply",strings.NewReader(`{"workspace_id":"11111111-1111-4111-8111-111111111111","device_ids":["22222222-2222-4222-8222-222222222222"],"operation_id":"33333333-3333-4333-8333-333333333333","action":"pause","version":"COPY_VERSION_FROM_PLAN","confirmed":true,"actions_confirmed":false}`));if err!=nil{panic("request failed")};req.AddCookie(&http.Cookie{Name:"__Host-mb_session",Value:"SESSION"});req.AddCookie(&http.Cookie{Name:"__Host-mb_csrf",Value:"CSRF"});req.Header.Set("X-CSRF-Token","CSRF");req.Header.Set("Content-Type","application/json");client:=http.Client{Timeout:10*time.Second};res,err:=client.Do(req);if err!=nil{panic("request failed")};defer res.Body.Close() }