Skip to main content

Quick Fixes Summary

Jump to the solution for common errors:

Error Response Format

All errors follow a consistent structure:

HTTP Status Codes


Authentication Errors

INVALID_API_KEY

Solution: Verify your API key is correct and active in Settings → API Keys. Related:

API_KEY_EXPIRED

Solution: Generate a new API key in your account settings. Related:

UNAUTHORIZED

Solution: Include Authorization: Bearer YOUR_API_KEY header in all requests. Example:
Related:

Session Errors

SESSION_NOT_FOUND

Causes:
  • Session was terminated
  • Session expired (5 min of inactivity)
  • Invalid sessionId
Solution: Create a new session with POST /start/start-session. Related:

SESSION_EXPIRED

Solution: Sessions expire after maxDuration. Create a new session for continuation. Best Practice:
Related:

SESSION_LIMIT_REACHED

Solution: Terminate unused sessions or upgrade your plan. Clean up sessions:
Related:

INSTANCE_UNAVAILABLE

Solution: Wait and retry, or contact support if persistent. Retry with backoff:

Task Execution Errors

TASK_NOT_FOUND

Solution: Verify taskId and sessionId are correct. Related:

TASK_ALREADY_RUNNING

Solution: Wait for current task to complete or stop it with newState: "stop". Stop running task:
Related:

TASK_TIMEOUT

Solution: Increase maxDuration or simplify the task. Adjust timeouts:
Related:

INVALID_TASK_DETAILS

Solution: Provide a valid task description. Good task examples:
Related:

Browser & Navigation Errors

Causes:
  • Slow website
  • Network issues
  • Website blocking automated access
Solution:
  • Retry the request
  • Check if website is accessible
  • Use startingUrl if navigating to a specific page
Example:
Related:

PAGE_CRASH

Solution: Retry the task. If persistent, report to support with session details. Related:

ELEMENT_NOT_FOUND

Causes:
  • Page structure changed
  • Element inside iframe
  • Element not yet loaded
Solution: Rephrase task description or wait for page load. Tips:
Related:

Rate Limiting & Network Errors

RATE_LIMIT_EXCEEDED

Solution: Wait before retrying. Implement exponential backoff. Rate Limits by Endpoint:
  • POST /start/start-session: 10 requests/minute per user
  • POST /start/send-message: 10 requests/minute per user
  • POST /start/run-task: 10 requests/minute per user
  • GET /task/:sessionId/:taskId: No rate limit
Note: Rate limits are per user (API key owner), not per API key. Exponential Backoff Implementation:
Related:

Billing & Payment Errors

INSUFFICIENT_BALANCE

Solution: Add credits to your account at webrun.ai/billing. Monitor balance:
  • Check your balance regularly in the dashboard
  • Set up low balance alerts
  • Consider auto-recharge options
Related:

PAYMENT_FAILED

Solution: Update payment method in Settings → Billing. Common causes:
  • Expired card
  • Insufficient funds
  • Card issuer declined
  • Invalid billing address

Validation Errors

INVALID_PARAMETER

Solution: Check parameter requirements in API documentation. Parameter Ranges:
  • maxDuration: 1,000 - 300,000 ms (max task duration, default 5 minutes)
  • maxInputTokens: 1,000 - 100,000 tokens
  • maxOutputTokens: 100 - 50,000 tokens
Related:

MISSING_REQUIRED_FIELD

Solution: Include all required fields in request body. Required fields by endpoint: POST /start/start-session:
  • prompt (string)
POST /start/send-message:
  • sessionId (string)
  • message (object)
POST /start/run-task:
  • sessionId (string)
  • prompt (string)
Related:

MCP-Specific Errors

MCP_SESSION_NOT_FOUND

Solution: Check your MCP session ID or reconnect to the SSE endpoint. Related:

MCP_METHOD_NOT_FOUND

Solution: Use valid MCP methods (tools/list, tools/call, etc.). Valid MCP methods:
  • tools/list
  • tools/call
  • resources/list
  • resources/read
Related:

MCP_INVALID_REQUEST

Solution: Ensure request follows JSON-RPC 2.0 format with jsonrpc: "2.0". Example:
Related:

Error Handling Best Practices

Complete Error Handling Example

Handling Guardrails

Related:

Debugging Checklist

When encountering issues:
  • Verify API key is valid and has correct permissions
  • Check account balance is sufficient
  • Confirm session/task IDs are correct
  • Review task instructions for clarity
  • Check network connectivity
  • Look for error codes in responses
  • Enable verbose logging
  • Test with simpler task first
  • Check system status page
  • Review usage limits for your plan

Getting Help

If you’re still experiencing issues:
  1. Documentation: Review relevant API docs
  2. Status Page: Check status.webrun.ai
  3. Support: Email support@webrun.ai with:
    • Error code and full error response
    • Session ID and task ID
    • Task description
    • Timestamp of occurrence
    • Steps to reproduce

Common Issues

Solutions for frequent problems

FAQs

Answers to common questions

Best Practices

Guidelines for optimal usage

API Reference

Complete endpoint documentation