REST API Schedules Stop Schedules

To update an existing schedule see below for JSON and JSONAPI example.

NOTE: Remember to substitute the token (after Bearer) and the service id (the [SERVICE ID] below) to your own token and service id.

JSON:

Stop schedule 19 from service with id [SERVICE ID]

curl 
  -H "Authorization: Bearer [API SECURITY TOKEN]"
  -H "Content-Type: application/json" 
  -H "Accept: application/json"
  -X POST
  https://api.myrapidi.com/api/v2/service/[SERVICE ID]/schedules/19/stop

The out-put for this example would be:

{
 "code": "G_TEST22_NAV356001",
 "description": "Group TEST22 NAV356001",
 "transfer": "",
 "group": "TEST22",
 "interval": 3,
 "interval_unit": "Hours",
 "status": "Stopped",
 "error_handling": "Skip",
 "last_datetime": null,
 "next_datetime": "2015-10-01T00:00:00Z",
 "error_interval": 0,
 "error_interval_unit": "Hours",
 "notify_interval": 0,
 "notify_interval_unit": "Hours",
 "notify_datetime": null,
 "start_time": "00:00:00Z",
 "end_time": "00:00:00Z",
 "monday": true,
 "tuesday": true,
 "wednesday": true,
 "thursday": true,
 "friday": true,
 "saturday": true, 
 "sunday": true,
 "tags": [
  {
   "code": "NAV300",
   "value": "NAV356001"
  }
 ],
 "comments": []
}

JSONAPI:

Stop schedule 19 from service with id [SERVICE ID]

curl 
  -H "Authorization: Bearer [API SECURITY TOKEN]"
  -H "Content-Type: application/vnd.api+json" 
  -H "Accept: application/vnd.api+json"
  -X POST
  https://api.myrapidi.com/api/v2/service/[SERVICE ID]/schedules/19/stop

The out-put for this example would be:

{
 "data":{
 "id":"19",
 "type": "schedules",
 "attributes":{
   "code": "G_TEST22_NAV356001",
   "description": "Group TEST22 NAV356001",
   "transfer": "",
   "group": "TEST22",
   "interval": 33,
   "interval_unit": "Day",
   "status": "Stopped",
   "error_handling": "Skip",
   "last_datetime": null,
   "next_datetime": "2015-10-01T00:00:00Z",
   "error_interval": 0,
   "error_interval_unit": "Hours",
   "notify_interval": 0,
   "notify_interval_unit": "Hours",
   "notify_datetime": null,
   "start_time": "00:00:00Z",
   "end_time": "00:00:00Z",
   "monday": true,
   "tuesday": true,
   "wednesday": true,
   "thursday": true,
   "friday": true,
   "saturday": true, 
   "sunday": true
  },
  "relationships": {
   "tags": {
    "data": [
     {
      "id": "7",
      "type": "schedule_tags"
     }
    ]
   },
   "comments": {
    "data": []
   }
  }
 },
"included": [
  {
   "id": "7",
   "type": "schedule_tags",
   "attributes": {
    "code": "NAV300",
    "value": "NAV356001"
   }
  }
 ]
}