Skip to content
Examples

Configure Chain

Automatically feed Google Maps leads into a Google Maps Reviews scrape

The v1 API, for batchesSquids, tasks and runs: many calls on a schedule, delivered where you work. For one call that answers in seconds, use the API v2.
POSThttps://api.lobstr.io/v1/squids/{squid_hash}/chain

Once your Google Maps Leads Scraper squid collects place URLs, you can chain it to a Google Maps Reviews Scraper so that reviews are fetched automatically for every place found — no manual steps required.

When a leads run completes with a status of DONE, the scheduler extracts the url field from each result and queues it as a task on the reviews squid, then starts a new run. Runs that end in ERROR do not trigger the chain.

Headers

Authorizationstringheaderrequired

Your API authentication token. Value: Token YOUR_API_KEY

Content-Typestringheaderrequired

Must be application/json. Value: application/json

Request Body

target_module_idstringrequired

Hash ID of the Google Maps Reviews Scraper crawler. Retrieve it from GET /v1/crawlers.

field_mapobjectrequired

Maps the url field from leads results to the url input on the reviews crawler. Always {"url": "url"} for this chain.

autostartboolean

Whether the reviews run starts automatically. Defaults to true.

cluster_namestring

Name for the auto-created reviews squid. Example: "Google Maps Reviews (chained)".

cluster_concurrencyinteger

Concurrency for the reviews squid. Defaults to 1.

Code Examples

curl -X POST "https://api.lobstr.io/v1/squids/YOUR_LEADS_SQUID_HASH/chain" \
  -H "Authorization: Token YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "target_module_id": "GOOGLE_MAPS_REVIEWS_CRAWLER_HASH",
    "field_map": {"url": "url"},
    "autostart": true,
    "cluster_name": "Google Maps Reviews (chained)",
    "cluster_concurrency": 3
  }'

Response

201
{
  "id": "a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4",
  "target_module": {
    "id": "9a3f1c8b2e7d4a56f0e1b2c3d4e5f678",
    "public_name": "Google Maps Reviews Scraper",
    "name": "googlemapreviews_matrix",
    "max_concurrency": 10
  },
  "target_cluster": null,
  "field_map": {"url": "url"},
  "is_active": true,
  "autostart": true,
  "cluster_name": "Google Maps Reviews (chained)",
  "cluster_concurrency": 3,
  "created_at": "2026-04-28T10:00:00Z"
}

target_cluster is null until the first leads run completes and triggers the chain. After that it will contain the auto-created reviews squid.

Set autostart: false if you want to review the queued tasks before the reviews run starts.