To get the status of an edge service, make the following GET request:
curl -X GET \
-H 'X-API-KEY:<your_api_key>' \
-H "Content-type:application/json" \
'https://<your_company>.manage.iotium.io/api/v1/service/<your_service_id>' \
| jq .status
The response includes the details about the edge service, including service status, service IP address, containers status, and more:
{
"status": "HEALTHY",
"reason": "",
"message": "",
"service_ip": [
{
"ip_address": "<your_service_ip_addr>",
"network_id": "<your_edge_inode_network_id>",
"mac_address": "<your_service_mac_addr>"
}
],
"running": "1/1",
"start_time": "2019-09-24T18:21:52.178900216+05:30",
"pod_condition": {
"type": "PodScheduled",
"status": "ConditionTrue",
"lastTransitionTime": "2019-09-24T18:21:58.432702432+05:30",
"reason": "",
"message": ""
},
"container_status": [
{
"name": "<your_service_name>0",
"state": {
"state": "RUNNING",
"started_at": "2019-09-24T18:21:57.206507595+05:30"
},
"lastTerminationState": {
"state": "UNKNOWN"
},
"ready": true,
"image": "<your_container_image_name>",
"restart_count": 0,
"image_id": "<your_container_image_id>",
"container_id": "<your_container_id>"
}
]
}