Introduction

What are Hooks?

Hooks, or webhooks are HTTP(s) URIs you can register on the Storage & Hooks page of the Cloud Dashboard. After registration, the details of each successful vehicle API request (including the full API result and a link to the image processed) will be sent to these URIs in HTTP POST requests.

caution

Hooks are only available if event storage is enabled for the one of our APIs (Vehicle API, Transportation & Cargo API). Please note that by enabling storage, you implicitly allow storing all data and images sent to the API endpoints for 24 hours.

The following diagram shows a simplified overview of how event forwarding works:

Architecture Overview

  1. The client sends an image to the API.
  2. The API responds with the recognition result and if storage is enabled, it also saves it in the temporary cloud storage database along with the source image.
  3. This triggers sending HTTP POST requests to all registered and verified hooks with the full API response and a link to the image processed.

Who should use Hooks?

For most use cases, calling the Vehicle API and processing the HTTP response is the most convenient way to use our recognition technology. If event storage is turned off, this architecture also offers stricter data security guarantees: input images and recognition results are not stored persistently in the cloud and are immediately discarded after sending the HTTP response. However, in certain cases you might need to forward results to a different server than where the API request originates, which is when Hooks come in handy.

  • Separation of Concerns: Sometimes, due to architectural reasons, you may need to process recognition data in a different location than where the input image was captured. For example, you may have multiple locations with cameras and client software installed which send the images to the Vehicle API but you need to collect and process the results on a central server.
  • Data Security: Using Hooks requires event storage to be turned on, so if required by law in your jurisdiction, you need to notify your customers that their data will be retained by a third party for up to 24 hours.

How much does it cost?

Using Event Storage and Hooks is free for all of our subscribers.

info

The number of Hook registrations is currently limited to 10 hooks per user account.