n8n-nodes-formbase 0.4.1 → 0.5.1
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 +35 -37
- package/dist/nodes/Formbase/FormbaseTrigger.node.js +72 -84
- package/dist/nodes/Formbase/FormbaseTrigger.node.js.map +1 -1
- package/dist/nodes/Formbase/GenericFunctions.d.ts +1 -1
- package/dist/nodes/Formbase/GenericFunctions.js +6 -9
- package/dist/nodes/Formbase/GenericFunctions.js.map +1 -1
- package/dist/nodes/Formbase/constants.d.ts +6 -6
- package/dist/nodes/Formbase/constants.js +2 -2
- package/dist/nodes/Formbase/constants.js.map +1 -1
- package/dist/package.json +5 -2
- package/examples/formbase-submission.json +5 -5
- package/package.json +5 -2
package/README.md
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
# n8n-nodes-formbase
|
|
2
2
|
|
|
3
|
-
Community node for [n8n](https://n8n.io) that
|
|
3
|
+
Community node for [n8n](https://n8n.io) that resumes workflows when a customer completes a [formbase](https://formbase.so) request or submits a form. formbase collects and verifies information from customers for workflows and AI agents: a workflow creates a request, the customer completes a branded form without an account, and the verified answers arrive in n8n keyed by stable field keys.
|
|
4
4
|
|
|
5
5
|
## Features
|
|
6
6
|
|
|
7
|
-
- Trigger on completed submissions.
|
|
7
|
+
- Trigger on completed submissions, including submissions that answer a request. `data.request` carries the request ID and the caller's `externalId` and `metadata`, so the workflow that created the request can resume.
|
|
8
8
|
- Trigger on abandoned submissions after a selected 12-hour, 1-day, 3-day, or 1-week idle window.
|
|
9
|
-
- Load forms dynamically from
|
|
9
|
+
- Load forms dynamically from the workspace the credential is scoped to, across every page.
|
|
10
10
|
- Register and remove formbase webhook subscriptions with the n8n workflow lifecycle.
|
|
11
11
|
- Verify every webhook with HMAC-SHA256 and reject stale or forged requests.
|
|
12
12
|
- Connect through workspace-scoped OAuth 2.1 with PKCE and automatic refresh-token rotation.
|
|
@@ -53,47 +53,45 @@ Import [`examples/formbase-submission.json`](examples/formbase-submission.json),
|
|
|
53
53
|
|
|
54
54
|
## Output
|
|
55
55
|
|
|
56
|
-
Each webhook produces one n8n item containing formbase
|
|
56
|
+
Each webhook produces one n8n item containing the formbase event envelope. Every answer appears once in `data.answers`, keyed by field key; `data.display` carries the human-readable text under the same keys:
|
|
57
57
|
|
|
58
58
|
```json
|
|
59
59
|
{
|
|
60
|
-
"
|
|
61
|
-
"
|
|
62
|
-
"
|
|
63
|
-
"
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
{
|
|
76
|
-
|
|
77
|
-
"title": "How likely are you to recommend us?",
|
|
78
|
-
"type": "rating",
|
|
79
|
-
"value": {
|
|
80
|
-
"raw": 9,
|
|
81
|
-
"display": "9"
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
]
|
|
60
|
+
"id": "evt_abc123",
|
|
61
|
+
"type": "submission.completed",
|
|
62
|
+
"createdAt": "2026-04-25T12:34:56.000Z",
|
|
63
|
+
"apiVersion": "2026-09-22",
|
|
64
|
+
"test": false,
|
|
65
|
+
"data": {
|
|
66
|
+
"form": { "id": "frm_abc123", "name": "Customer Feedback", "snapshotId": "snp_..." },
|
|
67
|
+
"submission": {
|
|
68
|
+
"id": "sub_xyz789",
|
|
69
|
+
"respondentEmail": "respondent@example.com",
|
|
70
|
+
"submittedAt": "2026-04-25T12:34:56.000Z",
|
|
71
|
+
"pdfUrl": null,
|
|
72
|
+
"language": "en"
|
|
73
|
+
},
|
|
74
|
+
"answers": { "recommend": 9, "plan": "pro" },
|
|
75
|
+
"display": { "recommend": "9", "plan": "Pro" }
|
|
76
|
+
}
|
|
85
77
|
}
|
|
86
78
|
```
|
|
87
79
|
|
|
88
|
-
|
|
80
|
+
Read a value with `{{ $json.data.answers.recommend }}`; the field keys come from `fields.list` (or the form's field Configure menu). A choice answer holds the readable option key (`"pro"`), and `display` holds its label (`"Pro"`). A repeating group is an array of row objects in `answers` and one joined line in `display`.
|
|
89
81
|
|
|
90
|
-
|
|
91
|
-
| ------------------ | ---------------------------------------------------------- |
|
|
92
|
-
| `SUBMIT_RESPONSE` | A respondent completed a new response. |
|
|
93
|
-
| `UPDATE_RESPONSE` | An existing completed response changed. |
|
|
94
|
-
| `ABANDON_RESPONSE` | An incomplete response reached the configured idle window. |
|
|
82
|
+
The node passes the envelope through unchanged — it does not flatten answers into the top level of the item. Nothing is dropped, every key stays where the formbase contract puts it, and a field key can never collide with an envelope key such as `type` or `test`. Map the handful of values a workflow needs with a Set node, as the example workflow does.
|
|
95
83
|
|
|
96
|
-
|
|
84
|
+
A submission that answered a request also carries `data.request` (`id`, and the caller's `externalId` and `metadata` when they were supplied). A response saved to PDF carries `data.submission.pdfUrl`; it is `null` when no PDF is kept. `test` is `true` for a test delivery, so a workflow can branch on it.
|
|
85
|
+
|
|
86
|
+
Delivered events use these `type` values:
|
|
87
|
+
|
|
88
|
+
| `type` | Meaning |
|
|
89
|
+
| ----------------------- | ---------------------------------------------------------- |
|
|
90
|
+
| `submission.completed` | A respondent completed a new response. |
|
|
91
|
+
| `submission.updated` | An existing completed response changed. |
|
|
92
|
+
| `submission.abandoned` | An incomplete response reached the configured idle window. |
|
|
93
|
+
|
|
94
|
+
Webhook registration events (`submission_created` and `submission_abandoned`) select which deliveries trigger the workflow. The event `type` identifies what happened to the response. Use `id` to deduplicate retries; the same values arrive as `X-formbase-Event-Id` and `X-formbase-Event-Type` headers.
|
|
97
95
|
|
|
98
96
|
Full contracts: [formbase API methods](https://docs.formbase.so/developers/rest-api) and [webhook reference](https://docs.formbase.so/developers/webhooks-reference).
|
|
99
97
|
|
|
@@ -106,7 +104,7 @@ npm run build
|
|
|
106
104
|
npm run lint
|
|
107
105
|
```
|
|
108
106
|
|
|
109
|
-
`npm run dev` starts n8n with the node loaded and rebuilds on changes. Compiled package files are written to `dist/`. Run `npm pack --dry-run` before publishing to inspect package contents.
|
|
107
|
+
`npm test` runs unit tests plus a lifecycle test that drives the node against an in-process formbase API over real HTTP (`test/fakeFormbase.mts`). `npm run dev` starts n8n with the node loaded and rebuilds on changes. Compiled package files are written to `dist/`. Run `npm pack --dry-run` before publishing to inspect package contents.
|
|
110
108
|
|
|
111
109
|
## License
|
|
112
110
|
|
|
@@ -6,44 +6,57 @@ const constants_1 = require("./constants");
|
|
|
6
6
|
const FormbaseWebhookSignature_1 = require("./FormbaseWebhookSignature");
|
|
7
7
|
const GenericFunctions_1 = require("./GenericFunctions");
|
|
8
8
|
const FORMS_PAGE_SIZE = 100;
|
|
9
|
-
async function
|
|
9
|
+
async function listForms(context) {
|
|
10
|
+
var _a;
|
|
11
|
+
const workspaces = await (0, GenericFunctions_1.formbaseApiRequest)(context, 'workspaces.list');
|
|
12
|
+
const workspace = workspaces.items[0];
|
|
13
|
+
if (!workspace) {
|
|
14
|
+
throw new n8n_workflow_1.NodeOperationError(context.getNode(), 'This formbase credential has no workspace. Reconnect it and pick one.');
|
|
15
|
+
}
|
|
10
16
|
const forms = [];
|
|
11
17
|
let cursor;
|
|
12
18
|
do {
|
|
13
|
-
const
|
|
19
|
+
const page = await (0, GenericFunctions_1.formbaseApiRequest)(context, 'forms.list', {
|
|
14
20
|
workspaceId: workspace.id,
|
|
15
21
|
limit: FORMS_PAGE_SIZE,
|
|
16
22
|
...(cursor ? { cursor } : {}),
|
|
17
|
-
})
|
|
18
|
-
forms.push(...
|
|
19
|
-
if (!
|
|
20
|
-
break;
|
|
21
|
-
if (!result.nextCursor) {
|
|
23
|
+
});
|
|
24
|
+
forms.push(...page.items);
|
|
25
|
+
if (page.hasMore && !page.nextCursor) {
|
|
22
26
|
throw new n8n_workflow_1.NodeApiError(context.getNode(), { message: 'formbase returned an incomplete forms page' });
|
|
23
27
|
}
|
|
24
|
-
cursor =
|
|
28
|
+
cursor = page.hasMore ? ((_a = page.nextCursor) !== null && _a !== void 0 ? _a : undefined) : undefined;
|
|
25
29
|
} while (cursor);
|
|
26
30
|
return forms;
|
|
27
31
|
}
|
|
28
|
-
function
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
}
|
|
37
|
-
function getIdleWindow(context, eventType) {
|
|
38
|
-
if (eventType === constants_1.FORMBASE_WEBHOOK_EVENTS.submissionCreated)
|
|
39
|
-
return undefined;
|
|
32
|
+
function readRegistration(context) {
|
|
33
|
+
const webhookUrl = context.getNodeWebhookUrl('default');
|
|
34
|
+
const formId = context.getNodeParameter('formId');
|
|
35
|
+
if (!webhookUrl || !formId)
|
|
36
|
+
return null;
|
|
37
|
+
const eventType = context.getNodeParameter('event');
|
|
38
|
+
if (eventType !== constants_1.FORMBASE_WEBHOOK_EVENTS.submissionAbandoned)
|
|
39
|
+
return { webhookUrl, formId, eventType };
|
|
40
40
|
const idleWindow = context.getNodeParameter('idleWindow');
|
|
41
41
|
if (!(0, constants_1.isFormbaseIdleWindow)(idleWindow)) {
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
});
|
|
42
|
+
const allowed = constants_1.FORMBASE_IDLE_WINDOW_OPTIONS.map((option) => option.value).join(', ');
|
|
43
|
+
throw new n8n_workflow_1.NodeOperationError(context.getNode(), `Idle window must be one of: ${allowed}`);
|
|
45
44
|
}
|
|
46
|
-
return idleWindow;
|
|
45
|
+
return { webhookUrl, formId, eventType, idleWindow };
|
|
46
|
+
}
|
|
47
|
+
function isOwnSubscription(subscription, registration) {
|
|
48
|
+
if (subscription.provider !== 'n8n')
|
|
49
|
+
return false;
|
|
50
|
+
if (subscription.targetUrl !== registration.webhookUrl)
|
|
51
|
+
return false;
|
|
52
|
+
return subscription.eventType === registration.eventType;
|
|
53
|
+
}
|
|
54
|
+
function isCurrentRegistration(subscription, registration, webhookData) {
|
|
55
|
+
if (subscription.subscriptionId !== webhookData.subscriptionId)
|
|
56
|
+
return false;
|
|
57
|
+
if (typeof webhookData.webhookSecret !== 'string')
|
|
58
|
+
return false;
|
|
59
|
+
return subscription.idleWindow === registration.idleWindow;
|
|
47
60
|
}
|
|
48
61
|
function clearWebhookRegistration(webhookData) {
|
|
49
62
|
delete webhookData.subscriptionId;
|
|
@@ -58,7 +71,7 @@ class FormbaseTrigger {
|
|
|
58
71
|
group: ['trigger'],
|
|
59
72
|
version: 1,
|
|
60
73
|
subtitle: '={{ $parameter["event"] === "submission_created" ? "On submission created" : "On submission abandoned" }}',
|
|
61
|
-
description: 'Starts the workflow when a formbase
|
|
74
|
+
description: 'Starts the workflow when a customer completes a formbase request or submits a form',
|
|
62
75
|
defaults: {
|
|
63
76
|
name: 'formbase Trigger',
|
|
64
77
|
},
|
|
@@ -103,18 +116,18 @@ class FormbaseTrigger {
|
|
|
103
116
|
name: 'event',
|
|
104
117
|
type: 'options',
|
|
105
118
|
options: [
|
|
119
|
+
{
|
|
120
|
+
name: 'Submission Created',
|
|
121
|
+
value: constants_1.FORMBASE_WEBHOOK_EVENTS.submissionCreated,
|
|
122
|
+
action: 'On submission created',
|
|
123
|
+
description: 'Runs when a respondent submits the selected form, and again when a completed submission is edited (event type submission.updated)',
|
|
124
|
+
},
|
|
106
125
|
{
|
|
107
126
|
name: 'Submission Abandoned',
|
|
108
127
|
value: constants_1.FORMBASE_WEBHOOK_EVENTS.submissionAbandoned,
|
|
109
128
|
action: 'On submission abandoned',
|
|
110
129
|
description: 'Runs when a respondent leaves the selected form before submitting it; requires partial submission tracking',
|
|
111
130
|
},
|
|
112
|
-
{
|
|
113
|
-
name: 'Submission Created',
|
|
114
|
-
value: constants_1.FORMBASE_WEBHOOK_EVENTS.submissionCreated,
|
|
115
|
-
action: 'On submission created',
|
|
116
|
-
description: 'Runs when a respondent submits the selected form',
|
|
117
|
-
},
|
|
118
131
|
],
|
|
119
132
|
default: 'submission_created',
|
|
120
133
|
description: 'Event to subscribe to. Abandoned submissions require partial submission tracking.',
|
|
@@ -138,70 +151,48 @@ class FormbaseTrigger {
|
|
|
138
151
|
this.methods = {
|
|
139
152
|
loadOptions: {
|
|
140
153
|
async getForms() {
|
|
141
|
-
const
|
|
142
|
-
|
|
143
|
-
workspace,
|
|
144
|
-
forms: await listWorkspaceForms(this, workspace),
|
|
145
|
-
})));
|
|
146
|
-
const showWorkspaceName = formsByWorkspace.length > 1;
|
|
147
|
-
return formsByWorkspace.flatMap(({ workspace, forms }) => forms.map((form) => ({
|
|
148
|
-
name: showWorkspaceName ? `${workspace.name} / ${form.name}` : form.name,
|
|
149
|
-
value: form.id,
|
|
150
|
-
})));
|
|
154
|
+
const forms = await listForms(this);
|
|
155
|
+
return forms.map((form) => ({ name: form.name, value: form.id }));
|
|
151
156
|
},
|
|
152
157
|
},
|
|
153
158
|
};
|
|
154
159
|
this.webhookMethods = {
|
|
155
160
|
default: {
|
|
156
161
|
async checkExists() {
|
|
157
|
-
const
|
|
158
|
-
if (!
|
|
159
|
-
return false;
|
|
160
|
-
const formId = this.getNodeParameter('formId');
|
|
161
|
-
if (!formId)
|
|
162
|
+
const registration = readRegistration(this);
|
|
163
|
+
if (!registration)
|
|
162
164
|
return false;
|
|
163
|
-
const eventType = this.getNodeParameter('event');
|
|
164
|
-
const idleWindow = getIdleWindow(this, eventType);
|
|
165
165
|
const webhookData = this.getWorkflowStaticData('node');
|
|
166
|
-
const
|
|
167
|
-
formId,
|
|
168
|
-
})
|
|
169
|
-
|
|
170
|
-
const
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
166
|
+
const { items } = await (0, GenericFunctions_1.formbaseApiRequest)(this, 'webhooks.list', {
|
|
167
|
+
formId: registration.formId,
|
|
168
|
+
});
|
|
169
|
+
let current = false;
|
|
170
|
+
for (const subscription of items) {
|
|
171
|
+
if (!isOwnSubscription(subscription, registration))
|
|
172
|
+
continue;
|
|
173
|
+
if (isCurrentRegistration(subscription, registration, webhookData)) {
|
|
174
|
+
current = true;
|
|
175
|
+
continue;
|
|
176
|
+
}
|
|
177
|
+
await (0, GenericFunctions_1.formbaseApiRequest)(this, 'webhooks.delete', { subscriptionId: subscription.subscriptionId });
|
|
175
178
|
}
|
|
176
|
-
if (!
|
|
179
|
+
if (!current)
|
|
177
180
|
clearWebhookRegistration(webhookData);
|
|
178
|
-
|
|
179
|
-
}
|
|
180
|
-
const registrationMatchesStaticData = webhookData.subscriptionId === match.subscriptionId && typeof webhookData.webhookSecret === 'string';
|
|
181
|
-
if (registrationMatchesStaticData)
|
|
182
|
-
return true;
|
|
183
|
-
await GenericFunctions_1.formbaseApiRequest.call(this, 'webhooks.delete', {
|
|
184
|
-
subscriptionId: match.subscriptionId,
|
|
185
|
-
});
|
|
186
|
-
clearWebhookRegistration(webhookData);
|
|
187
|
-
return false;
|
|
181
|
+
return current;
|
|
188
182
|
},
|
|
189
183
|
async create() {
|
|
190
|
-
const
|
|
191
|
-
if (!
|
|
184
|
+
const registration = readRegistration(this);
|
|
185
|
+
if (!registration)
|
|
192
186
|
return false;
|
|
193
|
-
const formId = this.getNodeParameter('formId');
|
|
194
|
-
const eventType = this.getNodeParameter('event');
|
|
195
|
-
const idleWindow = getIdleWindow(this, eventType);
|
|
196
187
|
const webhookSecret = (0, FormbaseWebhookSignature_1.createFormbaseWebhookSecret)();
|
|
197
|
-
const created =
|
|
198
|
-
formId,
|
|
199
|
-
targetUrl: webhookUrl,
|
|
188
|
+
const created = await (0, GenericFunctions_1.formbaseApiRequest)(this, 'webhooks.create', {
|
|
189
|
+
formId: registration.formId,
|
|
190
|
+
targetUrl: registration.webhookUrl,
|
|
200
191
|
provider: 'n8n',
|
|
201
|
-
eventType,
|
|
202
|
-
...(idleWindow
|
|
192
|
+
eventType: registration.eventType,
|
|
193
|
+
...(registration.idleWindow ? { idleWindow: registration.idleWindow } : {}),
|
|
203
194
|
signingSecret: webhookSecret,
|
|
204
|
-
})
|
|
195
|
+
});
|
|
205
196
|
const webhookData = this.getWorkflowStaticData('node');
|
|
206
197
|
webhookData.subscriptionId = created.subscriptionId;
|
|
207
198
|
webhookData.webhookSecret = webhookSecret;
|
|
@@ -215,14 +206,11 @@ class FormbaseTrigger {
|
|
|
215
206
|
return true;
|
|
216
207
|
}
|
|
217
208
|
try {
|
|
218
|
-
await GenericFunctions_1.formbaseApiRequest
|
|
219
|
-
subscriptionId,
|
|
220
|
-
});
|
|
209
|
+
await (0, GenericFunctions_1.formbaseApiRequest)(this, 'webhooks.delete', { subscriptionId });
|
|
221
210
|
}
|
|
222
211
|
catch (error) {
|
|
223
|
-
if (!(error instanceof n8n_workflow_1.NodeApiError) || error.httpCode !== '404')
|
|
212
|
+
if (!(error instanceof n8n_workflow_1.NodeApiError) || error.httpCode !== '404')
|
|
224
213
|
return false;
|
|
225
|
-
}
|
|
226
214
|
}
|
|
227
215
|
clearWebhookRegistration(webhookData);
|
|
228
216
|
return true;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FormbaseTrigger.node.js","sourceRoot":"","sources":["../../../nodes/Formbase/FormbaseTrigger.node.ts"],"names":[],"mappings":";;;AAUA,+
|
|
1
|
+
{"version":3,"file":"FormbaseTrigger.node.js","sourceRoot":"","sources":["../../../nodes/Formbase/FormbaseTrigger.node.ts"],"names":[],"mappings":";;;AAUA,+CAAoF;AAEpF,2CAOoB;AACpB,yEAAwG;AACxG,yDAAuD;AAmCvD,MAAM,eAAe,GAAG,GAAG,CAAA;AAO3B,KAAK,UAAU,SAAS,CAAC,OAA8B;;IACrD,MAAM,UAAU,GAAG,MAAM,IAAA,qCAAkB,EAAiC,OAAO,EAAE,iBAAiB,CAAC,CAAA;IACvG,MAAM,SAAS,GAAG,UAAU,CAAC,KAAK,CAAC,CAAC,CAAC,CAAA;IACrC,IAAI,CAAC,SAAS,EAAE,CAAC;QACf,MAAM,IAAI,iCAAkB,CAAC,OAAO,CAAC,OAAO,EAAE,EAAE,uEAAuE,CAAC,CAAA;IAC1H,CAAC;IAED,MAAM,KAAK,GAAkB,EAAE,CAAA;IAC/B,I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,IAAI,CAAC,qBAAqB,CAAC,MAAM,CAAC,CAAA;oBACtD,MAAM,cAAc,GAAG,WAAW,CAAC,cAAc,CAAA;oBACjD,IAAI,OAAO,cAAc,KAAK,QAAQ,EAAE,CAAC;wBACvC,wBAAwB,CAAC,WAAW,CAAC,CAAA;wBACrC,OAAO,IAAI,CAAA;oBACb,CAAC;oBAED,IAAI,CAAC;wBACH,MAAM,IAAA,qCAAkB,EAAC,IAAI,EAAE,iBAAiB,EAAE,EAAE,cAAc,EAAE,CAAC,CAAA;oBACvE,CAAC;oBAAC,OAAO,KAAc,EAAE,CAAC;wBAExB,IAAI,CAAC,CAAC,KAAK,YAAY,2BAAY,CAAC,IAAI,KAAK,CAAC,QAAQ,KAAK,KAAK;4BAAE,OAAO,KAAK,CAAA;oBAChF,CAAC;oBACD,wBAAwB,CAAC,WAAW,CAAC,CAAA;oBACrC,OAAO,IAAI,CAAA;gBACb,CAAC;aACF;SACF,CAAA;IAcH,CAAC;IAXC,KAAK,CAAC,OAAO;QACX,IAAI,CAAC,IAAA,yDAA8B,EAAC,IAAI,CAAC,EAAE,CAAC;YAC1C,IAAI,CAAC,iBAAiB,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC,GAAG,EAAE,CAAA;YAC/D,OAAO,EAAE,iBAAiB,EAAE,IAAI,EAAE,CAAA;QACpC,CAAC;QAED,MAAM,IAAI,GAAgB,IAAI,CAAC,WAAW,EAAE,CAAA;QAC5C,OAAO;YACL,YAAY,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,eAAe,CAAC,IAAI,CAAC,CAAC;SACnD,CAAA;IACH,CAAC;CACF;AAzLD,0CAyLC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { IHookFunctions, ILoadOptionsFunctions, IWebhookFunctions } from 'n8n-workflow';
|
|
2
2
|
export type FormbaseRpcContext = IHookFunctions | ILoadOptionsFunctions | IWebhookFunctions;
|
|
3
|
-
export declare function formbaseApiRequest<T = unknown>(
|
|
3
|
+
export declare function formbaseApiRequest<T = unknown>(context: FormbaseRpcContext, method: string, params?: Record<string, unknown>): Promise<T>;
|
|
@@ -14,9 +14,9 @@ const ERROR_CODE_TO_HTTP = {
|
|
|
14
14
|
RATE_LIMITED: 429,
|
|
15
15
|
INTERNAL_ERROR: 500,
|
|
16
16
|
};
|
|
17
|
-
async function formbaseApiRequest(method, params = {}) {
|
|
17
|
+
async function formbaseApiRequest(context, method, params = {}) {
|
|
18
18
|
var _a, _b, _c, _d, _e, _f;
|
|
19
|
-
const credentials = await
|
|
19
|
+
const credentials = await context.getCredentials(constants_1.FORMBASE_OAUTH2_CREDENTIAL_NAME);
|
|
20
20
|
const resourceUrl = String((_a = credentials.serverUrl) !== null && _a !== void 0 ? _a : constants_1.FORMBASE_API_RESOURCE_URL).replace(/\/+$/, '');
|
|
21
21
|
const options = {
|
|
22
22
|
method: 'POST',
|
|
@@ -25,20 +25,17 @@ async function formbaseApiRequest(method, params = {}) {
|
|
|
25
25
|
json: true,
|
|
26
26
|
returnFullResponse: false,
|
|
27
27
|
};
|
|
28
|
-
const response = (await
|
|
28
|
+
const response = (await context.helpers.httpRequestWithAuthentication.call(context, constants_1.FORMBASE_OAUTH2_CREDENTIAL_NAME, options));
|
|
29
29
|
if (!response || typeof response !== 'object') {
|
|
30
|
-
throw new n8n_workflow_1.NodeApiError(
|
|
30
|
+
throw new n8n_workflow_1.NodeApiError(context.getNode(), { message: 'Invalid response from formbase API' });
|
|
31
31
|
}
|
|
32
32
|
if (response.ok === false) {
|
|
33
33
|
const code = (_c = (_b = response.error) === null || _b === void 0 ? void 0 : _b.code) !== null && _c !== void 0 ? _c : 'INTERNAL_ERROR';
|
|
34
34
|
const message = (_e = (_d = response.error) === null || _d === void 0 ? void 0 : _d.message) !== null && _e !== void 0 ? _e : 'formbase API error';
|
|
35
|
-
throw new n8n_workflow_1.NodeApiError(
|
|
36
|
-
message: `${code}: ${message}`,
|
|
37
|
-
httpCode: String((_f = ERROR_CODE_TO_HTTP[code]) !== null && _f !== void 0 ? _f : 500),
|
|
38
|
-
});
|
|
35
|
+
throw new n8n_workflow_1.NodeApiError(context.getNode(), { message, code }, { message: `${code}: ${message}`, httpCode: String((_f = ERROR_CODE_TO_HTTP[code]) !== null && _f !== void 0 ? _f : 500) });
|
|
39
36
|
}
|
|
40
37
|
if (response.ok !== true || !('data' in response)) {
|
|
41
|
-
throw new n8n_workflow_1.NodeApiError(
|
|
38
|
+
throw new n8n_workflow_1.NodeApiError(context.getNode(), { message: 'Invalid response from formbase API' });
|
|
42
39
|
}
|
|
43
40
|
return response.data;
|
|
44
41
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GenericFunctions.js","sourceRoot":"","sources":["../../../nodes/Formbase/GenericFunctions.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"GenericFunctions.js","sourceRoot":"","sources":["../../../nodes/Formbase/GenericFunctions.ts"],"names":[],"mappings":";;AAuCA,gDA0CC;AAhFD,+CAA2C;AAE3C,2CAAwF;AAiBxF,MAAM,kBAAkB,GAA2B;IACjD,gBAAgB,EAAE,GAAG;IACrB,YAAY,EAAE,GAAG;IACjB,gBAAgB,EAAE,GAAG;IACrB,SAAS,EAAE,GAAG;IACd,SAAS,EAAE,GAAG;IACd,gBAAgB,EAAE,GAAG;IACrB,QAAQ,EAAE,GAAG;IACb,YAAY,EAAE,GAAG;IACjB,cAAc,EAAE,GAAG;CACpB,CAAA;AASM,KAAK,UAAU,kBAAkB,CACtC,OAA2B,EAC3B,MAAc,EACd,SAAkC,EAAE;;IAEpC,MAAM,WAAW,GAAG,MAAM,OAAO,CAAC,cAAc,CAAC,2CAA+B,CAAC,CAAA;IACjF,MAAM,WAAW,GAAG,MAAM,CAAC,MAAA,WAAW,CAAC,SAAS,mCAAI,qCAAyB,CAAC,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAAA;IAElG,MAAM,OAAO,G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I,CAAA;AACtB,CAAC"}
|
|
@@ -8,17 +8,17 @@ export declare const FORMBASE_WEBHOOK_EVENTS: {
|
|
|
8
8
|
};
|
|
9
9
|
export type FormbaseWebhookEvent = (typeof FORMBASE_WEBHOOK_EVENTS)[keyof typeof FORMBASE_WEBHOOK_EVENTS];
|
|
10
10
|
export declare const FORMBASE_IDLE_WINDOW_OPTIONS: readonly [{
|
|
11
|
-
readonly name: "1 Day";
|
|
12
|
-
readonly value: "1d";
|
|
13
|
-
}, {
|
|
14
|
-
readonly name: "1 Week";
|
|
15
|
-
readonly value: "1w";
|
|
16
|
-
}, {
|
|
17
11
|
readonly name: "12 Hours";
|
|
18
12
|
readonly value: "12h";
|
|
13
|
+
}, {
|
|
14
|
+
readonly name: "1 Day";
|
|
15
|
+
readonly value: "1d";
|
|
19
16
|
}, {
|
|
20
17
|
readonly name: "3 Days";
|
|
21
18
|
readonly value: "3d";
|
|
19
|
+
}, {
|
|
20
|
+
readonly name: "1 Week";
|
|
21
|
+
readonly value: "1w";
|
|
22
22
|
}];
|
|
23
23
|
export type FormbaseIdleWindow = (typeof FORMBASE_IDLE_WINDOW_OPTIONS)[number]['value'];
|
|
24
24
|
export declare function isFormbaseIdleWindow(value: unknown): value is FormbaseIdleWindow;
|
|
@@ -11,10 +11,10 @@ exports.FORMBASE_WEBHOOK_EVENTS = {
|
|
|
11
11
|
submissionAbandoned: 'submission_abandoned',
|
|
12
12
|
};
|
|
13
13
|
exports.FORMBASE_IDLE_WINDOW_OPTIONS = [
|
|
14
|
-
{ name: '1 Day', value: '1d' },
|
|
15
|
-
{ name: '1 Week', value: '1w' },
|
|
16
14
|
{ name: '12 Hours', value: '12h' },
|
|
15
|
+
{ name: '1 Day', value: '1d' },
|
|
17
16
|
{ name: '3 Days', value: '3d' },
|
|
17
|
+
{ name: '1 Week', value: '1w' },
|
|
18
18
|
];
|
|
19
19
|
const FORMBASE_IDLE_WINDOW_VALUES = new Set(exports.FORMBASE_IDLE_WINDOW_OPTIONS.map((option) => option.value));
|
|
20
20
|
function isFormbaseIdleWindow(value) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../nodes/Formbase/constants.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../nodes/Formbase/constants.ts"],"names":[],"mappings":";;;AA6BA,oDAEC;AA/BY,QAAA,wBAAwB,GAAG,yBAAyB,CAAA;AAEpD,QAAA,iBAAiB,GAAG,SAAS,CAAA;AAE7B,QAAA,yBAAyB,GAAG,GAAG,gCAAwB,GAAG,yBAAiB,EAAE,CAAA;AAE7E,QAAA,+BAA+B,GAAG,mBAAmB,CAAA;AAErD,QAAA,uBAAuB,GAAG;IACrC,iBAAiB,EAAE,oBAAoB;IACvC,mBAAmB,EAAE,sBAAsB;CACnC,CAAA;AAKG,QAAA,4BAA4B,GAAG;IAC1C,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,KAAK,EAAE;IAClC,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE;IAC9B,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,IAAI,EAAE;IAC/B,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,IAAI,EAAE;CACvB,CAAA;AAIV,MAAM,2BAA2B,GAAwB,IAAI,GAAG,CAC9D,oCAA4B,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,KAAK,CAAC,CAC3D,CAAA;AAED,SAAgB,oBAAoB,CAAC,KAAc;IACjD,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,2BAA2B,CAAC,GAAG,CAAC,KAAK,CAAC,CAAA;AAC5E,CAAC"}
|
package/dist/package.json
CHANGED
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "n8n-nodes-formbase",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "n8n community node for formbase —
|
|
3
|
+
"version": "0.5.1",
|
|
4
|
+
"description": "n8n community node for formbase — resume workflows when a customer completes a request or submits a form. Collect and verify customer information for workflows and AI agents.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"n8n-community-node-package",
|
|
7
7
|
"n8n",
|
|
8
8
|
"formbase",
|
|
9
9
|
"forms",
|
|
10
|
+
"requests",
|
|
11
|
+
"customer-in-the-loop",
|
|
12
|
+
"human-in-the-loop",
|
|
10
13
|
"webhook"
|
|
11
14
|
],
|
|
12
15
|
"license": "MIT",
|
|
@@ -19,31 +19,31 @@
|
|
|
19
19
|
{
|
|
20
20
|
"id": "cdcb57d7-377e-45e2-8da9-63e52f4690b4",
|
|
21
21
|
"name": "eventId",
|
|
22
|
-
"value": "={{ $json.
|
|
22
|
+
"value": "={{ $json.id }}",
|
|
23
23
|
"type": "string"
|
|
24
24
|
},
|
|
25
25
|
{
|
|
26
26
|
"id": "9da94c68-fcf8-4f79-b78e-5bb78c043aec",
|
|
27
27
|
"name": "eventType",
|
|
28
|
-
"value": "={{ $json.
|
|
28
|
+
"value": "={{ $json.type }}",
|
|
29
29
|
"type": "string"
|
|
30
30
|
},
|
|
31
31
|
{
|
|
32
32
|
"id": "b27b42be-fc5d-491f-a93b-02a7fa4e63f8",
|
|
33
33
|
"name": "submissionId",
|
|
34
|
-
"value": "={{ $json.submission.id }}",
|
|
34
|
+
"value": "={{ $json.data.submission.id }}",
|
|
35
35
|
"type": "string"
|
|
36
36
|
},
|
|
37
37
|
{
|
|
38
38
|
"id": "2b171786-cb32-4e73-96e5-d60f39060fe1",
|
|
39
39
|
"name": "respondentEmail",
|
|
40
|
-
"value": "={{ $json.submission.respondentEmail }}",
|
|
40
|
+
"value": "={{ $json.data.submission.respondentEmail }}",
|
|
41
41
|
"type": "string"
|
|
42
42
|
},
|
|
43
43
|
{
|
|
44
44
|
"id": "a6366cdf-c3b9-4bdc-be3c-723d2bfab7a4",
|
|
45
45
|
"name": "formName",
|
|
46
|
-
"value": "={{ $json.form.name }}",
|
|
46
|
+
"value": "={{ $json.data.form.name }}",
|
|
47
47
|
"type": "string"
|
|
48
48
|
}
|
|
49
49
|
]
|
package/package.json
CHANGED
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "n8n-nodes-formbase",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "n8n community node for formbase —
|
|
3
|
+
"version": "0.5.1",
|
|
4
|
+
"description": "n8n community node for formbase — resume workflows when a customer completes a request or submits a form. Collect and verify customer information for workflows and AI agents.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"n8n-community-node-package",
|
|
7
7
|
"n8n",
|
|
8
8
|
"formbase",
|
|
9
9
|
"forms",
|
|
10
|
+
"requests",
|
|
11
|
+
"customer-in-the-loop",
|
|
12
|
+
"human-in-the-loop",
|
|
10
13
|
"webhook"
|
|
11
14
|
],
|
|
12
15
|
"license": "MIT",
|