Example Webhook Payloads
There are multiple different workflow triggers. Each trigger has a different webhook payload.
Alarm
Created by the Alarm occurs trigger.
{
workflow: {
workflowId: 1,
name: 'monitor1',
},
trigger: {
triggerType: 'nc',
name: 'Alarm',
message: 'Some pre-built message based on the trigger',
nativeCode: 'test-nc',
},
machine: {
name: 'Machine Name',
machineId: 'webhook-machine-id-0',
machineRef: 1234,
},
company: {
name: 'Company Name',
companyId: 'some-company-id',
},
event: {
timestamp: '2021-05-20T10:00:00.000Z',
eventType: 'alarm',
}
}
Annotation
Created by the Downtime categorized as trigger.
{
workflow: {
workflowId: 5,
name: 'monitor5',
},
trigger: {
triggerType: 'annotation',
name: 'Downtime',
message: 'Some pre-built-message based on the trigger',
},
machine: {
name: 'Machine Name',
machineId: 'webhook-machine-id-0',
machineRef: 1234,
},
company: {
name: 'Company Name',
companyId: 'some-company-id',
},
event: {
timestamp: '2021-05-20T10:00:00.000Z',
eventType: 'annotation',
eventData: {
annotationId: 1,
message: 'No Downtime Notes',
start: '2020-10-01T15:33.034Z',
end: null,
annotationType: {
annotationTypeId: 22,
name: 'Test | Hierarchical | Type',
},
},
},
}
Downtime
Created by the Machine reports inactive trigger.
{
workflow: {
workflowId: 6,
name: 'monitor6',
},
trigger: {
triggerType: 'downtime',
name: 'Inactivity',
message: 'Trigger message',
downtimeMs: 1000,
},
machine: {
name: 'Machine Name',
machineId: 'webhook-machine-id-0',
machineRef: 1234,
},
company: {
name: 'Company Name',
companyId: 'some-company-id',
},
event: {
timestamp: '2021-05-20T10:00:00.000Z',
eventType: 'downtime',
}
}
Scheduled (Single Machine Selected)
Created by the Scheduled trigger when only a single machine is selected for the workflow.
{
workflow: {
workflowId: 6,
name: 'monitor6'
},
trigger: {
triggerType: 'scheduled',
name: 'Scheduled',
message: 'Test Payload'
},
machine: {
name: 'Machine Name'
machineId: 'webhook-machine-id-0',
machineRef: 1234,
},
company: {
name: 'Company Name',
companyId: 'some-company-id',
timezone: 'America/New_York'
},
event: {
timestamp: '2021-05-20T10:00:00.000Z',
eventType: 'scheduled'
}
}
Scheduled (All Machines)
Created by the Scheduled trigger when "All Machines" is selected fro the workflow.
{
workflow: {
workflowId: 6,
name: 'monitor6'
},
trigger: {
triggerType: 'scheduled',
name: 'Scheduled',
message: 'Test Payload'
},
machine: {
},
company: {
name: 'Company Name',
companyId: 'some-company-id',
timezone: 'America/New_York'
},
event: {
timestamp: '2021-05-20T10:00:00.000Z',
eventType: 'scheduled'
}
}