Skip to main content

Webhooks

A webhook is a message the shop sends to Invdash the moment something changes, for example when an order is placed. With webhooks, changes to orders, products and stock in WooCommerce reach Invdash within seconds instead of with the next scheduled sync.

Webhooks are a complement. The regular sync fetches the same changes, so nothing is lost if a message should fail to arrive.

Which shops it applies to​

The Webhooks page is for WooCommerce shops.

  • Shopify tells Invdash of changes by itself as soon as the shop is connected. You don't set anything up.
  • Abicart has Instant orders instead, which you turn on from the Stores page. See Connect an Abicart shop.

Shopify and Abicart stores are shown on the page with the label Scheduled sync and a line that says why: Shopify tells Invdash of changes by itself, and Abicart's changes are picked up with the scheduled sync. There's nothing to set up there.

Open the page​

Open Settings › Integration › Webhooks. Only owners and admins can see the page.

The page has two parts: a row per store with the state of the store's webhooks, and the Recent events list.

Set up webhooks for a WooCommerce shop​

You need the Invdash plugin in the shop. A store that isn't finished has the label Needs setup, and the row shows the steps that are left:

  1. Click Create secret on the store's row. WooCommerce signs each webhook with a secret, so Invdash knows it came from your shop. Invdash sends the secret to the plugin, so there's nothing to copy.
  2. Click Copy address on the row. In WordPress, open Settings › Invdash, paste the address under App webhook URL and save. The plugin then adds the webhooks to WooCommerce.

The label changes to Waiting for first event, and to Receiving events once the first change in the shop has arrived.

If the plugin can't take the secret

Invdash then shows the secret once, with the steps for adding it by hand: copy it, open Settings › Invdash in WordPress, paste it under Shared secret and save. The secret can't be shown again.

Read the store's row​

LabelMeaning
Receiving eventsThe webhooks are active and events arrive.
Waiting for first eventEverything is set up, but the shop hasn't sent anything yet.
Needs setupThe steps on the row are left to do.
Needs attentionSomething should be looked at, such as events that couldn't be processed.
Action requiredThe webhooks aren't working. The row says why.
PausedSync is paused for the store, and its events are refused.
Scheduled syncThe store's webhooks aren't set up here (Shopify and Abicart).

Under the label are the details:

  • How many webhooks are active in WooCommerce and when that was checked.
  • Last event. If it's been quiet for long, it says the store hasn't changed since. If the store has changed without an event arriving, the row says so.
  • Rejected deliveries, with the reason: that WooCommerce signs with a different secret, that no secret is set up or that the store is paused.
  • Events that couldn't be processed in the last 24 hours, with the Show failed events link.

When WooCommerce switches webhooks off​

WooCommerce switches off a webhook that has failed several times in a row, for example if the shop has had downtime. Invdash therefore checks the shop's webhooks regularly and turns them back on. You don't have to do anything.

If they can't be turned back on, the row says that re-enabling failed and the label becomes Action required. Then check that the store's API key has Read/Write access, and run Test connection on the Stores page. The state is also shown on Sync health.

Rotate or revoke the secret​

  • Rotate secret on the store's row creates a new secret and puts it on the store's webhooks. The old one keeps working for a while, so no deliveries are lost.
  • Revoke secret is under more actions on the row. Only do it if you know why: afterwards the store's events may be rejected.

Older stores may have no secret of their own (No secret of its own). A secret of its own is safer, and switching loses no events.

Recent events​

The list shows every event that has come in, grouped by day: what happened (for example Order created, Product updated or Stock reduced), which order or product it concerns and how it went.

  • Filter by Event type (orders, products, stock), Status and, if you have several WooCommerce stores, Store.
  • The status is Processed, Failed, Ignored, Received or Processing. The filter has the first four.
  • Load more fetches older events.

You normally don't need to do anything about a failed event: the regular sync fetches the same change.

If something doesn't work​

  • "No webhooks point at Invdash yet." The address isn't saved in the plugin. Do step 2 above.
  • "WooCommerce is signing with a different secret." Click Rotate secret and Invdash puts a new one in place.
  • "No signing secret is set up." Click Create secret.
  • The secret couldn't be put in place. Invdash says why, for example that the API key needs Read/Write access or that no webhooks point at Invdash, and shows how to add it by hand.