Facebook local listings
GET /v1/facebook/listings searches US Facebook Marketplace listings around a ZIP code or exact point, with radius, price, condition, delivery, listing age and sort filters.
https://api.soldgraph.com/v1/facebook/listingsSearch active Facebook Marketplace listings near a place. Give a five-digit zip, or lat and lon for an exact point, and optionally a radius in miles. One request returns one source page of up to about 24 listings. Sold search and completed sale prices are not supported; /v1/facebook/sold is not an API endpoint.
displayed_price is the seller's ask in USD. It is not a sale price, and buyers on Facebook Marketplace often negotiate. A price of 0 means the seller listed the item as free.
| Parameter | Type | Default | Description |
|---|---|---|---|
q | string | Required | Search keywords, 1–200 characters, as you'd type them into the marketplace's search box. Be specific: model, size, grade, edition. |
page | integer, 1–100 | 1 | Source page to fetch. Where an endpoint has cursor, pages after 1 also need it. |
min_price | integer, 0–1000000 | Lowest price, in whole US dollars. Optional. Must not be more than max_price. You can send it without max_price. | |
max_price | integer, 0–1000000 | Highest price, in whole US dollars. Optional. You can send it without min_price. | |
marketplace | facebook | facebook | Optional. If sent, it must be facebook. |
country | us | us | Only us is supported. |
zip | string | Five-digit US ZIP code to search around. Send zip, or both lat and lon. Unknown ZIP codes, and places more than 75 miles from any Facebook Marketplace city, return 422. | |
lat | number, 17–72 | Latitude of the search center in decimal degrees. Use with lon instead of zip. Rounded to 4 decimals (about 11 m). | |
lon | number, -180–-64 | Longitude of the search center in decimal degrees. Use with lat. | |
radius | integer, 1–100 | Search radius in miles, 1 to 100. Default is Facebook's own, about 40 miles. Rows whose city is farther than the radius plus 10 miles are dropped. | |
sort | best_match, newest, price_asc or price_desc | best_match | Facebook ranking, newest listed first, or asking price low to high or high to low. Sorted searches return up to 24 rows; best match often returns about 15. |
condition | new, used_like_new, used_good or used_fair | One condition, or several separated by commas, such as used_like_new,used_good. | |
delivery | local_pickup or shipping | Only listings offering local pickup, or only listings that ship. | |
days_since_listed | 1, 7 or 30 | Only listings posted in the last 1, 7 or 30 days. |
curl -G https://api.soldgraph.com/v1/facebook/listings \ -H "Authorization: Bearer $SOLDGRAPH_KEY" \ --data-urlencode "q=mountain bike" \ -d zip=28202 \ -d radius=25 \ -d max_price=800A cache miss returns 202 with a job to poll. Successful searches cost one credit, including cached results. Failed searches are free. Results are cached for 15 minutes. See search jobs.
#Location and radius
Facebook Marketplace searches around a city, not an arbitrary point. We search from the Facebook city closest to your zip or point, and show it as result.location.source_city, with its distance from your point.
zipuses the US Census center point of that ZIP code. A ZIP code with no Census area returns422. Uselatandloninstead.- Places more than 75 miles from any Facebook Marketplace city return
422. This is under 1% of US ZIP codes, mostly in remote areas. radiusis 1 to 100 miles. Without it, Facebook uses its own default of about 40 miles.- When the city is a few miles from your point, we widen the radius sent to Facebook so it still covers your whole circle.
result.location.source_radius_kmis the radius Facebook applied. - Listing rows carry only their city.
approx_distance_milesis the distance to that city, not to the item. Rows whose city is farther than your radius plus 10 miles are dropped. Use the item endpoint for a listing's approximate coordinates.
#Filters
sorttakesbest_match,newest,price_ascorprice_desc. Sorted searches return up to 24 rows; best match often returns about 15.conditiontakes one or more ofnew,used_like_new,used_goodandused_fair, separated by commas.deliverytakeslocal_pickuporshipping.days_since_listedtakes1,7or30.min_priceandmax_priceare whole US dollars. Either can be sent alone.- Facebook reports the filters it applied on every page. If it didn't apply one you sent, the search fails rather than returning unfiltered results as if they were filtered.
#One page per search
Facebook serves one page of results to logged-out visitors, so next_page is always null and there is no cursor. To reach more listings, run several narrower searches. Different sort orders, price bands such as 0-50, 50-150 and 150+, and days_since_listed=1 each return a different slice. Remove repeats by id.
Image links are signed by Facebook and expire after some days. Save the image itself if you need it later.