mirror of
https://github.com/n8n-io/n8n-nodes-starter.git
synced 2025-11-01 15:52:24 -05:00
feat: Add Resend node and trigger
Adds a new integration for Resend, an email sending service. Includes: - Resend API credential (`ResendApi.credentials.ts`) for API key authentication. - Resend action node (`nodes/Resend/Resend.node.ts`): - Supports "Send Email" operation with parameters for to, from, subject, html, text, cc, bcc, reply_to, and tags. - Uses Resend API `https://api.resend.com/emails`. - Resend trigger node (`nodes/Resend/ResendTrigger.node.ts`): - Handles Resend webhooks for various event types (email.sent, email.delivered, etc.). - Implements webhook signature verification using Svix and a user-provided signing secret. - Allows you to select which events to listen for. - Official Resend SVG icon (`nodes/Resend/Resend.svg`). - Adds `svix` as a dependency for webhook verification.
This commit is contained in:
parent
65e06338e3
commit
30fca2b5d5
6 changed files with 5148 additions and 0 deletions
27
credentials/ResendApi.credentials.ts
Normal file
27
credentials/ResendApi.credentials.ts
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
import {
|
||||
ICredentialType,
|
||||
INodeProperties,
|
||||
IAuthData,
|
||||
} from 'n8n-workflow';
|
||||
|
||||
export class ResendApi implements ICredentialType {
|
||||
name = 'resendApi';
|
||||
displayName = 'Resend API';
|
||||
documentationUrl = 'https://resend.com/docs/api-reference/introduction';
|
||||
properties: INodeProperties[] = [
|
||||
{
|
||||
displayName: 'API Key',
|
||||
name: 'apiKey',
|
||||
type: 'string',
|
||||
default: '',
|
||||
required: true,
|
||||
},
|
||||
];
|
||||
// Use IAuthData for authentication
|
||||
authenticate: IAuthData = {
|
||||
type: 'apiToken',
|
||||
properties: {
|
||||
token: '={{$credentials.apiKey}}'
|
||||
}
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue