Trawley
Search API

Export endpoint

Download every result from a scraper as JSON or CSV in one request.

The export endpoint streams all of a scraper's results as a downloadable file. It pages through the full result set for you, so a single request returns everything rather than one page.

Request

text
GET https://api.trawley.ai/v1/scrapers/{scraperId}/export?format=json

Query parameters

ParameterTypeDefaultDescription
formatstringjsonOutput format. One of json or csv.
JSON
curl -L "https://api.trawley.ai/v1/scrapers/scr_8f2a1c9e/export?format=json" \
  -o results.json

The response is sent as a file attachment named after your scraper (for example acme_listings_results.csv). CSV columns are your scraper's field names.

Passing any format other than json or csv returns 400 Bad Request.

When to use export vs results

Use export whenUse the results endpoint when
You want the entire dataset in one fileYou want to page through results in your app
You are loading into a spreadsheet or warehouseYou need a small, fast slice
A download is the end productThe data feeds further requests

What's next