There are two modes of authentication:
Returns all credentials parameters.
The available parameters to search / sort_by are:
| limit | integer (RequestParameters.limit) >= 1 Example: limit=20 Max items per pages |
| page | integer (RequestParameters.page) >= 1 Example: page=1 Number of the page requested |
| sort_by | object (RequestParameters.sortBy) Example: sort_by={"id":"ASC"} Used to sort the request |
| search | object (RequestParameters.search) Example: search={"name":"localhost"} Used to search with specifics parameters |
{- "result": [
- {
- "id": 0,
- "type_id": 0,
- "name": "string",
- "parameters": [
- {
- "name": "string",
- "value": "string",
- "description": "string",
- "is_hidden": true,
- "is_locked": true,
- "is_mandatory": true,
- "is_password": true
}
]
}
], - "meta": {
- "page": 0,
- "limit": 0,
- "search": { },
- "sort_by": { },
- "total": 0
}
}| credential_id required | integer <int64> Id of credential parameters |
{- "id": 0,
- "type_id": 0,
- "name": "string",
- "parameters": [
- {
- "name": "string",
- "value": "string",
- "description": "string",
- "is_hidden": true,
- "is_locked": true,
- "is_mandatory": true,
- "is_password": true
}
]
}| credential_id required | integer <int64> Id of the credential parameters |
Credential parameters
| name | string Name of the credential |
Array of objects |
{- "name": "string",
- "parameters": [
- {
- "name": "string",
- "value": "string"
}
]
}{- "code": 403,
- "message": "You are not authorized to access this resource"
}Returns all credentials parameters according to the provider type.
The available parameters to search / sort_by are:
| type_id required | integer <int64> Type's id of the provider linked to the credential parameters |
{- "result": [
- {
- "id": 0,
- "type_id": 0,
- "name": "string",
- "parameters": [
- {
- "name": "string",
- "value": "string",
- "description": "string",
- "is_hidden": true,
- "is_locked": true,
- "is_mandatory": true,
- "is_password": true
}
]
}
], - "meta": {
- "page": 0,
- "limit": 0,
- "search": { },
- "sort_by": { },
- "total": 0
}
}| type_id required | integer <int64> Type id of the provider linked to the credential parameters |
Credential parameters
| name | string Name of the credential |
Array of objects (CredentialParameter.add) |
{- "name": "string",
- "parameters": [
- {
- "name": "string",
- "value": "string"
}
]
}{- "code": 403,
- "message": "You are not authorized to access this resource"
}| type_id required | integer <int64> Type's id of the provider to which the credentials templates are linked |
[- {
- "name": "string",
- "description": "string",
- "value": "string",
- "is_hidden": true,
- "is_locked": true,
- "is_mandatory": true,
- "is_password": true
}
]Returns all discovery jobs
The available parameters to search / sort_by are:
| limit | integer (RequestParameters.limit) >= 1 Example: limit=20 Max items per pages |
| page | integer (RequestParameters.page) >= 1 Example: page=1 Number of the page requested |
| sort_by | object (RequestParameters.sortBy) Example: sort_by={"id":"ASC"} Used to sort the request |
| search | object (RequestParameters.search) Example: search={"name":"localhost"} Used to search with specifics parameters |
{- "result": [
- {
- "id": 0,
- "alias": "string",
- "credential_id": 0,
- "provider": {
- "id": 0,
- "name": "string",
- "is_need_proxy": true
}, - "monitoring_server_id": 0,
- "creation_date": "string",
- "last_execution": "string",
- "status": 0,
- "execution_mode": 0,
- "analysis_mode": 0,
- "save_mode": 63,
- "cron_expression": "string",
- "duration": 0,
- "number_of_hosts_discovered": 0,
- "message": "string"
}
], - "meta": {
- "page": 0,
- "limit": 0,
- "search": { },
- "sort_by": { },
- "total": 0
}
}Discovery job parameters
| alias required | string [ 1 .. 100 ] characters Alias of the discovery job |
| credential_id required | integer or null Credential id |
| provider_id required | integer Provider id |
| monitoring_server_id required | integer Id of monitoring server |
| execution_mode required | integer Enum: 0 1 2 Execution mode:
|
| analysis_mode required | integer Enum: 0 1 Analysis mode:
|
| save_mode | integer [ 0 .. 63 ] save_mode:
This property is only mandatory when the analysis_mode is equal to 1 (AUTOMATIC_ANALYSIS). To select more than one option, you have to add up their values. Example: If I select the options ADD_HOST and ENABLE_HOST => save_mode=5 (1+4) |
object (DiscoveryJob.scheduling) Allows you to define the scheduling of the task. Either the cron expression is directly defined or you just have to complete the properties minutes, hours, days, months and weekdays. | |
required | object (Proxy) |
required | Array of objects (Mapper) |
required | Array of objects (JobParameter.short) |
{- "alias": "string",
- "credential_id": 0,
- "provider_id": 0,
- "monitoring_server_id": 0,
- "execution_mode": 0,
- "analysis_mode": 0,
- "save_mode": 63,
- "scheduling": {
- "cron_expression": "string",
- "minutes": {
- "values": "string",
- "every": 0
}, - "hours": {
- "values": "string",
- "every": 0
}, - "days": {
- "values": "string",
- "every": 0
}, - "months": {
- "values": "string",
- "every": 0
}, - "weekdays": "string"
}, - "proxy": {
- "user": "string",
- "password": "string",
- "url": "string",
- "port": 0
}, - "mappers": [
- {
- "type": "property",
- "parameters": {
- "source": [
- {
- "type": "string",
- "values": "Hello world"
}
], - "conditions": [
- {
- "source": "string",
- "value": "string",
- "operator": "equal"
}
], - "value": "string",
- "operator": "string",
- "destination": "string",
- "is_password": true
}
}
], - "job_parameters": [
- {
- "name": "string",
- "value": "string"
}
]
}{- "code": 403,
- "message": "You are not authorized to access this resource"
}| job_id required | integer <int64> Id of discovery job |
{- "id": 0,
- "alias": "string",
- "credential": {
- "id": "string",
- "name": "string",
- "type_id": 0,
- "parameters": [
- {
- "name": "string",
- "description": "string",
- "value": "string",
- "is_hidden": true,
- "is_locked": true,
- "is_mandatory": true,
- "is_password": true
}
]
}, - "provider": {
- "id": 0,
- "name": "string",
- "type": {
- "id": 0,
- "name": "string"
}, - "is_need_proxy": true,
- "host_template": {
- "id": 0,
- "name": "string"
}
}, - "monitoring_server": {
- "id": 0,
- "name": "string",
- "address": "string",
- "is_localhost": true,
- "is_activate": true
}, - "creation_date": "string",
- "last_execution": "string",
- "status": 0,
- "execution_mode": 0,
- "analysis_mode": 0,
- "save_mode": 63,
- "scheduling": {
- "cron_expression": "string",
- "minutes": {
- "values": "string",
- "every": 0
}, - "hours": {
- "values": "string",
- "every": 0
}, - "days": {
- "values": "string",
- "every": 0
}, - "months": {
- "values": "string",
- "every": 0
}, - "weekdays": "string"
}, - "duration": 0,
- "number_of_hosts_discovered": 0,
- "message": "string",
- "proxy": {
- "user": "string",
- "password": "string",
- "url": "string",
- "port": 0
}, - "job_parameters": [
- {
- "name": "string",
- "value": "string",
- "group": "string",
- "description": "string",
- "is_hidden": true,
- "is_locked": true,
- "is_mandatory": true
}
], - "mappers_to_apply": [
- {
- "order": 1,
- "type": "property",
- "parameters": [
- {
- "source": [
- {
- "type": "string",
- "values": "Hello world"
}
], - "conditions": [
- {
- "source": "string",
- "value": "string",
- "operator": "equal"
}
], - "value": "string",
- "operator": "string",
- "destination": "string",
- "is_password": true
}
]
}
]
}| job_id required | integer <int64> Id of discovery job to be updated |
Discovery job parameters
| alias required | string [ 1 .. 100 ] characters Alias of the discovery job |
| credential_id required | integer or null Credential id |
| provider_id required | integer Provider id |
| monitoring_server_id required | integer Id of monitoring server |
| execution_mode required | integer Enum: 0 1 2 Execution mode:
|
| analysis_mode required | integer Enum: 0 1 Analysis mode:
|
| save_mode | integer [ 0 .. 63 ] save_mode:
This property is only mandatory when the analysis_mode is equal to 1 (AUTOMATIC_ANALYSIS). To select more than one option, you have to add up their values. Example: If I select the options ADD_HOST and ENABLE_HOST => save_mode=5 (1+4) |
object (DiscoveryJob.scheduling) Allows you to define the scheduling of the task. Either the cron expression is directly defined or you just have to complete the properties minutes, hours, days, months and weekdays. | |
required | object (Proxy) |
required | Array of objects (Mapper) |
required | Array of objects (JobParameter.short) |
{- "alias": "string",
- "credential_id": 0,
- "provider_id": 0,
- "monitoring_server_id": 0,
- "execution_mode": 0,
- "analysis_mode": 0,
- "save_mode": 63,
- "scheduling": {
- "cron_expression": "string",
- "minutes": {
- "values": "string",
- "every": 0
}, - "hours": {
- "values": "string",
- "every": 0
}, - "days": {
- "values": "string",
- "every": 0
}, - "months": {
- "values": "string",
- "every": 0
}, - "weekdays": "string"
}, - "proxy": {
- "user": "string",
- "password": "string",
- "url": "string",
- "port": 0
}, - "mappers": [
- {
- "type": "property",
- "parameters": {
- "source": [
- {
- "type": "string",
- "values": "Hello world"
}
], - "conditions": [
- {
- "source": "string",
- "value": "string",
- "operator": "equal"
}
], - "value": "string",
- "operator": "string",
- "destination": "string",
- "is_password": true
}
}
], - "job_parameters": [
- {
- "name": "string",
- "value": "string"
}
]
}{- "code": 403,
- "message": "You are not authorized to access this resource"
}| job_id required | integer <int64> Id of discovery job to be updated |
Discovery job parameters
| alias | string [ 1 .. 100 ] characters Alias of the discovery job |
| credential_id | integer or null Credential id |
| provider_id | integer Provider id |
| monitoring_server_id | integer Id of monitoring server |
| execution_mode | integer Enum: 0 1 2 Execution mode:
|
| analysis_mode | integer Enum: 0 1 Analysis mode:
|
| save_mode | integer [ 0 .. 63 ] save_mode:
This property is only mandatory when the analysis_mode is equal to 1 (AUTOMATIC_ANALYSIS). To select more than one option, you have to add up their values. Example: If I select the options ADD_HOST and ENABLE_HOST => save_mode=5 (1+4) |
object (DiscoveryJob.scheduling) Allows you to define the scheduling of the task. Either the cron expression is directly defined or you just have to complete the properties minutes, hours, days, months and weekdays. | |
object (Proxy) | |
Array of objects (Mapper) | |
Array of objects (JobParameter.short) |
{- "alias": "string",
- "credential_id": 0,
- "provider_id": 0,
- "monitoring_server_id": 0,
- "execution_mode": 0,
- "analysis_mode": 0,
- "save_mode": 63,
- "scheduling": {
- "cron_expression": "string",
- "minutes": {
- "values": "string",
- "every": 0
}, - "hours": {
- "values": "string",
- "every": 0
}, - "days": {
- "values": "string",
- "every": 0
}, - "months": {
- "values": "string",
- "every": 0
}, - "weekdays": "string"
}, - "proxy": {
- "user": "string",
- "password": "string",
- "url": "string",
- "port": 0
}, - "mappers": [
- {
- "type": "property",
- "parameters": {
- "source": [
- {
- "type": "string",
- "values": "Hello world"
}
], - "conditions": [
- {
- "source": "string",
- "value": "string",
- "operator": "equal"
}
], - "value": "string",
- "operator": "string",
- "destination": "string",
- "is_password": true
}
}
], - "job_parameters": [
- {
- "name": "string",
- "value": "string"
}
]
}{- "code": 403,
- "message": "You are not authorized to access this resource"
}| job_id required | integer <int64> Id of discovery job |
| discovered_host_id required | integer <int64> Id of the discovery host for which we want to retrieve the raw results of the discovery |
{- "id": 0,
- "job_id": 0,
- "discovery_result": { }
}Returns all discovered hosts for a job
The available parameters to search / sort_by are:
| job_id required | integer <int64> Id of discovery job |
| limit | integer (RequestParameters.limit) >= 1 Example: limit=20 Max items per pages |
| page | integer (RequestParameters.page) >= 1 Example: page=1 Number of the page requested |
| sort_by | object (RequestParameters.sortBy) Example: sort_by={"id":"ASC"} Used to sort the request |
| search | object (RequestParameters.search) Example: search={"name":"localhost"} Used to search with specifics parameters |
{- "result": [
- {
- "id": 0,
- "host": {
- "id": 0,
- "name": "string",
- "alias": "string",
- "ip_address": "string",
- "monitoring_server": {
- "name": "string"
}, - "templates": [
- {
- "name": "string"
}
], - "extended_host": {
- "notes": "string",
- "notesUrl": "string",
- "actionUrl": "string"
}, - "categories": [
- {
- "name": "string"
}
], - "groups": [
- {
- "name": "string"
}
], - "severity": {
- "id": 0,
- "name": "string"
}
}, - "host_name_already_used": true,
- "error_messages": { }
}
], - "meta": {
- "page": 0,
- "limit": 0,
- "search": { },
- "sort_by": { },
- "total": 0
}
}| job_id required | integer <int64> Job id associated to the discovered hosts to be saved |
| ids | Array of integers List of discovered host ids to be saved |
| all | boolean |
{- "ids": [
- 1,
- 2
], - "all": false
}{- "code": 403,
- "message": "You are not authorized to access this resource"
}| job_id required | integer <int64> Id of discovery job |
[- {
- "order": 1,
- "type": "property",
- "parameters": [
- {
- "source": [
- {
- "type": "string",
- "values": "Hello world"
}
], - "conditions": [
- {
- "source": "string",
- "value": "string",
- "operator": "equal"
}
], - "value": "string",
- "operator": "string",
- "destination": "string",
- "is_password": true
}
]
}
]| job_id required | integer <int64> Id of the discovery job for which mappers need to be updated |
List of mappers
| type | string Type of the mapper |
object (MapperParameter) |
[- {
- "type": "property",
- "parameters": {
- "source": [
- {
- "type": "string",
- "values": "Hello world"
}
], - "conditions": [
- {
- "source": "string",
- "value": "string",
- "operator": "equal"
}
], - "value": "string",
- "operator": "string",
- "destination": "string",
- "is_password": true
}
}
]{- "code": 403,
- "message": "You are not authorized to access this resource"
}| credential_id | integer Id of the credential |
| provider_id | integer Id of the provider |
Array of objects | |
Array of objects |
{- "credential_id": 0,
- "provider_id": 0,
- "mappers": [
- {
- "type": "property",
- "parameters": {
- "source": [
- {
- "type": "string",
- "values": "Hello world"
}
], - "conditions": [
- {
- "source": "string",
- "value": "string",
- "operator": "equal"
}
], - "value": "string",
- "operator": "string",
- "destination": "string",
- "is_password": true
}
}
], - "job_parameters": [
- {
- "name": "string",
- "value": "string"
}
]
}[- {
- "host": {
- "id": 0,
- "name": "string",
- "alias": "string",
- "ip_address": "string",
- "monitoring_server": {
- "name": "string"
}, - "templates": [
- {
- "name": "string"
}
], - "extended_host": {
- "notes": "string",
- "notesUrl": "string",
- "actionUrl": "string"
}, - "categories": [
- {
- "name": "string"
}
], - "groups": [
- {
- "name": "string"
}
], - "severity": {
- "id": 0,
- "name": "string"
}
}, - "error_messages": { }
}
]Returns all providers in plugin packs.
The available parameters to search / sort_by are:
| limit | integer (RequestParameters.limit) >= 1 Example: limit=20 Max items per pages |
| page | integer (RequestParameters.page) >= 1 Example: page=1 Number of the page requested |
| sort_by | object (RequestParameters.sortBy) Example: sort_by={"id":"ASC"} Used to sort the request |
| search | object (RequestParameters.search) Example: search={"name":"localhost"} Used to search with specifics parameters |
{- "result": [
- {
- "id": 0,
- "plugin_pack_id": 0,
- "name": "string",
- "description": "string",
- "icon": "string",
- "is_need_proxy": true,
- "type": {
- "id": 0,
- "name": "string"
}, - "host_template": {
- "id": 0,
- "name": "string"
}, - "job_parameters_template": [
- {
- "name": "string",
- "value": "string",
- "group": "string",
- "description": "string",
- "is_hidden": true,
- "is_locked": true,
- "is_mandatory": true
}
], - "mappers_examples": [
- {
- "type": "property",
- "parameters": {
- "source": [
- {
- "type": "string",
- "values": "Hello world"
}
], - "conditions": [
- {
- "source": "string",
- "value": "string",
- "operator": "equal"
}
], - "value": "string",
- "operator": "string",
- "destination": "string",
- "is_password": true
}
}
]
}
], - "meta": {
- "page": 0,
- "limit": 0,
- "search": { },
- "sort_by": { },
- "total": 0
}
}Returns all available attributes of provider used by mappers.
| provider_id required | integer <int64> Provider id |
{- "attributes": [
- {
- "type": "string",
- "name": "discovery.results.desc"
}, - {
- "type": "string",
- "name": "discovery.results.hostname"
}, - {
- "type": "string",
- "name": "discovery.results.ip"
}, - {
- "type": "string",
- "name": "discovery.results.snmp_community"
}, - {
- "type": "integer",
- "name": "discovery.results.snmp_port"
}, - {
- "type": "string",
- "name": "discovery.results.snmp_version"
}, - {
- "type": "array",
- "name": "discovery.results.tags",
- "properties": [
- "key",
- "value"
]
}, - {
- "type": "string",
- "name": "discovery.results.type"
}
], - "parameters": [
- {
- "type": "string",
- "name": "discovery.parameters.LOCATION"
}, - {
- "type": "string",
- "name": "discovery.parameters.TIMEOUT"
}
], - "credentials": [
- {
- "type": "string",
- "name": "discovery.credentials.AZURESUBSCRIPTION"
}, - {
- "type": "string",
- "name": "discovery.credentials.AZURETENANT"
}, - {
- "type": "string",
- "name": "discovery.credentials.AZURECLIENTID"
}, - {
- "type": "string",
- "name": "discovery.credentials.AZURECLIENTSECRET"
}
]
}Returns all discovery jobs
The available parameters to search / sort_by are:
| limit | integer (RequestParameters.limit) >= 1 Example: limit=20 Max items per pages |
| page | integer (RequestParameters.page) >= 1 Example: page=1 Number of the page requested |
| sort_by | object (RequestParameters.sortBy) Example: sort_by={"id":"ASC"} Used to sort the request |
| search | object (RequestParameters.search) Example: search={"name":"localhost"} Used to search with specifics parameters |
{- "result": [
- {
- "job_id": 0,
- "target": 0,
- "status": 0,
- "last_execution": "string",
- "token": "string",
- "uuid_attributes": [
- "hostname",
- "ip"
], - "command_line": "string",
- "plugins": "{ \"centreon-plugin-Cloud-Aws-Ec2-Api\": 20220727 }",
- "post_execution": {
- "commands": [ ]
}, - "execution": {
- "mode": 0,
- "parameters": {
- "cron_definition": "* * * * *",
- "is_paused": true
}
}
}
], - "meta": {
- "page": 0,
- "limit": 0,
- "search": { },
- "sort_by": { },
- "total": 0
}
}