merge DOC-269

This commit is contained in:
Deborah Barnard
2022-06-16 14:09:24 +01:00
24 changed files with 941 additions and 12 deletions

View File

@@ -0,0 +1,19 @@
!!! note "Subject to change"
The standards described in this document are for the first release of the community nodes repository. These may change in future releases.
Community nodes are npm packages, hosted in the npm registry.
When building a node to submit to the community node repository, use the following resources to make sure your node setup is correct:
* View the [starter node](https://github.com/n8n-io/n8n-nodes-starter).
* Refer to the documentation on [building your own nodes](/integrations/creating-nodes/).
* Make sure your node follows the [standards](#standards) for community nodes.
## Standards
To make your node available to the n8n community node repository, you must:
* Make sure the package name starts with `n8n-nodes-` or `@<scope>/n8n-nodes-`. For example, `n8n-nodes-weather` or `@weatherPlugins/n8n-nodes-weather`.
* Tag your package with `n8n-community-node-package`.
* Submit the package to the npm registry. Refer to npm's documentation on [Contributing packages to the registry](https://docs.npmjs.com/packages-and-modules/contributing-packages-to-the-registry){:target=_blank .external-link} for more information.
* Make sure that you add your nodes and credentials to the `package.json` file inside the `n8n` attribute. Refer to the [package.json in the starter node](https://github.com/n8n-io/n8n-nodes-starter/blob/master/package.json) for an example.

View File

@@ -111,6 +111,10 @@
margin-top: 0;
}
.n8n-new-features + .n8n-new-features {
margin-top: 1em;
}
/* preserve the logo and site title on page scroll */
.md-header__topic:first-child {

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

242
docs/embed/configuration.md Normal file
View File

@@ -0,0 +1,242 @@
# Configuration
## Authentication
You can secure n8n using Basic Authentication by setting the following environment variables:
```sh
export N8N_BASIC_AUTH_ACTIVE=true
export N8N_BASIC_AUTH_USER=<USER>
export N8N_BASIC_AUTH_PASSWORD=<PASSWORD>
```
### Credential overwrites
To offer OAuth login to users, it's possible to overwrite credentials on a global basis. This credential data isn't visible to users but the backend uses it automatically.
In the Editor UI, n8n hides all overwritten fields by default. This means that users are able to authenticate using OAuth by pressing the "connect" button on the credentials.
n8n offers two ways to apply credential overwrites: using Environment Variable and using the REST API.
#### Using environment variables
Credential overwrites can be set using environment variable by setting the `CREDENTIALS_OVERWRITE_DATA` to `{ CREDENTIAL_NAME: { PARAMETER: VALUE }}`.
!!! warning
Even though this is possible, it isn't recommended. Environment variables aren't protected in n8n, so the data can leak to users.
#### Using REST APIs
The recommended way is to load the data using a custom REST endpoint. Set the `CREDENTIALS_OVERWRITE_ENDPOINT` to a path under which this endpoint should be made available.
!!! note
The endpoints can be called just one at a time for security reasons.
For example:
1. Activate the endpoint by setting the environment variable in the environment n8n runs under:
```sh
export CREDENTIALS_OVERWRITE_ENDPOINT=send-credentials
```
2. A JSON file with the credentials to overwrite is then needed. For example, a `oauth-credentials.json` file to overwrite credentials for Asana and GitHub could look like this:
```json
{
"asanaOAuth2Api": {
"clientId": "<id>",
"clientSecret": "<secret>"
},
"githubOAuth2Api": {
"clientId": "<id>",
"clientSecret": "<secret>"
}
}
```
3. Then apply it to the instance by sending it using curl:
```sh
curl -H "Content-Type: application/json" --data @oauth-credentials.json http://localhost:5678/send-credentials
```
!!! note
There are cases when credentials are based on others. For example, the `googleSheetsOAuth2Api` extends the `googleOAuth2Api`.
In this case, you can set parameters on the parent credentials (`googleOAuth2Api`) which will be used by all child-credentials (`googleSheetsOAuth2Api`).
## Environment variables
There are many [environment variables configurable in n8n](https://docs.n8n.io/reference/environment-variables.html). The following are most relevant for your hosted solution:
| Variable | Values | Description |
| :------- | :----- | :---------- |
| `EXECUTIONS_TIMEOUT` | `number` | The maximum amount of time (in seconds) a workflow is allowed to run. |
| `EXECUTIONS_PROCESS` | `'main', 'own'` | If workflow executions should run in the main process or in their own process. The `main` setting requires fewer resources. |
| `EXECUTIONS_DATA_PRUNE` | `boolean` | If data of past executions should be deleted automatically. |
| `EXECUTIONS_DATA_MAX_AGE` | `number` | Number of hours after which old executions are deleted. |
| `NODES_EXCLUDE` | `Array<string>` | Specific nodes that should not be made available. |
| `NODES_INCLUDE` | `Array<string>` | Specific nodes that should be included. |
| `N8N_TEMPLATES_ENABLED` | `boolean` | Whether workflow templates should be enabled (true) or disabled (false) |
| `N8N_TEMPLATES_HOST` | `string` | Defaults to https://api.n8n.io. Change this if creating your own workflow template library. Note that to use your own workflow templates library, your API must provide the same endpoints and response structure as n8n's. Refer to [Workflow templates](workflow-templates.md) for more information. |
## Backend hooks
It's possible to define external hooks that n8n executes whenever a specific operation runs. You can use these to, for example, to log data, change data, or forbid an action by throwing an error.
### Available hooks
| Hook | Arguments | Description |
| :------- | :---------| :---------- |
| `credentials.create` | `[credentialData: ICredentialsDb]` | Called before new credentials get created. Can be used to restrict the number of credentials. |
| `credentials.delete` | `[id: credentialId]` | Called before credentials get deleted. |
| `credentials.update` | `[credentialData: ICredentialsDb]` | Called before existing credentials are saved. |
| `frontend.settings` | `[frontendSettings: IN8nUISettings]` | Gets called on n8n startup. Allows you to, for example, overwrite frontend data like the displayed OAuth URL. |
| `n8n.ready` | `[app: App]` | Called once n8n is ready. Can be used to, for example, register custom API endpoints. |
| `n8n.step` | | Called when an n8n process gets stopped. Allows you to save some process data. |
| `oauth1.authenticate` | `[oAuthOptions: clientOAuth1.Options, oauthRequestData: {oauth_callback: string}]` | Called before an OAuth1 authentication. Can be used to overwrite an OAuth callback URL. |
| `oauth2.callback` | `[oAuth2Parameters: {clientId: string, clientSecret: string \| undefined, accessTokenUri: string, authorizationUri: string, redirectUri: string, scopes: string[]}]` | Called in an OAuth2 callback. Can be used to overwrite an OAuth callback URL. |
| `workflow.activate` | `[workflowData: IWorkflowDb]` | Called before a workflow gets activated. Can be used to restrict the number of active workflows. |
| `workflow.afterDelete` | `[workflowId: string]` | Called after a workflow gets deleted. |
| `workflow.afterUpdate` | `[workflowData: IWorkflowBase]` | Called after an existing workflow gets saved. |
| `workflow.create` | `[workflowData: IWorkflowBase]` | Called before a workflow gets created. Can be used to restrict the number of saved workflows. |
| `workflow.delete` | `[workflowId: string]` | Called before a workflow gets delete. |
| `workflow.postExecute` | `[run: IRun, workflowData: IWorkflowBase]` | Called after a workflow gets executed. |
| `workflow.preExecute` | `[workflow: Workflow: mode: WorkflowExecuteMode]` | Called before a workflow gets executed. Allows you to count or limit the number of workflow executions. |
| `workflow.update` | `[workflowData: IWorkflowBase]` | Called before an existing workflow gets saved. |
### Registering hooks
Hooks are set by registering a hook file that contains the hook functions.
Hook registration is done using the environment variable `EXTERNAL_HOOK_FILES`.
The variable can be set to a single file:
`EXTERNAL_HOOK_FILES=/data/hook.js`
Or to contain multiple files separated by a semicolon:
`EXTERNAL_HOOK_FILES=/data/hook1.js;/data/hook2.js`
### Hook files
Hook files are regular JavaScript files that have the following format:
```js
module.exports = {
"frontend": {
"settings": [
async function (settings) {
settings.oauthCallbackUrls.oauth1 = 'https://n8n.example.com/oauth1/callback';
settings.oauthCallbackUrls.oauth2 = 'https://n8n.example.com/oauth2/callback';
}
]
},
"workflow": {
"activate": [
async function (workflowData) {
const activeWorkflows = await this.dbCollections.Workflow.count({ active: true });
if (activeWorkflows > 1) {
throw new Error(
'Active workflow limit reached.'
);
}
}
]
}
}
```
### Hook functions
A hook or a hook file can contain multiple hook functions, with all functions executed one after another.
If the parameters of the hook function are objects, it's possible to change the data of that parameter to change the behavior of n8n.
Additionally, the database can also be accessed in any hook function using `this.dbCollections` (see above).
## Frontend external hooks
Like backend external hooks, it's possible to define external hooks in the frontend code that get executed by n8n whenever a specific operation is performed. They can be used, for example, to log data and change data.
### Available hooks
| Hook | Description |
| :------- | :---------- |
| `credentialsEdit.credentialTypeChanged` | Called when an existing credential's type is changed. |
| `credentials.create` | Called when a new credential is created. |
| `credentialsList.dialogVisibleChanged` | |
| `dataDisplay.nodeTypeChanged` | |
| `dataDisplay.onDocumentationUrlClick` | Called when the help documentation link is selected. |
| `execution.open` | Called when an existing execution is opened. |
| `executionsList.openDialog` | Called when the an execution is selected from existing Workflow Executions. |
| `expressionEdit.itemSelected` | |
| `expressionEdit.dialogVisibleChanged` | |
| `nodeCreateList.filteredNodeTypesComputed` | |
| `nodeCreateList.nodeFilterChanged` | Called when a new entry has been made in the node panel filter. |
| `nodeCreateList.selectedTypeChanged` | |
| `nodeCreateList.mounted` | |
| `nodeCreateList.destroyed` | |
| `nodeSettings.credentialSelected` | |
| `nodeSettings.valueChanged` | |
| `nodeView.createNodeActiveChanged` | |
| `nodeView.addNodeButton` | |
| `nodeView.createNodeActiveChanged` | |
| `nodeView.mount` | |
| `pushConnection.executionFinished` | |
| `showMessage.showError` | |
| `runData.displayModeChanged` | |
| `workflow.activeChange` | |
| `workflow.activeChangeCurrent` | |
| `workflow.afterUpdate` | Called when an existing workflow is updated. |
| `workflow.open` | |
| `workflowRun.runError` | |
| `workflowRun.runWorkflow` | Called when a workflow is executed. |
| `workflowSettings.dialogVisibleChanged` | |
| `workflowSettings.saveSettings` | Called when the settings of a workflow are saved. |
### Registering hooks
Hooks can be set by loading the hooks script on the page. One way to do this is by creating a hooks file in the project and adding a script tag in your `editor-ui/public/index.html` file:
```html
<script src="frontend-hooks.js"></script>
```
### Hook files
Hook files are regular JavaScript files which have the following format:
```js
window.n8nExternalHooks = {
nodeView: {
mount: [
function (store, meta) {
// do something
},
],
createNodeActiveChanged: [
function (store, meta) {
// do something
},
function (store, meta) {
// do something else
},
],
addNodeButton: [
function (store, meta) {
// do something
},
],
},
};
```
### Hook functions
Multiple hook functions can be defined per hook. Each hook function is invoked with the following arguments arguments:
* `store`: The Vuex store object. Can be used to change or get data from the store.
* `metadata`: Object that contains any data provided by the hook. To see exactly what's passed, search for the hook in the `editor-ui` package.

17
docs/embed/deployment.md Normal file
View File

@@ -0,0 +1,17 @@
# Deployment
See the [hosting documentation](https://docs.n8n.io/reference/server-setup.html) for detailed setup options.
## User data
n8n recommends that you follow the same or similar practices used internally for n8n Cloud: Save user data using [Rook](https://rook.io/) and, if an n8n server goes down, a new instance starts on another machine using the same data.
Due to this, you don't need to use backups except in case of a catastrophic failure, or when a user wants to reactivate their account within your prescribed retention period (two weeks for n8n Cloud).
## Backups
n8n recommends creating nightly backups by attaching another container, and copying all data to this second container. In this manner, RAM usage is negligible, and so does'nt impact the amount of users you can place on the server.
## Restarting
If your instance is down or restarting, missed executions (for example, Cron or Webhook nodes) during this time aren't recoverable. If it's important for you to maintain 100% uptime, you need to build another proxy in front of it which caches the data.

13
docs/embed/index.md Normal file
View File

@@ -0,0 +1,13 @@
# Introduction
n8n Embed is part of n8n's paid offering. Using Embed, you can white label n8n, or incorporate it in your software as part of your commercial product.
For more information about when to use Embed, as well as costs and licensing processes, contact n8n using [this form](https://n8n-community.typeform.com/to/qOBgyWWA){:target=_blank .external-link}.
## Support
The [community forum](https://community.n8n.io/) can help with many issues. If you are a current Embed customer, you can also contact n8n support, using the email provided when you bought the license.
## Russia and Belarus
n8n Embed isn't available in Russia and Belarus. Refer to n8n's blog post [Update on n8n cloud accounts in Russia and Belarus](https://n8n.io/blog/update-on-n8n-cloud-accounts-in-russia-and-belarus/){:target=_blank .external-link} for more information.

View File

@@ -0,0 +1,388 @@
# Workflow management in Embed
When managing an embedded n8n deployment, spanning across teams or organizations, you will likely need to run the same (or similar) workflows for multiple users. There are two available options for doing so:
| Solution | Pros | Cons |
| -------- | ---- | ---- |
| Create a workflow for each user | No limitation on how workflow starts (can use any trigger) | Requires managing multiple workflows. |
| Create a single workflow, and pass it user credentials when executing | Simplified workflow management (only need to change one workflow). | To run the workflow, your product must call it |
!!! warning
The APIs referenced in this document are subject to change at any time. Be sure the check for continued functionality with each version upgrade.
## Workflow per user
There are three general steps to follow:
* Obtain the credentials for each user, and any additional parameters that may be required based on the workflow.
* Create the n8n credentials for this user.
* Create the workflow.
### 1. Obtain user credentials
Here you need to capture all credentials for any node/service this user must authenticate with, along with any additional parameters required for the particular workflow. The credentials and any parameters needed will depend on your workflow and what you are trying to do.
### 2. Create user credentials
After all relevant credential details have been obtained, you can proceed to create the relevant service credentials in n8n. This can be done via the Editor UI or API call.
#### Using the Editor UI
1. From the menu select **Credentials** > **New**.
1. Use the drop-down to select the **Credential type** to create, for example *Airtable*.
![Create New Credentials drop-down](/_images/embed/managing-workflows/create_new_credentials.png)
1. In the **Create New Credentials** modal, enter the corresponding credentials details for the user, and select the nodes that will have access to these credentials.
![Create New Credentials modal](/_images/embed/managing-workflows/create_new_credentials2.png)
1. Click **Create** to finish and save.
#### Using the API
The frontend API used by the Editor UI can also be called to achieve the same result. The API endpoint is in the format: `https://<n8n-domain>/rest/credentials`.
For example, to create the credentials in the Editor UI example above, the request would be:
```
POST https://<n8n-domain>/rest/credentials
```
With the request body:
```json
{
"name":"MyAirtable",
"type":"airtableApi",
"nodesAccess":[
{
"nodeType":"n8n-nodes-base.airtable"
}
],
"data":{
"apiKey":"q12we34r5t67yu"
}
}
```
The response will contain the ID of the new credentials, which you will use when creating the workflow for this user:
```json
{
"data":{
"name":"MyAirtable",
"type":"airtableApi",
"data":{
"apiKey":"q12we34r5t67yu"
},
"nodesAccess":[
{
"nodeType":"n8n-nodes-base.airtable",
"date":"2021-09-10T07:41:27.770Z"
}
],
"id":"29",
"createdAt":"2021-09-10T07:41:27.777Z",
"updatedAt":"2021-09-10T07:41:27.777Z"
}
}
```
### 3. Create the workflow
Best practice is to have a “base” workflow that you then duplicate and customize for each new user with their credentials (and any other details).
You can duplicate and customize your template workflow using either the Editor UI or API call.
#### Using the Editor UI
1. From the menu select **Workflows** > **Open** to open the template workflow to be duplicated.
1. Select **Workflows** > **Duplicate**, then enter a name for this new workflow and click **Save**.
![Duplicate workflow](/_images/embed/managing-workflows/duplicate_workflow.png)
1. Update all relevant nodes to use the credentials for this user (created above).
1. **Save** this workflow set it to **Active** using the toggle in the top-right corner.
#### Using the API
1. Fetch the JSON of the template workflow using the endpoint: `https://<n8n-domain>/rest/workflows/<workflow_id>`
```
GET https://<n8n-domain>/rest/workflows/1012
```
The response will contain the JSON data of the selected workflow:
```json
{
"data": {
"id": "1012",
"name": "Nathan's Workflow",
"active": false,
"nodes": [
{
"parameters": {},
"name": "Start",
"type": "n8n-nodes-base.start",
"typeVersion": 1,
"position": [
130,
640
]
},
{
"parameters": {
"authentication": "headerAuth",
"url": "https://internal.users.n8n.cloud/webhook/custom-erp",
"options": {
"splitIntoItems": true
},
"headerParametersUi": {
"parameter": [
{
"name": "unique_id",
"value": "recLhLYQbzNSFtHNq"
}
]
}
},
"name": "HTTP Request",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 1,
"position": [
430,
300
],
"credentials": {
"httpHeaderAuth": "beginner_course"
}
},
{
"parameters": {
"operation": "append",
"application": "appKBGQfbm6NfW6bv",
"table": "processingOrders",
"options": {}
},
"name": "Airtable",
"type": "n8n-nodes-base.airtable",
"typeVersion": 1,
"position": [
990,
210
],
"credentials": {
"airtableApi": "Airtable"
}
},
{
"parameters": {
"conditions": {
"string": [
{
"value1": "={{$json[\"orderStatus\"]}}",
"value2": "processing"
}
]
}
},
"name": "IF",
"type": "n8n-nodes-base.if",
"typeVersion": 1,
"position": [
630,
300
]
},
{
"parameters": {
"keepOnlySet": true,
"values": {
"number": [
{
"name": "=orderId",
"value": "={{$json[\"orderID\"]}}"
}
],
"string": [
{
"name": "employeeName",
"value": "={{$json[\"employeeName\"]}}"
}
]
},
"options": {}
},
"name": "Set",
"type": "n8n-nodes-base.set",
"typeVersion": 1,
"position": [
800,
210
]
},
{
"parameters": {
"functionCode": "let totalBooked = items.length;\nlet bookedSum = 0;\n\nfor(let i=0; i < items.length; i++) {\n bookedSum = bookedSum + items[i].json.orderPrice;\n}\nreturn [{json:{totalBooked, bookedSum}}]\n"
},
"name": "Function",
"type": "n8n-nodes-base.function",
"typeVersion": 1,
"position": [
800,
400
]
},
{
"parameters": {
"webhookUri": "https://discord.com/api/webhooks/865213348202151968/oD5_WPDQwtr22Vjd_82QP3-_4b_lGhAeM7RynQ8Js5DzyXrQEnj0zeAQIA6fki1JLtXE",
"text": "=This week we have {{$json[\"totalBooked\"]}} booked orders with a total value of {{$json[\"bookedSum\"]}}. My Unique ID: {{$node[\"HTTP Request\"].parameter[\"headerParametersUi\"][\"parameter\"][0][\"value\"]}}"
},
"name": "Discord",
"type": "n8n-nodes-base.discord",
"typeVersion": 1,
"position": [
1000,
400
]
},
{
"parameters": {
"triggerTimes": {
"item": [
{
"mode": "everyWeek",
"hour": 9
}
]
}
},
"name": "Cron",
"type": "n8n-nodes-base.cron",
"typeVersion": 1,
"position": [
220,
300
]
}
],
"connections": {
"HTTP Request": {
"main": [
[
{
"node": "IF",
"type": "main",
"index": 0
}
]
]
},
"Start": {
"main": [
[]
]
},
"IF": {
"main": [
[
{
"node": "Set",
"type": "main",
"index": 0
}
],
[
{
"node": "Function",
"type": "main",
"index": 0
}
]
]
},
"Set": {
"main": [
[
{
"node": "Airtable",
"type": "main",
"index": 0
}
]
]
},
"Function": {
"main": [
[
{
"node": "Discord",
"type": "main",
"index": 0
}
]
]
},
"Cron": {
"main": [
[
{
"node": "HTTP Request",
"type": "main",
"index": 0
}
]
]
}
},
"createdAt": "2021-07-16T11:15:46.066Z",
"updatedAt": "2021-07-16T12:05:44.045Z",
"settings": {},
"staticData": null,
"tags": []
}
}
```
1. Save the returned JSON data and update any relevant credentials and fields for the new user.
1. Create a new workflow using the updated JSON as the request body at endpoint: `https://<n8n-domain>/rest/workflows`
```
POST https://<n8n-domain>/rest/workflows/
```
The response will contain the ID of the new workflow, which you will use in the next step.
1. Lastly, activate the new workflow:
```
PATCH https://<n8n-domain>/rest/workflows/1012
```
Passing the additional value `active` in your JSON payload:
```json
// ...
"active":true,
"settings": {},
"staticData": null,
"tags": []
```
## Single workflow
There are four steps to follow to implement this method:
* Obtain the credentials for each user, and any additional parameters that may be required based on the workflow. See [Obtain user credentials](#obtain-user-credentials) above.
* Create the n8n credentials for this user. See [Create user credentials](#create-user-credentials) above.
* Create the workflow.
* Call the workflow as needed.
### Create the workflow
The details and scope of this workflow will vary greatly according to the individual use case, however there are a few design implementations to keep in mind:
* This workflow must be triggered by a [Webhook](https://docs.n8n.io/nodes/n8n-nodes-base.webhook/#webhook) node.
* The incoming webhook call must contain the users credentials and any other workflow parameters required.
* Each node where the users credentials are needed should use an [expression](https://docs.n8n.io/nodes/expressions.html) so that the nodes credential field reads the credential provided in the webhook call.
* Save and activate the workflow, ensuring the [Production URL](https://docs.n8n.io/nodes/n8n-nodes-base.webhook/#node-reference) is selected for the Webhook node.
### Call the workflow
For each new user, or for any existing user as may be needed, call the webhook defined as the workflow trigger and provide the necessary credentials (and any other workflow parameters).

View File

@@ -0,0 +1,37 @@
# Prerequisites
The requirements provided here are an example based on n8n.cloud and are for illustrative purposes only. Your requirements may vary depending on the number of users, workflows, and executions. Contact n8n for more information.
| Component | Sizing | Supported |
| :-------- | :----- | :-------- |
| CPU/vCPU | Minimum 10 CPU cycles, scaling as needed | Any public or private cloud |
| Database | 512 MB - 4 GB SSD | SQLite, PostgreSQL, MySQL, MariaDB |
| Memory | 320 MB - 2 GB | |
## CPU considerations
n8n isn't CPU intensive so even small instances (of providers such as AWS and GCP) should be enough for most use cases. Usually, memory requirements supersede CPU requirements, so focus resources there when planning your infrastructure.
## Database considerations
n8n uses its database to store credentials, past executions, and workflows.
A core feature of n8n is the flexibility to choose a database. All the supported databases have different advantages and disadvantages, which you have to consider individually and pick the one that best suits your needs. By default n8n creates an SQLite database if no database exists at the given location.
n8n recommends that every n8n instance have a dedicated database. This helps to prevent dependencies and potential performance degradation. If it isn't possible to provide a dedicated database for every n8n instance, n8n recommends making use of Postgres's schema feature.
For Postgres, MySQL, and MariaDB, the database must already exist on the DB-instance. The database user for the n8n process needs to have full permissions on all tables that they're using or creating. n8n creates and maintains the database schema.
### Best practices
* SSD storage.
* In containerized cloud environments, ensure that the volume is persisted and mounted when stopping/starting a container. If not, all data is lost.
* If using Postgres, don't use the `tablePrefix` configuration option. It will be deprecated in the near future.
* Pay attention to the changelog of new versions and consider reverting migrations before downgrading.
* Set up at least the basic database security and stability mechanisms such as IP allow lists and backups.
## Memory considerations
An n8n instance doesn't typically require large amounts of available memory. For example an n8n.cloud instance at idle requires ~100MB. It's the nature of your workflows and the data being processed that determines your memory requirements.
For example, while most nodes just pass data to the next node in the workflow, `Function` nodes create a pre-processing and post-processing copy of the data. When dealing will large binary files, this can consume all available resources.

View File

@@ -0,0 +1,30 @@
# Workflow templates
n8n provides a library of workflow templates. When embedding n8n, you can:
* Continue to use n8n's workflow templates library (this is the default behavior)
* Disable workflow templates
* Create your own workflow templates library
## Disable workflow templates
In your environment variables, set `N8N_TEMPLATES_ENABLED` to false.
## Use your own workflow templates library
In your environment variables, set `N8N_TEMPLATES_HOST` to the base URL of your API.
Your API must provide the same endpoints and data structure as n8n's.
The endpoints are:
| Method | Path |
| ------ | ---- |
| GET | /templates/workflows/`<id>` |
| GET | /templates/workflows |
| GET | /templates/collections/`<id>` |
| GET | /templates/collections |
| GET | /templates/categories |
| GET | /health |
To learn about the data structure, try out the endpoints. You can also [contact us](mailto:support@n8n.io) for more support.

View File

@@ -0,0 +1,14 @@
# n8n community node blocklist
n8n maintains a blocklist of community nodes. You can't install any node on this list.
n8n may add community nodes to the blocklist for a range of reasons, including:
* The node is intentionally malicious
* It's low quality (low enough to be harmful)
<!-- vale off -->
If you are a community node creator whose node is on the blocklist, and you believe this is a mistake, contact [hello@n8n.io](mailto: hello@n8n.io).
<!-- vale on -->

View File

@@ -0,0 +1,6 @@
# Overview
The community nodes repository allows n8n users to publish and install custom nodes.
n8n provides hundreds of built-in nodes. It also supports users [creating their own nodes](/integrations/creating-nodes/){:target=_blank}. The community nodes repository allows users who create nodes to publish them to npm. These nodes are then available to install and use in your n8n instance.

View File

@@ -0,0 +1,56 @@
# Install, upgrade, and downgrade community nodes
!!! note "Limited to n8n instance owners"
Only the n8n instance owner can install and manage community nodes. The instance owner is the person who sets up and manages user management. If you haven't set up user management, the instance owner is the default user.
## Install a community node
To install a community node:
1. Go to **Settings** > **Community Nodes**.
2. Select **Install a community node**.
3. Find the node you want to install:
1. Select **Browse**. n8n takes you to an npm search results page, showing all npm packages tagged with the keyword `n8n-community-node-package`.
2. Browse the list of results. You can filter the results or add more keywords.
3. Once you find the package you want, make a note of the package name. If you want to install a specific version, make a note of the version number as well.
4. Return to n8n.
4. Enter the npm package name, and version number if required. For example, consider a community node designed to access a weather API called "Storms." The package name is n8n-node-storms, and it has three major versions.
* To install the latest version of a package called n8n-node-weather: enter `n8n-node-storms` in **Enter npm package name**.
* Install version 2.3: enter `n8n-node-storms@2.3` in **Enter npm package name**.
<!-- vale off -->
5. Agree to the [risks](/integrations/community-nodes/risks/) of using community nodes: select **I understand the risks of installing unverified code from a public source.**
<!-- vale on -->
6. Select **Install**. n8n installs the node, and returns to the **Community Nodes** list in **Settings**.
!!! note "Nodes on the blocklist"
n8n maintains a blocklist of community nodes that it prevents you from installing. Refer to [n8n community node blocklist](/integrations/community-nodes/blocklist/) for more information.
## Uninstall a community node
To uninstall a community node:
1. Go to **Settings** > **community nodes**.
2. On the node you want to install, select **Options** [TODO: add image of icon].
3. Select **Uninstall package**.
## Upgrade a community node
!!! warning "Breaking changes in versions"
Node developers may introduce breaking changes in new versions of their nodes. A breaking change is an update that breaks previous functionality. Depending on the node versioning approach that a node developer chooses, upgrading to a version with a breaking change could cause all workflows using the node to break. Be careful when upgrading your nodes.
### Upgrade to the latest version
You can upgrade community nodes to the latest version from the node list in **Settings** > **community nodes**.
When a new version of a community node is available, n8n displays an **Update** button on the node. Click the button to upgrade to the latest version.
### Upgrade to a specific version
To upgrade to a specific version (a version other than the latest), uninstall the node, then reinstall it, making sure to specify the target version. Follow the [Installation](#install-a-community-node) instructions for more guidance.
## Downgrade a community node
If there is a problem with a particular version of a community node, you may want to roll back to a previous version.
To do this, uninstall the community node, then reinstall it, targeting a specific node version. Follow the [Installation](#install-a-community-node) instructions for more guidance.

View File

@@ -0,0 +1,17 @@
# Risks when using community nodes
Using community nodes has some risks. You are installing unverified code from a public source into your n8n instance.
Risks include:
* Data security: any community node that you use has access to data in your workflows.
* Breaking changes: node developers may introduce breaking changes in new versions of their nodes. A breaking change is an update that breaks previous functionality. Depending on the node versioning approach that a node developer chooses, upgrading to a version with a breaking change could cause all workflows using the node to break. Be careful when upgrading your nodes.
## Report bad community nodes
<!-- vale off -->
You can report bad community nodes to [security@n8n.io](mailto: security@n8n.io)
<!-- vale on -->

View File

@@ -0,0 +1,3 @@
# Submit your node to the community node repository
--8<-- "_snippets/integrations/submit-community-node.md"

View File

@@ -0,0 +1,12 @@
# Using community nodes
To use community nodes, you first need to [install](/integrations/community-nodes/installation/){:target=_blank} them.
## Adding community nodes to your workflow
After installing a community node, you can use it like any other node. n8n displays the node in search results in the **Nodes** panel. To show which nodes are community nodes and which are built-in, n8n marks community nodes with a **Package** icon [TODO: add icon].
## Community nodes with duplicate names
It's possible for several community nodes to have the same name. If you use two nodes with the same name in your workflow, they'll look the same, unless they have different icons.

View File

@@ -58,8 +58,6 @@ String field with more than one row:
![Multiple rows](/_images/integrations/creating-nodes/multiple-rows.png)
## Number
Basic configuration:
@@ -100,8 +98,6 @@ Number field with decimal points:
![Decimal](/_images/integrations/creating-nodes/decimal.png)
## Collection
Use the `collection` type when you need to display optional fields.
@@ -190,8 +186,6 @@ The `color` type provides a color selector.
![Color](/_images/integrations/creating-nodes/color.png)
## Options
The `options` type adds an options list. Users can select a single value.
@@ -286,9 +280,6 @@ Use the `fixedCollection` type to group fields that are semantically related.
![Fixed collection](/_images/integrations/creating-nodes/fixed-collection.png)
## JSON
```typescript

View File

@@ -0,0 +1,20 @@
# Postbin
[Postbin](https://www.toptal.com/developers/postbin/){:target=_blank .external-link} is a service that collects all requests to a URL, which you can use to test your API Clients or your WebHooks.
## Send requests
To send requests to a Postbin bin:
1. Go to [Postbin](https://www.toptal.com/developers/postbin/){:target=_blank .external-link} and follow the steps to generate a new bin. Postbin gives you a unique URL, including a bin ID.
2. In the Postbin node, select the **Request** resource.
3. Choose the type of **Operation** you want to perform.
4. Enter your bin ID in **Bin ID**.
## Create and manage bins
You can create and manage Postbin bins using the Postbin node.
1. In **Resource**, select **Bin**.
2. Choose an **Operation**. You can create, delete, or get a bin.

View File

@@ -1,5 +1,39 @@
# Release notes
## n8n@0.182.0
View the [commits](https://github.com/n8n-io/n8n/compare/n8n@0.181.2...n8n@0.182.0){:target=_blank .external-link} for this version.<br />
**Release date:** 2022-06-14
This release contains enhancements to the Twilio and Wise integrations, and adds support for a new grant type for OAuth2. It also includes some bug fixes.
### New features
Added support for the client_credentials grant type for OAuth2.
### Node enhancements
* [Twilio node](/integrations/nodes/n8n-nodes-base.twilio/){:target=_blank}: added the ability to make a voice call using TTS.
* [Wise node](/integrations/nodes/n8n-nodes-base.wise/){:target=_blank}: added support for downloading statements as JSON, CSV, or PDF.
### Bug fixes
* Core: fixes an issue that was causing parameters to get lost in some edge cases.
* Core: fixes an issue with combined expressions not resolving if one expression was invalid.
* Core: fixed an issue that was causing the public API to fail to build on Windows.
* Editor: ensure errors display correctly.
* [HTTP Request node](/integrations/core-nodes/n8n-nodes-base.httpRequest/){:target=_blank}: better handling for requests that return null.
* [Pipedrive node](/integrations/nodes/n8n-nodes-base.pipedrive/){:target=_blank}: fixes a limits issue with the GetAll operation on the Lead resource.
* [Postbin node](/integrations/nodes/n8n-nodes-base.postbin/){:target=_blank}: remove a false error.
### Contributors
[Albrecht Schmidt](https://github.com/IamDrowsy){:target=_blank .external-link}
[Erick Friis](https://github.com/efriis){:target=_blank .external-link}
[JoLo](https://github.com/jolo-dev){:target=_blank .external-link}
[Shaun](https://github.com/simshaun){:target=_blank .external-link}
[Valentin Mocanu](https://github.com/rontav){:target=_blank .external-link}
## n8n@0.181.2
View the [commits](https://github.com/n8n-io/n8n/compare/n8n@0.181.1...n8n@0.181.2){:target=_blank .external-link} for this version.<br />

View File

@@ -121,6 +121,13 @@ nav:
- Trigger nodes: integrations/trigger-nodes/
- Credentials: integrations/credentials/
- Custom API actions for existing nodes: integrations/custom-operations.md
- Community nodes:
- Overview: integrations/community-nodes/index.md
- Installation and management: integrations/community-nodes/installation.md
- Risks: integrations/community-nodes/risks.md
- Blocklist: integrations/community-nodes/blocklist.md
- Using community nodes: integrations/community-nodes/usage.md
- Submit your node: integrations/community-nodes/submit-nodes.md
- Creating nodes:
- Overview: integrations/creating-nodes/index.md
- Choose a node building style: integrations/creating-nodes/choose-node-method.md
@@ -204,4 +211,11 @@ nav:
- Pagination: api/pagination.md
- Using the API playground: api/using-api-playground.md
- API reference: api/api-reference.md
- Embed:
- n8n Embed: embed/index.md
- Prerequisites: embed/prerequisites.md
- Deployment: embed/deployment.md
- Configuration: embed/configuration.md
- Workflow management: embed/managing-workflows.md
- Workflows templates: embed/workflow-templates.md
- Contributing: contributing.md

View File

@@ -9,4 +9,6 @@
g.async=true; g.src='https://cdn.matomo.cloud/n8n.matomo.cloud/container_V5geRwlT.js'; s.parentNode.insertBefore(g,s);
</script>
<!-- End Matomo Tag Manager -->
{% endblock %}
{% endblock %}

View File

@@ -1,3 +1,4 @@
Asana
backend
Cron
Dockerfile
@@ -11,4 +12,10 @@ namespace
npm
onboarding
Trello
URL
URL
Pipedrive
Postbin
Postgres
Twilio
URL
Vuex

View File

@@ -1,3 +1,6 @@
N8n
n8N
N8N
N8N
NPM
nPM
NPm