Alerts
Alerts wrap an existing Ultralayer endpoint, poll it on a schedule, skip what was already delivered, and push new matches to email, Telegram, and/or a webhook. Same filters and queries as the underlying endpoint — plus schedule and delivery. Alerts are billed as the underlying endpoint calls — there is no alert surcharge.
| Operation | Role |
|---|---|
create_alert | Validate endpoint + receivers (delivers a sample), then persist |
get_alerts | List alerts with recent attempts and deliveries |
activate_alert / deactivate_alert | active ↔ paused |
execute_alert | Run now (same path as scheduled execution) |
delete_alert | Permanent delete |
When to use
Use alerts when you need:
- Continuous monitoring of Wire, semantic search, developments, or events
- Delivery to inbox, Telegram, or a webhook without running your own cron
- The same conditions you already validated interactively, left running
Do not use alerts when you need:
- A one-shot answer → call the underlying endpoint directly
- To alert on endpoints that are not in the alertable set below
Use cases
Company wire monitor — Get emailed when a company prints material news with strong positive or negative tone, skipping copycat syndication.
Code
Exact canonical names (see Wire). Sentiment min/max together = strong positive or strong negative. Novelty drops syndication duplicates.
Semantic Monitoring — Watch a theme by meaning (not just a ticker) and push new matching passages to email and a webhook.
Code
Ticker development feed — Get pinged when important new developments land for a ticker, with who is affected already scored.
Code
Tracked event lifecycle — Follow one known story (earnings cycle, M&A, etc.) and get notified as new developments attach to it.
Code
Discover event_id via search_events or a development hit first.
Events scan (M&A) — Stay on top of new deal activity without polling for mergers yourself.
Code
Alertable endpoints
path | What you’re monitoring |
|---|---|
/v0/search/list_wire | Filtered headlines |
/v0/search/semantic_search | Passages by meaning |
/v0/search/search_developments | Structured developments |
/v0/search/search_events | Events with recent activity |
/v0/search/retrieve_event_developments | Developments on a known event_id |
Wire for company/news. Developments/events for structured lifecycle. Semantic search for thematic language.
Create params
| Field | Notes |
|---|---|
name | Optional; unique per user. Duplicate → 400. |
path | One of the alertable paths above |
arguments | Upstream body minus timestamps. Never include start_timestamp / end_timestamp (422). |
interval_minutes | ≥ 5 and a multiple of 5 |
lookback_minutes | Rolling window; defaults to interval_minutes |
threshold | Min matching items before delivery (default 1) |
receivers | 1–2 targets; duplicate targets rejected |
Receivers
| Type | Config |
|---|---|
email | { "type": "email" } — delivers to the verified account email |
telegram | { "type": "telegram", "chat_id": "…" } — start the Ultralayer alerts bot first |
webhook | { "type": "webhook", "url": "…", "headers"? } — public http(s) only |
Envelope: { "name": "<alert name>", "response": <exact upstream JSON> }. Subject: ULTRALAYER ALERT: {name}.
create_alert immediately calls the endpoint and delivers a sample to every receiver before persisting.
Delivery behavior
Each run checks a rolling lookback window and never re-sends data already delivered. The alert fires only when at least threshold new items match. Attempt outcomes (delivered, no_data, below_threshold, endpoint_error, delivery_partial, delivery_failed) and recent deliveries are visible via get_alerts. If all receivers fail, the same data is retried next run.
There is no update-alert endpoint. Changing filters = delete + recreate.
Workflow
- Prototype filters with the underlying endpoint until results look right.
create_alertwith those arguments (no timestamps) + receivers + interval. Expect a sample delivery.get_alertsto confirm status and early attempts.execute_alertto force a test run.deactivate_alert/activate_alertto pause/resume.delete_alertwhen done. Prefer pause over delete if the config may be reused.
Limitations
- Poll-based (minimum 5-minute cadence), not push-on-insert.
- Only the alertable paths listed above.
- Max 2 receivers; email is account-bound.
- Webhooks must be public.
- Create always sends a sample — warn before creating noisy webhooks.
- No patch API for existing alerts.
FAQ
Q: Is this more expensive than calling the API myself on a cron?
A: Same underlying pricing; you gain dedupe, thresholding, multi-channel delivery, history, and managed scheduling.
Q: Why can’t I set start_timestamp in arguments?
A: The alert owns the rolling window. Including timestamps → 422.
Q: Why did create email me immediately?
A: Receiver verification delivers a real sample by design.
Q: no_data every 15 minutes — broken?
A: Healthy. The window had zero matches. Check deliveries for real fires.
Q: How do I change an alert’s filters?
A: There is no patch. Pause or delete + recreate.