Webhook Creating Endpoints Part 1
2:40

Webhook Creating Endpoints Part 1

n8n 01.02.2021 9 315 просмотров 45 лайков

Machine-readable: Markdown · JSON API · Site index

Поделиться Telegram VK Бот
Транскрипт Скачать .md
Анализ с AI
Описание видео
In part one of two videos, we will be setting up a custom endpoint for the webhook and then returning information based on what was queried in the request. Resources: - n8n Website - https://n8n.io/ - n8n Documentation - https://docs.n8n.io/ - n8n Community - https://community.n8n.io/ - n8n Workflows - https://n8n.io/workflows/ - n8n Webhook Node - https://docs.n8n.io/nodes/n8n-nodes-base.webhook/ A Basic Introduction to Webhooks - https://markheath.net/post/basic-introduction-webhooks

Оглавление (13 сегментов)

Intro

in today's video we're going to show you how to make a web hook or api endpoint so we're just going to open up

Trigger Node

a trigger node a web hook trigger node and in that webhook trigger node you'll

HTTP Method

notice that there's an http method by default it's set to get which is the most common one but there are a couple other options there that do modify how things are done so we'll just

Response Mode

reset it back to get you'll also notice that there's a response mode and by default it's set to on received but what we're going to do is we're going to move it to last node and what that does is when it executes the workflow it'll respond back with the information that's in the workflow and you'll notice that there's a new response data we're just going to use the one that's by default

Endpoint Path

again you'll see we have our webhook url and um by default it gives it a random path so we're going to change that path to something a little bit easier to remember and we're just going to call it endpoint and we'll save that there and now when

Endpoint URL

we go back into the webhook urls you'll notice that it says endpoint instead of that random string so we'll click on that and put that into our clip clipboard and we'll just close down the

Close Webhook Node

web hook node um because we have the webhook node we don't really need the start nodes we're just going to set it aside here and uh we'll save this workflow because

Save Workflow

once again a web hook nodes require them to be saved before you can do any testing all right so we're going to add another

Add Set Node

node so we're just going to grab a set node here and attach it to the system

Add String

and we're going to add in a string you'll notice i've set the keep only set so that it only sends one thing

Keep Only Set

so a quick note as to why i turned on the keep only set option in the set node there's a lot of extra information coming in from the web hook and we really don't want this information going out when responding back to the call so when we turn this on only the information that is set in the set note itself will be forwarded on to the api anyway back to the video so we're going to call

Response

this the response and the response is going to be message received all right so then we'll close that node

Execution

so now that we have both of them done we'll just save that again make sure we've got everything saved properly and then we're going to execute the workflow i'm going to go into the other web browser and we're going to paste in the uh endpoint that we had there and you'll notice now the response is message received exactly the way we put it in thanks for watching

Другие видео автора — n8n

Ctrl+V

Экстракт Знаний в Telegram

Экстракты и дистилляты из лучших YouTube-каналов — сразу после публикации.

Подписаться

Дайджест Экстрактов

Лучшие методички за неделю — каждый понедельник