Add trackers to monitor

POST /v1/monitors/{id}/trackers

Moves the account's trackers into this monitor by id ({ tracker_ids: ["trk_..."] }), out of the monitors they are in. A tracker always sits in one monitor and alerts through its delivery settings. It does not create trackers: POST /v1/monitors/{id}/entities does. Supply 1 to 90 IDs. Duplicate IDs count once. Every ID must belong to the account; a missing or foreign ID returns tracker_not_found and none move. attached_count reports the unique moved count.

Parameters

NameLocationDescription
id (required)pathMonitor id.
Idempotency-KeyheaderOne key per intent, 1 to 255 printable ASCII characters (0x21 to 0x7E); anything else is 400 invalid_idempotency_key. Keys are scoped to the account, credential and resource family. The same key and normalized method, path and body returns the committed response with Idempotency-Replayed: true. A changed intent within the same family returns 409 idempotency_conflict. Monitor and tracker families have independent namespaces. Secret recovery is limited as described by the operation.

Request body

{
  "content": {
    "application/json": {
      "schema": {
        "type": "object",
        "properties": {
          "tracker_ids": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1
            },
            "minItems": 1,
            "maxItems": 90,
            "description": "Ids of the account's trackers (\"trk_...\") to move into this monitor from the monitors they are in. At most 90 IDs per request; duplicates count once. All IDs must belong to the account or none move."
          }
        },
        "required": [
          "tracker_ids"
        ],
        "additionalProperties": false
      }
    }
  }
}

Responses

200 Success
{
  "description": "Success",
  "headers": {
    "X-Request-Id": {
      "$ref": "#/components/headers/X-Request-Id"
    },
    "X-Arcmira-Version": {
      "$ref": "#/components/headers/X-Arcmira-Version"
    },
    "RateLimit-Limit": {
      "$ref": "#/components/headers/RateLimit-Limit"
    },
    "RateLimit-Remaining": {
      "$ref": "#/components/headers/RateLimit-Remaining"
    },
    "RateLimit-Reset": {
      "$ref": "#/components/headers/RateLimit-Reset"
    },
    "Idempotency-Replayed": {
      "$ref": "#/components/headers/Idempotency-Replayed"
    }
  },
  "content": {
    "application/json": {
      "schema": {
        "$ref": "#/components/schemas/MonitorAddTrackersResponse"
      }
    }
  }
}
400 InvalidRequest
{
  "$ref": "#/components/responses/InvalidRequest"
}
401 AuthenticationError
{
  "$ref": "#/components/responses/AuthenticationError"
}
403 PermissionError
{
  "$ref": "#/components/responses/PermissionError"
}
404 NotFound
{
  "$ref": "#/components/responses/NotFound"
}
409 Conflict. idempotency_conflict means the Idempotency-Key was finalized with a different request intent.
{
  "description": "Conflict. idempotency_conflict means the Idempotency-Key was finalized with a different request intent.",
  "headers": {
    "X-Request-Id": {
      "$ref": "#/components/headers/X-Request-Id"
    },
    "X-Arcmira-Version": {
      "$ref": "#/components/headers/X-Arcmira-Version"
    }
  },
  "content": {
    "application/json": {
      "schema": {
        "$ref": "#/components/schemas/Error"
      }
    }
  }
}
429 RateLimited
{
  "$ref": "#/components/responses/RateLimited"
}
500 ServerError
{
  "$ref": "#/components/responses/ServerError"
}

Operation definition

{
  "tags": [
    "Monitors"
  ],
  "operationId": "add_monitor_trackers",
  "summary": "Add trackers to monitor",
  "description": "Moves the account's trackers into this monitor by id ({ tracker_ids: [\"trk_...\"] }), out of the monitors they are in. A tracker always sits in one monitor and alerts through its delivery settings. It does not create trackers: POST /v1/monitors/{id}/entities does. Supply 1 to 90 IDs. Duplicate IDs count once. Every ID must belong to the account; a missing or foreign ID returns tracker_not_found and none move. attached_count reports the unique moved count.",
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "parameters": [
    {
      "schema": {
        "type": "string",
        "description": "Monitor id."
      },
      "required": true,
      "description": "Monitor id.",
      "name": "id",
      "in": "path"
    },
    {
      "schema": {
        "type": "string"
      },
      "required": false,
      "name": "Idempotency-Key",
      "in": "header",
      "example": "8b2f6c3e-4d1a-4e7b-9c05-2f6a1b7d3e90",
      "description": "One key per intent, 1 to 255 printable ASCII characters (0x21 to 0x7E); anything else is 400 invalid_idempotency_key. Keys are scoped to the account, credential and resource family. The same key and normalized method, path and body returns the committed response with Idempotency-Replayed: true. A changed intent within the same family returns 409 idempotency_conflict. Monitor and tracker families have independent namespaces. Secret recovery is limited as described by the operation."
    }
  ],
  "requestBody": {
    "content": {
      "application/json": {
        "schema": {
          "type": "object",
          "properties": {
            "tracker_ids": {
              "type": "array",
              "items": {
                "type": "string",
                "minLength": 1
              },
              "minItems": 1,
              "maxItems": 90,
              "description": "Ids of the account's trackers (\"trk_...\") to move into this monitor from the monitors they are in. At most 90 IDs per request; duplicates count once. All IDs must belong to the account or none move."
            }
          },
          "required": [
            "tracker_ids"
          ],
          "additionalProperties": false
        }
      }
    }
  },
  "responses": {
    "200": {
      "description": "Success",
      "headers": {
        "X-Request-Id": {
          "$ref": "#/components/headers/X-Request-Id"
        },
        "X-Arcmira-Version": {
          "$ref": "#/components/headers/X-Arcmira-Version"
        },
        "RateLimit-Limit": {
          "$ref": "#/components/headers/RateLimit-Limit"
        },
        "RateLimit-Remaining": {
          "$ref": "#/components/headers/RateLimit-Remaining"
        },
        "RateLimit-Reset": {
          "$ref": "#/components/headers/RateLimit-Reset"
        },
        "Idempotency-Replayed": {
          "$ref": "#/components/headers/Idempotency-Replayed"
        }
      },
      "content": {
        "application/json": {
          "schema": {
            "$ref": "#/components/schemas/MonitorAddTrackersResponse"
          }
        }
      }
    },
    "400": {
      "$ref": "#/components/responses/InvalidRequest"
    },
    "401": {
      "$ref": "#/components/responses/AuthenticationError"
    },
    "403": {
      "$ref": "#/components/responses/PermissionError"
    },
    "404": {
      "$ref": "#/components/responses/NotFound"
    },
    "409": {
      "description": "Conflict. idempotency_conflict means the Idempotency-Key was finalized with a different request intent.",
      "headers": {
        "X-Request-Id": {
          "$ref": "#/components/headers/X-Request-Id"
        },
        "X-Arcmira-Version": {
          "$ref": "#/components/headers/X-Arcmira-Version"
        }
      },
      "content": {
        "application/json": {
          "schema": {
            "$ref": "#/components/schemas/Error"
          }
        }
      }
    },
    "429": {
      "$ref": "#/components/responses/RateLimited"
    },
    "500": {
      "$ref": "#/components/responses/ServerError"
    }
  }
}