Trawley
Search API

Hybrid search

The recommended endpoint — natural language search combining AI filters, vector similarity, and keyword matching.

Hybrid search is the endpoint you will reach for most. You send a natural language query, and Trawley combines three techniques in a single call:

  1. AI-generated structured filters turn precise constraints in your query (bedrooms, price, dates) into exact filters.
  2. Vector similarity matches fuzzy, semantic parts of the query (locations, descriptions, names) by meaning, not exact words.
  3. Keyword matching catches literal term overlaps.

The result: "3 bed houses near Kendal under £500k with a garden" returns the right records without you writing any query logic.

Request

text
GET https://api.trawley.ai/v1/scrapers/{scraperId}/hybrid

Query parameters

ParameterTypeDefaultDescription
searchstringrequiredThe natural language query.
pagenumber1Page of results to return.
takenumber10Number of results per page.
cURL
curl "https://api.trawley.ai/v1/scrapers/scr_8f2a1c9e/hybrid?\
search=3+bed+houses+with+a+garden&page=1&take=10"

Response

json
{
  "data": [
    {
      "title": "3 bed semi-detached house",
      "price": 425000,
      "bedrooms": 3,
      "location": "Kendal",
      "url": "https://acmehomes.co.uk/listings/3-bed-semi-kendal"
    }
  ],
  "pagination": {
    "total": 18,
    "page": 1,
    "take": 10,
    "totalPages": 2,
    "hasMore": true
  },
  "meta": {
    "filter": "bedrooms = 3"
  }
}
FieldDescription
dataArray of matching records. Each record's fields are the ones you defined on the scraper.
pagination.totalEstimated total number of matches across all pages.
pagination.totalPagesTotal pages given the current take.
pagination.hasMoretrue when more pages remain after this one.
meta.filterThe structured filter Trawley's AI derived from your query.

Debugging with meta.filter

meta.filter shows the exact structured filter the AI built from your natural language query before similarity ranking. It is the single most useful field for understanding why you got the results you did.

If a query returns too few or unexpected results, check meta.filter. A query like "cheap flats" might produce no filter at all (price thresholds are fuzzy), while "flats under £200k" produces price < 200000. Seeing the filter tells you whether the constraint was interpreted as exact or left to similarity search.

Trawley deliberately leaves fuzzy aspects (approximate locations, names, free text) out of the filter and resolves them through vector similarity instead, so you do not need exact-match values for them.

Notes

  • Only fields with a non-text data type (number, date, boolean) are eligible for structured filters. Text fields are always matched by similarity.
  • Results come from the most recent completed scrape run.
  • If the scraper has never completed a run, data is an empty array.

What's next