# Rollbar Integration

### Overview

[Rollbar](https://app.rollbar.com/a/itserv/fix/items?isSnoozed=false\&from=now+-+7d) is an error monitoring and tracking platform that captures exceptions, errors, and log messages from your applications in real time. By configuring a webhook notification channel in Rollbar, you can forward error alerts directly to ITOC360 and trigger your on-call escalation policies the moment a new issue is detected.

### Provider Configuration & Mapping

ITOC360 uses the `event_name` field from the Rollbar webhook payload to determine the alert type.

| Rollbar Event      | ITOC360 Type |
| ------------------ | ------------ |
| `new_item`         | ALERT        |
| `reactivated_item` | ALERT        |
| `reopened_item`    | ALERT        |
| `occurrence`       | ALERT        |
| `item_velocity`    | ALERT        |
| `exp_repeat_item`  | ALERT        |
| `resolved_item`    | RESOLVE      |

Priority is mapped from the `level` field on the item:

| Rollbar Level   | ITOC360 Priority |
| --------------- | ---------------- |
| `20` (debug)    | LOW              |
| `30` (warning)  | MEDIUM           |
| `40` (error)    | HIGH             |
| `50` (critical) | CRITICAL         |

### Setup Instructions

#### Step 1: Get Your Webhook URL and Token

1. Log in to your ITOC360 platform.
2. Go to **Sources → Add Source**.
3. Select **Rollbar** as your provider.
4. Save the configuration and copy the generated **Token**.

#### Step 2: Open Your Rollbar Project

1. Log in to your Rollbar account.
2. From the left sidebar, click **Projects** and select your project.

<figure><img src="https://4108595529-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FimJRSa33y5Ej6rwXrBeA%2Fuploads%2FtLh2GmO59qxB2BVn2nqS%2Fimage.png?alt=media&#x26;token=cb576804-5893-4738-8e63-35c4a3ad2fc6" alt=""><figcaption></figcaption></figure>

#### Step 3: Configure the Webhook

1. Inside your project, go to **Settings → Notifications**.
2. Under **Available Channels**, click **Webhook**.

<figure><img src="https://4108595529-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FimJRSa33y5Ej6rwXrBeA%2Fuploads%2FqgBNEkYMClInLEOg5NQ0%2Fimage.png?alt=media&#x26;token=e3e47f80-c9b5-4674-8de4-d11c2ed36f19" alt=""><figcaption></figcaption></figure>

3. In the **URL** field, paste your ITOC360 webhook URL in the following format:

   ```
   https://api.itoc360.app/functions/v1/events?token=YOUR_TOKEN
   ```
4. Click **Save Settings**. The webhook status will change to **Enabled**.

<figure><img src="https://4108595529-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FimJRSa33y5Ej6rwXrBeA%2Fuploads%2FjlmS4JnTGGskILg7GEjF%2Fimage.png?alt=media&#x26;token=4b31bc25-cc97-4089-b387-ab9c8872dba3" alt=""><figcaption></figcaption></figure>

#### Step 4: Verify the Rules

Rollbar automatically creates default notification rules when you enable the webhook. Make sure the following rules are active:

* **New Item → Post to Webhook** — triggers when a new error is detected
* **Item Reactivated → Post to Webhook** — triggers when a previously resolved error recurs
* **Item Resolved → Post to Webhook** — triggers when an item is resolved, which automatically closes the alert in ITOC360

You can add, edit, or remove rules from the same Webhook settings page based on your team's alerting preferences.

#### Step 5: Verify the Integration

Trigger a test error in your application or use Rollbar's **Send Test Notification** button on the Webhook settings page. The alert should appear in ITOC360 under the source you created.

When the item is resolved in Rollbar, ITOC360 will automatically close the corresponding alert.
