---
title: "Test-evaluate an alert rule against an item without persisting."
method: POST
path: "/v1/alerts/test_rule"
tags: ["resource-facade"]
---

# Test-evaluate an alert rule against an item without persisting.

`POST /v1/alerts/test_rule`

## Headers

- `x-api-key` string, nullable

## Request body

- TestAlertRuleInput
  - `rule_id` string, required
  - `item_id` string, required

## Response `200`

Successful Response

- TestAlertRuleOutput
  - `computed_value` number, required
  - `threshold` number, required
  - `comparison` string, required
  - `would_trigger` boolean, required
  - `expression` string, required
  - `item_id` string, required

## Other responses

- `401` — Unauthorized
- `403` — Forbidden
- `404` — Not Found
- `422` — Validation Error
- `500` — Internal Server Error

---

[API](https://skmtc.dev/geopera/apis/geopera-data-platform.md) · [All operations](https://skmtc.dev/geopera/apis/geopera-data-platform/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/geopera/geopera-data-platform/revisions/cb0130b2a40a/schema)
