Documentation

The public Fetch API, in two minutes.

A small, predictable interface for retrieving publicly accessible web content with the access mode that fits the page.

Quick Start

Use the API base URL configured for your environment. Keep the API key on your server and send it as a Bearer token.

curl

curl -X POST https://web-bypass.dev/v1/fetch \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url":"https://example.com","mode":"auto"}'

Python

import json
import urllib.request

request = urllib.request.Request(
    "https://web-bypass.dev/v1/fetch",
    data=json.dumps({"url": "https://example.com", "mode": "auto"}).encode(),
    headers={
        "Authorization": "Bearer YOUR_API_KEY",
        "Content-Type": "application/json",
    },
    method="POST",
)

with urllib.request.urlopen(request) as response:
    print(response.read().decode())

JavaScript

const response = await fetch("https://web-bypass.dev/v1/fetch", {
  method: "POST",
  headers: {
    Authorization: "Bearer YOUR_API_KEY",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({ url: "https://example.com", mode: "auto" }),
});

console.log(await response.json());

Authentication

Authenticate requests to /v1/fetch with:

Authorization: Bearer YOUR_API_KEY

API keys are issued by the current account-access workflow. Never embed one in browser code, public repositories, or client-side examples.

Fetch API

Send a JSON request to POST /v1/fetch. The request body is strict and accepts only the fields below:

{
  "url": "https://example.com",
  "mode": "auto"
}
  • url is a public HTTP or HTTPS URL.
  • mode is optional and defaults to auto.
  • Accepted modes are auto, easy, and hard.

Auto Mode

Auto is the recommended mode. Easy is attempted first. Hard is used only when the result requires escalation. The successful mode determines the charge; a final failed request is free.

Easy Mode

Easy is a fast, lightweight path for pages that do not require full browser execution. It is the lowest-cost mode, but it is not promised to work for every page.

Hard Mode

Hard is intended for JavaScript-heavy and difficult public pages that need a fuller browser path. Use it when you already know the page requires it; the service does not promise universal success.

Billing

Usage pricing applies to successful requests:

  • Successful Easy requests use the Easy rate.
  • Successful Hard requests use the Hard rate.
  • Auto with Easy success uses the Easy rate.
  • Auto with Easy failure and Hard success uses the Hard rate only.
  • A final failure costs $0.

There is no monthly commitment. The intended balance top-up currency is USDT, with a minimum top-up of $5. Public recharge availability is not represented as active by this pre-release documentation.

Response

A successful response contains the requested URL, the final URL, HTTP metadata, normalized content, access-attempt metadata, and billing metadata:

{
  "success": true,
  "request_id": "req_...",
  "url": "https://example.com",
  "final_url": "https://example.com/",
  "status_code": 200,
  "content_type": "text/html",
  "content_encoding": "utf8",
  "content": "...",
  "access": {
    "requested_mode": "auto",
    "used_mode": "easy",
    "easy_attempted": true,
    "hard_attempted": false
  },
  "billing": {
    "charged": true,
    "charge_usd": "0.000100",
    "balance_remaining_usd": "4.999900"
  }
}

content_encoding is utf8 for valid text and base64 when binary or non-text content cannot safely be represented as text.

Errors

Failures use a stable error code and a zero-charge billing object. The public error family is:

CodeMeaning
INVALID_REQUESTThe request is invalid.
INVALID_API_KEYThe API key is invalid.
INSUFFICIENT_BALANCEInsufficient balance.
INSUFFICIENT_BALANCE_FOR_HARDInsufficient balance for Hard mode.
INVALID_URLThe URL is invalid.
TARGET_NOT_ALLOWEDThe target URL is not allowed.
TARGET_NOT_FOUNDThe target could not be found.
RATE_LIMITEDToo many concurrent requests.
FETCH_FAILEDThe page could not be retrieved.
FETCH_TIMEOUTThe page retrieval timed out.
INTERNAL_ERRORAn internal error occurred.

Rate Limits

Concurrency is limited per API key. The current default maximum is 10 concurrent requests per key. The MVP does not claim a requests-per-minute quota.

Security

  • Use HTTPS in deployment and keep API keys server-side.
  • Target URLs must be public HTTP or HTTPS resources.
  • Local, private, internal, and metadata-network targets are rejected.
  • Rotate credentials if you believe a key has been compromised.