Webhook
With this module you can work with webhook in Rocketbot, how to wait for a request before continuing with the flow of
your robot
Howto install this module
Download and install the content in 'modules' folder in Rocketbot path
How to use this module
To use this module, you need to have a port available to expose the webhook.
Expose the
webhook with NGROK
- Download NGROK (https://ngrok.com/download)
- Unzip the file
- Run ngrok and run command "ngrok
http port-number" Here the port-number is: 5002
Once you run the above command it will expose two URLs. One for HTTP
and another for HTTPS. You can use either of them. - Copy the public URL of the HTTP and HTTP.
Use the webhook
When executing the 'Create webhook' command, Rocketbot will pause waiting
for the url configured in the command to be queried, either with a GET or POST request. If the request is GET, the data
to be sent must be in the URL. If the request is POST, the data must be in the body of the request.
This will return
the following JSON:
{
"status": "true",
"uuid": "2c9f8f7e-b8e7-4b5b-b8e7-4b5b8e7b8e7b"
}
To
get data from Rocketbot, you must query the url 'localhost:port/:enpoint/:uuid'.
This will return a JSON response in the
following format:
{
"status": True",
"data": datos_desde_rocketbot
}
Overview
- Create webhook
With this command you can create an endpoint for the robot to listen to a request before continuing, the url will be
'0.0.0.0:port/endpoint'
OS
- windows
- mac
- linux
- docker
Dependencies
License
Con este módulo podrás trabajar con webhook en Rocketbot, como esperar una petición antes de continuar con el flujo de tu robot | With this module you can work with webhook in Rocketbot, how to wait for a request before continuing with the flow of your robot
Category
Orchestrator
Author
Danilo Toro
Version
1.0.0
Published
2021-11-18
Tags
Downloads
See documentation