# Creating a Monitor

## Starting Monitor Creation

1. Navigate to the **Alerting Monitors** page
2. Select the asset you want to monitor from the left sidebar
3. Click the **"+ New Monitor"** button in the top-right corner

<figure><img src="https://604868671-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MkO3-a8YVu1iq1jP__S%2Fuploads%2FfUuygB6O2r4iShwpTWxV%2Fimage.png?alt=media&#x26;token=3fc7814f-bcea-4d0e-b732-1cbf024835da" alt=""><figcaption></figcaption></figure>

### Monitor Creation Panel

The monitor creation panel opens on the right side with two main sections:

**Section 1: Monitor Policy:** Choose your monitoring type

**Section 2: Configuration:** Set thresholds and conditions

**Section 3: Notification:** Set notification channels \[optional]

**Section 4: Ticketing:** Set auto-ticketing requirements \[optional]

***

## Choosing Monitor Type

Select from three monitor types based on your monitoring needs:

* [Built-in Metric](https://docs.telm.ai/telmai/monitoring-data/user-defined-monitors/built-in-metrics)
* [User-Defined Metric](https://docs.telm.ai/telmai/monitoring-data/user-defined-monitors/user-defined-metrics)
* [Record Validation Rule](https://docs.telm.ai/telmai/monitoring-data/user-defined-monitors/record-validation-rules)

<figure><img src="https://604868671-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MkO3-a8YVu1iq1jP__S%2Fuploads%2FTSaQLXS8n4Rc97R28WFf%2Fimage.png?alt=media&#x26;token=caa7fd31-f5e3-4769-86c9-6c5e34cb3a5f" alt=""><figcaption></figcaption></figure>

{% hint style="warning" %}
**Important:** Monitor type cannot be changed after creation. Choose carefully based on your monitoring requirements.
{% endhint %}

### Configuration Section

After selecting your monitor type, configure the monitor details:

<figure><img src="https://604868671-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MkO3-a8YVu1iq1jP__S%2Fuploads%2FRLGP35FO8txNOnoTTxoZ%2Fimage.png?alt=media&#x26;token=e0a930e4-2bb8-4e63-a09a-30942097aeb0" alt=""><figcaption></figcaption></figure>

#### Basic Information

<table><thead><tr><th width="227.0810546875">Section</th><th>Details</th></tr></thead><tbody><tr><td><strong>Monitor Name (Required)</strong></td><td><ul><li>Must be unique per asset</li><li>Use descriptive names that clearly indicate what's being monitored</li><li>Example: <code>sales_data_freshness_check</code>, <code>email_validation_monitor</code></li></ul></td></tr><tr><td><strong>Description (Optional)</strong></td><td><p>Add context about:</p><ul><li>What the monitor checks</li><li>Why it's important</li><li>Expected behaviour</li><li>Remediation steps</li></ul></td></tr><tr><td><strong>Monitor Tags (Optional)</strong></td><td><p>Organize monitors using tags:</p><ul><li>Add multiple tags for categorization</li><li>Use consistent tagging across monitors</li><li>Examples: <code>critical</code>, <code>daily-check</code>, <code>revenue-impacting</code></li></ul></td></tr><tr><td><strong>Impact (Optional)</strong></td><td><p>Set the severity level for alerts generated by this monitor:</p><ul><li><strong>High</strong>: Important issues requiring prompt resolution</li><li><strong>Medium</strong>: Notable issues that should be addressed</li><li><strong>Low</strong>: Minor issues for awareness</li></ul></td></tr></tbody></table>

***

### Configuring Built-in Metrics

When you select **Built-in Metric**, you'll see the predefined metric configuration section.

#### Data Quality Metric (Required)

Select from available predefined metrics:

* **record\_count**: Total number of records
* **null\_percentage**: Percentage of null values
* **freshness**: Time since last data update
* **completeness**: Data completeness score
* **uniqueness**: Duplicate detection
* **schema\_drifts**: Schema change detection
* [And more...](https://docs.telm.ai/telmai/monitoring-data/user-defined-monitors/built-in-metrics)

#### Attributes (Optional)

For metrics that support attribute-level monitoring:

* Select specific columns to monitor
* Leave blank for table-level metrics
* Multiple attributes can be selected

**Examples:**

* Monitor `uniqueness` on `customer_id` field

***

### Configuring User-Defined Metrics

When you select **User-Defined Metric**, you can define custom metrics using expressions or SQL.

#### Method 1: Expression-Based Metrics

Write simple aggregations with grouping. Example:

```
AGGREGATION(`attribute`) GROUP BY `dimension1`, `dimension2`
```

See [full expression documentation](https://docs.telm.ai/telmai/user-defined-monitors/user-defined-metrics#metric-expressions) for more examples.

#### Method 2: Custom SQL Queries

Write SQL queries for complex monitoring logic. Example:

```sql
SELECT AVG(order_value), customer_region, product_category
FROM `orders` 
WHERE order_date >= CURRENT_DATE - 30
GROUP BY customer_region, product_category
```

See [push down SQL documentation ](https://docs.telm.ai/telmai/user-defined-monitors/user-defined-metrics#raw-sql-queries)for more examples.

***

### Configuring Record Validation Rules

When you select **Record Validation Rule**, you define checks for individual records.

#### Rule Definition

Write validation expressions for row-level checks:

**Syntax:**

```
validate CONDITION expect TELM_EXPECTATION
```

See [record violation rules ](https://docs.telm.ai/telmai/monitoring-data/user-defined-monitors/record-validation-rules)for more examples.

***

## Threshold Configuration

All monitor types require threshold configuration to determine when alerts are triggered.

<figure><img src="https://604868671-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MkO3-a8YVu1iq1jP__S%2Fuploads%2FwraesUBBliEy40SWciD8%2Fimage.png?alt=media&#x26;token=c8b8b0f7-4011-4561-9d91-ef17c96ea411" alt=""><figcaption></figcaption></figure>

### Threshold Types

Choose from three threshold approaches:

#### **Automatic (ML-Based)**

Let machine learning determine dynamic boundaries based on historical patterns.

**Best for:**

* Metrics with seasonal patterns
* Establishing initial baselines
* Adapting to data evolution

#### **Acceptable Drift %**

Set percentage-based boundaries using moving averages.

**Best for:**

* Relative comparisons to recent performance
* Allowing controlled variance
* Gradual data changes

**Configuration:**

* Define acceptable drift percentage: Set minimum & maximum drift percentage values

#### **Acceptable Range**

Define constant, fixed boundaries.

**Best for:**

* Hard business rules
* Strict compliance requirements
* Known acceptable limits

**Configuration:**

* Set minimum & maximum value

### Additional Configuration Options

#### Compare to Past # Scans

Specify how many historical datapoints to consider:

* More scans = more stable baseline
* Fewer scans = more responsive to recent changes
* Default: `Automatic` (system-determined)

#### Replace Missing Values

Choose how to handle gaps in your metric time series:

* **Ignore**: Skip missing datapoints
* **Use average**: Fill with calculated average
* **Use zero**: Treat missing as zero

***

## Notification & Ticketing Configuration

Each monitor can be configured to send alerts and automatically create tickets when data quality issues are detected. These settings help ensure the right teams are notified and issues are tracked through resolution.

Configure where alerts should be sent when this monitor detects data quality issues.

### **Setting Up Alert Channels**

1. Click **+ Add Channel** in the Notifications section
2. Add as many predefined notification destination as needed
3. Use the **Enabled** toggle to activate or deactivate notifications for this monitor

**Note**: Notifications are marked as **OPTIONAL**. Monitors will continue to function and track data quality even without configured alert channels.

[Learn more about managing alert channels](https://docs.telm.ai/telmai/monitoring-data/monitors-management/configuring-notifications)

***

### Ticketing

Enable automatic ticket creation to track and manage data quality issues through your existing workflow tools.

**Auto-Ticketing Setup**

When enabled, Telmai automatically creates a ticket in your ticketing system whenever this monitor's policy conditions are met. This ensures data quality issues are formally tracked and assigned for resolution.

**To enable auto-ticketing:**

1. Check the **Create ticket automatically** checkbox
2. Select a ticket **Template** from the dropdown
   * Templates define ticket fields, priority, assignment rules, and other properties
   * Templates must be configured in advance in your ticketing integration settings
3. Save your monitor configuration

**Note**: Ticketing is marked as **OPTIONAL**. This feature requires a configured ticketing integration and defining templates before this feature is enabled. [Learn more about managing ticketing integration with Jira.](https://docs.telm.ai/telmai/integrations/jira-integration)

***

## Saving Your Monitor

#### Save and Cancel Actions

After configuring your monitor:

1. **Review** all settings
2. Click **"Save"** to create the monitor (green button, bottom-right)
3. Or click **"Cancel"** to discard changes

![](https://604868671-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MkO3-a8YVu1iq1jP__S%2Fuploads%2FQnVs5Xd3xfMBUiBwD70e%2Fimage.png?alt=media\&token=978e923b-b19c-4602-b121-ff4623fa854a)

### What Happens After Saving

* Monitor is immediately created and enabled (by default)
* Appears in the monitor list for the selected asset
* Begins evaluating data according to configured schedule
* Will generate alerts when thresholds are violated

***

## Related Documentation

* [Managing Existing Monitors](https://docs.telm.ai/telmai/monitoring-data/monitors-management/managing-existing-monitors)
* [Configuring Data-Binning](https://docs.telm.ai/telmai/monitoring-data/monitors-management/configuring-data-binning)
* [Configuring Notification](https://docs.telm.ai/telmai/monitoring-data/monitors-management/configuring-notifications)

***
