Response schema
Header
The header contains a field named TL-Signature. This allows you to verify that the event was sent by TwelveLabs. The TL-Signature field is composed of two parts:
t: A Unix timestamp representing the time when the platform sent the notification.v1: A signature generated uniquely for each webhook event, usingHMACwithSHA-256. For instructions on how to verify the signature, see the Validate the integrity of an event section.
Response schema
All notifications are in JSON format and contain the following top-level fields:
id: A string representing the unique identifier of the notification.created_at: A string indicating the date and time, in RFC 3339 format, when the platform sent the notification.type: A string indicating the event type. Use this field to determine whether the notification is for a video indexing task or an async analysis task.data: An object containing event-specific fields. The fields depend on the event type. See the sections below for details.
Video indexing notifications
These notifications apply to video indexing tasks. The type field is index.task.ready or index.task.failed.
The data object contains the following fields:
id: A string representing the unique identifier of the video indexing task.metadata: An object containing metadata about the video, such as its duration.status: A string representing the status of the video indexing task. For details about the possible statuses, see the Task object page.models: A list of objects containing the video understanding models and the associated model options used to index this video.tags: An array of strings representing the tags associated with this video indexing task.
Example
Async analysis notifications
These notifications apply to async analysis tasks. The type field is analyze.task.ready or analyze.task.failed.
The data object contains the following fields:
id: A string representing the unique identifier of the analysis task.status: A string representing the status of the analysis task. It is eitherreadyorfailed.created_at: A string indicating the date and time, in RFC 3339 format, when the analysis task was created.error: An object containing amessagefield that describes the failure. The platform includes this field only whenstatusisfailed.