Search ads
dv_searchSearch Divar ads across one or more cities by category, text, price, and filters. Returns compact newest-first ad cards with Toman prices and cursor paging.
Instructions
Search Divar ads in one or more cities by category, text and filters; compact cards, prices in Toman.
Card fields are described in the server instructions; age_h is hours since the last bump, image comes only
with thumbnails, and suspect_price includes 'outlier' (at or under a tenth of the fetched median, 5+ priced
ads). Newest first; the first 1-3 rows may be promoted older ads. Continue with next_cursor as cursor.
Filters the category lacks come back in ignored; an empty Persian query is retried once with letters folded.
Next: dv_post, dv_compare, dv_cheapest, dv_market.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| city | No | City name or id; several comma-separated, e.g. 'تهران', 'mashhad', 'تهران,کرج'. | تهران |
| sort | No | 'newest' is Divar's own order (default, pages by cursor). 'cheapest' / 'expensive' sort the ads fetched in this call by price (Divar cannot sort by price). | newest |
| limit | No | Max ads in the answer. | |
| pages | No | Result pages to merge, about 25 ads each. | |
| query | No | Free text in title or description, e.g. 'پراید 111'. | |
| cursor | No | `next_cursor` of the previous call, for older ads. | |
| recent | No | Published within '3h', '12h', '1d', '3d' or '7d'. | |
| exclude | No | Drop ads whose title has any of these words. | |
| filters | No | Other category filters (keys from dv_filters): {'size': {'min': 80, 'max': 120}, 'rooms': ['دو'], 'parking': true}. Unknown keys are returned in `ignored`. | |
| category | No | Category slug or Persian name, e.g. 'light' (cars), 'apartment-sell', 'apartment-rent', 'mobile-phones'. | |
| keywords | No | Words that must all be in the title. | |
| districts | No | Neighbourhood names or ids in the one city, e.g. ['ونک']. | |
| has_photo | No | Only ads with photos. | |
| max_price | No | Toman; monthly rent in rent categories. | |
| min_price | No | Toman; monthly rent in rent categories. | |
| thumbnails | No | Include each ad's thumbnail URL in `image` (about 40 tokens per ad). | |
| brand_model | No | Vehicles, phones: brand/model, e.g. ['پژو 206']. | |
| max_deposit | No | Rent categories: deposit (ودیعه) in Toman. | |
| min_deposit | No | Rent categories: deposit (ودیعه) in Toman. | |
| max_age_hours | No | Only ads bumped within this many hours. |