> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stackone.com/llms.txt
> Use this file to discover all available pages before exploring further.

# AD Manager Webhook Setup Guide

> Configure AD Manager to deliver events to StackOne.

## Prerequisites

The connector should already be set up, with a Connector Profile and a Linked Account. See [Getting Started](https://docs.stackone.com/connectors/admanager.md#getting-started) on the AD Manager connector page.

## Retrieve the Native Webhook URL

The **Native Webhook URL** is generated once an account has been linked.

<ul>
  <li>Open the linked account in StackOne.</li>
  <li>Copy the value from **Native Webhook URL**.</li>
  <li>The URL ends with a per-connection `?token=` that identifies your account, so treat it like a secret and paste it in full.</li>
</ul>

## Creating the webhook template

A webhook template defines the request ADManager Plus sends to StackOne.

**1. Open Orchestration Template**

Sign in to the ADManager Plus web console as an admin, open the **Automation** tab and, under **Configuration**, click **Orchestration Template**.

![The Automation tab with Orchestration Template highlighted in the Configuration menu](https://mintcdn.com/stackone-60/hLRfDk2Cq1W-3g4N/connectors/admanager/images/events-orchestration-template-menu.png?fit=max\&auto=format\&n=hLRfDk2Cq1W-3g4N\&q=85\&s=b4df194046ff125247f725104d94ec67)

**2. Open Configure Webhook**

On the **Orchestration Template** page, click **Configure Webhook**.

![The Orchestration Template page with the Configure Webhook link highlighted](https://mintcdn.com/stackone-60/hLRfDk2Cq1W-3g4N/connectors/admanager/images/events-configure-webhook.png?fit=max\&auto=format\&n=hLRfDk2Cq1W-3g4N\&q=85\&s=8d1aaf78251423c8a8057f21ff2e87e8)

**3. Create a new webhook template**

On the **Webhook Template** page, click **New Webhook Template**.

![The Webhook Template page with the New Webhook Template button highlighted](https://mintcdn.com/stackone-60/hLRfDk2Cq1W-3g4N/connectors/admanager/images/events-new-webhook-template.png?fit=max\&auto=format\&n=hLRfDk2Cq1W-3g4N\&q=85\&s=cf966c509f1b914731cdb271d68e770a)

**4. Set the name, URL and header**

Fill in the request details.

<ul>
  <li>Click **Untitled Webhook Template** and enter a name, for example `StackOne Integration`.</li>
  <li>Keep the method set to **POST** and paste the **Native Webhook URL** into **Enter a URL**.</li>
  <li>Leave **Authorization** set to **- Select -**. The token in the URL authenticates the request.</li>
  <li>Under **Headers**, click **Click here to add**, then enter `Content-Type` as the **Header name** and `application/json` as the **Header value**.</li>
</ul>

![The webhook template form with the name, POST method, URL field, Authorization and Content-Type header highlighted, and the URL hidden](https://mintcdn.com/stackone-60/hLRfDk2Cq1W-3g4N/connectors/admanager/images/events-webhook-request-details.png?fit=max\&auto=format\&n=hLRfDk2Cq1W-3g4N\&q=85\&s=a5435fc880388931bf6d801dffef63b5)

**5. Add the JSON body**

Under **Body Message**, select **JSON** and enter the event body. **Body Message** defaults to **None**, which sends an empty body, so StackOne receives an event with no data. Type `%` in the body to pick macros, and include an `object_guid` so the event carries the AD object id, for example:

```json theme={null}
{
  "event": "user.created",
  "object_guid": "%ad.objectGUID%",
  "sam_account_name": "%ad.SamAccountName%",
  "display_name": "%ad.displayName%"
}
```

<ul>
  <li>Click **Test and Save**.</li>
</ul>

![The Body Message section with JSON selected, the JSON body and the Test and Save button highlighted](https://mintcdn.com/stackone-60/hLRfDk2Cq1W-3g4N/connectors/admanager/images/events-webhook-json-body.png?fit=max\&auto=format\&n=hLRfDk2Cq1W-3g4N\&q=85\&s=9016dca882837790c785499f592eff38)

## Testing and saving the webhook

**Test and Save** sends a real request to StackOne using the attributes of an object you pick.

**1. Pick a test object**

In **Test Webhook**, select a user on the **Users** tab and click **OK**, then click **Yes** to confirm the API call.

![The Test Webhook dialog with a user selected and the OK button highlighted](https://mintcdn.com/stackone-60/hLRfDk2Cq1W-3g4N/connectors/admanager/images/events-test-webhook.png?fit=max\&auto=format\&n=hLRfDk2Cq1W-3g4N\&q=85\&s=4a32473428754bef5838d6098ff1b840)

**2. Check the result and save**

In the test result, open **Response Details** and confirm **Response Status** is **SUCCESS** and **Response Status Code** is **200**, then click **Save**.

![The Test Connection Result with Response Status SUCCESS and Response Status Code 200 highlighted, and the Save button highlighted](https://mintcdn.com/stackone-60/hLRfDk2Cq1W-3g4N/connectors/admanager/images/events-test-result.png?fit=max\&auto=format\&n=hLRfDk2Cq1W-3g4N\&q=85\&s=47ef1695828b33fb7637b437fa6ff254)

## Triggering the webhook from AD events

An event-driven automation runs the webhook whenever the chosen AD action happens in ADManager Plus.

**1. Create an event-driven automation**

Under **Automation**, click **Event-driven Automation**, then click **Create New Automation**.

![The Event-driven Automation page with the menu item and the Create New Automation button highlighted](https://mintcdn.com/stackone-60/hLRfDk2Cq1W-3g4N/connectors/admanager/images/events-create-automation.png?fit=max\&auto=format\&n=hLRfDk2Cq1W-3g4N\&q=85\&s=7a560a8539a7da3ef788d97c736afb40)

**2. Select the webhook template**

Click the **+** next to **Templates**, open the **Webhook** tab in **Select Templates**, tick your webhook template and click **OK**.

![The Select Templates dialog with the Webhook tab, the webhook template and the OK button highlighted](https://mintcdn.com/stackone-60/hLRfDk2Cq1W-3g4N/connectors/admanager/images/events-select-webhook.png?fit=max\&auto=format\&n=hLRfDk2Cq1W-3g4N\&q=85\&s=0080fa755924725b7814058985f61790)

**3. Configure and save the automation**

Complete the automation and click **Save**.

<ul>
  <li>**Automation Name**: a name, for example `StackOne Integration`</li>
  <li>**Automate For**: **User** or **Group**</li>
  <li>**Execute When**: tick **Created**, **Modified** and/or **Deleted**, and use **On Success** to choose which outcomes fire it</li>
  <li>Optionally add **Criteria** to limit which objects trigger the webhook.</li>
  <li>Use one automation per action, with a matching `event` value in its webhook body, if consumers need to tell creates, updates and deletes apart.</li>
</ul>

![The event-driven automation form with Automation Name, Automate For, Execute When, On Success, Templates and Save highlighted](https://mintcdn.com/stackone-60/hLRfDk2Cq1W-3g4N/connectors/admanager/images/events-automation-form.png?fit=max\&auto=format\&n=hLRfDk2Cq1W-3g4N\&q=85\&s=37b17f02736211d9ef7b5372fbbe8995)

## Available webhook events

StackOne receives every delivery from your ADManager Plus webhook templates as a single event type.

**1. AD Manager events**

Events sent by ADManager Plus outbound webhooks.

<ul>
  <li>**AD Manager Event** (`admanager.event`) — Fired when an ADManager Plus webhook template posts to the Native Webhook URL. The event data is the JSON body you configured, and its `object_guid` becomes the event's record id</li>
</ul>

## Delivery format

Details of how ADManager Plus delivers events to StackOne.

**1. One event per request**

Each webhook execution sends one POST request with the body defined in the template, so StackOne receives one event per request. ADManager Plus does not sign webhook requests; the token in the Native Webhook URL identifies the account.

## Verify

Your Connector should now be able to receive and process events. Try triggering an event and you should see an Event appear in the Connector logs.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.