n8n-nodes-cakemail 1.6.2 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +235 -0
- package/SECURITY.md +91 -0
- package/credentials/CakemailApi.credentials.ts +47 -0
- package/dist/credentials/CakemailApi.credentials.d.ts +1 -10
- package/dist/credentials/CakemailApi.credentials.js +41 -63
- package/dist/nodes/Cakemail/Cakemail.node.d.ts +1 -98
- package/dist/nodes/Cakemail/Cakemail.node.js +1284 -3761
- package/dist/nodes/Cakemail/__tests__/Cakemail.node.test.js +4 -6
- package/dist/nodes/Cakemail/resources/account.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/account.operations.js +37 -0
- package/dist/nodes/Cakemail/resources/action.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/action.operations.js +463 -0
- package/dist/nodes/Cakemail/resources/campaign.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/campaign.operations.js +652 -0
- package/dist/nodes/Cakemail/resources/campaign_blueprint.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/campaign_blueprint.operations.js +111 -0
- package/dist/nodes/Cakemail/resources/contact.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/contact.operations.js +784 -0
- package/dist/nodes/Cakemail/resources/custom_attribute.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/custom_attribute.operations.js +163 -0
- package/dist/nodes/Cakemail/resources/dkim.operations.d.ts +1 -1
- package/dist/nodes/Cakemail/resources/dkim.operations.js +45 -53
- package/dist/nodes/Cakemail/resources/domain.operations.d.ts +1 -1
- package/dist/nodes/Cakemail/resources/domain.operations.js +28 -81
- package/dist/nodes/Cakemail/resources/email_api.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/email_api.operations.js +430 -0
- package/dist/nodes/Cakemail/resources/form.operations.d.ts +1 -1
- package/dist/nodes/Cakemail/resources/form.operations.js +171 -186
- package/dist/nodes/Cakemail/resources/index.d.ts +30 -13
- package/dist/nodes/Cakemail/resources/index.js +32 -29
- package/dist/nodes/Cakemail/resources/interest.operations.d.ts +1 -1
- package/dist/nodes/Cakemail/resources/interest.operations.js +115 -94
- package/dist/nodes/Cakemail/resources/links.operations.d.ts +1 -1
- package/dist/nodes/Cakemail/resources/links.operations.js +18 -18
- package/dist/nodes/Cakemail/resources/list.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/list.operations.js +528 -0
- package/dist/nodes/Cakemail/resources/log.operations.d.ts +1 -1
- package/dist/nodes/Cakemail/resources/log.operations.js +452 -87
- package/dist/nodes/Cakemail/resources/logo.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/logo.operations.js +54 -0
- package/dist/nodes/Cakemail/resources/report.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/report.operations.js +397 -0
- package/dist/nodes/Cakemail/resources/segment.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/segment.operations.js +207 -0
- package/dist/nodes/Cakemail/resources/sender.operations.d.ts +1 -1
- package/dist/nodes/Cakemail/resources/sender.operations.js +124 -110
- package/dist/nodes/Cakemail/resources/sub-account.operations.d.ts +1 -0
- package/dist/nodes/Cakemail/resources/sub-account.operations.js +311 -0
- package/dist/nodes/Cakemail/resources/subAccount.operations.js +1 -4
- package/dist/nodes/Cakemail/resources/sub_account.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/sub_account.operations.js +309 -0
- package/dist/nodes/Cakemail/resources/suppressedEmail.operations.js +1 -4
- package/dist/nodes/Cakemail/resources/suppressed_email.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/suppressed_email.operations.js +239 -0
- package/dist/nodes/Cakemail/resources/system_email.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/system_email.operations.js +37 -0
- package/dist/nodes/Cakemail/resources/tags.operations.d.ts +1 -1
- package/dist/nodes/Cakemail/resources/tags.operations.js +84 -146
- package/dist/nodes/Cakemail/resources/task.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/task.operations.js +157 -0
- package/dist/nodes/Cakemail/resources/template.operations.d.ts +1 -1
- package/dist/nodes/Cakemail/resources/template.operations.js +58 -216
- package/dist/nodes/Cakemail/resources/token.operations.d.ts +1 -1
- package/dist/nodes/Cakemail/resources/token.operations.js +50 -71
- package/dist/nodes/Cakemail/resources/transactional_email.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/transactional_email.operations.js +425 -0
- package/dist/nodes/Cakemail/resources/user.operations.d.ts +1 -1
- package/dist/nodes/Cakemail/resources/user.operations.js +441 -204
- package/dist/nodes/Cakemail/resources/webhook.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/webhook.operations.js +279 -0
- package/dist/nodes/Cakemail/resources/workflow.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/workflow.operations.js +432 -0
- package/dist/nodes/Cakemail/resources/workflow_blueprint.operations.d.ts +2 -0
- package/dist/nodes/Cakemail/resources/workflow_blueprint.operations.js +162 -0
- package/dist/nodes/CakemailTrigger/CakemailTrigger.node.d.ts +1 -1
- package/dist/nodes/CakemailTrigger/CakemailTrigger.node.js +308 -342
- package/jest.config.js +15 -0
- package/nodes/Cakemail/Cakemail.node.ts +1247 -4492
- package/nodes/Cakemail/resources/account.operations.ts +40 -0
- package/nodes/Cakemail/resources/action.operations.ts +483 -0
- package/nodes/Cakemail/resources/campaign.operations.ts +680 -0
- package/nodes/Cakemail/resources/campaign_blueprint.operations.ts +117 -0
- package/nodes/Cakemail/resources/contact.operations.ts +814 -0
- package/nodes/Cakemail/resources/custom_attribute.operations.ts +173 -0
- package/nodes/Cakemail/resources/dkim.operations.ts +143 -145
- package/nodes/Cakemail/resources/domain.operations.ts +83 -133
- package/nodes/Cakemail/resources/email_api.operations.ts +440 -0
- package/nodes/Cakemail/resources/form.operations.ts +326 -330
- package/nodes/Cakemail/resources/index.ts +33 -13
- package/nodes/Cakemail/resources/interest.operations.ts +281 -250
- package/nodes/Cakemail/resources/links.operations.ts +64 -59
- package/nodes/Cakemail/resources/list.operations.ts +551 -0
- package/nodes/Cakemail/resources/log.operations.ts +570 -186
- package/nodes/Cakemail/resources/logo.operations.ts +58 -0
- package/nodes/Cakemail/resources/report.operations.ts +413 -0
- package/nodes/Cakemail/resources/segment.operations.ts +218 -0
- package/nodes/Cakemail/resources/sender.operations.ts +315 -291
- package/nodes/Cakemail/resources/sub_account.operations.ts +323 -0
- package/nodes/Cakemail/resources/suppressed_email.operations.ts +250 -0
- package/nodes/Cakemail/resources/system_email.operations.ts +40 -0
- package/nodes/Cakemail/resources/tags.operations.ts +211 -266
- package/nodes/Cakemail/resources/task.operations.ts +165 -0
- package/nodes/Cakemail/resources/template.operations.ts +206 -359
- package/nodes/Cakemail/resources/token.operations.ts +97 -115
- package/nodes/Cakemail/resources/transactional_email.operations.ts +443 -0
- package/nodes/Cakemail/resources/user.operations.ts +677 -416
- package/nodes/Cakemail/resources/webhook.operations.ts +292 -0
- package/nodes/Cakemail/resources/workflow.operations.ts +451 -0
- package/nodes/Cakemail/resources/workflow_blueprint.operations.ts +170 -0
- package/package.json +19 -41
- package/test-webhook.js +32 -0
- package/tsconfig.json +15 -0
- package/nodes/Cakemail/__tests__/Cakemail.node.test.ts +0 -467
- package/nodes/Cakemail/cakemail.svg +0 -365
- package/nodes/Cakemail/resources/subAccount.operations.ts +0 -393
- package/nodes/Cakemail/resources/suppressedEmail.operations.ts +0 -338
- package/nodes/CakemailTrigger/CakemailTrigger.node.ts +0 -460
package/README.md
ADDED
|
@@ -0,0 +1,235 @@
|
|
|
1
|
+
# n8n-nodes-cakemail
|
|
2
|
+
|
|
3
|
+
Community node for integrating [Cakemail](https://www.cakemail.com) with [n8n](https://n8n.io), providing complete email marketing automation capabilities.
|
|
4
|
+
|
|
5
|
+

|
|
6
|
+
|
|
7
|
+
## Features
|
|
8
|
+
|
|
9
|
+
- **22 Resources** with **130+ operations**
|
|
10
|
+
- Full Cakemail API coverage
|
|
11
|
+
- Webhook trigger support
|
|
12
|
+
- Multi-tenant account management
|
|
13
|
+
- Built with TypeScript and the official [@cakemail-org/cakemail-sdk](https://www.npmjs.com/package/@cakemail-org/cakemail-sdk)
|
|
14
|
+
|
|
15
|
+
### Supported Resources
|
|
16
|
+
|
|
17
|
+
- **Campaigns** - Create, send, and manage email campaigns
|
|
18
|
+
- **Contacts** - Manage contact lists and subscriber data
|
|
19
|
+
- **Lists** - Create and organize mailing lists
|
|
20
|
+
- **Segments** - Target specific audiences with segments
|
|
21
|
+
- **Templates** - Design and manage email templates
|
|
22
|
+
- **Forms** - Create signup and preference forms
|
|
23
|
+
- **Senders** - Manage sender profiles
|
|
24
|
+
- **Domains** - Configure and verify sending domains
|
|
25
|
+
- **DKIM** - Set up email authentication
|
|
26
|
+
- **Relays** - Configure SMTP relay settings
|
|
27
|
+
- **Links** - Track and manage campaign links
|
|
28
|
+
- **Logs** - Access email delivery logs
|
|
29
|
+
- **Users** - Manage team members and permissions
|
|
30
|
+
- **Sub-accounts** - Handle multi-tenant account structures
|
|
31
|
+
- **Tokens** - Manage API tokens
|
|
32
|
+
- **Interests** - Set up subscriber interest categories
|
|
33
|
+
- **Tags** - Organize contacts with tags
|
|
34
|
+
- **Suppressed Emails** - Manage bounce and unsubscribe lists
|
|
35
|
+
- And more...
|
|
36
|
+
|
|
37
|
+
## Installation
|
|
38
|
+
|
|
39
|
+
### Community Node (Recommended)
|
|
40
|
+
|
|
41
|
+
Install directly in n8n:
|
|
42
|
+
|
|
43
|
+
1. Go to **Settings** > **Community Nodes**
|
|
44
|
+
2. Select **Install**
|
|
45
|
+
3. Enter `n8n-nodes-cakemail`
|
|
46
|
+
4. Click **Install**
|
|
47
|
+
|
|
48
|
+
### Manual Installation
|
|
49
|
+
|
|
50
|
+
For self-hosted n8n instances:
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
npm install n8n-nodes-cakemail
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
Restart your n8n instance after installation.
|
|
57
|
+
|
|
58
|
+
## Configuration
|
|
59
|
+
|
|
60
|
+
### 1. Create Cakemail Credentials
|
|
61
|
+
|
|
62
|
+
1. In n8n, go to **Credentials** > **New**
|
|
63
|
+
2. Search for **Cakemail API**
|
|
64
|
+
3. Enter your credentials:
|
|
65
|
+
- **Email**: Your Cakemail account email
|
|
66
|
+
- **Password**: Your Cakemail account password
|
|
67
|
+
- **API Base URL** (optional): Default is `https://api.cakemail.dev`
|
|
68
|
+
|
|
69
|
+
### 2. Test Connection
|
|
70
|
+
|
|
71
|
+
Click **Test** to verify your credentials are working correctly.
|
|
72
|
+
|
|
73
|
+
## Usage
|
|
74
|
+
|
|
75
|
+
### Basic Workflow Example
|
|
76
|
+
|
|
77
|
+
Here's a simple workflow to create a contact:
|
|
78
|
+
|
|
79
|
+
1. Add a **Cakemail** node to your workflow
|
|
80
|
+
2. Select your Cakemail credentials
|
|
81
|
+
3. Choose **Resource**: `Contact`
|
|
82
|
+
4. Choose **Operation**: `Create`
|
|
83
|
+
5. Fill in the required fields:
|
|
84
|
+
- List ID
|
|
85
|
+
- Email address
|
|
86
|
+
- Additional contact details
|
|
87
|
+
|
|
88
|
+
### Using the Trigger Node
|
|
89
|
+
|
|
90
|
+
The **Cakemail Trigger** node allows you to react to webhook events:
|
|
91
|
+
|
|
92
|
+
1. Add a **Cakemail Trigger** node
|
|
93
|
+
2. Select your Cakemail credentials
|
|
94
|
+
3. Choose the event type to listen for:
|
|
95
|
+
- Campaign sent
|
|
96
|
+
- Contact subscribed
|
|
97
|
+
- Contact unsubscribed
|
|
98
|
+
- Email bounced
|
|
99
|
+
- Link clicked
|
|
100
|
+
- And more...
|
|
101
|
+
|
|
102
|
+
### Common Use Cases
|
|
103
|
+
|
|
104
|
+
#### Automated Welcome Email
|
|
105
|
+
|
|
106
|
+
```
|
|
107
|
+
Manual Trigger → Create Contact → Send Campaign
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
#### Sync Contacts from CRM
|
|
111
|
+
|
|
112
|
+
```
|
|
113
|
+
Schedule Trigger → Get CRM Contacts → Create/Update Cakemail Contacts
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
#### Bounce Handling
|
|
117
|
+
|
|
118
|
+
```
|
|
119
|
+
Cakemail Trigger (Bounce) → Update CRM → Send Notification
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
## Development
|
|
123
|
+
|
|
124
|
+
### Prerequisites
|
|
125
|
+
|
|
126
|
+
- Node.js 18+
|
|
127
|
+
- npm or yarn
|
|
128
|
+
- n8n (for testing)
|
|
129
|
+
|
|
130
|
+
### Setup
|
|
131
|
+
|
|
132
|
+
```bash
|
|
133
|
+
# Clone the repository
|
|
134
|
+
git clone https://github.com/cakemail/n8n-nodes-cakemail.git
|
|
135
|
+
cd n8n-nodes-cakemail
|
|
136
|
+
|
|
137
|
+
# Install dependencies
|
|
138
|
+
npm install
|
|
139
|
+
|
|
140
|
+
# Build the project
|
|
141
|
+
npm run build
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
### Development Workflow
|
|
145
|
+
|
|
146
|
+
```bash
|
|
147
|
+
# Clean previous builds
|
|
148
|
+
npm run clean
|
|
149
|
+
|
|
150
|
+
# Build TypeScript
|
|
151
|
+
npm run build
|
|
152
|
+
|
|
153
|
+
# Run tests
|
|
154
|
+
npm run test
|
|
155
|
+
|
|
156
|
+
# Lint code
|
|
157
|
+
npm run lint
|
|
158
|
+
```
|
|
159
|
+
|
|
160
|
+
### Project Structure
|
|
161
|
+
|
|
162
|
+
```
|
|
163
|
+
n8n-nodes-cakemail/
|
|
164
|
+
├── credentials/
|
|
165
|
+
│ └── CakemailApi.credentials.ts # API authentication
|
|
166
|
+
├── nodes/
|
|
167
|
+
│ ├── Cakemail/
|
|
168
|
+
│ │ ├── Cakemail.node.ts # Main node
|
|
169
|
+
│ │ ├── cakemail.svg # Node icon
|
|
170
|
+
│ │ └── resources/ # Resource operations
|
|
171
|
+
│ │ ├── sender.operations.ts
|
|
172
|
+
│ │ ├── template.operations.ts
|
|
173
|
+
│ │ ├── domain.operations.ts
|
|
174
|
+
│ │ └── ... (13 more resources)
|
|
175
|
+
│ └── CakemailTrigger/
|
|
176
|
+
│ └── CakemailTrigger.node.ts # Webhook trigger node
|
|
177
|
+
├── src/ # Source utilities
|
|
178
|
+
├── dist/ # Compiled output
|
|
179
|
+
└── package.json
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
### Testing Locally with n8n
|
|
183
|
+
|
|
184
|
+
To test your changes in a local n8n instance:
|
|
185
|
+
|
|
186
|
+
```bash
|
|
187
|
+
# 1. Build the package
|
|
188
|
+
npm run build
|
|
189
|
+
|
|
190
|
+
# 2. Link the package globally
|
|
191
|
+
npm link
|
|
192
|
+
|
|
193
|
+
# 3. In your n8n installation directory
|
|
194
|
+
cd /path/to/n8n
|
|
195
|
+
npm link n8n-nodes-cakemail
|
|
196
|
+
|
|
197
|
+
# 4. Restart n8n
|
|
198
|
+
n8n start
|
|
199
|
+
```
|
|
200
|
+
|
|
201
|
+
## Resources
|
|
202
|
+
|
|
203
|
+
- [Cakemail API Documentation](https://docs.cakemail.com)
|
|
204
|
+
- [Cakemail SDK](https://github.com/cakemail/cakemail-sdk)
|
|
205
|
+
- [n8n Documentation](https://docs.n8n.io)
|
|
206
|
+
- [n8n Community Nodes](https://docs.n8n.io/integrations/community-nodes/)
|
|
207
|
+
|
|
208
|
+
## Support
|
|
209
|
+
|
|
210
|
+
For issues, questions, or contributions:
|
|
211
|
+
|
|
212
|
+
- [GitHub Issues](https://github.com/cakemail/n8n-nodes-cakemail/issues)
|
|
213
|
+
- [Cakemail Support](https://www.cakemail.com/support)
|
|
214
|
+
|
|
215
|
+
## Contributing
|
|
216
|
+
|
|
217
|
+
Contributions are welcome! Please feel free to submit a Pull Request.
|
|
218
|
+
|
|
219
|
+
1. Fork the repository
|
|
220
|
+
2. Create your feature branch (`git checkout -b feature/amazing-feature`)
|
|
221
|
+
3. Commit your changes (`git commit -m 'Add some amazing feature'`)
|
|
222
|
+
4. Push to the branch (`git push origin feature/amazing-feature`)
|
|
223
|
+
5. Open a Pull Request
|
|
224
|
+
|
|
225
|
+
## License
|
|
226
|
+
|
|
227
|
+
MIT License - see the [LICENSE](LICENSE) file for details.
|
|
228
|
+
|
|
229
|
+
## Keywords
|
|
230
|
+
|
|
231
|
+
`n8n` `n8n-community-node-package` `cakemail` `email` `marketing` `automation` `multi-tenant`
|
|
232
|
+
|
|
233
|
+
---
|
|
234
|
+
|
|
235
|
+
Made with ❤️ by [Cakemail](https://www.cakemail.com)
|
package/SECURITY.md
ADDED
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
# Security Policy
|
|
2
|
+
|
|
3
|
+
## Supported Versions
|
|
4
|
+
|
|
5
|
+
We release patches for security vulnerabilities in the following versions:
|
|
6
|
+
|
|
7
|
+
| Version | Supported |
|
|
8
|
+
| ------- | ------------------ |
|
|
9
|
+
| 1.6.x | :white_check_mark: |
|
|
10
|
+
| < 1.6 | :x: |
|
|
11
|
+
|
|
12
|
+
## Reporting a Vulnerability
|
|
13
|
+
|
|
14
|
+
We take the security of n8n-nodes-cakemail seriously. If you believe you have found a security vulnerability, please report it to us as described below.
|
|
15
|
+
|
|
16
|
+
### How to Report
|
|
17
|
+
|
|
18
|
+
**Please do not report security vulnerabilities through public GitHub issues.**
|
|
19
|
+
|
|
20
|
+
Instead, please report them via email to:
|
|
21
|
+
|
|
22
|
+
- **Email**: security@cakemail.com
|
|
23
|
+
- **Subject**: [SECURITY] n8n-nodes-cakemail vulnerability report
|
|
24
|
+
|
|
25
|
+
### What to Include
|
|
26
|
+
|
|
27
|
+
Please include the following information in your report:
|
|
28
|
+
|
|
29
|
+
- Type of vulnerability
|
|
30
|
+
- Full paths of source file(s) related to the manifestation of the vulnerability
|
|
31
|
+
- The location of the affected source code (tag/branch/commit or direct URL)
|
|
32
|
+
- Step-by-step instructions to reproduce the issue
|
|
33
|
+
- Proof-of-concept or exploit code (if possible)
|
|
34
|
+
- Impact of the issue, including how an attacker might exploit it
|
|
35
|
+
|
|
36
|
+
### What to Expect
|
|
37
|
+
|
|
38
|
+
- You should receive an acknowledgment within 48 hours
|
|
39
|
+
- We will investigate and provide an initial assessment within 7 days
|
|
40
|
+
- We will keep you informed about our progress toward a fix
|
|
41
|
+
- We will publicly acknowledge your responsible disclosure, unless you prefer to remain anonymous
|
|
42
|
+
|
|
43
|
+
## Security Best Practices
|
|
44
|
+
|
|
45
|
+
When using this package:
|
|
46
|
+
|
|
47
|
+
1. **Keep your credentials secure**: Never commit credentials to version control
|
|
48
|
+
2. **Use environment variables**: Store sensitive data like API keys in environment variables
|
|
49
|
+
3. **Update regularly**: Keep the package updated to receive security patches
|
|
50
|
+
4. **Validate webhook signatures**: The webhook trigger node validates signatures to prevent unauthorized requests
|
|
51
|
+
5. **Use HTTPS**: Always use HTTPS URLs for webhook endpoints in production
|
|
52
|
+
|
|
53
|
+
## Known Security Considerations
|
|
54
|
+
|
|
55
|
+
### Webhook Signature Verification
|
|
56
|
+
|
|
57
|
+
The Cakemail Trigger node implements HMAC SHA256 signature verification for incoming webhooks. However, in some n8n hosting environments where `rawBody` is not available, signature verification may be skipped. We recommend:
|
|
58
|
+
|
|
59
|
+
- Hosting n8n in environments that support `rawBody` access
|
|
60
|
+
- Implementing additional security measures like IP allowlisting
|
|
61
|
+
- Using rate limiting to prevent abuse
|
|
62
|
+
|
|
63
|
+
### Dependencies
|
|
64
|
+
|
|
65
|
+
This package relies on:
|
|
66
|
+
|
|
67
|
+
- `@cakemail-org/cakemail-sdk` - Official Cakemail SDK
|
|
68
|
+
- `n8n-workflow` - n8n workflow library (dev dependency)
|
|
69
|
+
|
|
70
|
+
We regularly monitor and update dependencies to address security vulnerabilities.
|
|
71
|
+
|
|
72
|
+
## Security Updates
|
|
73
|
+
|
|
74
|
+
Security updates will be released as patch versions and announced through:
|
|
75
|
+
|
|
76
|
+
- GitHub Security Advisories
|
|
77
|
+
- Release notes
|
|
78
|
+
- npm package updates
|
|
79
|
+
|
|
80
|
+
Subscribe to releases and security advisories on our [GitHub repository](https://github.com/cakemail/n8n-nodes-cakemail) to stay informed.
|
|
81
|
+
|
|
82
|
+
## Contact
|
|
83
|
+
|
|
84
|
+
For general security questions or concerns, please contact:
|
|
85
|
+
|
|
86
|
+
- **Email**: security@cakemail.com
|
|
87
|
+
- **Website**: https://www.cakemail.com/security
|
|
88
|
+
|
|
89
|
+
---
|
|
90
|
+
|
|
91
|
+
Thank you for helping keep n8n-nodes-cakemail and its users safe!
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
// ABOUTME: n8n credentials for the Cakemail API.
|
|
2
|
+
// ABOUTME: Generated by api-kit from the OpenAPI spec.
|
|
3
|
+
|
|
4
|
+
import type { ICredentialType, INodeProperties, ICredentialTestRequest } from 'n8n-workflow';
|
|
5
|
+
|
|
6
|
+
export class CakemailApi implements ICredentialType {
|
|
7
|
+
name = 'cakemailApi';
|
|
8
|
+
displayName = 'Cakemail API';
|
|
9
|
+
documentationUrl = 'https://dev.cakemail.com';
|
|
10
|
+
|
|
11
|
+
properties: INodeProperties[] = [
|
|
12
|
+
{
|
|
13
|
+
displayName: 'Email',
|
|
14
|
+
name: 'email',
|
|
15
|
+
type: 'string',
|
|
16
|
+
default: '',
|
|
17
|
+
required: true,
|
|
18
|
+
placeholder: 'your-email@example.com',
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
displayName: 'Password',
|
|
22
|
+
name: 'password',
|
|
23
|
+
type: 'string',
|
|
24
|
+
typeOptions: { password: true },
|
|
25
|
+
default: '',
|
|
26
|
+
required: true,
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
displayName: 'API Base URL',
|
|
30
|
+
name: 'baseURL',
|
|
31
|
+
type: 'string',
|
|
32
|
+
default: 'https://api.cakemail.dev',
|
|
33
|
+
required: false,
|
|
34
|
+
description: 'API base URL (advanced)',
|
|
35
|
+
},
|
|
36
|
+
];
|
|
37
|
+
|
|
38
|
+
test: ICredentialTestRequest = {
|
|
39
|
+
request: {
|
|
40
|
+
baseURL: '={{$credentials.baseURL || "https://api.cakemail.dev"}}',
|
|
41
|
+
url: '/token',
|
|
42
|
+
method: 'POST',
|
|
43
|
+
headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
|
|
44
|
+
body: '=grant_type=password&username={{encodeURIComponent($credentials.email)}}&password={{encodeURIComponent($credentials.password)}}',
|
|
45
|
+
},
|
|
46
|
+
};
|
|
47
|
+
}
|
|
@@ -1,17 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
/**
|
|
3
|
-
* Cakemail API credentials
|
|
4
|
-
*/
|
|
1
|
+
import type { ICredentialType, INodeProperties, ICredentialTestRequest } from 'n8n-workflow';
|
|
5
2
|
export declare class CakemailApi implements ICredentialType {
|
|
6
3
|
name: string;
|
|
7
4
|
displayName: string;
|
|
8
5
|
documentationUrl: string;
|
|
9
6
|
properties: INodeProperties[];
|
|
10
|
-
/**
|
|
11
|
-
* Test the credentials by attempting to authenticate
|
|
12
|
-
*
|
|
13
|
-
* Note: We don't use the 'authenticate' property because the Cakemail SDK
|
|
14
|
-
* handles OAuth2 authentication internally using the email and password.
|
|
15
|
-
*/
|
|
16
7
|
test: ICredentialTestRequest;
|
|
17
8
|
}
|
|
@@ -1,64 +1,42 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
},
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
description: 'Cakemail API base URL (advanced users only)',
|
|
43
|
-
},
|
|
44
|
-
];
|
|
45
|
-
/**
|
|
46
|
-
* Test the credentials by attempting to authenticate
|
|
47
|
-
*
|
|
48
|
-
* Note: We don't use the 'authenticate' property because the Cakemail SDK
|
|
49
|
-
* handles OAuth2 authentication internally using the email and password.
|
|
50
|
-
*/
|
|
51
|
-
this.test = {
|
|
52
|
-
request: {
|
|
53
|
-
baseURL: '={{$credentials.baseURL || "https://api.cakemail.dev"}}',
|
|
54
|
-
url: '/token',
|
|
55
|
-
method: 'POST',
|
|
56
|
-
headers: {
|
|
57
|
-
'Content-Type': 'application/x-www-form-urlencoded',
|
|
58
|
-
},
|
|
59
|
-
body: '=grant_type=password&username={{encodeURIComponent($credentials.email)}}&password={{encodeURIComponent($credentials.password)}}',
|
|
60
|
-
},
|
|
61
|
-
};
|
|
62
|
-
}
|
|
1
|
+
// ABOUTME: n8n credentials for the Cakemail API.
|
|
2
|
+
// ABOUTME: Generated by api-kit from the OpenAPI spec.
|
|
3
|
+
export class CakemailApi {
|
|
4
|
+
name = 'cakemailApi';
|
|
5
|
+
displayName = 'Cakemail API';
|
|
6
|
+
documentationUrl = 'https://dev.cakemail.com';
|
|
7
|
+
properties = [
|
|
8
|
+
{
|
|
9
|
+
displayName: 'Email',
|
|
10
|
+
name: 'email',
|
|
11
|
+
type: 'string',
|
|
12
|
+
default: '',
|
|
13
|
+
required: true,
|
|
14
|
+
placeholder: 'your-email@example.com',
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
displayName: 'Password',
|
|
18
|
+
name: 'password',
|
|
19
|
+
type: 'string',
|
|
20
|
+
typeOptions: { password: true },
|
|
21
|
+
default: '',
|
|
22
|
+
required: true,
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
displayName: 'API Base URL',
|
|
26
|
+
name: 'baseURL',
|
|
27
|
+
type: 'string',
|
|
28
|
+
default: 'https://api.cakemail.dev',
|
|
29
|
+
required: false,
|
|
30
|
+
description: 'API base URL (advanced)',
|
|
31
|
+
},
|
|
32
|
+
];
|
|
33
|
+
test = {
|
|
34
|
+
request: {
|
|
35
|
+
baseURL: '={{$credentials.baseURL || "https://api.cakemail.dev"}}',
|
|
36
|
+
url: '/token',
|
|
37
|
+
method: 'POST',
|
|
38
|
+
headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
|
|
39
|
+
body: '=grant_type=password&username={{encodeURIComponent($credentials.email)}}&password={{encodeURIComponent($credentials.password)}}',
|
|
40
|
+
},
|
|
41
|
+
};
|
|
63
42
|
}
|
|
64
|
-
exports.CakemailApi = CakemailApi;
|
|
@@ -1,102 +1,5 @@
|
|
|
1
|
-
import { IExecuteFunctions, INodeExecutionData, INodeType, INodeTypeDescription } from 'n8n-workflow';
|
|
2
|
-
/**
|
|
3
|
-
* Cakemail n8n node
|
|
4
|
-
*/
|
|
1
|
+
import type { IExecuteFunctions, INodeExecutionData, INodeType, INodeTypeDescription } from 'n8n-workflow';
|
|
5
2
|
export declare class Cakemail implements INodeType {
|
|
6
3
|
description: INodeTypeDescription;
|
|
7
4
|
execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]>;
|
|
8
|
-
/**
|
|
9
|
-
* Execute account operations
|
|
10
|
-
*/
|
|
11
|
-
private executeAccountOperation;
|
|
12
|
-
/**
|
|
13
|
-
* Execute contact operations
|
|
14
|
-
*/
|
|
15
|
-
private executeContactOperation;
|
|
16
|
-
/**
|
|
17
|
-
* Execute list operations
|
|
18
|
-
*/
|
|
19
|
-
private executeListOperation;
|
|
20
|
-
/**
|
|
21
|
-
* Execute campaign operations
|
|
22
|
-
*/
|
|
23
|
-
private executeCampaignOperation;
|
|
24
|
-
/**
|
|
25
|
-
* Execute email operations
|
|
26
|
-
*/
|
|
27
|
-
private executeEmailOperation;
|
|
28
|
-
/**
|
|
29
|
-
* Execute custom attribute operations
|
|
30
|
-
*/
|
|
31
|
-
private executeCustomAttributeOperation;
|
|
32
|
-
/**
|
|
33
|
-
* Execute webhook operations
|
|
34
|
-
*/
|
|
35
|
-
private executeWebhookOperation;
|
|
36
|
-
/**
|
|
37
|
-
* Execute report operations
|
|
38
|
-
*/
|
|
39
|
-
private executeReportOperation;
|
|
40
|
-
/**
|
|
41
|
-
* Execute segment operations
|
|
42
|
-
*/
|
|
43
|
-
private executeSegmentOperation;
|
|
44
|
-
/**
|
|
45
|
-
* Execute sender operations
|
|
46
|
-
*/
|
|
47
|
-
private executeSenderOperation;
|
|
48
|
-
/**
|
|
49
|
-
* Execute template operations
|
|
50
|
-
*/
|
|
51
|
-
private executeTemplateOperation;
|
|
52
|
-
/**
|
|
53
|
-
* Execute sub-account operations
|
|
54
|
-
*/
|
|
55
|
-
private executeSubAccountOperation;
|
|
56
|
-
/**
|
|
57
|
-
* Execute log operations
|
|
58
|
-
* Note: The SDK v2.0.0 LogService provides context-specific log methods
|
|
59
|
-
* (getCampaignLogs, getListLogs, getActionLogs) instead of generic log operations.
|
|
60
|
-
* This implementation is a placeholder that throws an error directing users
|
|
61
|
-
* to use the appropriate resource (Campaign, List, or Workflow) for log access.
|
|
62
|
-
*/
|
|
63
|
-
private executeLogOperation;
|
|
64
|
-
/**
|
|
65
|
-
* Execute user operations
|
|
66
|
-
*/
|
|
67
|
-
private executeUserOperation;
|
|
68
|
-
/**
|
|
69
|
-
* Execute domain operations
|
|
70
|
-
* Note: The SDK v2.0.0 DomainService handles Tracking and Bounce domains,
|
|
71
|
-
* not custom sender domains. Available operations: show, patch, validate.
|
|
72
|
-
*/
|
|
73
|
-
private executeDomainOperation;
|
|
74
|
-
/**
|
|
75
|
-
* Execute DKIM operations
|
|
76
|
-
*/
|
|
77
|
-
private executeDkimOperation;
|
|
78
|
-
/**
|
|
79
|
-
* Execute form operations
|
|
80
|
-
*/
|
|
81
|
-
private executeFormOperation;
|
|
82
|
-
/**
|
|
83
|
-
* Execute token operations
|
|
84
|
-
*/
|
|
85
|
-
private executeTokenOperation;
|
|
86
|
-
/**
|
|
87
|
-
* Execute interest operations
|
|
88
|
-
*/
|
|
89
|
-
private executeInterestOperation;
|
|
90
|
-
/**
|
|
91
|
-
* Execute tags operations
|
|
92
|
-
*/
|
|
93
|
-
private executeTagsOperation;
|
|
94
|
-
/**
|
|
95
|
-
* Execute suppressed email operations
|
|
96
|
-
*/
|
|
97
|
-
private executeSuppressedEmailOperation;
|
|
98
|
-
/**
|
|
99
|
-
* Execute links operations
|
|
100
|
-
*/
|
|
101
|
-
private executeLinksOperation;
|
|
102
5
|
}
|