DOESCAP DOCS
MODULE 6 / 6 • CLI & DIAGNOSTICS

CLI & DIAGNOSTICS

Run DoesCap straight from your terminal, run the offline pytest suite, and review production operational notes.

COMMAND LINE USAGE

Installed as the doescap CLI command:

# Basic execution
doescap --sitekey "10000000-ffff-ffff-ffff-000000000001"

# Full flags reference
doescap --sitekey "..." \
  --rqdata "OPTIONAL_RQDATA" \
  --captcha-host "discord.com" \
  --host "0.0.0.0" \
  --port 8989 \
  --timeout 180 \
  --title "DoesCap CLI" \
  --browser "chrome" \
  --custom-html "./my_ui.html" \
  --assets-dir "./assets" \
  --no-browser

AUTOMATED & SANDBOX TESTING

Run the offline test suite in tests/test_doescap.py (covers SolveResult, RelayConfig, Termux detection, HTTP endpoints, SSR placeholders, asset traversal guards, and async_solve):

# Run offline unit & integration tests
pytest -v

# Manual interactive test with hCaptcha's public test sitekey
doescap --sitekey "10000000-ffff-ffff-ffff-000000000001" --port 8787

PRODUCTION NOTES

  • No authentication — treat relay endpoints as local-only bearer services.
  • Direct mode operates at native monitor/display refresh rates (60Hz – 144Hz) with 0ms synthetic input lag.
  • Network pairing: phones on the same Wi-Fi can open relay.relay_url to solve challenges for headless hosts. On Windows, allow_firewall_rule=True attempts to allow the active port through Windows Defender Firewall.
  • Deferred shutdown & live post-solve updates: calling mark_claimed() keeps the HTTP server alive for 25s (and mark_failed() for 10s) and updates the open browser success screen with CLAIMED, task_name, and copyable promo_code even after solve() has already returned.