Get App Event List
This endpoint provides a comprehensive list of workflow events within your organisation, detailing each event's metadata, associated app, and type (e.g., actions or triggers). It allows organisations to explore event functionality, integrate seamlessly with external systems, and optimise event usage within workflows.
Syntax: see 'CCall Structure
Type = 'GET'
'https://connect.cambrionix.com/api/workflows/v1/apps/app-id/events' |
Output | Description |
---|---|
app-id | This is the id of the app as a unique 128-bit number |
Returns:
{ "result": [ { "created": { "time": time }, "updated": { "time": time }, "id": "event-id", "name": "event-name", "description": "event-description", "type": "event-type", "app": { "id": "app-id" }, "schema": { "options": { "type": "schema-type", "properties": {}, "default": {} }, "output": { "type": "schema-type", "properties": { "success": { "type": "schema-type", "default": true } }, "default": {} } } } ] } |
Output | Description |
---|---|
time | The hub time, shown as an integer in ms |
app-id | This is the id of the app as a unique 128-bit number |
event-id | This is the id of the event as a unique 128-bit number |
event-name | This is the name of the event |
event-description | This is a description of the event |
event-type | This is the type of event see Event Types |
schema-type | This is the type of Schema for the event see Schema Types |
Example
curl -X 'GET' \
'https://connect.cambrionix.com/api/workflows/v1/apps/00000000-0000-0000-0000-000000000001/events' \
-H 'accept: application/json' \
-H 'Authorization: Bearer eyJhbGciOiJSUzI1NiIsIMS05ZDhmLWQxOTZiYmY0NTJlYSIsInR5cC
Returns
{
"result": [
{
"created": {
"time": 1731663026837
},
"updated": {
"time": 1731663026837
},
"id": "00000000-0000-0000-0000-000000000005",
"name": "Switch All Ports Off",
"description": "Switches all ports off on all hubs.",
"type": "action",
"app": {
"id": "00000000-0000-0000-0000-000000000001"
},
"schema": {
"options": {
"type": "object",
"properties": {},
"default": {}
},
"output": {
"type": "object",
"properties": {
"success": {
"type": "boolean",
"default": true
}
},
"default": {}
}
}
},
{
"created": {
"time": 1731663026799
},
"updated": {
"time": 1731663026799
},
"id": "00000000-0000-0000-0000-000000000006",
"name": "Switch All Ports On",
"description": "Switches all ports on for all available Hubs.",
"type": "action",
"app": {
"id": "00000000-0000-0000-0000-000000000001"
},
"schema": {
"options": {
"type": "object",
"properties": {
"waitForPortSync": {
"title": "Wait for Port Sync",
"description": "Workflow awaits for a response from all ports with a device attached that were switched off.",
"type": "boolean",
"default": true
}
},
"default": {}
},
"output": {
"type": "object",
"properties": {
"success": {
"type": "boolean",
"default": true
}
},
"default": {}
}
}
},
{
"created": {
"time": 1731663026693
},
"updated": {
"time": 1731663026693
},
"id": "00000000-0000-0000-0000-000000000007",
"name": "Switch Ports Off When Charged",
"description": "Switches any port off that has met provided charge level",
"type": "action",
"app": {
"id": "00000000-0000-0000-0000-000000000001"
},
"schema": {
"options": {
"type": "object",
"properties": {
"chargeLevel": {
"title": "Charge Level",
"description": "The charge level at which to switch the port off",
"type": "number",
"default": 80,
"minimum": 0,
"maximum": 100
}
},
"default": {
"chargeLevel": 80
}
},
"output": {
"type": "object",
"properties": {
"success": {
"type": "boolean",
"default": true
}
},
"default": {}
}
}
}
]
}
Errors
If there is an error in the API method then JSON-RPC Error Object a will be returned