feat(Stripe Trigger Node): Add Stripe webhook descriptions based on the workflow ID and name (#9956)

This commit is contained in:
Javier Ferrer González 2024-08-07 11:40:04 +02:00 committed by GitHub
parent 0a84e0d8b0
commit 34334651e0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -865,12 +865,15 @@ export class StripeTrigger implements INodeType {
async create(this: IHookFunctions): Promise<boolean> {
const webhookUrl = this.getNodeWebhookUrl('default');
const webhookDescription = `Created by n8n for workflow ID: ${this.getWorkflow().id}`;
const events = this.getNodeParameter('events', []);
const endpoint = '/webhook_endpoints';
const body = {
url: webhookUrl,
description: webhookDescription,
enabled_events: events,
};