Retire Service Immediately
Request:
POST /api/services
{
"action" : "request_retire",
"resource" : { "href" : "http://localhost:3000/api/services/35" }
}
Response:
{
"results" : [
{
"href": "http://localhost:3000/api/services/95",
"id": "95",
"name": "sample_service_95",
"description": "Description for sample_service_95",
"guid": "eb713538-7c9b-11e4-8a3a-b8e85646e742",
"options": {
},
"created_at": "2014-12-05T16:29:43Z",
"updated_at": "2015-05-08T19:32:00Z"
}
]
}
Or simply targeting the service directly:
POST /api/services/95
{
"action" : "request_retire"
}
Response:
{
"href": "http://localhost:3000/api/services/95",
"id": "95",
"name": "sample_service_95",
"description": "Description for sample_service_95",
"guid": "eb713538-7c9b-11e4-8a3a-b8e85646e742",
"options": {
},
"created_at": "2014-12-05T16:29:43Z",
"updated_at": "2015-05-08T19:32:00Z"
}
Retire Service In the Future
Request:
POST /api/services/93
{
"action" : "request_retire",
"resource" : { "date" : "10/31/2015", "warn" : "7" }
}
Response:
{
"href": "http://localhost:3000/api/services/93",
"id": "93",
"name": "sample_service_93",
"description": "Description for sample_service_93",
"guid": "eb709e02-7c9b-11e4-8a3a-b8e85646e742",
"options": {
},
"created_at": "2014-12-05T16:29:43Z",
"updated_at": "2015-05-08T19:40:19Z",
"retired": false,
"retires_on": "2015-10-30",
"retirement_warn": 7
}