Skip to Content
AnySolver logo
AnySolver
Other

CloudflareWaitingRoom

Get through a Cloudflare Waiting Room queue page through your proxy and receive the cookies for the protected site. With the schema, example and prices.

CloudflareWaitingRoom works through a Cloudflare Waiting Room queue page through your proxy and returns the cookies for the protected site. A Waiting Room holds visitors on a queue page when a site expects more traffic than it wants to serve at once, and admits them in turn.

If the page says "Just a moment..." instead of describing a queue, use CloudflareChallengeCookie.

It takes queue time

The wait is set by the site's queue, not by the solve. Size your own timeouts for it, and do not treat a long-running task as stuck. A new attempt starts a new position in line, so retrying quickly does not shorten the wait.

Parameters

All of these are required.

  • websiteURL is the URL of the protected page.
  • htmlPageBase64 is the queue page you are currently held on, base64-encoded. It carries the queue state the solve answers against, so capture it from the response you hold instead of reusing an older one.
  • websiteKey is the data-sitekey of the Turnstile widget rendered on the queue page.
  • userAgent is the User-Agent of the client you use afterwards.
  • proxy is the proxy for the solve: see Proxy.

To capture the page in a browser:

const html = new XMLSerializer().serializeToString(document);
const htmlPageBase64 = new TextEncoder().encode(html).toBase64();

If you fetch the page with an HTTP client, base64-encode the body of the response that returned the queue page.

Proxy

task.proxy is required on this task type, and the provider solves from that address. Keep using the same proxy and User-Agent for the requests you make after admission, and keep one IP for the whole solve: see Keep the same IP for the whole solve.

Use the cookies

Attach solution.cookies to your later requests together with the same User-Agent and proxy, as with CloudflareChallengeCookie. solution.token is present only when the queue page also issued a Turnstile token.

Check Provider stats for live success rates and solve times before you pick a provider.

Supported Providers

ProviderPrice per 1,000Routing
CapMonster
$1.30

Request Schema

FieldTypeRequiredDescription
clientKey*
stringYes

Your API key. Create one in a workspace of the AnySolver dashboard.

Example: your-api-key-from-dashboard

task*
objectYes

The task body. Required fields depend on the task type. See Tasks for per-task schemas.

View task properties
settings
objectNo

Per-request settings for routing, Auto Retry, Auto Fallback, proxy reuse, response statistics and detailed analytics. Each field overrides the API key's value. See Routing modes.

View settings reference

Task Object Properties

The task field accepts an object with the following properties:

FieldTypeRequiredDescription
type*
Yes
websiteURL*
URLYes

Full URL of the page where the CAPTCHA is displayed.

Example: https://example.com/

websiteKey*
stringYes

Sitekey of the Turnstile widget rendered on the waiting-room page.

Example: 0x4AAAAAAA…

proxy*
string | objectYes

Proxy the provider solves through, as a string or an object. See Proxy configuration.

View proxy configuration

Example: http://user:pass@1.2.3.4:8080

userAgent*
stringYes

User-Agent of the browser you use for the target site. Send your later requests to the site with the same value.

Example: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/144.0.0.0 Safari/537.36

htmlPageBase64*
stringYes

The waiting-room page you were served, base64-encoded. It carries the queue state the solve has to answer against, so capture it from the response you are holding rather than reusing an older one.

Example: PCFET0NUWVBFIGh0bWw+…

{
    "clientKey": "YOUR_API_KEY",
    "task": {
        "type": "CloudflareWaitingRoom",
        "websiteURL": "https://example.com/",
        "websiteKey": "0x4AAAAAAA…",
        "proxy": "http://user:pass@1.2.3.4:8080",
        "userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/144.0.0.0 Safari/537.36",
        "htmlPageBase64": "PCFET0NUWVBFIGh0bWw+…"
    }
}

Optional fields are not guaranteed across providers

Required fields are guaranteed across every provider that supports this task. Optional fields may be honored by some providers and silently ignored by others. AnySolver does not document per-provider parameter support, so before relying on an optional field, check that provider's own docs for the task you are using.

Response Schema

FieldTypeRequiredDescription
status*
Yes

Task status: "processing", "ready", or "failed".

Example: ready

errorId*
Yes

0 on success; 1 or 2 on an error. Branch on errorCode: Error IDs explains the two error groups.

Example: 0

taskId
stringNo

Unique identifier returned when the task was created.

Example: 01KFNDF328KAN2AJ3BNHCQYE88

errorCode
No

Machine-readable error code.

Example: CAPTCHA_UNSOLVABLE

errorDescription
stringNo

Human-readable error message with resolution hints.

Example: The captcha could not be solved.

cost
numberNo

Actual cost charged for this task in USD.

Example: 0.002

taskType
No

The type of CAPTCHA task to solve.

Example: ReCaptchaV2TokenProxyLess

provider
No

Provider that handled this task. While processing, the provider currently solving it.

Example: Multibot

solution
objectNo

Solution Object Properties

The solution field contains an object with the following properties:

FieldTypeRequiredDescription
cookies*
Record<string, unknown>Yes

Session cookies granted by the solve, including cf_clearance. Replay them with the same proxy and the returned User-Agent.

Example: {"cf_clearance":"Bcg6jNLzTVaa3IsFhtDI.e4_LX8p7q7zFYHF7wiHPo...uya1bbdfwBEi3tNNQpc"}

raw*
Record<string, unknown>Yes

Raw provider response data for advanced use cases.

token
stringNo

Turnstile token, when the queue page issued one. Admission itself rides on the cookies.

Example: 0.zrSnRHO7h0HwSjSCU8oyzbjEtD8p.d62306d4ee00c77dda697f959ebbd7bd97

userAgent
stringNo

User-Agent string used during solving.

Example: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/144.0.0.0 Safari/537.36