POST
/
annotations
/
types
/
v1
/
{annotation_type_id}
/
action_configuration

Authorizations

Authorization
string
headerrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

annotation_type_id
string
required

The id of the annotation type to attach action types to

Body

application/json
annotation_type_id
string
required

The id of the annotation type to attach action types to

configuration
object
required

A map of action_type_id to a set of key-value pairs containing all input fields for that action type, and their values.

For example, if there are two action types configured, create_clip and share_to_instagram, this map would look like:

{
  "create_clip": {
    "name": "Goal",
    "relative_end_offset": 10000,
    "relative_start_offset": -10000
  },
  "share_to_instagram": {
    "clip_asset_id": "$create_clip.reserved_asset_id"
    "social_media_post": "Have a look at this great goal! #soccer #goal #sports"
  }
}

A few things to note:

  1. The values you specify in this payload must match the types as defined in the action type's input_fields field.
  2. If you do not provide a value on an input field, the action type input field's default value will be used.
  3. If you want to pass the output of an action type as input to a following action type, you can use the $ notation. The required format is $action_type_id.output_field. The field name must be a field in the output of a previous action type. In the example above, the clip_asset_id field in the share_to_instagram action type is populated with the reserved_asset_id field from the create_clip action type.

These actions are executed in parallel where possible, unless there is a dependency between actions, in which case the dependent action will wait for the dependency to complete.

Response

200 - application/json

The response is of type object.