ConnectCloud Developers

The actions, events and node kinds flows can use (tenant:flows:read|write|admin)

GET /api/flows/v1/catalog

Module: Flows · operationId: getFlowsCatalog · Tag: Catalog · Auth: access token (Authorization: Bearer <accessToken>)

Every module's flows manifest (its x-flows actions with parameter and answer schemas, its events with payload schemas), the built-in node kinds, the expression namespaces and the functions of the expression language.

Responses

  • 200 The catalogue (application/json)
  • 401 Missing, invalid or expired token (no body).
  • 403 The token lacks the permission or has no active tenant (forbidden). Also: person_required (a service-account key on personal flows or the task inbox), live_test_forbidden, forbidden_grant, starter_excluded. (application/json)

Fields of the 200 answer:

  • functions (array of string, required): Functions of the expression language
  • kinds (array of object, required): Every node kind with its default ports (a node's own ports – switch cases, parallel branches, the task type – come with each validation)
    • fields (array of KindField, required): The kind's fields besides the common ones
      • path (string, required): Dotted below the node or trigger
      • type (string, required): The editor: expression (expr-lang, no braces), template / longtemplate (text with {{ }}), text, enum (one of options), number, bool, duration (30s, 2h, 3d), list, people (a list of references: person:<email>, employee:<id>, group:<id>, role:<id>, manager:<email or employee id> – HR ids – or an expression; a mail's to also takes a plain address and channel:<id>, a comms channel of kind Teams or webhook), channel:teams / channel:email (the id of a comms channel of that medium), map, cases, form, escalation, aifields. Clients treat an unknown type as JSON.
      • options (array of string): The values of an enum – exactly what the validator accepts
      • when (object): The field applies only while the sibling field has one of the values
        • equals (array of string): Values of the sibling field for which this field applies
        • field (string): The sibling field
    • name (string, required): Node kind
    • ports (array of string, required): Default output ports
    • retry (boolean, required): Whether timeout and retry apply (other kinds are never retried)
  • modules (array of Manifest, required): Every module's flows manifest
    • events (array of object): The events flows can start on, with their payload schemas
    • inline (object): What the module's own, immediate automations do besides its inline actions (absent: nothing)
      • mail (boolean): They send mail immediately
      • manualEvent (string): The event whose payload a manual start carries (absent: nothing is started by hand)
    • module (string): Module name
    • nodes (array of object): The actions; inline: true marks one the module also runs immediately in its own automations
    • revision (string): Revision of the manifest (changes with the module's spec)
    • version (integer): Manifest format version
  • namespaces (array of string, required): Namespaces expressions can read
  • retryFields (array of KindField): timeout and retry.* of the kinds with retry
    • path (string, required): Dotted below the node or trigger
    • type (string, required): The editor: expression (expr-lang, no braces), template / longtemplate (text with {{ }}), text, enum (one of options), number, bool, duration (30s, 2h, 3d), list, people (a list of references: person:<email>, employee:<id>, group:<id>, role:<id>, manager:<email or employee id> – HR ids – or an expression; a mail's to also takes a plain address and channel:<id>, a comms channel of kind Teams or webhook), channel:teams / channel:email (the id of a comms channel of that medium), map, cases, form, escalation, aifields. Clients treat an unknown type as JSON.
    • options (array of string): The values of an enum – exactly what the validator accepts
    • when (object): The field applies only while the sibling field has one of the values
      • equals (array of string): Values of the sibling field for which this field applies
      • field (string): The sibling field
  • triggers (array of object): Every trigger kind with its fields
    • fields (array of KindField, required): Fields of the trigger kind
      • path (string, required): Dotted below the node or trigger
      • type (string, required): The editor: expression (expr-lang, no braces), template / longtemplate (text with {{ }}), text, enum (one of options), number, bool, duration (30s, 2h, 3d), list, people (a list of references: person:<email>, employee:<id>, group:<id>, role:<id>, manager:<email or employee id> – HR ids – or an expression; a mail's to also takes a plain address and channel:<id>, a comms channel of kind Teams or webhook), channel:teams / channel:email (the id of a comms channel of that medium), map, cases, form, escalation, aifields. Clients treat an unknown type as JSON.
      • options (array of string): The values of an enum – exactly what the validator accepts
      • when (object): The field applies only while the sibling field has one of the values
        • equals (array of string): Values of the sibling field for which this field applies
        • field (string): The sibling field
    • name (string, required): Trigger kind (one of event, schedule, manual, webhook)

Example 200 answer:

{
  "functions": [
    "len",
    "lower",
    "upper",
    "trim",
    "join",
    "filter",
    "map",
    "first",
    "last",
    "now",
    "date",
    "duration"
  ],
  "kinds": [
    {
      "fields": [
        {
          "path": "deadline.after",
          "type": "duration"
        }
      ],
      "name": "human_task",
      "ports": [
        "approved",
        "rejected",
        "timeout",
        "error"
      ],
      "retry": false
    },
    {
      "fields": [
        {
          "path": "action",
          "type": "text"
        }
      ],
      "name": "action",
      "ports": [
        "success",
        "error"
      ],
      "retry": true
    }
  ],
  "modules": [
    {
      "events": [
        {
          "actorKind": "person",
          "group": "Tickets",
          "label": {
            "de": "Ticket angelegt",
            "en": "Ticket created"
          },
          "requires": [
            "desk:read"
          ],
          "schema": {
            "properties": {
              "itemId": {
                "type": "string"
              },
              "number": {
                "type": "string"
              },
              "priority": {
                "type": "string"
              }
            },
            "type": "object"
          },
          "type": "desk.item.created"
        }
      ],
      "inline": {
        "mail": true,
        "manualEvent": "desk.item.updated"
      },
      "module": "desk",
      "nodes": [
        {
          "access": "read",
          "category": "Tickets",
          "description": {
            "de": "Ein Ticket mit seinen Feldern.",
            "en": "A ticket with its fields."
          },
          "idempotency": "natural",
          "key": "desk.item.get",
          "label": {
            "de": "Ticket lesen",
            "en": "Read ticket"
          },
          "method": "GET",
          "operationId": "getItem",
          "paramIn": {
            "ref": "path"
          },
          "params": {
            "properties": {
              "ref": {
                "type": "string"
              }
            },
            "required": [
              "ref"
            ],
            "type": "object"
          },
          "pathTemplate": "/api/desk/v1/items/{ref}",
          "permission": [
            "desk:read",
            "desk:write",
            "desk:admin"
          ]
        }
      ],
      "revision": "9f3c1a7e",
      "version": 1
    }
  ],
  "namespaces": [
    "trigger",
    "nodes",
    "vars",
    "item",
    "loop",
    "error",
    "run"
  ],
  "retryFields": [
    {
      "path": "timeout",
      "type": "duration"
    },
    {
      "path": "retry.attempts",
      "type": "number"
    }
  ],
  "triggers": [
    {
      "fields": [
        {
          "path": "cron",
          "type": "text"
        },
        {
          "path": "timezone",
          "type": "text"
        },
        {
          "options": [
            "skip",
            "once"
          ],
          "path": "catchup",
          "type": "enum"
        }
      ],
      "name": "schedule"
    }
  ]
}

Example request

curl -X GET 'https://api.mbcom.cloud/api/flows/v1/catalog' \
  -H "Authorization: Bearer $ACCESS_TOKEN"

View as Markdown · Interactive reference · OpenAPI