# Choosing the Right Endpoint

> URL: https://foura.ai/docs/guides/choosing-task-type
> Updated: 2026-11-05
> Index: https://foura.ai/llms.txt

FourA offers four request endpoints, each optimized for a different scenario. Choosing the right one saves time, reduces cost, and improves success rates.

## Quick Decision Guide

**Use the auto endpoint when:**
- You're targeting a new site and you don't yet know what it needs
- You want one call that handles proxy-rotated and browser fallbacks for you
- You want a session you can replay cheaply on the next call to the same host

**Use the single endpoint when:**
- The page is server-rendered (no JavaScript required)
- You need maximum speed (typically under 1 second)
- You're hitting APIs or static HTML pages from a host you already know works

**Use the browser endpoint when:**
- The page relies on JavaScript to render content
- Content loads after the initial page load
- You need the fully rendered DOM

**Use the proxy endpoint when:**
- The target site actively blocks requests
- You need to rotate through multiple IP addresses
- Previous attempts returned 403 or verification pages

## Endpoint Comparison

### Auto (`POST /api/auto/`)

The smart-fetch endpoint. You pass a URL and (ideally) a `validate` rule, and FourA walks a cost-aware ladder: a rotated proxy first, then a full browser through a proxy. Set `forceProxy: false` and a cheap direct probe and a direct browser render run before both. The first rung that returns a response matching your `validate` wins. On repeat calls to the same host, a warm session is replayed, so the second call is cheap.

```bash
curl -X POST https://eu.api.foura.ai/api/auto/ \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://example.com/product/42",
    "validate": {"data": {"accept": ["Add to cart"]}}
  }'
```

**Typical response time:** 200ms (warm) to 30s+ (cold solve on a hard site)
**Best for:** New targets, mixed-protection sites, "I just want the page"

For a deeper walkthrough, see the [Smart Fetch guide](https://foura.ai/docs/guides/smart-fetch).

### Single (`POST /api/single/`)

The fastest option. Sends an HTTP request with realistic browser-like wire characteristics, without spinning up a browser process.

```bash
curl -X POST https://eu.api.foura.ai/api/single/ \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"method": "GET", "url": "https://example.com/api/products"}'
```

**Typical response time:** 200ms to 2s
**Best for:** APIs, news sites, blogs, static product pages

### Browser (`POST /api/browser/`)

Opens your URL in a Chrome browser instance. The page loads completely, JavaScript executes, and you get the final rendered HTML.

```bash
curl -X POST https://eu.api.foura.ai/api/browser/ \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://example.com/spa-app",
    "timeout_ms": 15000,
    "checkText": "data-table"
  }'
```

**Typical response time:** 2s to 10s
**Best for:** Single-page apps (SPAs), sites with lazy loading, JavaScript-rendered content

### Proxy (`POST /api/proxy/`)

Combines HTTP requests with automatic proxy rotation. If the first attempt fails or gets blocked, FourA retries through different proxies.

```bash
curl -X POST https://eu.api.foura.ai/api/proxy/ \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "maxTries": 5,
    "request": {
      "method": "GET",
      "url": "https://example.com/pricing"
    }
  }'
```

**Typical response time:** 1s to 5s
**Best for:** E-commerce price monitoring, travel aggregation, sites with bot detection

## Auto vs Manual

When should you let auto pick, and when should you call Single, Proxy, or Browser yourself?

| Pick auto | Pick manual |
|-----------|-------------|
| You don't know what the site needs yet | You know exactly which engine the target wants |
| You want one call that just works | You're optimizing the request shape for a known target |
| You're fine with auto reusing a session it learned | You want full control over per-call retry, timeout, and proxy choice |
| You're paying for a few seconds of probing on the first call | Latency on the first call matters more than discovery |

Auto isn't always the cheaper pick. If you already know a target works with Single and `unblocker` on, calling Single directly skips the ladder and costs 2 credits. Auto on the same target costs whatever its ladder spends.

## When to Combine Approaches

Some workflows benefit from using multiple endpoints:

1. **Discover with auto**: pass a `validate` rule and let the ladder figure out which rung the site needs.
2. **Replay with single**: take the `session.proxy`, `session.cookies`, and `session.userAgent` auto returned, then call Single with them for follow-up pages on the same host.
3. **Fall back to browser**: if single starts failing, switch to browser rendering.
4. **Add proxy**: if you're getting refused (403 or a verification page) without auto, wrap your request in the proxy endpoint for automatic rotation.

This progressive approach keeps cost low while keeping success rates high.

## Performance Tips

- Pass a `validate.data.accept` substring on protected targets. Auto recognizes the common challenge pages on its own, but only your rule can catch a check page it doesn't know, or a page that loaded without the content you need.
- Use the single endpoint by default for known-working hosts and only upgrade when needed.
- Set `checkText` in browser requests so a page that rendered without your content comes back as a failure (`checkText:<text> not found`) instead of a success. `checkText` doesn't make FourA wait longer for the text.
- Set `maxTries` in proxy requests to control retry behavior (default is 5, max is 90).
- Keep `timeout_ms` reasonable: 10 to 15 seconds for most pages, 30s+ for cold auto runs against protected sites.

## Next Steps

- [Smart Fetch (Auto)](https://foura.ai/docs/guides/smart-fetch): The deep dive on `/api/auto/`
- [API Endpoints](https://foura.ai/docs/api/endpoints): Full parameter reference
- [Scrape a Dynamic Website](https://foura.ai/docs/how-to/scrape-dynamic-website): Step-by-step browser request guide
- [Quick Start](https://foura.ai/docs/getting-started/quick-start): Your first request in 30 seconds
