Trigger Webhook widget to PUT data to other Blynk Project

Hi Blynkers!
I’m playing a little bit with “Webhook widget” in order to send data from 2 Esp’s to update a Vpin from Esp “A” to Esp “B”. The problem I’m facing is that I have no idea about the way to activate the widget…:sweat_smile:

The configuration “inside” the Widget is working fine because when I press “Run Test” the Vpin at devide “B” is updated (even using my local server). If I put the URL at the browser it works also.

I tried to add a Button (in device “A”) at the same pin as the Widget in Switch mode but nothing happens.

¿How should I activate the Webhook widget properly?

Thanks in advance!!

Hi mates, please, any small advise would be appreciated…
Thanks

If I am understanding correctly, you are gathering data on Device A and want to send that value to Device B.

Why not use bridge?

Hi @Toro_Blanco,
Thanks for your help. The use of webhook widget would allow me sending data directly to other device without the need to add extra code to that device (activating or deactivating virtual pins for instance) even through different networks and possibly to other users using their own local server.
Does it have sense for you? :sweat_smile:

Yes, I can see how that would be useful.

I think the big question is can a pins value be sent to another pin?

I have passed a simple value to a virtual pin via the http://blynk-cloud.com/auth_token/update/pin?value= route, but I am not sure how you would send the value of a pin.

The idea at the moment is just feed device “B” with a fixed value.

Yep, this is already achieved l, but I wanted to do it activating the widget somehow

put that url in the webhook. then just add a button to the project (set to push) and assign it to the same pin as the webhook. When you press the button it should send the value

Hi mate,
I tried exactly the same thing without success

:wink:

hmm. I just tried it and was able to send a number to a display on a different project. As I don’t think the device is really involved it seems more like server to server communication.

button on project 1 (set as push), set to the same pin as webhook widget. Webhook widget has auth_token of project 2 that I want to send data to and the pin of the display in project 2 in its url.
Display on receiving project set to pin used in webhook url.

when button is pressed the value in webhook url is sent.

for example: http://blynk-cloud.com/auth_token/update/v2?value=167 sends the value of 167 to the display on project 2 with that is set to virtual pin 2. when i press the button on project 1 set to the webhook pin

Wow, so strange… when I press the “Run test” button it works fine, but nothing happens with Button at the dashboard…I’ll test it again in push mode instead…
Thanks @Toro_Blanco!

@Toro_Blanco,
Could you please be so kind to show your settings?
It’s not working for me…

Thanks in advance

Sure, no problem.

These two projects are running on devices in two different locations. Both on my account. Although it probably doesn’t make a difference. I am using the blynk server.

The url in the webhook is (except with my actual auth_token): http://blynk-cloud.com/auth_token/update/v1?value=test123

I can stop project 1 change the text after the "= " re-start project 1, press the button and whatever text I input is displayed on project 2.

Value Display Setting On Project 2 (receiving):

Button Setting on Project 1 (sending):

Webhook Setting on Project 1:

Project 2 with received value (test123):

2 Likes

Thanks @Toro_Blanco, much appreciated, my configuration is exactly as yours and in my case it’s not working properly, again, the “Run test” works but it does nothing when the button is pressed…

The only difference is that I’m using the local server… I’m going to flash 2 different projects using Cloud server and test it again…

Thanks again for your time…

Confirmed!!

Working fine at Cloud Server but not using Local Server.

@Gunner, could you please be so kind to check it as you use your own server as I do?

Thanks in advance

Umm, I will try. I have never really (successfully) worked with the webhook, so I will have to look this over and try and figure out what you are doing before I can test it :stuck_out_tongue:

2 Likes

Oh… it is just another way of using the API commands from the App instead of the browser… Doh… :blush:

OK, I will set up something between a couple of my projects and get back to you.

Definitely… Not a big deal for you… but I have been struggling using it with my Local Server.

Many thanks @Gunner

OK it took me a bit of fiddling to figure it out… but in my case I had missed entering the port (probably unnecessary with Cloud?) but once I added that, it worked as apparently expected :stuck_out_tongue: I didn’t even need to modify either of the projects scripts… nice trick.

Webhook URL on one project sending “test” (quite literally, including the quotes, guess they are not required for strings) to V0 on another project, all over Local Server

http://10.10.3.13:8080/803ca069e2a94533906c34c0743c85cd/update/V0?value="test"

BTW, if I have an already existing display widget that gets updated on the source project, then simply using that Display Widget’s vPin (in my case V3) in the Webhook Widget will send that data (using /pin/) to my other project’s V5 pin, each time the source Display Widget is updated.

1 Like

Many thanks @Gunner, it should be something related my server, I will check log file just in case.
Nice you like this trick, I think it could be really useful.
@Dmitriy, I’m not able to understand the reason why it works fine at could server but not using my Local Server (keep in mind the run test works properly)
Is there anything I should check/review/modify at my local server to do it work?
Thanks!