# InspectionService

Inspects middleware. Provides services to discover your topology and resources and synchronize them with the state currently known in Deployit.

POST | /inspection/ | Creates the inspection task.
POST | /inspection/prepare | Initializes the task parameter object for inspection on a CI.
GET | /inspection/prepare/{id:.*?} | Initializes the task parameter object for inspection on a CI.
POST | /inspection/retrieve/{taskId} | Retrieved the inspection results

## POST /inspection/

Creates the inspection task.

Permissions
  `discovery`

Parameters

  Request body | application/xml | Inspection | the inspection parameter object, created by invoking `/inspection/prepare`.

Response body
  String - a reference to a Task ID that can be executed by the TaskService .
  Content type: application/xml

## POST /inspection/prepare

Initializes the task parameter object for inspection on a CI.

Permissions
  `discovery`

Parameters

  Request body | application/xml | ConfigurationItem | The CI to inspect. For example, the root node of a middleware topology.

Response body
  Inspection - an Inspection parameter object.
  Content type: application/xml

## GET /inspection/prepare/{id:.*?}

Initializes the task parameter object for inspection on a CI.

Permissions
  `discovery`

Parameters

  Path | id | String | The id of the CI to inspect. For example, the root node of a middleware topology.

Response body
  Inspection - an Inspection parameter object.
  Content type: application/xml

## POST /inspection/retrieve/{taskId}

Retrieved the inspection results

Parameters

  Path | taskId | String | the Task ID of the task that ran the inspection.

Response body
  List of ConfigurationItem - the list of CIs that were inspected.
  Content type: application/xml