---
title: "Create a coordination alert rule"
method: POST
path: "/kol/coordination/alerts"
tags: ["KOL"]
---

# Create a coordination alert rule

`POST /kol/coordination/alerts`

## Request

- Base URL: `https://madeonsol.com/api/v1`
- URL: `https://madeonsol.com/api/v1/kol/coordination/alerts`
- Auth: HTTP bearer

Rule fires via pg_notify push when a token hits `min_kols` distinct KOL buys inside a rolling `window_minutes` window AND scores >= `min_score`. Cooldown per (rule, token); re-fires early if score jumps >= `score_jump_break`. Delivery: `websocket` (on the `kol:coordination` WS channel), `webhook` (per-rule HMAC), or `both`.

## Request body

- object
  - `name` string
  - `min_kols` integer
  - `window_minutes` integer
  - `min_score` integer
  - `include_majors` boolean
  - `cooldown_min` integer
  - `score_jump_break` integer: Re-fire during cooldown when new score ≥ last_score + this
  - `delivery_mode` 'websocket' | 'webhook' | 'both'
  - `webhook_url` string, uri: Required if delivery_mode includes webhook. HTTPS only.
  - `min_mc_usd` number, nullable: v1.6: lower bound on entry MC (MC at the triggering trade). Triggers on tokens with unknown MC drop out when set.
  - `max_mc_usd` number, nullable: v1.6: upper bound on entry MC.

## Response `200`

Rule created. Response includes `webhook_secret` (one-time) if a webhook URL was supplied.

- object
  - `rule` CoordinationAlertRule: A saved /kol/coordination/alerts rule. `created_at` is present on list/GET-one responses; `updated_at` is present on GET-one/PATCH responses (list omits it).
    - `id` string, uuid
    - `name` string, nullable
    - `min_kols` integer
    - `window_minutes` integer
    - `min_score` integer
    - `include_majors` boolean
    - `cooldown_min` integer
    - `score_jump_break` integer
    - `delivery_mode` 'websocket' | 'webhook' | 'both'
    - `webhook_url` string, uri, nullable
    - `min_mc_usd` number, nullable
    - `max_mc_usd` number, nullable
    - `is_active` boolean
    - `created_at` string, date-time
    - `updated_at` string, date-time
  - `webhook_secret` string, nullable: One-time reveal — only present when a webhook_url was supplied. Use to verify HMAC-SHA256 signatures (X-MadeOnSol-Signature).
  - `note` string, nullable

## Other responses

- `401`: Missing or invalid API key, or an expired free-tier key. Authentication-stage error: no `X-RateLimit-*` headers, no `_rid`.
- `403`: Pro/Ultra required
- `409`: Rule quota reached
- `429`: Too many requests. Every 429 carries `Retry-After`. A quota 429 (`rate_limit_exceeded`, with `X-RateLimit-*`), a heavy-query concurrency 429 (`error_kind` `concurrency`/`capacity`), or the per-IP authentication-failure block (30 failed auths/min; plain `error` + `retry_after_seconds`, no `X-RateLimit-*`).
- `500`: Unexpected server error from the route (`Internal server error`, with `_rid`). Safe to retry with backoff. A failed API-key lookup is a 503 `auth_backend_unavailable`, never a 500.
- `503`: The API-key or subscription lookup could not be answered (authentication stage). Retryable and not your fault: it is never counted as a failed authentication. Honour `Retry-After`; no `X-RateLimit-*`, no `_rid`.

---

[API](https://skmtc.dev/madeonsol/apis/madeonsol-api.md) · [All operations](https://skmtc.dev/madeonsol/apis/madeonsol-api/llms.txt) · [OpenAPI document](https://skmtc.dev/madeonsol/apis/madeonsol-api/revisions/96ce84657f55?raw)
