Skip to Content
AnySolver logo
AnySolver
Token

AWSWafToken

Solve an AWS WAF challenge or CAPTCHA through your own proxy and get the aws-waf-token cookie. Shows the request schema, an example and provider prices.

AWSWafToken solves an AWS WAF challenge or CAPTCHA through your proxy and returns the aws-waf-token cookie value. It is the same task as AWSWafTokenProxyLess: the parameters, where to find them and how to use the cookie are identical, so start from that page.

Use it when the site ties the cookie to the address that earned it. On this task type, RiskBypass also needs awsChallengeJS and fails with INVALID_TASK_DATA without it, so send it whenever the page loads challenge.js.

Proxy

task.proxy is required on this task type, and the provider solves from that address. Send the proxy you will use for the request that submits the cookie, and keep one IP for the whole solve: see Keep the same IP for the whole solve.

If the site still rejects the cookie, check that the proxy kept one IP and that the parameters come from a fresh load of the page that returns the challenge.

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

Supported Providers

ProviderPrice per 1,000Routing
CapSolver
$2.00
CapMonster
$1.40
RiskBypass
$1.00
Solverify
$0.50
DraxonSolver
$0.80
VoidCaptcha
$1.45

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 that returns the AWS WAF challenge or captcha.

Example: https://efw47fpad9.execute-api.us-east-1.amazonaws.com/latest

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

awsKey
stringNo

The key value from window.gokuProps on the challenge page. Fetch key, iv and context fresh for every task.

Example: AQIDAHjcYu/GjX+QlghicBg......shMIKvZswZemrVVqA==

awsIv
stringNo

The iv value from window.gokuProps on the challenge page.

Example: CgAAFDIlckAAAAid

awsContext
stringNo

The context value from window.gokuProps on the challenge page.

Example: 7DhQfG5CmoY90ZdxdHCi8WtJ3z......njNKULdcUUVEtxTk=

awsChallengeJS
URLNo

URL of the challenge.js script loaded by the page (the src of the awsThreatDetection script). Several providers require it; send it whenever the page loads one.

Example: https://41bcdd4fb3cb.610cd090.us-east-1.token.awswaf.com/41bcdd4fb3cb/0d21de737ccb/cd77baa6c832/challenge.js

awsApiJs
URLNo

URL of the jsapi.js captcha SDK script, for pages that load jsapi.js instead of exposing challenge.js.

Example: https://9175c2fd4189.edge.captcha-sdk.awswaf.com/9175c2fd4189/jsapi.js

awsProblemUrl
URLNo

URL of the captcha problem endpoint, containing problem and num_solutions_required, for pages that only load captcha.js. Only some providers use it.

Example: https://ait.2608283a.us-east-1.captcha.awswaf.com/ait/ait/ait/problem?kind=visual&domain=www.amazon.com&locale=en-us&problem=gridcaptcha-5-0.15-0&num_solutions_required=2

awsApiKey
stringNo

The api_key of the problem endpoint, used for secondary verification together with awsExistingToken. Only some providers use it.

Example: Sps+L2gV...

awsExistingToken
stringNo

The aws-waf-token from the previous verification, for secondary verification. Only some providers use it.

Example: 5na16dg6-216a-...

platform
No

AWS WAF SDK flow to run: web for browser pages, android or ios for mobile apps. Defaults to web. Not every provider supports this; those that do not ignore it.

Example: web

{
    "clientKey": "YOUR_API_KEY",
    "task": {
        "type": "AWSWafToken",
        "websiteURL": "https://efw47fpad9.execute-api.us-east-1.amazonaws.com/latest",
        "proxy": "http://user:pass@1.2.3.4:8080"
    }
}

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
aws-waf-token*
stringYes

The aws-waf-token cookie value. Set it as the aws-waf-token cookie on requests to the protected site.

Example: 223d1f60-0e9f-4238-ac0a-e766b15a778e:EQoAf0APpGIKAAAA:AJam3OWpff1VgKIJxH4lGMMHxPVQ0q0R3CNtgcMbR4VvnIBSpgt1Otbax4kuqrgkEp0nFKanO5oPtwt9+Butf7lt0JNe4rZQwZ5IrEnkXvyeZQPaCFshHOISAFLTX7AWHldEXFlZEg7DjIc=

raw*
Record<string, unknown>Yes

Raw provider response data for advanced use cases.

captchaVoucher
stringNo

Captcha voucher returned by providers that solve the visual captcha step instead of issuing a cookie.

Example: eyJ0eXAiO...oQjTnJlBvAW4

userAgent
stringNo

User-Agent string used during solving.