Get each run’s new results at your own address by webhook, check its signature, and read monitors with an API key or from an MCP client.
Goal: get what your monitors find into your own system, pushed to your address after each run or read with an API key whenever you want. Neither costs anything.
ACTION FOR THE HUMAN: open https://app.anysite.io/monitors (Open Monitors).
https:// address. Click Save changes. Every monitor type takes it,
People under post links included. Saving only the webhook charges nothing.id. Every post, change, person and item carries its id. The same item can come
again, by the webhook and by the API; keep the first one.To stop the calls, clear Webhook URL and save. Regenerate secret on Settings makes a new secret; the old one stops working at once, so update your receiver.
After each run that found something, one POST goes to your address, beside the results e-mail:
| Header | Value |
|---|---|
Content-Type |
application/json |
User-Agent |
Anysite-Webhook/1.0 |
X-Webhook-Signature |
sha256= and the hex HMAC-SHA256 of the raw body, keyed with the secret |
{
"monitor_id": "<monitor id>",
"runs": [
{
"id": "<run id>",
"status": "done",
"result_count": 2,
"person_count": 1,
"started_at": 1764000000,
"finished_at": 1764000300,
"posts": [],
"changes": [],
"people": [],
"items": []
}
],
"has_more": false,
"next_cursor": "<cursor>"
}
posts, changes, people and items hold the same items as the monitor’s tabs. items is a
Custom flow’s, as its Items tab shows them, and is empty on every other type: kind is item for
a new item or item_change for a watched field’s change, fields the fields you chose to show (each
with its step, path and value), and change, on an item_change, the field’s path, old and
new value and the threshold it crossed (null when the watch has none); null on a new item. A
Custom flow’s run:
{
"id": "<run id>",
"status": "done",
"result_count": 2,
"person_count": 0,
"started_at": 1764000000,
"finished_at": 1764000300,
"posts": [],
"changes": [],
"people": [],
"items": [
{
"id": "<item id>",
"kind": "item",
"item_url": "https://jp.mercari.com/item/m2",
"title": "Switch 2",
"fields": [
{ "step": 2, "path": "name", "value": "Switch 2" },
{ "step": 2, "path": "price", "value": 30002 }
],
"change": null,
"is_new": true,
"found_at": 1764000120
},
{
"id": "<item id>",
"kind": "item_change",
"item_url": "https://jp.mercari.com/item/m1",
"title": "Switch 1",
"fields": [
{ "step": 2, "path": "name", "value": "Switch 1" },
{ "step": 2, "path": "price", "value": 27500 }
],
"change": { "path": "price", "old": 30001, "new": 27500, "threshold": null },
"is_new": true,
"found_at": 1764000180
}
]
}
A call carries at most 100
items of its run; when has_more is true, read the rest from the news feed with
after=<next_cursor>. Times are Unix seconds. A redirect is not followed, and a call with no answer in
10 seconds counts as failed.
Check the signature over the bytes you received, never over re-encoded JSON:
import hashlib, hmac
def is_signed(secret: str, raw_body: bytes, header: str) -> bool:
expected = "sha256=" + hmac.new(secret.encode(), raw_body, hashlib.sha256).hexdigest()
return hmac.compare_digest(expected, header)
Send your API key in the access-token header, as for every Anysite API call. Results are kept for 30
days.
List your monitors with their ids:
curl https://api.anysite.io/monitors \
-H "access-token: YOUR_API_KEY"
ACTION FOR THE HUMAN: copy your API key at https://app.anysite.io/billing — an agent cannot obtain it.
Read a monitor’s news: its finished runs that found something, oldest first, each with its new posts, changes and people, or a Custom flow’s items.
curl "https://api.anysite.io/monitors/<monitor id>/news?limit=100" \
-H "access-token: YOUR_API_KEY"
ACTION FOR THE HUMAN: copy your API key at https://app.anysite.io/billing — an agent cannot obtain it.
The answer has the shape of the webhook body without monitor_id. Store next_cursor and pass it
back unchanged as after=<next_cursor> on the next read to get only what is new; without after the
feed starts from the oldest results kept. While has_more is true, read again at once. limit is 1
to 100, 100 by default.
https:// address of your receiver.401 with {"detail": "Token is empty"}: the call carried no access-token header, or it went to a
route a key cannot read. A key reads GET /monitors, GET /monitors/<monitor id>, its results
(posts, changes, people, companies, items), news and export; Run history, settings, pause, resume,
delete and the other routes answer only to the signed-in dashboard.403 with {"detail": "Monitors are not available for guest keys"}: guest keys cannot read monitors.404 with {"detail": "Monitor not found"}: the id is not one of your monitors; take it from
GET /monitors.422 with {"detail": "cursor_invalid"}: pass a next_cursor from an earlier answer unchanged, or
leave after out.