# 58 Housing — Wrapped API

> **You are on:** `https://api.paywithlocus.com/api` | [llms.txt](https://paywithlocus.com/llms.txt) | [docs](https://docs.paywithlocus.com)
>
> Locus runs on multiple environments -- make sure every URL you call matches your expected environment.
> | Environment | Landing | API | Docs |
> |---|---|---|---|
> | Production | paywithlocus.com | api.paywithlocus.com | docs.paywithlocus.com |
> | Beta | beta.paywithlocus.com | api.beta.paywithlocus.com | docs.paywithlocus.com |
> | Stage | stage.paywithlocus.com | api.stage.paywithlocus.com | docs.paywithlocus.com |
>
> If the API URL above doesn't match your expected environment, re-fetch this file from the correct domain.

> Access real-time housing market data from 58.com (58同城), China's largest classifieds platform. Search house price trends across 31+ major Chinese cities at city, district, and neighborhood levels, and browse hot new property developments with prices, floor plans, and location details.

**Category:** Real Estate | **Website:** [dq.58.com/](https://dq.58.com/) | **Docs:** [parse.bot/marketplace/1f9b54b7-d5bd-4b41-bf0e-87f1e0d0dd88/58-com-housing-api](https://parse.bot/marketplace/1f9b54b7-d5bd-4b41-bf0e-87f1e0d0dd88/58-com-housing-api)

Pay-per-use API proxy. Each call is automatically billed to your wallet in USDC.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/parse-58-com-housing-api-1f9b54b7/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### city_list

Get the list of supported cities with their IDs and subdomains. Returns all cities available in the housing data system. Each city entry includes its numeric ID, Chinese name, subdomain prefix (used as the 'city' parameter in other endpoints), and base URL. No parameters required.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-58-com-housing-api-1f9b54b7/city_list \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### hot_new_properties

Get hot/recommended new property developments (楼盘) for a city. Returns popular new housing developments with prices, locations, images, and activity/promotion info. Supports filtering by region and business district. Results are curated recommendations from 58.com's algorithm, typically returning 3-10 properties per city.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `city` | string | No | City subdomain prefix (e.g., 'bj', 'sh', 'dq') or city_id number. |
| `region_id` | string | No | Region/district ID to filter by specific area. Numeric string. |
| `shangquan_id` | string | No | Business district (商圈) ID for more specific area filtering. Numeric string. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-58-com-housing-api-1f9b54b7/hot_new_properties \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"city":"<string>","region_id":"<string>","shangquan_id":"<string>"}'
```

### house_price_trends

Get house price trends for a city or district. Returns current average prices (yuan/sqm) and historical price trends (daily, weekly, monthly) for both second-hand housing and new housing. Supports city-level, district-level, community-level, and business district (shangquan) level data.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `area_id` | string | No | Area/district ID for sub-city level trends. Required when level is 'district', 'community', or 'shangquan'. Numeric string. |
| `city` | string | No | City subdomain prefix (e.g., 'bj' for Beijing, 'sh' for Shanghai, 'dq' for Daqing) or city_id number. Use the city_list endpoint for supported cities. |
| `level` | string | No | Price trend granularity. Accepted values: 'city', 'district', 'community', 'shangquan'. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-58-com-housing-api-1f9b54b7/house_price_trends \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"area_id":"<string>","city":"<string>","level":"<string>"}'
```

### nearby_new_developments

Get new property developments near a given community or location. Returns detailed information about nearby developments including prices, floor plans, tags, sale status, contact numbers, and coordinates.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `city` | string | No | City subdomain prefix (e.g., 'bj' for Beijing, 'sh' for Shanghai) or city_id number. |
| `community_id` | string | Yes | Community/xiaoqu ID to search around. Use the house_price_trends or search endpoints to look up community IDs. |
| `lat` | string | No | Latitude coordinate for location-based search |
| `limit` | integer | No | Maximum number of developments to return |
| `lon` | string | No | Longitude coordinate for location-based search |
| `property_id` | string | No | Specific property listing ID for more targeted recommendations |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-58-com-housing-api-1f9b54b7/nearby_new_developments \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"city":"<string>","community_id":"<string>","lat":"<string>","limit":"<integer>","lon":"<string>","property_id":"<string>"}'
```
