> ## Documentation Index
> Fetch the complete documentation index at: https://docs.scrapegraphai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Zapier

> Use ScrapeGraphAI inside Zapier Zaps — scrape, extract, search, crawl, and monitor web pages with no code

## Overview

The ScrapeGraphAI app for Zapier connects any Zap to ScrapeGraph's v2 API as native Zapier actions — fetch pages, extract structured JSON, run web searches, kick off multi-page crawls, and schedule monitors. Pair it with Zapier's 7,000+ apps to wire scraping into Slack, Sheets, Notion, Airtable, HubSpot, or anything else.

<CardGroup cols={2}>
  <Card title="ScrapeGraphAI on Zapier" icon="bolt" href="https://zapier.com/apps/scrapegraphai/integrations">
    Install the app and start a Zap
  </Card>

  <Card title="ScrapeGraphAI Dashboard" icon="key" href="https://scrapegraphai.com/dashboard">
    Get your API key
  </Card>
</CardGroup>

## Connect ScrapeGraphAI

1. In any Zap, search for **ScrapeGraphAI** as an action and pick one — for example **Scrape a URL**.
2. When prompted, click **Sign in** → paste your `SGAI-APIKEY` from the [dashboard](https://scrapegraphai.com/dashboard).
3. Save the connection — Zapier reuses it across every ScrapeGraphAI step in every Zap.

<Frame>
  <img src="https://mintcdn.com/scrapegraphaiinc-9e950277/ec5tYX4JlXnnZOYS/integrations/images/zapier/connection.png?fit=max&auto=format&n=ec5tYX4JlXnnZOYS&q=85&s=f1fa23f4a9785b40d14e68dacb0f1f68" alt="ScrapeGraphAI connection dialog in Zapier with API Key field" width="2184" height="1476" data-path="integrations/images/zapier/connection.png" />
</Frame>

<Note>
  Your API key is stored on Zapier's side and is sent in the `SGAI-APIKEY` header on each call. Rotate it from the [dashboard](https://scrapegraphai.com/dashboard) and update the connection if needed.
</Note>

## What's in the integration

<Frame>
  <img src="https://mintcdn.com/scrapegraphaiinc-9e950277/ec5tYX4JlXnnZOYS/integrations/images/zapier/actions.png?fit=max&auto=format&n=ec5tYX4JlXnnZOYS&q=85&s=3e3e858376097ae5b1ab2b0b9d87863c" alt="Zapier action picker showing ScrapeGraphAI actions" width="2936" height="1604" data-path="integrations/images/zapier/actions.png" />
</Frame>

| Action                    | What it does                                                                           |
| ------------------------- | -------------------------------------------------------------------------------------- |
| **Scrape a URL**          | Fetch a page in markdown or HTML — single round-trip                                   |
| **Extract Data From URL** | Run a natural-language prompt over a URL, raw HTML, or markdown — optional JSON schema |
| **Search Web**            | AI web search with inline content; optional rollup prompt across results               |
| **Crawl a Website**       | Start an async multi-page crawl from an entry URL — returns a job ID                   |
| **Get Crawl Status**      | Poll a crawl job by ID until it returns the `pages` array                              |
| **Get a Past Result**     | Fetch any stored job result by `id` or `scrapeRefId`                                   |
| **Create Monitor**        | Schedule a recurring fetch on a cron with diff detection and optional webhook          |
| **Get Monitor Activity**  | Read recent ticks from a monitor (`changed`, `diffs`, `status`, `createdAt`)           |

<Note>
  Zapier action timeouts cap individual steps at 30–60 seconds (depending on your plan). For larger crawls, use **Crawl a Website** to start the job, then a **Delay** + **Get Crawl Status** to poll — same async pattern as n8n.
</Note>

## Actions

### Scrape a URL

Fetch a page and return its content in a chosen format.

<Frame>
  <img src="https://mintcdn.com/scrapegraphaiinc-9e950277/_h_-wH4N4HusJ-mn/integrations/images/zapier/scrape.png?fit=max&auto=format&n=_h_-wH4N4HusJ-mn&q=85&s=384bedf0512830bfd78819cc6b253292" alt="Scrape a URL action with URL filled and Format = markdown" width="1652" height="1318" data-path="integrations/images/zapier/scrape.png" />
</Frame>

| Field  | Description                               |
| ------ | ----------------------------------------- |
| URL    | The page to fetch                         |
| Format | Output format — Markdown or HTML          |
| Mode   | Rendering mode — Normal, Reader, or Prune |

***

### Extract Data From URL

Send a URL (or raw HTML / markdown) to ScrapeGraph and get back structured JSON, driven by a natural-language prompt.

<Frame>
  <img src="https://mintcdn.com/scrapegraphaiinc-9e950277/_h_-wH4N4HusJ-mn/integrations/images/zapier/extract.png?fit=max&auto=format&n=_h_-wH4N4HusJ-mn&q=85&s=afdb1b85c4d844ab5a0984423663a59d" alt="Extract Data From URL action configuration in Zapier" width="1652" height="1318" data-path="integrations/images/zapier/extract.png" />
</Frame>

| Field    | Description                                                         |
| -------- | ------------------------------------------------------------------- |
| Source   | `URL`, `HTML`, or `Markdown` — picks which input field is used      |
| URL      | Page to extract from (when Source = URL)                            |
| HTML     | Raw HTML to extract from (when Source = HTML)                       |
| Markdown | Markdown to extract from (when Source = Markdown)                   |
| Prompt   | Natural-language instruction, e.g. `Extract product name and price` |
| Schema   | Optional JSON schema to enforce output shape                        |
| Mode     | Extraction mode — `Auto`, `Fast`, or `JS`                           |

***

### Search Web

Run a web search and get the top results back inline, optionally with AI extraction applied across them.

<Frame>
  <img src="https://mintcdn.com/scrapegraphaiinc-9e950277/_h_-wH4N4HusJ-mn/integrations/images/zapier/search.png?fit=max&auto=format&n=_h_-wH4N4HusJ-mn&q=85&s=0822902152b377ece35e9fd8646e75de" alt="Search Web action with a query, 3 results, markdown format" width="1652" height="1318" data-path="integrations/images/zapier/search.png" />
</Frame>

| Field                   | Description                                                                                      |
| ----------------------- | ------------------------------------------------------------------------------------------------ |
| Query                   | Search query string                                                                              |
| Number of Results       | 1–20, default 3                                                                                  |
| Format                  | Content format for each result (`markdown` / `html`)                                             |
| Prompt                  | Optional rollup prompt run across all results                                                    |
| Time Range              | Filter to a recent window (`past_hour`, `past_24_hours`, `past_week`, `past_month`, `past_year`) |
| Location (Country Code) | Two-letter ISO country code for localized results                                                |

***

### Crawl a Website

Start a multi-page crawl from an entry URL. Returns immediately with a job ID — pair with **Get Crawl Status** to retrieve the pages.

<Frame>
  <img src="https://mintcdn.com/scrapegraphaiinc-9e950277/_h_-wH4N4HusJ-mn/integrations/images/zapier/crawl.png?fit=max&auto=format&n=_h_-wH4N4HusJ-mn&q=85&s=35e7c97db0275e8cbf06da05c9e21c8f" alt="Crawl a Website action with URL, format, max pages, max depth, and max links per page" width="1652" height="1318" data-path="integrations/images/zapier/crawl.png" />
</Frame>

| Field              | Description                                             |
| ------------------ | ------------------------------------------------------- |
| URL                | Entry point for the crawl                               |
| Format             | Output format per page (`markdown` / `html`)            |
| Mode               | Rendering mode — Normal, Reader, or Prune               |
| Max Pages          | Cap on total pages crawled (1–1000)                     |
| Max Depth          | How many link levels deep to traverse                   |
| Max Links Per Page | Maximum links to follow per page                        |
| Include Patterns   | Newline-separated URL globs to include (e.g. `/blog/*`) |
| Exclude Patterns   | Newline-separated URL globs to exclude                  |

***

### Get Crawl Status

Poll a crawl job until it completes. When `status` is `completed`, the response carries a `pages` array with a `scrapeRefId` per page that you can pass to **Get a Past Result**.

<Frame>
  <img src="https://mintcdn.com/scrapegraphaiinc-9e950277/_h_-wH4N4HusJ-mn/integrations/images/zapier/crawl-status.png?fit=max&auto=format&n=_h_-wH4N4HusJ-mn&q=85&s=7727ce98ee15c69759b036568eee0721" alt="Get Crawl Status action with Crawl Job ID mapped from a previous step" width="1652" height="1318" data-path="integrations/images/zapier/crawl-status.png" />
</Frame>

| Field    | Description                                                                  |
| -------- | ---------------------------------------------------------------------------- |
| Crawl ID | The `id` returned by Crawl a Website — usually mapped from the previous step |

The async pattern looks like this on the canvas — kick off the crawl, wait, then poll:

<Frame>
  <img src="https://mintcdn.com/scrapegraphaiinc-9e950277/ec5tYX4JlXnnZOYS/integrations/images/zapier/crawl-pair.png?fit=max&auto=format&n=ec5tYX4JlXnnZOYS&q=85&s=fae78f9c06cb07052b2b76603a24376e" alt="Zap canvas: Schedule → Crawl a Website → Delay → Get Crawl Status" width="2936" height="1604" data-path="integrations/images/zapier/crawl-pair.png" />
</Frame>

***

### Get a Past Result

Fetch a stored job result by its ID. Most useful for retrieving the full content of a crawled page using the `scrapeRefId` from **Get Crawl Status**.

<Frame>
  <img src="https://mintcdn.com/scrapegraphaiinc-9e950277/_h_-wH4N4HusJ-mn/integrations/images/zapier/past-result.png?fit=max&auto=format&n=_h_-wH4N4HusJ-mn&q=85&s=4d86a7fefc9d553e365c6327621591b0" alt="Get a Past Result action with the Entry ID field" width="1652" height="1318" data-path="integrations/images/zapier/past-result.png" />
</Frame>

| Field    | Description               |
| -------- | ------------------------- |
| Entry ID | A job ID or `scrapeRefId` |

***

### Create Monitor

Schedule ScrapeGraph to fetch a URL on a recurring cron and detect changes between runs.

<Frame>
  <img src="https://mintcdn.com/scrapegraphaiinc-9e950277/_h_-wH4N4HusJ-mn/integrations/images/zapier/monitor-create.png?fit=max&auto=format&n=_h_-wH4N4HusJ-mn&q=85&s=4ef745709d6f2cc87e4602f183429fc9" alt="Create Monitor action with URL, name, cron, format, HTML mode, and webhook URL fields" width="1652" height="1318" data-path="integrations/images/zapier/monitor-create.png" />
</Frame>

| Field           | Description                                                                      |
| --------------- | -------------------------------------------------------------------------------- |
| URL             | Page to watch                                                                    |
| Monitor Name    | Optional display name                                                            |
| Interval (Cron) | 5-field cron expression — see table below                                        |
| Format          | Content format captured on each tick (`markdown` / `html` / `links` / `summary`) |
| HTML Mode       | Rendering mode — Normal, Reader, or Prune                                        |
| Webhook URL     | Optional URL to POST tick payloads to                                            |

**Common cron expressions**

| Schedule           | Cron          |
| ------------------ | ------------- |
| Every hour         | `0 * * * *`   |
| Every 6 hours      | `0 */6 * * *` |
| Daily at 09:00 UTC | `0 9 * * *`   |
| Weekly on Monday   | `0 9 * * 1`   |

***

### Get Monitor Activity

Fetch the latest activity ticks from an existing monitor.

<Frame>
  <img src="https://mintcdn.com/scrapegraphaiinc-9e950277/_h_-wH4N4HusJ-mn/integrations/images/zapier/monitor-activity.png?fit=max&auto=format&n=_h_-wH4N4HusJ-mn&q=85&s=89bbf07db79147848fe79cce8eab8797" alt="Get Monitor Activity action with Monitor ID and Limit fields" width="1652" height="1318" data-path="integrations/images/zapier/monitor-activity.png" />
</Frame>

| Field      | Description                                   |
| ---------- | --------------------------------------------- |
| Monitor ID | The `id` returned by Create Monitor           |
| Limit      | Number of ticks to return (1–100, default 20) |

Returns a `ticks` array where each entry has `changed` (boolean), `diffs`, `status`, and `createdAt`.

## Example Zap: extract product data into Google Sheets

A daily Zap that pulls product data from a listing page and appends each product as a row in Google Sheets.

1. **Trigger** — `Schedule by Zapier` → Every day.
2. **Action 1** — `ScrapeGraphAI → Extract Data From URL`:
   * **Source:** `URL`
   * **URL:** the product listing page
   * **Prompt:** `Extract all products on the page with their name, price, rating, and number of reviews`
   * **Schema:**
     ```json theme={null}
     {
       "type": "object",
       "properties": {
         "products": {
           "type": "array",
           "items": {
             "type": "object",
             "properties": {
               "name": {"type": "string"},
               "price": {"type": "string"},
               "rating": {"type": "number"},
               "reviews": {"type": "number"}
             }
           }
         }
       }
     }
     ```
3. **Action 2** — `Looping by Zapier → Loop From Line Items`, fed from the previous step's `products` array. Zapier runs the next action once per item.
4. **Action 3** — `Google Sheets → Create Spreadsheet Row`:
   * **Name** → `{{loop.name}}`
   * **Price** → `{{loop.price}}`
   * **Rating** → `{{loop.rating}}`
   * **Reviews** → `{{loop.reviews}}`

Result: every product on the page gets its own row.

## Patterns that carry over

| Pattern                   | Action(s)                                              | Notes                                                                              |
| ------------------------- | ------------------------------------------------------ | ---------------------------------------------------------------------------------- |
| One-shot fetch            | Scrape a URL                                           | Cheapest path — markdown by default                                                |
| Structured extraction     | Extract Data From URL                                  | JSON schema is optional but locks the shape                                        |
| Multi-page archive        | Crawl a Website + Get Crawl Status + Get a Past Result | Loop over `pages` from Get Crawl Status, feed `scrapeRefId` into Get a Past Result |
| Recurring fetch with diff | Create Monitor + Get Monitor Activity                  | Or wire `webhookUrl` to a Zapier Webhook trigger for instant deltas                |
| AI search rollup          | Search Web with Prompt                                 | Single call replaces "search → scrape each → summarize"                            |

## Troubleshooting

* **Action times out on Crawl a Website** — large crawls run longer than Zapier's per-action limit. Keep Crawl a Website as the start step, then add a **Delay** + **Get Crawl Status** to poll until `status` is `completed`.
* **Extract returns an empty `json`** — sharpen the prompt, or pin the shape with a JSON Schema. Pages that need rendering may need `Mode: JS`.
* **Connection test fails** — confirm the API key is from the v2 dashboard (`scrapegraphai.com/dashboard`). v1 keys won't validate against the v2 API.
* **Get Past Result returns stale data** — `scrapeRefId` always points to the latest stored result for that pointer. Trigger a fresh crawl to refresh.

## Resources

<CardGroup cols={2}>
  <Card title="ScrapeGraphAI on Zapier" icon="bolt" href="https://zapier.com/apps/scrapegraphai/integrations">
    Marketplace listing and Zap templates
  </Card>

  <Card title="API Reference" icon="code" href="/api-reference/introduction">
    Full v2 endpoint reference — every parameter the actions send
  </Card>

  <Card title="Dashboard" icon="key" href="https://scrapegraphai.com/dashboard">
    Get an API key and check usage
  </Card>

  <Card title="Zapier docs" icon="book" href="https://zapier.com/help">
    How Zaps, triggers, actions, and Looping work
  </Card>
</CardGroup>
