Mux · Arazzo Workflow

Mux Manage Data Annotation

Version 1.0.0

Create a Mux Data annotation marking a deploy or event, read it back, update its note, then list annotations to confirm.

1 workflow 1 source API 1 provider
View Spec View on GitHub Video InfrastructureVideo StreamingLive StreamingVideo AnalyticsVideo AIEncodingArazzoWorkflows

Provider

mux-com

Workflows

annotation-manage
Create, read, update, and confirm a Mux Data annotation.
Creates an annotation, reads it back, updates its note, then lists annotations to confirm.
4 steps inputs: date, note, updatedNote outputs: annotationId, annotations, note
1
createAnnotation
create-annotation
Create an annotation at the supplied timestamp marking the event of interest.
2
getAnnotation
get-annotation
Read the annotation back to confirm it was created with the supplied note and date.
3
updateAnnotation
update-annotation
Update the annotation's note text while keeping the same timestamp.
4
listAnnotations
list-annotations
List annotations to confirm the updated annotation is present on the timeline.

Source API Descriptions

Arazzo Workflow Specification

mux-com-annotation-manage-workflow.yml Raw ↑
arazzo: 1.0.1
info:
  title: Mux Manage Data Annotation
  summary: Create a Mux Data annotation marking a deploy or event, read it back, update its note, then list annotations to confirm.
  description: >-
    Marks a deploy, config change, or marketing event on the Mux Data timeline so
    metric shifts can be correlated with what changed. The workflow creates an
    annotation at a given timestamp, reads it back, updates the note text, and
    lists annotations to confirm the change landed. Every step spells out its
    request inline so the flow can be read and executed without opening the
    underlying OpenAPI description.
  version: 1.0.0
sourceDescriptions:
- name: muxApi
  url: ../openapi/mux-openapi.yml
  type: openapi
workflows:
- workflowId: annotation-manage
  summary: Create, read, update, and confirm a Mux Data annotation.
  description: >-
    Creates an annotation, reads it back, updates its note, then lists
    annotations to confirm.
  inputs:
    type: object
    required:
    - note
    - date
    properties:
      note:
        type: string
        description: The annotation note content (e.g. "Deployed player v3.2").
      date:
        type: integer
        description: Unix timestamp the annotation applies to.
      updatedNote:
        type: string
        description: Replacement note text applied in the update step.
        default: Updated annotation note
  steps:
  - stepId: createAnnotation
    description: >-
      Create an annotation at the supplied timestamp marking the event of
      interest.
    operationId: create-annotation
    requestBody:
      contentType: application/json
      payload:
        note: $inputs.note
        date: $inputs.date
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      annotationId: $response.body#/data/id
  - stepId: getAnnotation
    description: >-
      Read the annotation back to confirm it was created with the supplied note
      and date.
    operationId: get-annotation
    parameters:
    - name: ANNOTATION_ID
      in: path
      value: $steps.createAnnotation.outputs.annotationId
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      note: $response.body#/data/note
  - stepId: updateAnnotation
    description: >-
      Update the annotation's note text while keeping the same timestamp.
    operationId: update-annotation
    parameters:
    - name: ANNOTATION_ID
      in: path
      value: $steps.createAnnotation.outputs.annotationId
    requestBody:
      contentType: application/json
      payload:
        note: $inputs.updatedNote
        date: $inputs.date
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      note: $response.body#/data/note
  - stepId: listAnnotations
    description: >-
      List annotations to confirm the updated annotation is present on the
      timeline.
    operationId: list-annotations
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      annotations: $response.body#/data
  outputs:
    annotationId: $steps.createAnnotation.outputs.annotationId
    note: $steps.updateAnnotation.outputs.note
    annotations: $steps.listAnnotations.outputs.annotations