# Web Hooks

Web hook is a way for a company app to provide Kvalifika with real-time session information. A web hook delivers data to Kvalifika as it happens, meaning the data is received immediately. *Web Hooks* page shows added web hooks and gives the possibility to add new and update/delete the existing ones:

![Settings / Web hooks](https://1657647809-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MVNVgV6Dh2kMg2n55Z5%2F-MWPwfRxHRZENuVa-BSb%2F-MWPzT1Rt8wndUragULX%2Fimage.png?alt=media\&token=1be42d21-ca34-46f5-9140-45454129f9e3)

By clicking `CONFIGURE NEW WEBHOOK`, Master User can add a new web hook, after first selecting from the two available types:

* Callback webhook
* Serverless function web hook

![Adding a new web hook](https://1657647809-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MVNVgV6Dh2kMg2n55Z5%2F-MWPwfRxHRZENuVa-BSb%2F-MWQ0A9MJ9ZZa1bDz4r5%2Fimage.png?alt=media\&token=23972f6f-6ea0-43fc-a9c5-3df3390e2aff)

### Callback webhook

After selecting Callback webhook, it is possible to configure it on the same pop-up window:

![Adding Callback webhook](https://1657647809-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MVNVgV6Dh2kMg2n55Z5%2F-MWPwfRxHRZENuVa-BSb%2F-MWQ0hnmKDu7xBHf8Cfq%2Fimage.png?alt=media\&token=bb400d4e-33ae-4411-94f9-be639d62f916)

The following options should be selected:

* Web Hook
  * Post Verification
  * Post Manual Verification
* Method (see [this article](https://www.w3schools.com/tags/ref_httpmethods.asp) for more details)
  * POST
  * PUT
* Callback URL
* Active (ON/OFF)
* ACTIVATE

### Serverless function hook

If Serverless function hook is selected, it is possible to create web hook directly from the Kvalifika platform in the same pop-up window:

![Adding Serverless function hook](https://1657647809-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MVNVgV6Dh2kMg2n55Z5%2F-MWPwfRxHRZENuVa-BSb%2F-MWQ2-CQ-ia2BYxM-wXg%2Fimage.png?alt=media\&token=5be2cb12-21a5-4f14-b109-f62f5181568d)

Serverless function is written in JavaScript programming language (Python or other languages may be added later). The following information is needed for creating a new serverless function hook:

* Function name
* Web Hook
  * Which session data should be transferred:
    * Verification
    * Manual Verification
* Enabled (ON/OFF)
* Function body
* CREATE

After adding a new web hook, it will be available for further configuration on the landing page of Settings/Configuration/Web Hooks.
