Skip to main content

WEBHOOK

EXE Webhooks

Overview

UI path - https://<your-tenant>.hiiretail.com/external-events/webhooks

Webhook is a way for an external developer, to receive events from HiiRetail services. Webhooks specify which events you want to consume and what callback url will be called on specific events.

How to create webhooks?

Using UI - navigate to https://<your-tenant>.hiiretail.com/external-events/event-sources, select needed event sources, and click Subscribe.

Using API - OpenAPI Schema.

Consuming the data

All data is sent in form of a Cloud Event, refer to this document

Security

We have two possible ways for you to ensure that data you receive in your callback method is secure and safe:

  • In all the incoming requests that you receive we will include an Authorization header which can contain:
    • Google Bearer token in which you could verify that it was signed by Google with expected service account, and your Webhook's name will be specified as the audience.
    • Basic authorization, which you can verify by username and password that you specified when creating the Webhook.
  • There's also a possibility for you to specify a secret when you configure your Webhook. In that case in addition to the Authorization header we will also include a custom signature header X-Hii-Signature with the HMAC signature of the payload. You can use that to verify data integrity and security (more about signature here).