Register a webhook event

Webhook registration is the process of establishing a connection between systems to enable the exchange of real-time information. When you register a webhook, you're essentially telling one system where to send data when a specific event occurs in another system.

When your user turns on a flow that contains your deployed webhook event card, the registration helper flow is triggered.

Before you begin

  • You must be a super admin with access to Okta Workflows.

  • If you haven't already created a connector, follow these steps to create one:

    • From the Okta Workflows Console, click the App switcher icon and then the link for the Connector Builder console.

    • In Connector Builder, click the + icon to create a connector. Give your new connector a unique name and a useful description.

  • Ensure that the connector has the basic foundation and authentication elements provided through the tasks in the Get started quickly with the basics section.

Start this task

  1. Click your new connector to open it in the main panel.

  2. On the Flows tab, create a flow by clicking + New Flow.

  3. Click Add event and from the Events choices, select Webhook Event: Registration.

  4. In the Webhook Registration card, define the inputs for your webhook registration. You can provide these input values in two ways:

    • As static text that is used every time the webhook event card executes the registration flow.

    • As optional values that are passed to the registration flow from the webhook event card. When you add the registration flow to a webhook event card, you can map values from the webhook event options to the inputs on this card. This second option gives you the ability to reuse the same registration event card for multiple webhook event cards.

    The Event URL is an auto-generated URL. This gets created when the user turns on their flow that contains this webhook event.

  5. Use function cards to construct and call the external service and register the webhook.

You can now reference this registration flow inside a webhook event card.

Return card

The return card includes a Registration Data object. When your user turns off a flow that contains a webhook event, the deregistration event flow references the information stored inside this object to deregister the webhook. For example, this may be a simple object with a unique identifier:

Copy
{  
"webhook_id": "99b50e15-8809-47f1"
}

The object could also consist of an API endpoint, a URL, or any other information returned by the service that is required to deregister the webhook. See Deregister a webhook event.

This field can't be deleted or removed, and no other fields can be defined on the return card.