Skip to main content

HTTP Status Codes

All Anysite API endpoints return standard HTTP status codes. Below is the complete list of error codes you may encounter.
CodeDescriptionAction
400Invalid input format (e.g., malformed LinkedIn URN, missing required field)Check your request body and parameter formats
401Missing or invalid access-token headerVerify your API key at app.anysite.io
403No access to the requested resource or accountCheck your subscription plan and permissions
404Requested entity not found (account, email, job listing, etc.)Verify the URL, username, or ID you’re querying
408Request execution timeout exceededIncrease the timeout parameter or simplify your query
412Entity unavailable at source (deleted, blocked, or URL not responding)The target profile/page may have been removed or restricted
422Validation error — request body doesn’t match expected schemaCheck required fields and parameter types
429Rate limit exceededWait and retry, or reduce request frequency
500Internal server error or data source unavailableRetry after a short delay; contact support if persistent

Error Response Format

All error responses return a JSON body:
{
  "detail": "Error description message"
}
For validation errors (422), the response includes field-level details:
{
  "detail": [
    {
      "loc": ["body", "user"],
      "msg": "field required",
      "type": "value_error.missing"
    }
  ]
}

Common Scenarios

400 — Bad Request

// Invalid LinkedIn URN format
{"detail": "Invalid URN format. Expected: 'urn:li:fsd_profile:ABC123'"}

404 — Not Found

// User profile doesn't exist
{"detail": "LinkedIn user not found"}

408 — Timeout

Increase the timeout parameter in your request body (default: 300 seconds, max: 1500):
{
  "user": "linkedin.com/in/username",
  "timeout": 600
}

412 — Precondition Failed

The target entity exists but is not accessible:
  • LinkedIn profile is private or deactivated
  • Instagram account is restricted
  • Web page returns an error

429 — Rate Limit

Check your current usage with the token management endpoints:
curl -H "access-token: YOUR_API_KEY" https://api.anysite.io/token/statistic