Console
Capture the JavaScript console output a page produces as it loads — errors, warnings and uncaught exceptions. Useful for monitoring third-party scripts, catching regressions and health-checking your own pages.
It uses no AI, and costs 1 credit per call. See Credits.
Capture console messages
Body parameters
- Name
url- Type
- string
- Required
- Required
- Description
- The absolute URL of the page to process. Rendered with headless Chrome, so JavaScript runs and redirects are followed. It must not include a username or password (
https://user:pass@example.com).
- Name
page_options- Type
- object
- Description
- Wait for the page, and remove ads, cookie banners or your own elements from it before it is read — gone from this result, not merely hidden. See Page options.
- Name
residential- Type
- boolean
- Description
- Fetch the page from a residential exit — an address on a home broadband line rather than one in a datacentre. Reach for it when a site serves you less than it serves a browser, or nothing at all. Defaults to
false. Adds 25 credits per page fetch on top of what the operation costs, and its results are kept separate from the ordinary ones.
- Name
report_to- Type
- string
- Description
- Webhook URL — an
httporhttpsaddress URLpipe POSTs the result to when it's ready. Optional: without it we deliver to your project's default endpoint if it has one, and otherwise send no webhook at all — the result still waits for you at GET /result/:token. A value we cannot deliver to returns422. Ignored on async=truerequest. Deliveries can be signed so your endpoint can verify they came from us.
- Name
sync- Type
- boolean
- Description
- Process the request synchronously, returning the result inline in the response. Defaults to
false(async: return a token now, and either receive the result at a webhook or fetch it with GET /result/:token). See Async & sync modes for the full contract.
- Name
max_age- Type
- string | integer
- Description
- How fresh a cached result must be to be accepted. Either an integer number of seconds (
3600) or a duration string of the form"<number> <unit>"— unitss/min/h/d/w(e.g."2 hours","3 days","30m"). Defaults to7 days, clamped to a max of30 days;0always bypasses the cache. See Caching for all accepted units.
- Name
labels- Type
- object
- Description
- Your own keys to find and account for this request by — a client, a project, a campaign:
{"client": "acme"}. Returned with the result, in the webhook and in theX-Labelsheader, and your dashboard filters history and totals credits by them. Up to 16 keys; string values. See Labels.
Response
Content type application/json — an array of message objects. An empty array [] means the page produced no errors or warnings.
Message fields
- Name
type- Type
- string
- Description
- One of
error,warningorexception.
- Name
text- Type
- string
- Description
- The message text.
curl -X POST https://urlpipe.dev/console \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"url": "https://example.com"}'import requests
res = requests.post(
"https://urlpipe.dev/console",
headers={"Authorization": "Bearer YOUR_API_KEY"},
json={"url": "https://example.com"},
)const res = await fetch("https://urlpipe.dev/console", {
method: "POST",
headers: {
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({ url: "https://example.com" }),
})$ch = curl_init("https://urlpipe.dev/console");
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOUR_API_KEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS => json_encode(["url" => "https://example.com"]),
]);
$response = curl_exec($ch);[
{
"type": "error",
"text": "Cart failed to load: TypeError: Failed to fetch"
},
{
"type": "warning",
"text": "[analytics] consent not given, events are queued"
},
{
"type": "exception",
"text": "ReferenceError: bar is not defined"
}
]Message types
- Name
error- Description
- From
console.error()calls.
- Name
warning- Description
- From
console.warn()calls.
- Name
exception- Description
- Uncaught JavaScript exceptions, and promise rejections nothing handled. Plain
console.log()output is not captured.
How it works
URLpipe loads the page in a headless browser, listens for console errors, warnings and uncaught exceptions, then waits briefly after the page's network activity settles so asynchronous scripts have time to run and report. All captured messages are returned together.
Messages come from the page itself. Scripts inside embedded frames — ads, widgets, third-party players — log to their own console, so what you get back is your page's output rather than everyone else's.
Responses
Whatever the status, the response carries metadata headers: the result token, whether it was served from cache and how old that result is, how long we took, what it cost in credits, and the allowance you have left.
200 OK422 Unprocessable Entity429 Too Many Requests504 Gateway Timeout401 UnauthorizedTry it live — no API key needed
Run this endpoint against any URL right in your browser.