Create manual threshold
POST
Creates a manual threshold in the caller's environment.
Active target uniqueness
Only one active manual threshold can exist for the same target. Creating a second active threshold for the same statTypeId and optional nodeId returns 409.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
target | object | Yes | Metric target that the threshold applies to |
target.statTypeId | string | Yes | Metric identifier to attach the threshold to |
target.nodeId | integer | No | Optional node identifier for a node-specific threshold |
mode | string | Yes | Threshold mode. Supported values: CAPPED, STATIC. See Mode behavior. |
bounds | object | Yes | Lower and upper bound values |
bounds.upper | number | Yes | Upper bound value |
bounds.lower | number | Yes | Lower bound value |
Mode behavior
CAPPEDcaps the machine-learning corridor with the provided bounds and can only tighten the existing machine-learning rangeSTATICdisables machine-learning baselines for the target and uses the provided bounds directly
For example, if machine learning produces lower=20 and upper=100:
CAPPEDwithlower=25andupper=50produces effective boundslower=25andupper=50CAPPEDwithlower=10andupper=50produces effective boundslower=20andupper=50STATICwithlower=10andupper=50useslower=10andupper=50
Target validation
target.statTypeIdmust reference a metric that exists in the caller's environment- If
target.nodeIdis provided, the node must exist and the metric must belong to that node - If
target.nodeIdis omitted, the threshold applies to all nodes in the environment that expose the metric
Response
201 Created
The response is a Manual threshold object.
{
"id": "64b64b64b64b64b64b64b64b",
"target": {
"statTypeId": "11111111-1111-1111-1111-111111111111"
},
"mode": "CAPPED",
"bounds": {
"upper": 10,
"lower": 20
},
"createdAt": "2025-01-02T00:00:00.000Z",
"updatedAt": "2025-01-02T00:00:00.000Z"
}
Errors
400: invalid JSON body, invalid request fields, unknown metric, unknown node, or invalid node and metric combination401: unauthorized403: forbidden409: an active manual threshold already exists for the same target
Example request
{
"target": {
"statTypeId": "11111111-1111-1111-1111-111111111111",
"nodeId": 123
},
"mode": "STATIC",
"bounds": {
"upper": 30,
"lower": 10
}
}