Property AI Search API
RAG-powered natural language search for properties (lower-level than listing search).
Base path: /api/v1/search/properties or /api/v1/properties
Search Properties by Query
POST /api/v1/search/properties/search/ids
{ "query": "Pet-friendly villa in Goa near beach for 6 people" }
Response:
{
"propertyIds": ["prop_abc", "prop_def", "prop_ghi"],
"checkInDate": "2026-04-05",
"checkOutDate": "2026-04-07",
"adultCount": 6,
"childCount": null,
"infantCount": null
}
How it works:
- Query embedded via
text-embedding-3-small - pgvector cosine similarity finds top 50 property candidates
- Geo anchor resolved from query (e.g., "Goa" → coordinates)
- LLM re-ranks by relevance and extracts dates/guests
- Cached by
date:normalized_queryfor 10 minutes