feat(webhook): add webhook application

This commit is contained in:
Ali BARIN
2022-12-07 23:41:46 +01:00
parent 67964192de
commit 3c62f182ab
13 changed files with 107 additions and 20 deletions

View File

@@ -0,0 +1,20 @@
import isEmpty from 'lodash/isEmpty';
import defineTrigger from '../../../../helpers/define-trigger';
export default defineTrigger({
name: 'Catch raw webhook',
key: 'catchRawWebhook',
type: 'webhook',
description: 'Triggers when the webhook receives a request.',
async testRun($) {
if (!isEmpty($.lastExecutionStep?.dataOut)) {
$.pushTriggerItem({
raw: $.lastExecutionStep.dataOut,
meta: {
internalId: '',
}
});
}
},
});