← 返回首页
API

数据接口文档

全国数据整合为两个全量文件——一次请求拿全量,不必逐城拼凑。所有端点只读、无鉴权、可被 CDN 缓存,适合 skill / agent / 前端直接消费。

端点总览

端点格式内容体积
/data.jsonJSON全国全量单文件:meta / stats / provinces(32 省汇总)/ cities(389 城全量明细) / food_top(800)/ districts_top(1000)51.3 MB · gzip 约 10.7 MB
/data.mdMarkdown全国全量单文件:目录 + 统计 + 32 省索引 + 389 城档案(每城 13 章)+ 接口与来源附录38.9 MB · gzip 约 10.9 MB

/data.json 顶层结构

{
  "meta":  { "name": "FUN 全国美食×商圈×娱乐数据库", "version": "v0.9.0",
            "generated": "...", "home": "https://fun.worldstip.com", "schema": {...} },
  "stats": { "provinces": 32, "cities": 389, "poi_total": 328980,
            "districts_total": 15405, "grades": {"S": 231, "A": 3345, "B": 5300, "C": 6529} },
  "provinces": [ {"province": "湖南省", "cities": 14, "poi": 11628,
                  "districts": 428, "grades": {...}, "page": "provinces/湖南省.html"} ],  // ×32
  "cities": [ { // ×389,字段见下 } ],
  "food_top": [ {"name": "...", "type": "餐饮服务;中餐厅;...", "rating": 4.8,
                 "avg": 63, "address": "...", "image": "https://store.is.autonavi.com/...",
                 "city": "岳阳市", "province": "湖南省", "city_page": "cities/430600.html"} ],  // ×800,已剔除住宿业主导 POI
  "districts_top": [ {"name": "...", "grade": "S", "carrier": "...", "rating": 4.8,
                      "food": 120, "leisure": 88, "city": "...", "province": "...", "city_page": "..."} ]  // ×1000,S/A 级
}

城市记录字段(cities[])

字段类型说明
city / province / adcodestr城市名 / 所属省 / 高德区划代码(页面文件名同 adcode)
poi_total / district_countint去重 POI 总数 / 商圈档案数
waves / updatedarray / str采集波次(1 美食商圈 / 2 酒店亲子商场 / 3 休闲全维度)/ 采集时间
credibilityobj§0 可信度:poi_total / rated_ratio / warnings / dims 六维计数
overviewobj§1 总览:行政层级 / 各区县 POI 分布 / 载体类型分布
districtsarray§2 商圈档案:name / grade(S·A·B·C) / carrier / rating / food / leisure / kids / hotel / detail
gradesobj本市商圈评级计数 {S, A, B, C}
food / xiaocanarray§6 美食 / §7 小店候选(POI 记录,字段见下)
leisure / kidsobj§3 / §4:{"subcats": [{name, count}], "list": [POI]}
malls / specialties / hotelsarray§5 综合体商场 / §8 特产 / §10 酒店
assocarray§9 商圈×美食关联:{district, count, items: [{name, how, dist, rating, src}]}
queries / externalarray / obj§11 原始查询面统计 / 美团·大众点评城市外链
pagestr城市页相对地址 cities/<adcode>.html

POI 记录字段(各明细表内)

字段类型说明
markstr商圈携带标记,如 ✅A-;空 = 不属任何已评商圈
namestr店名 / 名称
substr细分 / 备注 / 载体类型 / 来源查询面(各节表头归一)
typestr高德多段类型串,; 分隔,首段为主类(如 餐饮服务;中餐厅;海鲜酒楼)
ratingnum高德快照评分 0–5,无评分为 null
avgnum人均消费(元),无则 null
addrstr地址
imgstr高德商家实拍图 URL,无图为空串

调用示例

# 1. 全量一次落地(约 51.3 MB,CDN 自动 gzip/br)
curl -s https://fun.worldstip.com/data.json -o fun-data.json

# 2. Python 流式读取,只保留目标城市
import json, urllib.request
with urllib.request.urlopen("https://fun.worldstip.com/data.json") as r:
    d = json.load(r)
yy = next(c for c in d["cities"] if c["city"] == "岳阳市")
print(yy["poi_total"], yy["grades"], len(yy["food"]))

# 3. 只要某省汇总 / 某城商圈 S 级
curl -s https://fun.worldstip.com/data.json | jq '.provinces[] | select(.province=="湖南省")'
curl -s https://fun.worldstip.com/data.json | jq '.cities[] | select(.city=="岳阳市") | .districts[] | select(.grade=="S")'

# 4. 全国美食榜前 10(评分降序,已剔住宿业主导 POI)
curl -s https://fun.worldstip.com/data.json | jq '.food_top[:10]'

# 5. 带图美食(jq 过滤 img 非空)
curl -s https://fun.worldstip.com/data.json | jq '[.cities[] | select(.city=="岳阳市") | .food[] | select(.img != "")][:10]'

# 6. 人类可读全量 Markdown(LLM / skill 直读)
curl -s https://fun.worldstip.com/data.md -o fun-data.md

使用约定

一致性承诺:data.json 与 data.md 由同一数据层(build_api.py)从 data/ 源档案一次生成,同源同值;任一字段都能在 data.md 对应城市档案中找到出处。