Search Alerts

Filter and Search alerts of the tenant.

Query String example usage

  • queryString is Query Parameter creates simple and complex filters
  • Basic filtering with no page limits. eg Filter all Critical Alerts
    • {base-url}/api/v2/tenants/<tenantId>/sites/search?queryString=states:CRITICAL,WARNING
  • Filtering with page limits . eg Get 500 Suppressed alerts in the first page
    • {base-url}/api/v2/tenants/<tenantId>/alerts/search?pageSize=500&pageNo=1&sortName=id&isDescendingOrder=false&queryString=actions:SUPPRESSED
  • Filtering with multiple conditions . eg Get 500 Ticketed alerts in the first page occured in between these dates in descending order
    • {base-url}/api/v2/tenants/<tenantId>/alerts/search?pageSize=500&pageNo=1&sortName=id&isDescendingOrder=false&queryString=actions:TICKETED%2BstartDate:2016-02-24T09:19:47%200000%2BendDate:2016-02-26T10:20:47%200000
  • Incorrect usage of queryString
    • <base-url>/api/v2/tenants/<tenantId>/alerts/search?pageSize=500&pageNo=1&sortName=id&isDescendingOrder=false&queryString=ticketed:True
    • ticketed is a value here not an query parameter attribute, hence query fails
    • If the resultset has all the values irrespective of query, this would mean failed query like above example

Path Parameters

  • tenantIdstringrequired

    Describes the clientId or mspId of the tenant

Query Parameters

  • pageNointeger

    Current pagination number

  • pageSizeinteger

    No of records in each page

  • isDescendingOrderboolean

    Pagination data ordering: true for descending false for ascending

  • sortNamestring

    Field name on which paginated data is ordered

    Enum:
    idtsstartaltimec_namep_namesourcertypername
  • queryStringstringrequired

    Generic query string to be prepared using below query parameters See "api-overview"

  • viewIDstring

  • statusHistorystring

  • statesstring

    Current state of the alert

    Enum:
    OkWarningCriticalInfo
  • startDatestring

    Filter the alert with alert base. startDate denotes the from date. Example: 2016-02-24T09:19:47 0000 (GMT)

  • endDatestring

    endDate denotes to date. Example: 2016-02-26T10:20:47 0000 (GMT)

  • uniqueIdstring

    uuid of the alert.

  • deviceStatusstring

    Status of the device

    Enum:
    manageunmanage
  • resourceTypestring

    Type of resource. Example:LOAD_BALANCER, SQS, EBS, DEVICE, SNS, REDSHIFT, SERVICE

  • resourceIdsstring

    ID of a resource. Example: DEV0000015754,148e892d-84ce-496c-a123-f91e1a8a3f7d.

  • actionsstring

    Actions performed on the alert. Example: ACKNOWLEDGED, TICKETED.

    Enum:
    ACKNOWLEDGEDTICKETEDCLOSEDIGNORESUPPRESSEDOPENPURGEDCORRELATED
  • alertTypesstring

    Types of alerts

    Enum:
    MonitoringMaintenanceApplianceAgentScheduled MaintenanceObsoleteIntegration Failure
  • metricsstring

    Metric type of the alert. Example: PING, SNMP Response.

  • durationstring

    Duration of alert. Duration is represented in Number of Days Example: 1, 7.

  • alertTimeBasestring

    Search for the alert based on the updated or created time of an alert. Example: updated.

    Enum:
    updatedcreated
  • clientIdsstring

    ID of clients. Example: client_1, client_2,526674ad-be06-4bdc-9634-e3b8c78b906e. Separate the IDs with a comma.

  • ticketIdstring

    ID of the ticket to which the alert is attached. Example: INC0000000001

  • appsstring

    Apps from which the alert is generated. Example: Email, Nagios

Responses

  • resultsarray

  • totalResultsinteger

  • orderBystring

  • pageNointeger

  • pageSizeinteger

  • totalPagesinteger

  • nextPageboolean

  • previousPageNointeger

  • descendingOrderboolean

Loading Examples...