GET /api/config_reports
List all reports

Params

Param name Description
location_id
optional

Set the current location context for the request

Validations:

  • Integer

organization_id
optional

Set the current organization context for the request

Validations:

  • Integer

search
optional

filter results

Validations:

  • String

order
optional

Sort field and order, eg. ‘id DESC’

Validations:

  • String

page
optional

Page number, starting at 1

Validations:

  • Must be a number.

per_page
optional

Number of results per page to return, ‘all’ to return all results

Validations:

  • Must match regular expression /\A([1-9]\d|all)\Z$/.

Search fields

Field name Type Possible values
applied integer
environment string
eventful true, false
failed integer
failed_restarts integer
host string
host_id integer
hostgroup string
hostgroup_fullname string
hostgroup_title string
last_report datetime
location string
log text
organization string
origin string
pending integer
reported datetime
resource text
restarted integer
skipped integer

GET /api/config_reports/:id
Show a report

Params

Param name Description
location_id
optional

Set the current location context for the request

Validations:

  • Integer

organization_id
optional

Set the current organization context for the request

Validations:

  • Integer

id
required

Validations:

  • string from 2 to 128 characters containing only alphanumeric characters, space, ‘‘, ‘-’ with no leading or trailing space..


POST /api/config_reports
Create a report

Params

Param name Description
location_id
optional

Set the current location context for the request

Validations:

  • Integer

organization_id
optional

Set the current organization context for the request

Validations:

  • Integer

config_report
required

Validations:

  • Hash

config_report[host]
required

Hostname or certname

Validations:

  • String

config_report[reported_at]
required

UTC time of report

Validations:

  • String

config_report[status]
required

Hash of status type totals

Validations:

  • Hash

config_report[metrics]
required

Hash of report metrics, can be just {}

Validations:

  • Hash

config_report[logs]
optional , nil allowed

Optional array of log hashes

Validations:

  • Must be an array of any type


DELETE /api/config_reports/:id
Delete a report

Params

Param name Description
location_id
optional

Set the current location context for the request

Validations:

  • Integer

organization_id
optional

Set the current organization context for the request

Validations:

  • Integer

id
required

Validations:

  • String


GET /api/hosts/:host_id/config_reports/last
Show the last report for a host

Params

Param name Description
location_id
optional

Set the current location context for the request

Validations:

  • Integer

organization_id
optional

Set the current organization context for the request

Validations:

  • Integer

id
required

Validations:

  • string from 2 to 128 characters containing only alphanumeric characters, space, ‘‘, ‘-’ with no leading or trailing space..