{
  "openapi": "3.0.1",
  "info": {
    "title": "IBX SmartView System Alert APIs",
    "description": "Empower yourself with IBX SmartView System Alert APIs to access information on the alarms, now \nknown as system alerts. Given a multiple criteria, this API retrieves all the system alerts.\nWe recommend customers utilize the POST call, however both calls are supported and functional.",
    "termsOfService": "https://www.equinix.com/about/legal/terms",
    "contact": {
      "name": "Equinix API Support",
      "url": "https://docs.equinix.com/api-support.htm"
    },
    "version": "2.0.1"
  },
  "servers": [
    {
      "url": "https://api.equinix.com",
      "description": "Production server"
    }
  ],
  "security": [
    {
      "BearerAuth": []
    }
  ],
  "tags": [
    {
      "name": "DCIM System Alert",
      "description": "Access System Alert Information"
    }
  ],
  "paths": {
    "/smartview/v2/systemAlerts/search": {
      "get": {
        "tags": [
          "DCIM System Alert"
        ],
        "summary": "system alerts search",
        "description": "Returns all system alerts in a paginated way\nallows narrowing returned results by submitting additional search filters.\n\nAllowed search filters.",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer"
            },
            "description": "Number of records to retrieve per request.",
            "required": true,
            "example": "100"
          },
          {
            "name": "offset",
            "in": "query",
            "schema": {
              "type": "integer"
            },
            "description": "Record Number you want start to retrieve from (0..N)",
            "required": true,
            "example": "0"
          },
          {
            "name": "status",
            "in": "query",
            "schema": {
              "type": "string"
            },
            "description": "Alert status: ACTIVE or INACTIVE",
            "required": false,
            "example": "ACTIVE"
          },
          {
            "name": "assetClassification",
            "in": "query",
            "schema": {
              "type": "string"
            },
            "description": "The class of assets this asset belongs to: Mechanical/Electrical/Environmental",
            "required": false,
            "example": "Mechanical"
          },
          {
            "name": "edgeCollectedOn",
            "in": "query",
            "schema": {
              "type": "string"
            },
            "description": "Returns the alarms after the passed time",
            "required": false,
            "example": "2023-11-30T05:08:39.345Z"
          }
        ],
        "operationId": "postAlerts",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaginatedResponseAlertReadModel"
                }
              }
            }
          },
          "400": {
            "description": "Bad request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiErrorResponse"
                },
                "examples": {
                  "objectExample": {
                    "$ref": "#/components/examples/ApiError400"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiErrorResponse"
                },
                "examples": {
                  "objectExample": {
                    "$ref": "#/components/examples/ApiError401"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiErrorResponse"
                },
                "examples": {
                  "objectExample": {
                    "$ref": "#/components/examples/ApiError403"
                  }
                }
              }
            }
          },
          "422": {
            "description": "Unprocessable entity",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiErrorResponse"
                },
                "examples": {
                  "arrayExample": {
                    "$ref": "#/components/examples/ApiError422"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiErrorResponse"
                },
                "examples": {
                  "objectExample": {
                    "$ref": "#/components/examples/ApiError500"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "DCIM System Alert"
        ],
        "summary": "system alerts search",
        "description": "Returns all system alerts in a paginated way\nallows narrowing returned results by submitting additional search filters.\n\nAllowed search filters\n<table>\n  <tr>\n    <th>Property</th>\n    <th>Operator</th>\n    <th>Description</th>\n  </tr>\n  <tr>\n    <td>/status</td>\n    <td>=, IN</td>\n    <td>Alert status, INACTIVE or ACTIVE</td>\n  </tr>\n  <tr>\n    <td>/assetTagUid</td>\n    <td>=, IN</td>\n    <td>Asset tag point unique id, example: PA8A.CB-CRITICAL-DB2:tripped</td>\n  </tr>\n  <tr>\n    <td>/assetTagDisplayName</td>\n    <td>=, IN</td>\n    <td>Active tag reading display value, example: ALARM</td>\n  </tr>\n  <tr>\n    <td>/configuration/thresholdType</td>\n    <td>=, IN</td>\n    <td>Example: DIGITAL</td>\n  </tr>\n  <tr>\n    <td>/configuration/conditionName</td>\n    <td>=, IN</td>\n    <td>Name given to the alarm condition. Example: ALARM</td>\n  </tr>\n  <tr>\n    <td>/asset/ibx</td>\n    <td>=, IN</td>\n    <td>Name of the IBX for which data is being requested, example: PA8A</td>\n  </tr>\n  <tr>\n    <td>/asset/assetUid</td>\n    <td>=, IN, LIKE</td>\n    <td>Asset unique ID, example: PA8A.CB-CRITICAL-DB2:tripped#DIGITAL:ALARM</td>\n  </tr>\n  <tr>\n    <td>/activeProcessing/edgeCollectedOn</td>\n    <td>=, >=, <=</td>\n    <td>When tag reading was collected on source, example: 2022-09-23T13:40:53.449276Z</td>\n  </tr>\n  <tr>\n    <td>/asset/assetUnderMaintenance</td>\n    <td>=, IN</td>\n    <td>Asset was under maintenance during alert processing, example: false</td>\n  </tr>\n  <tr>\n    <td>/asset/assetType</td>\n    <td>=, IN</td>\n    <td>Indicates the template name for the asset, example: Circuit Breaker with Metering</td>\n  </tr>\n  <tr>\n    <td>/asset/assetClassification</td>\n    <td>=, IN</td>\n    <td>The class of assets this asset belongs to. Asset classification is electrical or mechanical, example: Electrical</td>\n  </tr>\n</table>\n\nAllowed search request sort options:\n<ul>\n  <li style=\"list-style-type: circle\">/status</li>\n  <li style=\"list-style-type: circle\">/assetTagUid</li>\n  <li style=\"list-style-type: circle\">/assetTagDisplayName</li>\n  <li style=\"list-style-type: circle\">/configuration/thresholdType</li>\n  <li style=\"list-style-type: circle\">/configuration/conditionName</li>\n  <li style=\"list-style-type: circle\">/asset/ibx</li>\n  <li style=\"list-style-type: circle\">/asset/assetUid</li>\n  <li style=\"list-style-type: circle\">/activeProcessing/edgeCollectedOn</li>\n  <li style=\"list-style-type: circle\">/asset/assetUnderMaintenance</li>\n  <li style=\"list-style-type: circle\">/asset/assetType</li>\n  <li style=\"list-style-type: circle\">/asset/assetClassification</li>\n</ul>\n",
        "operationId": "getAlerts",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SearchRequest"
              },
              "examples": {
                "objectExample": {
                  "$ref": "#/components/examples/SearchRequest"
                }
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaginatedResponseAlertReadModel"
                }
              }
            }
          },
          "400": {
            "description": "Bad request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiErrorResponse"
                },
                "examples": {
                  "objectExample": {
                    "$ref": "#/components/examples/ApiError400"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiErrorResponse"
                },
                "examples": {
                  "objectExample": {
                    "$ref": "#/components/examples/ApiError403"
                  }
                }
              }
            }
          },
          "422": {
            "description": "Unprocessable entity",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiErrorResponse"
                },
                "examples": {
                  "arrayExample": {
                    "$ref": "#/components/examples/ApiError422"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiErrorResponse"
                },
                "examples": {
                  "objectExample": {
                    "$ref": "#/components/examples/ApiError500"
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "SearchCondition": {
        "required": [
          "operator",
          "property",
          "values"
        ],
        "type": "object",
        "properties": {
          "property": {
            "type": "string",
            "description": "Field name",
            "example": "status"
          },
          "operator": {
            "type": "string",
            "description": "Condition used to compare the property and the value(s).",
            "example": "=",
            "enum": [
              "<=",
              ">=",
              "LIKE",
              "IN",
              "=",
              "!="
            ]
          },
          "values": {
            "maxItems": 2147483647,
            "minItems": 1,
            "type": "array",
            "description": "Array of values to be compared with the field.",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "SearchFilter": {
        "type": "object",
        "properties": {
          "and": {
            "type": "array",
            "description": "Array of search conditions.",
            "items": {
              "$ref": "#/components/schemas/SearchCondition"
            }
          },
          "or": {
            "type": "array",
            "description": "Array of search conditions.",
            "items": {
              "$ref": "#/components/schemas/SearchCondition"
            }
          }
        }
      },
      "SearchPagination": {
        "required": [
          "limit",
          "offset"
        ],
        "type": "object",
        "properties": {
          "offset": {
            "minimum": 0,
            "type": "integer",
            "description": "Starting index of an item. First item is offset 0. Default value for offset is 0.",
            "format": "int64",
            "example": 0
          },
          "limit": {
            "type": "integer",
            "description": "The maximum number of items to return starting from the index denotes by the offset item. Default value for limit is 20. Upper limit is 1000",
            "format": "int32",
            "example": 20
          }
        }
      },
      "SearchRequest": {
        "type": "object",
        "properties": {
          "filter": {
            "$ref": "#/components/schemas/SearchFilter"
          },
          "pagination": {
            "$ref": "#/components/schemas/SearchPagination"
          },
          "sort": {
            "type": "array",
            "description": "Array of sorting conditions.",
            "items": {
              "$ref": "#/components/schemas/SearchSort"
            }
          }
        }
      },
      "SearchSort": {
        "required": [
          "property"
        ],
        "type": "object",
        "properties": {
          "direction": {
            "type": "string",
            "description": "Direction of sorting. Default is ASC.",
            "example": "DESC",
            "enum": [
              "ASC",
              "DESC"
            ]
          },
          "property": {
            "type": "string",
            "description": "Property used for sorting the data.",
            "example": "/asset/ibx"
          }
        }
      },
      "ApiError": {
        "required": [
          "errorCode",
          "errorMessage"
        ],
        "type": "object",
        "properties": {
          "errorCode": {
            "type": "string",
            "description": "Application error code.",
            "example": "EQ-1912306"
          },
          "errorMessage": {
            "type": "string",
            "description": "Application error message",
            "example": "Wrong customer id"
          },
          "correlationId": {
            "type": "string",
            "description": "Correlation ID without any sensitive or meaningful information.",
            "example": "b1ea22f8-34ae-6f67-4a33-b4f5ec99a1c6"
          },
          "details": {
            "type": "string",
            "description": "More information on errors.",
            "example": "Wrong value of ph#. Correct format is xxx-xxx-xxxx"
          },
          "help": {
            "type": "string",
            "description": "URL to a help page for the corresponding errorCode.\nThe exact base path for help URL is not yet decided. <domain>/help/error is a placeholder.\n",
            "example": "https://<domain>/help/error/EQ-1912306"
          },
          "additionalInfo": {
            "type": "array",
            "description": "Contains application specific information for this error. The object inside this array can have any number of application specific properties.\nIt has two reserved properties (they are optional):\n- property - This refers to the name of one of the following that is passed when invoking the API - query parameter, path parameter, JSON property of HTTP request body. It is used if there is a need to explicitly hightlight the name of the property.\n- reason - Error message specific to the corresponding property.\n",
            "items": {
              "$ref": "#/components/schemas/ErrorAdditionalInfo"
            }
          }
        }
      },
      "ErrorAdditionalInfo": {
        "type": "object",
        "properties": {
          "constraintCode": {
            "type": "string",
            "description": "Violated constraint name (simple class name). Can be used to render and localize the validation message by the consumer component such as a frontend application.",
            "example": "InvalidFormat"
          },
          "root": {
            "type": "string",
            "description": "The root bean. Multiple parameters can be validated during a single validation call, this parameter indicates the validated parameter name (example pagination, requestBody etc.).",
            "example": "requestBody"
          },
          "property": {
            "type": "string",
            "description": "Represents the JSON path of the property that failed validation. Can be used to map the failed property to the UI input.",
            "example": "id"
          },
          "reason": {
            "type": "string",
            "description": "Server side constraint violation message. Can be used as a translation fallback. The message will always be in English.",
            "example": "Unable to deserialize input value to destination type."
          }
        }
      },
      "ApiErrorResponse": {
        "type": "array",
        "items": {
          "$ref": "#/components/schemas/ApiError"
        }
      },
      "AlertReadModel": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer",
            "description": "database ID",
            "format": "int64",
            "example": 420
          },
          "alertUid": {
            "type": "string",
            "description": "alert unique ID",
            "example": "PA8A.CB-CRITICAL-DB2:tripped#DIGITAL:ALARM"
          },
          "traceUid": {
            "type": "string",
            "description": "alert trace unique ID related to status change",
            "example": "1652686263561/PA8A.CB-CRITICAL-DB2:tripped#DIGITAL:ALARM"
          },
          "assetTagUid": {
            "type": "string",
            "description": "asset tag point unique id",
            "example": "PA8A.CB-CRITICAL-DB2:tripped"
          },
          "assetTagDisplayName": {
            "type": "string",
            "description": "asset tag point display name",
            "example": "Tripped"
          },
          "status": {
            "type": "string",
            "description": "alert status",
            "example": "INACTIVE",
            "enum": [
              "ACTIVE",
              "INACTIVE"
            ]
          },
          "value": {
            "$ref": "#/components/schemas/ValueReadModel"
          },
          "asset": {
            "$ref": "#/components/schemas/AssetReadModel"
          },
          "configuration": {
            "$ref": "#/components/schemas/ConfigurationReadModel"
          },
          "activeProcessing": {
            "$ref": "#/components/schemas/ProcessingTimeReadModel"
          },
          "inactiveProcessing": {
            "$ref": "#/components/schemas/ProcessingTimeReadModel"
          }
        }
      },
      "AssetReadModel": {
        "type": "object",
        "properties": {
          "ibx": {
            "type": "string",
            "description": "ibx",
            "example": "PA8A"
          },
          "assetUid": {
            "type": "string",
            "description": "asset unique id",
            "example": "PA8A.CB-CRITICAL-DB2"
          },
          "assetType": {
            "type": "string",
            "description": "asset type",
            "example": "Circuit Breaker with Metering"
          },
          "assetClassification": {
            "type": "string",
            "description": "asset classification",
            "example": "Electrical"
          },
          "assetRegion": {
            "type": "string",
            "description": "asset region",
            "example": "EMEA"
          },
          "assetUnderMaintenance": {
            "type": "boolean",
            "description": "asset was under maintenance during alert processing",
            "example": false
          }
        }
      },
      "ConfigurationReadModel": {
        "type": "object",
        "properties": {
          "thresholdValue": {
            "type": "string",
            "description": "threshold value",
            "example": "0"
          },
          "thresholdValueDisplayName": {
            "type": "string",
            "description": "threshold display value",
            "example": "ALARM"
          },
          "unitOfMeasurement": {
            "type": "string",
            "description": "unit of measurement",
            "example": "i.e °C"
          },
          "thresholdType": {
            "type": "string",
            "description": "threshold type",
            "example": "DIGITAL",
            "enum": [
              "DIGITAL",
              "ABSOLUTE",
              "DEVIATION",
              "MULTI_STATE"
            ]
          },
          "conditionName": {
            "type": "string",
            "description": "condition name",
            "example": "ALARM",
            "enum": [
              "ALARM",
              "WARNING",
              "VERY_LOW",
              "LOW",
              "HIGH",
              "VERY_HIGH"
            ]
          },
          "customerVisible": {
            "type": "boolean",
            "description": "asset is customer visible",
            "example": false
          },
          "configurationVersion": {
            "type": "string",
            "description": "alert configuration version",
            "example": "1.0"
          }
        }
      },
      "PaginatedResponseAlertReadModel": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "description": "Array of the alerts.",
            "items": {
              "$ref": "#/components/schemas/AlertReadModel"
            }
          },
          "pagination": {
            "$ref": "#/components/schemas/Pagination"
          }
        }
      },
      "Pagination": {
        "type": "object",
        "properties": {
          "offset": {
            "type": "integer",
            "description": "Starting index of an item. First item is offset 0. Default value for offset is 0.",
            "format": "int64",
            "example": 20
          },
          "limit": {
            "type": "integer",
            "description": "The maximum number of items to return starting from the index denotes by the offset item. Default value for limit is 20. Upper limit is 1000",
            "format": "int64",
            "example": 10
          },
          "total": {
            "type": "integer",
            "description": "Total number of available items",
            "format": "int64",
            "example": 500
          },
          "next": {
            "type": "string",
            "description": "Offset for next page of the data. If there is no next value (i.e., reached the last item), then this property should not be present in the response.",
            "example": "30"
          },
          "previous": {
            "type": "string",
            "description": "Offset for previous page of the data. If there is no previous page (i.e., first page is returned in the current response), then this property should not be present in the response.",
            "example": "10"
          }
        }
      },
      "ProcessingTimeReadModel": {
        "type": "object",
        "properties": {
          "edgeCollectedOn": {
            "type": "string",
            "description": "when tag reading was collected on source",
            "format": "date-time",
            "example": "2023-01-11T16:06:10.082Z"
          },
          "tagCalculationJobProcessedOn": {
            "type": "string",
            "description": "when tag reading was processed by tag-calculation rtp",
            "format": "date-time",
            "example": "2023-01-11T16:06:10.082Z"
          },
          "processingStartOn": {
            "type": "string",
            "description": "when tag reading was accepted by alert rtp",
            "format": "date-time",
            "example": "2023-01-11T16:06:10.082Z"
          },
          "processingEndOn": {
            "type": "string",
            "description": "when tag reading was processed by alert rtp",
            "format": "date-time",
            "example": "2023-01-11T16:06:10.082Z"
          },
          "publishedOn": {
            "type": "string",
            "description": "when tag reading was published by alert rtp",
            "format": "date-time",
            "example": "2023-01-11T16:06:10.082Z"
          }
        }
      },
      "ValueReadModel": {
        "type": "object",
        "properties": {
          "alertTagValue": {
            "type": "string",
            "description": "tag reading raw value",
            "example": "1"
          },
          "alertTagValueDisplayName": {
            "type": "string",
            "description": "tag reading display value",
            "example": "NORMAL"
          },
          "activeAlertTagValueDisplayName": {
            "type": "string",
            "description": "active tag reading display value",
            "example": "ALARM"
          },
          "currentTagValue": {
            "type": "string",
            "description": "current tag reading display value",
            "example": "NORMAL"
          }
        }
      }
    },
    "examples": {
      "SearchRequest": {
        "summary": "search request with multiple filters",
        "value": {
          "filter": {
            "and": [
              {
                "property": "/status",
                "operator": "=",
                "values": [
                  "ACTIVE"
                ]
              },
              {
                "property": "/asset/ibx",
                "operator": "IN",
                "values": [
                  "MI1",
                  "NY1",
                  "WAW2"
                ]
              },
              {
                "property": "/asset/assetUid",
                "operator": "=",
                "values": [
                  "MI1.arc-reactor"
                ]
              },
              {
                "property": "/assetTagUid",
                "operator": "=",
                "values": [
                  "MI1.arc-reactor:alarm"
                ]
              },
              {
                "property": "/assetTagDisplayName",
                "operator": "=",
                "values": [
                  "Arc Reactor Alarm"
                ]
              },
              {
                "property": "/asset/assetType",
                "operator": "=",
                "values": [
                  "Arc Reactor"
                ]
              },
              {
                "property": "/asset/assetClassification",
                "operator": "=",
                "values": [
                  "Mechanical"
                ]
              },
              {
                "property": "/asset/assetUnderMaintenance",
                "operator": "=",
                "values": [
                  "false"
                ]
              },
              {
                "property": "/state",
                "operator": "=",
                "values": [
                  "OPEN"
                ]
              },
              {
                "property": "/configuration/thresholdType",
                "operator": "=",
                "values": [
                  "DIGITAL"
                ]
              },
              {
                "property": "/configuration/conditionName",
                "operator": "=",
                "values": [
                  "ALARM"
                ]
              },
              {
                "property": "activeProcessing.edgeCollectedOn",
                "operator": ">=",
                "values": [
                  "2000-03-25T04:03:06.000Z"
                ]
              }
            ]
          },
          "pagination": {
            "offset": 0,
            "limit": 50
          }
        }
      },
      "ApiError400": {
        "summary": "bad request",
        "value": [
          {
            "errorCode": "EQ-50001400",
            "errorMessage": "Bad request",
            "correlationId": "dc1fe6b2-4ee1-11ed-bdc3-0242ac120002",
            "details": "",
            "help": "Please fix submitted payload"
          }
        ]
      },
      "ApiError401": {
        "summary": "unauthorized error",
        "value": [
          {
            "errorDomain": "api-platform",
            "errorTitle": "Access Token expired",
            "errorCode": "401",
            "developerMessage": "Please pass a valid access token",
            "errorMessage": "Access Token expired"
          }
        ]
      },
      "ApiError403": {
        "summary": "authorization error",
        "value": [
          {
            "errorCode": "EQ-5000002",
            "errorMessage": "Forbidden",
            "correlationId": "dc1fe6b2-4ee1-11ed-bdc3-0242ac120002",
            "details": "Access is denied"
          }
        ]
      },
      "ApiError422": {
        "summary": "wrong search filters",
        "value": [
          {
            "errorCode": "EQ-5000023",
            "errorMessage": "Unprocessable Entity",
            "correlationId": "dc1fe6b2-4ee1-11ed-bdc3-0242ac120002",
            "details": "The submitted payload does not meet validation criteria.",
            "help": "Please fix submitted payload according to additionalInfo.",
            "additionalInfo": [
              {
                "constraintCode": "AllowedSearchRequest",
                "root": "searchRequest",
                "property": "and[ 17 ]",
                "reason": "Unsupported search field operator `customers.ucid` `LIKE`"
              }
            ]
          }
        ]
      },
      "ApiError500": {
        "summary": "internal error",
        "value": [
          {
            "errorCode": "EQ-5000030",
            "errorMessage": "Internal Server Error",
            "correlationId": "dc1fe6b2-4ee1-11ed-bdc3-0242ac120002",
            "details": "The server was unable to process the request due to an internal server error. Additional information can be found in server logs.",
            "help": "Please contact vendor."
          }
        ]
      }
    },
    "securitySchemes": {
      "BearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "token generated from /v1/auth/satoken endpoint"
      }
    }
  }
}
