Duplicate Webhook Execution

I’m using

bool result = Particle.publish(“Logger”, message);

The event occurs once in the “Events” view.

However the event occurs twice in the corresponding Webhook log (with the same published_at timestamp).

What could cause this?

Hi there,

Could you please submit a support ticket at support.particle.io with your Particle account details so that we can review the logs?

A few possibilities:

  1. The webhook event name is a prefix, so if you if you have webhooks with the events “test” and “test2” and fire the event “test2” then both webhooks will execute.

  2. You can have multiple webhooks responding to the same event.

  3. If there is a webhook both as a product webhook and a user webhook for the same filter, both will fire if the product device is claimed to that user.

  4. When you upload a webhook by the CLI, it will create another webhook with the same event filter, so there will now be two (or more).

Since you mentioned that it’s showing up twice in the webhook log it may not be any of these issues, but those are the common reasons in general.