Scout · Recipe

First verification

One realistic path: discover URLs on a site, extract a field from each page, then verify a critical element is visible — using crawl, jobs, extract, and visibility together.

What you need
A Scout API key from app.scout.macrocontent.dev → API keys and enough credits (Free tier is enough for a small run). No domain verify for this read-only path.
  1. Crawl the site (link discovery)

    Call POST /v1/crawl to get discovered_urls[] — not page HTML.

    json
    {
      "start_url": "https://example.com",
      "max_depth": 1,
      "max_pages": 10,
      "same_origin": true,
      "seed_from_sitemap": true
    }

    Keep max_pages small while learning (credits = 15 + 2×max_pages).

  2. Batch extract with a job

    Take a few URLs from the crawl and enqueue POST /v1/jobs with type: "extract" (or save selectors as a template).

    json
    {
      "requests": [
        {
          "type": "extract",
          "body": {
            "url": "https://example.com/pricing",
            "fields": [{ "name": "h1", "selector": "h1", "type": "text" }]
          }
        },
        {
          "type": "extract",
          "body": {
            "url": "https://example.com/about",
            "fields": [{ "name": "h1", "selector": "h1", "type": "text" }]
          }
        }
      ]
    }

    Poll GET /v1/jobs/:id until completed. Results expire (~30 min) — persist what you need.

  3. Verify a critical element is visible

    For your money-page URL, call POST /v1/checks/visibility — Scout’s occlusion-aware check.

    json
    {
      "url": "https://example.com/pricing",
      "selector": "a[href*='signup']",
      "scroll_into_view": true
    }

    You want overall_pass: true, visible: true, and not_covered: true. If overlap_detected_by is set, something sits on top of the element.

  4. Optional: screenshot evidence

    Attach a screenshot/json shot of the same URL for humans/auditors. Decode image_base64 to a file.

When to switch to a journey

If the element only appears after login or a click path, use a journey (shared browser state) instead of separate extract calls — and verify the domain before interact.