feat: Convert all app files to JS
This commit is contained in:
@@ -1,17 +1,6 @@
|
||||
import Crypto from 'crypto';
|
||||
import isEmpty from 'lodash/isEmpty';
|
||||
import defineTrigger from '../../../../helpers/define-trigger';
|
||||
|
||||
type Response = {
|
||||
data: {
|
||||
data: {
|
||||
id: string;
|
||||
event_id: string;
|
||||
target_url: string;
|
||||
format: string;
|
||||
};
|
||||
};
|
||||
};
|
||||
import isEmpty from 'lodash/isEmpty.js';
|
||||
import defineTrigger from '../../../../helpers/define-trigger.js';
|
||||
|
||||
export default defineTrigger({
|
||||
name: 'New invoices',
|
||||
@@ -54,7 +43,7 @@ export default defineTrigger({
|
||||
rest_method: 'post',
|
||||
};
|
||||
|
||||
const response: Response = await $.http.post('/v1/webhooks', payload);
|
||||
const response = await $.http.post('/v1/webhooks', payload);
|
||||
|
||||
await $.flow.setRemoteWebhookId(response.data.data.id);
|
||||
},
|
Reference in New Issue
Block a user