A
A
abonu2016-12-28 12:48:14
PHP
abonu, 2016-12-28 12:48:14

How to dynamically create webhooks?

Hello!
There are services, for example, Zapier, where you can create many Webhooks for specific purposes, each Webhook is a separate URL (for example, https://hooks.zapier.com/hooks/catch/1111111/222222/)
Interested in 2 questions:
1 ) What actually happens when creating such a Webhook. In general, a Webhook's URL is simply the path to the script on the site (domain.com/folder/username/idscript). It is not clear how it is created dynamically? Create a directory like this https://hooks.zapier.com/hooks/catch/1111111/222222/ ?
2) Are there any services through which it would be possible to dynamically create Webhooks separately for each user of my site? Purpose: to create a site where users would specify their API key for a third-party application and for each user their own webhook would be created, which would be linked to this user's account in a third-party service. As far as I understand, this is implemented in some online chats.
The request of knowledgeable people to share their experience in creating such things. Thanks in advance!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
abonu, 2017-05-02
@abonu

I have analyzed all the popular API frameworks. Given the specifics of what I wanted to store, I chose the Node.js (Hapi.js) + Mongo bundle.
In Hapi, it seemed to me the easiest way to start working with routes, request parameters, responses, etc. from scratch.
As a result, I nevertheless filed down my site, on which a person can register, and at the same time he will be assigned an individual link, which he can indicate in third-party services as a Webhook.

Z
ZloyHobbit, 2017-01-05
@ZloyHobbit

In fact, it is completely incomprehensible what is, what should be, and by what means you plan to achieve this. I can say one thing, any dynamism is done with the help of programming, so you need a programming language, ideally the same one that is already used on the server. And on it, many different implementations are possible with identifiers, tokens, and many other tricks.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question