Reference

DEV3 Cogvane REST API

Base URL /api/v1 · Authenticate with Authorization: Bearer n3k_... · OpenAPI 3.1 JSON

get/api/v1/mescope: read

The workspace this key belongs to

get/api/v1/usagescope: read

Runs and operations used in the current billing period

get/api/v1/nodesscope: flows:read

Node catalogue

get/api/v1/flowsscope: flows:read

List flows

Parameters: status (query), q (query), page (query), limit (query)

post/api/v1/flowsscope: flows:write

Create a flow by importing JSON (credentials by name only)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "flow": {},
    "credentialMap": {
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {
        "type": "string"
      }
    },
    "name": {
      "type": "string"
    }
  },
  "required": [
    "flow"
  ],
  "additionalProperties": false
}
get/api/v1/flows/{id}scope: flows:read

Get a flow with its draft graph

Parameters: id (path)

patch/api/v1/flows/{id}scope: flows:write

Update the draft (needs the current draftRev)

Parameters: id (path)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "draftRev": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991
    },
    "graph": {
      "type": "object",
      "properties": {
        "cogvaneFlow": {
          "type": "number",
          "const": 1
        },
        "nodes": {
          "type": "array",
          "items": {}
        },
        "edges": {
          "type": "array",
          "items": {}
        }
      },
      "required": [
        "nodes",
        "edges"
      ],
      "additionalProperties": false
    },
    "name": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "tags": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "timezone": {
      "type": "string"
    }
  },
  "required": [
    "draftRev"
  ],
  "additionalProperties": false
}
post/api/v1/flows/{id}/publishscope: flows:write

Publish the draft as a new immutable version

Parameters: id (path)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "note": {
      "type": "string",
      "maxLength": 300
    },
    "expectedVersionNo": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991
    }
  },
  "additionalProperties": false
}
post/api/v1/flows/{id}/activatescope: flows:write

Activate the published version (triggers go live)

Parameters: id (path)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
post/api/v1/flows/{id}/pausescope: flows:write

Pause a flow

Parameters: id (path)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
get/api/v1/flows/{id}/versionsscope: flows:read

List published versions

Parameters: id (path)

get/api/v1/flows/{id}/exportscope: flows:read

Export a flow as JSON (credential names only)

Parameters: id (path), version (query)

get/api/v1/runsscope: runs:read

List runs

Parameters: flow (query), status (query), from (query), page (query), limit (query)

get/api/v1/runs/{id}scope: runs:read

Run with steps (redacted previews)

Parameters: id (path)

post/api/v1/flows/{id}/runsscope: runs:write

Start a run of the published version (manual trigger)

Parameters: id (path)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "input": {},
    "idempotencyKey": {
      "type": "string",
      "maxLength": 200
    }
  },
  "additionalProperties": false
}
post/api/v1/runs/{id}/retryscope: runs:write

Retry a failed, timed-out or cancelled run

Parameters: id (path)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "fromStep": {
      "type": "boolean"
    }
  },
  "additionalProperties": false
}
post/api/v1/runs/{id}/cancelscope: runs:write

Cancel a run

Parameters: id (path)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {},
  "additionalProperties": false
}
get/api/v1/credentialsscope: vault:list

List credential names (values are never returned)