Skip to content

Workflows API

Base URL: https://YOUR-SERVER/api. Send your API key in x-api-key where authentication is required. A key also needs the listed permission; your account's access rules still apply.

API guide · All endpoints · OpenAPI JSON

List all workflows

GET /api/workflows

Retrieve a list of workflows available to the authenticated user.

Authentication: API key. Permission: workflow.read.

Parameters

NameWhereRequiredDescription
descriptionqueryNoWorkflow description
enabledqueryNoWorkflow enabled
idqueryNoWorkflow ID
loggingqueryNoWorkflow logs run results
namequeryNoWorkflow name
triggerqueryNoWorkflow trigger type
Parameter types, defaults and constraints

Field definitions: WorkflowTrigger

[
  {
    "name": "description",
    "required": false,
    "in": "query",
    "description": "Workflow description",
    "schema": {
      "type": "string"
    }
  },
  {
    "name": "enabled",
    "required": false,
    "in": "query",
    "description": "Workflow enabled",
    "schema": {
      "type": "boolean"
    }
  },
  {
    "name": "id",
    "required": false,
    "in": "query",
    "description": "Workflow ID",
    "schema": {
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$",
      "type": "string"
    }
  },
  {
    "name": "logging",
    "required": false,
    "in": "query",
    "description": "Workflow logs run results",
    "schema": {
      "type": "boolean"
    }
  },
  {
    "name": "name",
    "required": false,
    "in": "query",
    "description": "Workflow name",
    "schema": {
      "type": "string"
    }
  },
  {
    "name": "trigger",
    "required": false,
    "in": "query",
    "description": "Workflow trigger type",
    "schema": {
      "$ref": "#/components/schemas/WorkflowTrigger"
    }
  }
]

Responses

Field definitions: WorkflowResponseDto

{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "items": {
            "$ref": "#/components/schemas/WorkflowResponseDto"
          },
          "type": "array"
        }
      }
    },
    "description": ""
  }
}

Create a workflow

POST /api/workflows

Create a new workflow, the workflow can also be created with empty filters and actions.

Authentication: API key. Permission: workflow.create.

Request body

Required.

Field definitions: WorkflowCreateDto

{
  "application/json": {
    "schema": {
      "$ref": "#/components/schemas/WorkflowCreateDto"
    }
  }
}

Responses

Field definitions: WorkflowResponseDto

{
  "201": {
    "content": {
      "application/json": {
        "schema": {
          "$ref": "#/components/schemas/WorkflowResponseDto"
        }
      }
    },
    "description": ""
  }
}

List all workflow triggers

GET /api/workflows/triggers

Retrieve a list of all available workflow triggers.

Authentication: API key. Permission: No additional key permission.

Responses

Field definitions: WorkflowTriggerResponseDto

{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "items": {
            "$ref": "#/components/schemas/WorkflowTriggerResponseDto"
          },
          "type": "array"
        }
      }
    },
    "description": ""
  }
}

Delete a workflow

DELETE /api/workflows/{id}

Delete a workflow by its ID.

Authentication: API key. Permission: workflow.delete.

Parameters

NameWhereRequiredDescription
idpathYesstring
Parameter types, defaults and constraints
[
  {
    "name": "id",
    "required": true,
    "in": "path",
    "schema": {
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$",
      "type": "string"
    }
  }
]

Responses

{
  "204": {
    "description": ""
  }
}

Retrieve a workflow

GET /api/workflows/{id}

Retrieve information about a specific workflow by its ID.

Authentication: API key. Permission: workflow.read.

Parameters

NameWhereRequiredDescription
idpathYesstring
Parameter types, defaults and constraints
[
  {
    "name": "id",
    "required": true,
    "in": "path",
    "schema": {
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$",
      "type": "string"
    }
  }
]

Responses

Field definitions: WorkflowResponseDto

{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "$ref": "#/components/schemas/WorkflowResponseDto"
        }
      }
    },
    "description": ""
  }
}

Update a workflow

PUT /api/workflows/{id}

Update the information of a specific workflow by its ID. This endpoint can be used to update the workflow name, description, trigger type, filters and actions order, etc.

Deprecated. Avoid this operation in new integrations; use the replacement supported by your server release.

Authentication: API key. Permission: workflow.update.

Parameters

NameWhereRequiredDescription
idpathYesstring
Parameter types, defaults and constraints
[
  {
    "name": "id",
    "required": true,
    "in": "path",
    "schema": {
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$",
      "type": "string"
    }
  }
]

Request body

Required.

Field definitions: WorkflowUpdateDto

{
  "application/json": {
    "schema": {
      "$ref": "#/components/schemas/WorkflowUpdateDto"
    }
  }
}

Responses

Field definitions: WorkflowResponseDto

{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "$ref": "#/components/schemas/WorkflowResponseDto"
        }
      }
    },
    "description": ""
  }
}

Retrieve workflow logs

GET /api/workflows/{id}/logs

Retrieve logs of a workflows runs by ID

Authentication: API key. Permission: workflow.logs.

Parameters

NameWhereRequiredDescription
beforequeryNoFilter by runs before a date/time
idpathYesstring
limitqueryNoMaximum number of logs
resultqueryNoFilter by run result
Parameter types, defaults and constraints

Field definitions: WorkflowResult

[
  {
    "name": "before",
    "required": false,
    "in": "query",
    "description": "Filter by runs before a date/time",
    "schema": {
      "format": "date-time",
      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
      "example": "2024-01-01T00:00:00.000Z",
      "type": "string"
    }
  },
  {
    "name": "id",
    "required": true,
    "in": "path",
    "schema": {
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$",
      "type": "string"
    }
  },
  {
    "name": "limit",
    "required": false,
    "in": "query",
    "description": "Maximum number of logs",
    "schema": {
      "maximum": 200,
      "exclusiveMinimum": true,
      "default": 50,
      "type": "integer",
      "minimum": 0
    }
  },
  {
    "name": "result",
    "required": false,
    "in": "query",
    "description": "Filter by run result",
    "schema": {
      "$ref": "#/components/schemas/WorkflowResult"
    }
  }
]

Responses

Field definitions: WorkflowLogEntryDto

{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "items": {
            "$ref": "#/components/schemas/WorkflowLogEntryDto"
          },
          "type": "array"
        }
      }
    },
    "description": ""
  }
}

Retry a workflow run

POST /api/workflows/{id}/runs/{runId}/retry

Run a logged workflow run again, as its next attempt, for the photo or video that started it. The workflow must be enabled and able to run.

Authentication: API key. Permission: workflow.update.

Parameters

NameWhereRequiredDescription
idpathYesWorkflow ID
runIdpathYesRun ID
Parameter types, defaults and constraints
[
  {
    "name": "id",
    "required": true,
    "in": "path",
    "description": "Workflow ID",
    "schema": {
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "type": "string"
    }
  },
  {
    "name": "runId",
    "required": true,
    "in": "path",
    "description": "Run ID",
    "schema": {
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      "type": "string"
    }
  }
]

Responses

{
  "204": {
    "description": ""
  }
}

Retrieve a workflow

GET /api/workflows/{id}/share

Retrieve a workflow details without ids, default values, etc.

Authentication: API key. Permission: workflow.read.

Parameters

NameWhereRequiredDescription
idpathYesstring
Parameter types, defaults and constraints
[
  {
    "name": "id",
    "required": true,
    "in": "path",
    "schema": {
      "format": "uuid",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$",
      "type": "string"
    }
  }
]

Responses

Field definitions: WorkflowShareResponseDto

{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "$ref": "#/components/schemas/WorkflowShareResponseDto"
        }
      }
    },
    "description": ""
  }
}