Live Scheduler Notifications

When creating workflows with the scheduler, you can optionally configure notifications.

Introduction

After completing a task, the scheduler will send a notification to the configured endpoint using http method POST with details on what action was performed and it's success/failure.

You can also configure a pre-notification of an upcoming task. See the Live API Reference for details on specifying the notification url and settings, and note the differences for scheduling the start/stop times for an SEP job, and for scheduling clips:

Start/Stop scheduler
  • The notification URL is defined at the top level of the request body object
  • Notifications are scheduled in the activation and deactivation objects (time in seconds before the event to send the notification)

Example

{
	"job_id": "your Job ID",
	"activation": {
		"time_utc": 1612274100,
		"notification": 600
	},
	"deactivation": {
		"time_utc": 1612281600,
		"notification": 600
	},
	"description": "My Tuesday broadcast",
	"notification_url": "https://example.com/live/jobstartstop/callbacks"
}
Clips scheduler
  • The notification URL is defined at the top level of the request body object
  • Notifications are scheduled in the clip object (time in seconds before the task starts to send the notification)

Example

{
	"job_id":  "your Job ID",
	"description": "My Scheduled Clip",
	"notification_url": "https://example.com/live/clip/callbacks",
	"clip": {
		"output": {
			"label": "My Scheduled Clip",
			"start_time": 1612878900,
			"end_time": 1612879800,
			"videocloud": {
				"video": {
					"name": "My Scheduled Clip"
				}
			}
		},
		"time_utc": 1612879800,
		"notification": 600
	}
}

Notification body

When the server sends a notification to your notification_url, the request will include a JSON body. The fields are detailed in the tables below.

Notification Body Fields
action Action name. See Actions
workflow Updated workflow after action completion. Structure will depend on workflow type.
error If error occurred completing action, this field will contain the error. value depends on action type.

Actions

The following table details the actions by workflow type.

Actions
Name Workflow Type Description
notify-activate jobstartstop Heads up notification that your Job will be activated soon.
activate jobstartstop Job activation complete. If "error" is present, the activation has failed and the deactivation will be cancelled.
notify-deactivate jobstartstop Heads up notification that your Job will be activated soon.
deactivate jobstartstop Job deactivation complete. If "error" is present, the deactvation has failed.
notify-clip clip Heads up notification that your Clip will be requested soon.
clip clip Clip request complete. If "error" is present, the request has failed.