Actions9
- Host Actions
- Service Actions
Overview
This node integrates with the Centreon Web API (version 2 and later) to manage monitoring resources such as hosts and services. It supports operations like listing, adding, and acknowledging hosts or services within a Centreon monitoring environment.
For the List operation on the Default resource (which corresponds to listing services), the node fetches a list of monitoring services from Centreon, optionally filtered by service name or host ID, and limited in number.
Common scenarios:
- Retrieving a list of monitored services for reporting or further automation.
- Filtering services by name or associated host to focus on specific subsets.
- Integrating Centreon service data into workflows for alerting, dashboards, or audits.
Practical example:
- A user wants to get all services related to a particular host to check their status or trigger downstream actions based on service health.
Properties
| Name | Meaning |
|---|---|
| API Version | Version of the Centreon API to use (e.g., "latest", "v24.10"). |
| Options Avancées | Advanced options including: - Ignore SSL Errors: Whether to ignore TLS certificate errors. |
Output
The node outputs an array of JSON objects representing the retrieved services. Each object contains the full response data from the Centreon API for a service, including fields such as service ID, display name, description, and associated host information.
No binary data output is produced by this operation.
Dependencies
- Requires valid credentials for Centreon API access, including base URL, username, and password.
- The node performs authentication via a POST request to the
/api/{version}/loginendpoint to obtain a token. - Subsequent requests include this token in the
X-AUTH-TOKENheader. - The node uses HTTP requests with JSON payloads and supports ignoring SSL errors if configured.
- No additional external dependencies beyond the Centreon API and n8n's HTTP request helper.
Troubleshooting
Authentication failures:
Error message: "Authentication failed" or "Failed to authenticate to Centreon".
Resolution: Verify that the provided Centreon API credentials are correct and that the API version matches the Centreon server.API request failures:
Error message: "Failed to fetch services".
Resolution: Check network connectivity, API endpoint correctness, and whether the API token is valid. Also verify if ignoring SSL errors is needed for self-signed certificates.Unexpected response format:
Error message: 'Unexpected response format: "result" is not an array'.
Resolution: This indicates the API response structure changed or an error occurred. Confirm the API version and endpoint compatibility.Empty or incomplete results:
Could be due to filters applied (e.g., service name regex or host ID). Try removing filters or increasing the limit.
Links and References
- Centreon API Documentation
- n8n Expressions Documentation
- n8n HTTP Request Node (for understanding underlying request mechanics)