Solve reCAPTCHA V2 challenges and receive a verification token.
reCAPTCHA V2 is one of the most common CAPTCHA systems. It typically presents as a checkbox labeled "I'm not a robot" and may require users to complete image selection challenges (e.g., "select all squares with traffic lights").
Successful completion returns a gRecaptchaResponse token which you submit with your target form.
This variant uses your proxy. If you do not need proxy control or want the provider to use their own IPs, use ReCaptchaV2TokenProxyLess.
Set isInvisible to true when the reCAPTCHA appears without a visible checkbox. The challenge triggers
automatically on a user action like a button click.
The enterprisePayload (e.g. the short-lived s token) and isSession parameters are not supported by all
providers. Test with your target site to verify compatibility.
Per-request settings for routing, auto retry, auto fallback, and proxy behavior. See Routing Strategies.
provider
No
Specific provider to use. If omitted, automatic routing selects the best provider.
Example:CapSolver
selectionMode
No
Routing strategy for this request. Overrides the API key default. See Routing Strategies.
Example:autoCheapest
keyPoolMode
No
Which provider key pool to use: all (default, uses AnySolver-managed keys and your own) or platformOnly (AnySolver-managed keys only). See Key Pool Mode.
Example:all
Task Object Properties
The task field accepts an object with the following properties:
Field
Type
Required
Description
type*
Yes
websiteURL*
URL
Yes
Full URL of the page where the CAPTCHA is displayed.
Set to true when the widget is invisible, for example when the iframe URL contains size=invisible or the challenge starts after a button click without showing a checkbox first.
Example:false
userAgent
string
No
Browser User-Agent string. Must match the browser used on the target page. Not all providers properly support this parameter. Verify the compatibility with the provider you are using.
Example:Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/144.0.0.0 Safari/537.36
cookies
string
No
Cookies from the target page session, if required for solving.
Example:NID=511=example; 1P_JAR=2026-03-01-12;
pageAction
string
No
Action passed to grecaptcha.execute() or grecaptcha.enterprise.execute(), such as verify or submit. This is mainly relevant on enterprise flows and should match the page JavaScript exactly.
Example:verify
apiDomain
string
No
Domain used to load reCAPTCHA. Use google.com for standard widgets or recaptcha.net when the page loads the API from recaptcha.net or www.recaptcha.net.
Example:www.recaptcha.net
isSession
boolean
No
Enable session mode to receive worker session cookies together with the token. Only supported by providers that expose session-cookie responses.
Example:false
enterprisePayload
Record<string, unknown>
No
Additional values passed to grecaptcha.render() or grecaptcha.enterprise.render(), such as the s token ({ "s": "..." }). The s value is the data-s parameter used on some Google-owned pages and other protected flows; it is short-lived and should be extracted fresh for every solve attempt.
Example:{"s":"data-s_example_value"}
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.