Overview
The Service Management endpoints allow you to monitor service health, list configured services, add new services to monitoring, and remove services from the configuration.Get Service Status
GET /status
Response
Returns an object where each key is a service name and the value contains status information:Status information for each monitored service
Service status:
"running", "stopped", or "error"Additional details about the service state. For running services, typically “Service is active”. For stopped or error states, contains diagnostic information.
Service type (e.g.,
"systemd", "docker", "custom")Example Response
If SSH connection fails, all services will be marked as
"error" with details indicating SSH unavailability.List Services
GET /services
Response
Returns an object with service configurations:Example Response
Add Service
POST /services
Request Body
Unique name identifier for the service
Shell command to execute for checking service status. This command will be run via SSH on the monitored host.
String pattern that should appear in the command output when the service is running. The service is considered running if this string is found in the output.
Service type classification (e.g.,
"systemd", "docker", "custom"). This is used for categorization and reporting.Response
Operation status - will be “ok”
Confirmation message with the service name
The service will be immediately available for monitoring and will be included in subsequent
/status calls.Delete Service
DELETE /services/{name}
Path Parameters
The name of the service to remove
Response
Operation status - will be “ok”
Confirmation message with the service name
Error Responses
404 Not Found - Service does not exist:Service Types
Sentinel AI supports monitoring various service types. Common configurations:Systemd Services
Docker Containers
Custom Services
The
check_command is executed via SSH on the monitored host. Ensure the SSH user has appropriate permissions to run these commands.