RESTful API Overview

Sensu API

The Sensu API provides access to monitoring data collected by Sensu, such as a client registry, check results, and event data. The API can be used to request adhoc check executions, and resolve events, among other things.

RESTful JSON API

The Sensu API is JSON-based RESTful API. Familiarity with (or willingness to Google) industry standard RESTful API behaviors – including HTTP response codes – are strongly recommended.

Reference documentation

Response Content Filtering

Sensu API endpoints that support the GET HTTP method support HTTP response content filtering on one or more Sensu attributes. To use response content filtering, construct the URL for your API request using a dot notation query beginning with filter.

For example, to return only events that match the production environment and ops contact, use the following request.

curl -i 'http://127.0.0.1:4567/events?filter.client.environment=production&filter.check.contact=ops'

Response filtering is only available for string values; integers (for example: filter.check.status=2) are not supported.