Skip to main content

Overview

Every solve request follows a predictable lifecycle. Understanding this flow helps you build robust integrations and handle edge cases.

Task Flow

1

Task Creation

You send a POST /createTask request. The server validates your API key, task parameters, proxy format, and checks your balance or package quota. If everything is valid, a task ID (UUID) is returned and the task is queued for processing.
2

Validation

The server performs deep validation:
  • API key and account status
  • Task type must be FunCaptchaTask
  • Public key must be a valid UUID
  • Proxy format and port validation
  • Thread limit check
3

Session Initialization

A session is created through your proxy. The system detects the proxy’s geolocation to set the correct timezone and language, then generates the initial Arkose token.
4

Silent Pass Check

If the Arkose token contains sup=1, no challenge is required — the token is returned immediately. This is the fastest path.
5

Challenge Solving

If a challenge is required, the system parses the challenge type, variant, and number of waves, then solves each wave until completion or timeout.
6

Result Available

Once solved, the result is stored with a 120-second TTL. Poll GET /getTaskResult/{taskId} to retrieve it.

Task Statuses

StatusDescription
createdTask accepted and queued
processingTask is being solved
readyTask completed (check errorId for success/failure)
failureTask failed with an error

Timeouts

PhaseTimeout
Total task300 seconds
Solve phase120 seconds
Result TTL120 seconds after completion
Results expire 120 seconds after completion. Make sure to poll frequently enough to retrieve your token before it expires.

Balance & Refunds

For balance-based users (FUN- keys):
  • Balance is deducted when the task starts processing
  • If the task fails for any reason (proxy error, timeout, unsolvable), the balance is automatically refunded

Polling Best Practices

Poll every 0.5 seconds for optimal results. Polling too slowly risks missing the result TTL.
import time
import requests

def solve_captcha(client_key, task_params):
    # Create task
    resp = requests.post("https://api.funbypass.com/createTask", json={
        "clientKey": client_key,
        "task": task_params
    })
    task_id = resp.json()["taskId"]

    # Poll with 0.5s interval
    for _ in range(600):  # max ~5 minutes
        result = requests.get(f"https://api.funbypass.com/getTaskResult/{task_id}").json()

        if result["status"] == "ready":
            if result["errorId"] == 0:
                return result["solution"]["token"]
            else:
                raise Exception(result["errorCode"])

        time.sleep(0.5)

    raise TimeoutError("Task did not complete in time")