Skip to main content
Every API call needs an API key in the X-API-Key header.
curl https://api.webscrape.ai/v1/scrape \
  -H "X-API-Key: wsg_live_..." \
  -H "Content-Type: application/json" \
  -d '{"website_url": "https://example.com"}'

Key format

Keys look like wsg_live_<32 base62 chars>. The wsg_live_ prefix marks them as production keys. The full secret is shown once at generation time — after that, we don’t have it either. Lost a key? Generate a new one and revoke the old. There’s no recovery flow.

Generating a key

1

Open the dashboard

Go to API Keys.
2

Click Generate

Label the key so you can tell which integration it belongs to later.
3

Copy the secret immediately

The cleartext appears once. Put it in a secrets manager — never in source control.

Revoking a key

Click Revoke on the row in the dashboard. It takes effect immediately — the next request with that key gets a 401 Unauthorized.

Rotation

There’s no automated rotation yet. To rotate by hand:
  1. Generate a new key.
  2. Deploy it to your application.
  3. Confirm requests succeed under the new key (the Usage page is the easy check).
  4. Revoke the old key.

Errors

StatusMeaning
401 UnauthorizedMissing or revoked key
402 Payment RequiredOut of credits. See Credits
See Errors for the full response shape.