Monitors a page for changes: each call returns the page's text as snapshot (lines), a SHA-256 hash of it and a snapshot_id. Pass an earlier call's snapshot_id as since to get changed and a diff (lines added and removed, with counts), or an earlier hash to get changed only. mode=content (default) compares the main content (navigation, footers and ads dropped), text the whole visible text, html the markup without scripts and styles. ignore is a regular expression for lines to leave out (timestamps, counters). A snapshot can be compared as long as your plan keeps responses. Never served from cache.
Every response includes credits_used: the credits this call cost.
Parameters
name
type
description
urlrequired
string
Public http(s) URL of the page (a bare domain works too). Example: https://example.com
since
string
The snapshot_id (for a diff) or hash of an earlier call.
mode
content | text | html
What to compare. Default: content
ignore
string
Regular expression; matching lines are ignored.
country
string
Two-letter country to view the page from (default US).
import os, requests
res = requests.get(
"https://api.api.sh/web/v1/changes",
params={"url": "https://example.com"},
headers={"x-api-key": os.environ["APISH_KEY"]},
timeout=120,
)
res.raise_for_status()
data = res.json()
const url = new URL("https://api.api.sh/web/v1/changes");
url.searchParams.set("url", "https://example.com");
const res = await fetch(url, { headers: { "x-api-key": process.env.APISH_KEY } });
if (!res.ok) throw new Error(`${res.status} ${await res.text()}`);
const data = await res.json();
Response
A JSON object with the fields described above, plus raw (the source's own data), cached, fetched_at and credits_used. Errors return {"success": false, "error": "…"} with the HTTP status (see errors). A lookup that ran but found nothing (404) costs the price above; refused calls and errors on our side are free (what's charged).
The fastest way to see the full response is the playground: it runs this endpoint with your account and shows the exact JSON.