---
title: "Add an alert to a Codeless test"
method: POST
path: "/v1/lab/{id}/alert"
tags: ["Codeless tests"]
---

# Add an alert to a Codeless test

`POST /v1/lab/{id}/alert`

Adds a notification channel (email, SMS, or callback URL) that fires when a scheduled run fails. Use PUT to modify an existing alert.

## Path parameters

- `id` integer, required

## Request body

- PostV1LabIdAlert — Add an alert to a Codeless test
  - `kind` 'EMAIL' | 'API' | 'SMS', required — Alert channel.
  - `level` 'IMMEDIATELY' | 'DAILY', required — When to send (every failure vs. daily digest).
  - `content` string, required — Destination — email address, callback URL, or phone number.

## Response `201`

Add an alert to a Codeless test

- TestingbotEntitiesAck — Testingbot_Entities_Ack model
  - `success` boolean, required — Whether the operation succeeded.
  - `errors` object, required — Validation errors keyed by field name. Only present when `success` is false.
  - `error` string, required — Single human-readable reason, used by the older endpoints in place of `errors`. Only present when `success` is false.

## Other responses

- `400` — Alert already exists — use PUT
- `401` — Authentication required
- `403` — Account is read-only
- `404` — Test not found

---

[API](https://skmtc.net/testingbot/apis/testingbot-rest-api.md) · [All operations](https://skmtc.net/testingbot/apis/testingbot-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/testingbot/testingbot-rest-api/versions/8f493cca8f92/schema)
