Create and use your solvethree API key
Create your key in the workspace you’ll use for solving. Keep the full secret on your server; a displayed key prefix isn’t enough to authenticate.
On this page
Create and save your key
- 1.
Open API keys
In the console, open API keys at
/api-keysin the intended workspace. - 2.
Name the key
Select Create API key. Enter a name in Key name that helps you recognize where you’ll use it, then select Create key.
- 3.
Copy the full secret
Under Save your API key, copy the secret and store it securely for your server application. It’s shown only once.
- 4.
Close the dialog
Select I saved this key only after you’ve stored the secret.
Send the key from your server
Authenticate requests with Authorization: Bearer followed by the full workspace key. Keep it out of browser-side code.
For the example below, set SOLVETHREE_API_KEY to your secret and SOLVETHREE_PROXY to your proxy URL in the server environment. Replace accounts.example.com and login with your target hostname and action. The target site must already have an active profile available to this workspace; sending its hostname doesn’t create one. See site profile setup if you haven’t configured it.
# Set SOLVETHREE_API_KEY and SOLVETHREE_PROXY in your environment first.
# Replace the hostname and action with your active site profile.
jq -n \
--arg proxy "$SOLVETHREE_PROXY" \
--arg requestId "login-$(date +%s)-$$" \
'{site:"accounts.example.com", action:"login", proxy:$proxy, requestId:$requestId}' \
| curl --fail-with-body --max-time 30 \
'https://api.solvethree.com/v1/tasks?waitMs=15000' \
-H "Authorization: Bearer $SOLVETHREE_API_KEY" \
-H 'Content-Type: application/json' \
--data-binary @-This sends a task-creation request to the public API. It creates a real solve, not just an authentication check: a ready task is billed. A successful HTTP response alone doesn’t mean the task is ready or that the target website will accept its solution.
Separate authentication errors from task errors
- The API returns HTTP 401.
Check the server’s Authorization header. It needs Bearer followed by the full secret, not the key name or a revealed prefix. Check whether the key has been revoked.
Try this: Correct the header or replace the revoked key and update your server configuration. Handle the non-success HTTP response before trying to read a task payload.
- The key authenticates, but the intended site profile isn’t available.
Confirm which workspace owns the key and whether that workspace has an active profile for the target site. A valid key from another workspace isn’t a global credential.
Try this: Use a key belonging to the workspace with the intended profile, or set up the profile in the workspace you’re using. Changing the hostname in the request won’t create it.
For other request and task failures, see CAPTCHA API errors.
Sources and API reference
Run your first task.
Start with $5 in workspace credit.