---
title: Thresholds
summary: Manage workspace thresholds.
url: https://www.fastly.com/documentation/reference/api/ngwaf/thresholds
---

Manage workspace thresholds.

## Data model

| Field | Type | Description |
|-------|------|-------------|
| `action` | string | Action to take when threshold is exceeded. |
| `dont_notify` | boolean | Whether to silence notifications when action is taken. |
| `duration` | integer | Duration the action is in place. Default duration is 86,400 seconds (1 day). |
| `enabled` | boolean | Whether this threshold is active. |
| `id` | string | Threshold ID. (Read-only) |
| `interval` | integer | Threshold interval in seconds. Default interval is 3600 seconds (1 hour). |
| `limit` | integer | Threshold limit. Default limit is 10. |
| `name` | string | Threshold name. |
| `signal` | string | The name of the signal this threshold is acting on. |

## API endpoints

### List thresholds

**GET** `/ngwaf/v1/workspaces/{workspace_id}/thresholds`

List configured thresholds for this workspace.

**Parameters:**

| Name | Type | In | Required | Description |
|------|------|----|---------|--------------|
| `limit` | integer | query | No | Limit how many results are returned. |
| `workspace_id` | string | path | Yes | The ID of the workspace. |

### Create a new workspace threshold

**POST** `/ngwaf/v1/workspaces/{workspace_id}/thresholds`

Add a new threshold.

**Parameters:**

| Name | Type | In | Required | Description |
|------|------|----|---------|--------------|
| `workspace_id` | string | path | Yes | The ID of the workspace. |

### Retrieve threshold

**GET** `/ngwaf/v1/workspaces/{workspace_id}/thresholds/{threshold_id}`

Get a threshold for a workspace.

**Parameters:**

| Name | Type | In | Required | Description |
|------|------|----|---------|--------------|
| `threshold_id` | string | path | Yes | The ID of the threshold. |
| `workspace_id` | string | path | Yes | The ID of the workspace. |

### Remove a threshold

**DELETE** `/ngwaf/v1/workspaces/{workspace_id}/thresholds/{threshold_id}`

Delete a threshold.

**Parameters:**

| Name | Type | In | Required | Description |
|------|------|----|---------|--------------|
| `threshold_id` | string | path | Yes | The ID of the threshold. |
| `workspace_id` | string | path | Yes | The ID of the workspace. |

### Edit threshold

**PATCH** `/ngwaf/v1/workspaces/{workspace_id}/thresholds/{threshold_id}`

Change attributes of a threshold in a workspace.

**Parameters:**

| Name | Type | In | Required | Description |
|------|------|----|---------|--------------|
| `threshold_id` | string | path | Yes | The ID of the threshold. |
| `workspace_id` | string | path | Yes | The ID of the workspace. |

