Creating a Webhook Action from the Action Center #
To create a Webhook Action from the Action Center page:
-
In the Create a New Action page, in the General step, enter:
-
Action Type. Select an action from the pulldown options.
-
Configuration Name. Select an action configuration from the pulldown options.
-
Action Name. Identifier for the action. This name will appear in the Lucidum Action Center.
-
Description. Description of the action.
-
-
Click the Next (>) icon.
-
In the Filters page, click Configure Filters.
-
The Configure Filters for Action page appears.
-
In the Configure Filters for Action page, you define the query for the assets or users that the action will act upon. For existing actions, the query is already loaded in this page.
-
For details on creating and editing queries in Lucidum, the section on Building Queries.
NOTE: To optimize performance, the default time range is Current. If you need to access historical data, contact Lucidum Custom Success for help on using historical data without affecting performance.
-
Click the Apply (page and pencil) icon.
-
Click the Next (>) icon.
-
In the Schedule step, enter:
-
Schedule Type. Define the schedule for the action. Choices are:
-
Recurrence. Specify a frequency for the recurring schedule.
-
After Data Ingestion. The action is executed after data ingestion, which happens at least once every 24 hours and can also be triggered manually.
-
-
Do not trigger the action unless. Specify the number of results from Filters as a prerequisite for executing the action.
-
-
Click the Next (>) icon.
-
In the Details step, enter the following:
-
Output Fields. For the records selected with the Filters field, specify the columns to display. When creating or editing the query, you can select these fields in the Query Results page > Edit Column button.
-
Payload template. This field formats the webhook payload before sending it. By default, the payload template includes logic that specifies:
-
For the value from each field in Output Fields, push the value through a program that converts the value to JSON, then add a new line character.
-
However, you can use any JINJA statements, expressions, and filters to modify this template to suit your needs. For details on JINJA, see https://jinja.palletsprojects.com/en/3.1.x/templates/.
-
-
Dedup previous jobs. In this field, you specify whether you want duplicates of asset IDs (if your query is for assets) or user IDs (if your query is for users). You can specify integers between 0 and the number specified in Settings > Data Settings > Action Result Retention in Days. This setting specifies the number of days that Lucidum stores action results.
-
If you specify “0” (zero), Lucidum includes all the records from the query in each delivery of the webhook.
-
If you specify “1” (one), Lucidum examines the previous webhook payload and excludes records for asset IDs or user IDs that were sent in the previous webhook payload.
-
If you specify “2” (two), Lucidum examines the last two webhook payloads and excludes records for asset IDs or user IDs that were sent in the previous two webhook payloads.
-
-
-
Click the Save (disc) icon to save the Webhook Action.
Creating a Webhook Action from the Query Results page #
You can also create a Webhook Action when viewing the results of a query. To do this:
-
Create a query from the Query button. For details, see the chapter on Creating Queries.
-
Click the Show Results (checklist) icon to open the Query Result page
-
The Query Results page displays a the results of query.
-
In the Query Results page, click the Create a recurring action (arrows) icon.
-
In the Send to Action Center page, select Webhook.
-
Lucidum displays the Create a New Action page, with the query already loaded in the Filters page.
-
Follow the steps from the previous section to create the Webhook Action.