# How to Install DataDome Bot Protection

**DataDome Bot Protection** is a *serverless* integration available at Azion **Marketplace**. Powered by AI and machine learning, DataDome detects and blocks OWASP automated threats in real time—including credential stuffing, layer 7 DDoS, bot-induced SQL injection, and scraping—in less than 2 milliseconds per request.

This integration runs as a **Firewall** function on the Azion Web Platform, enabling you to protect your websites, mobile apps, and APIs without changing your existing architecture.

:::note
DataDome Bot Protection requires an active DataDome subscription. Visit [datadome.co](https://datadome.co) to learn more about plans and pricing.
:::

---

## Getting the integration

To install **DataDome Bot Protection** from Azion Marketplace:

1. Access [Azion Console](/en/documentation/products/guides/how-to-access-azion-console/) > **Marketplace**.
2. On the Marketplace homepage, type `DataDome Bot Protection` in the search bar.
3. Select the **DataDome Bot Protection** card.
4. Once the integration's page opens, click the **Install** button.

A **"Latest version installed!"** message confirms the integration was successfully installed.

:::tip
You can search for any integration by browsing through the cards, using the filters, or typing a keyword in the search bar.
:::

---

## Configuring the integration

The integration is added to your list of **Functions** after installation. Because DataDome Bot Protection runs under Azion **Firewall**, you must configure a firewall, instantiate the function, and set up the Rules Engine.

### Setting up a Firewall

1. On the upper-left corner, select **Products menu** > **Firewall** in the **Secure** section.
2. Click the **+ Firewall** button.
3. Give an easy-to-remember name to your firewall.
4. Enable the **Functions** switch in the **Modules** section.
5. Click the **Save** button.

Done. Your firewall is configured and has access to Functions.

:::caution[Warning]
Activating modules may generate usage-related costs. Check the [pricing page](/en/documentation/products/pricing/) for more details.
:::

### Setting up the function

While still on the **Firewall** page:

1. Select the **Functions Instances** tab.
2. Click the **+ Function Instance** button.
3. Give an easy-to-remember name to your instance.
4. On the dropdown menu, select the **DataDome Bot Protection** function.
   - This action will load the **Arguments** tab.
5. On the **Arguments** tab, fill in the required parameters.
   - `api_key`: Your DataDome server-side API key.

6. Click the **Save** button.

Done. Your DataDome Bot Protection instance is saved.

### Setting up the Rules Engine

To finish, configure the **Rules Engine** to define the *criteria* and *behavior* that trigger the integration.

Still on the **Firewall** page:

1. Select the **Rules Engine** tab.
2. Click the **+ Rule Engine** button.
3. Give an easy-to-remember name to the rule.
4. Select a *criteria* to match the domains you want to protect.
   - Example: if `Host` *matches* `yourdomain.com`.
5. Below, select **Run Function** as the *behavior*.
   - Select the DataDome Bot Protection function instance you created in the previous step.
6. Click the **Save** button.

Now, configure your domain to be protected by this firewall:

7. On the **Products menu**, select **Workloads**.
8. Click on the domain you want to protect.
9. In the **Settings** section, click on the `Firewall` selector and choose the firewall you created.
10. Click the **Save** button.

Done. **DataDome Bot Protection** is now running for every request made to the domain you indicated.

---

## How it works

For each incoming request, the DataDome function:

1. Collects request metadata (IP address, User-Agent, headers, and cookies).
2. Sends the data to the DataDome API for real-time analysis.
3. Based on the DataDome response, either allows the request to proceed or blocks/challenges it according to your DataDome dashboard configuration.

DataDome's AI engine analyzes billions of daily requests and updates continuously to identify and prevent both known and zero-day threats.

---

## Monitoring bot activity

Use Azion observability tools to monitor the DataDome integration activity:

- **[Real-Time Events](/en/documentation/products/observe/real-time-events/)**: Access the **Functions** tab to inspect individual request logs and DataDome responses.
- **[Data Stream](/en/documentation/products/observe/data-stream/)**: Create a stream using the **Functions Event Collector** template to forward logs to your preferred endpoint for long-term analysis.