跳到主要内容

丰富版生活指数

全球支持,逐小时更新

curl "https://api.caiyunapp.com/v1/lifeindex/?token=TOKEN&lng=110.8840&lat=21.6594&fields=DressingIndex,WindColdIndex"
  • fields 可选参数见下方列表,默认为全部
lifeindex_sample.json
{
"status": "ok",
"result": {
"meta": {
"created_at": 1619078405
},
"$LifeIndex": [
{
"datetime": "2021-04-22T00:00+08:00",
"level": 1,
"desc": "适宜",
"detail": "描述..."
}
]
}
}

其中 $LifeIndex 支持类型如下:

  • AirConditionerIndex: 空调指数
  • AllergyIndex: 过敏指数
  • AnglingIndex: 钓鱼指数
  • AQIIndex: 空气污染扩散条件指数
  • BoatingIndex: 划船指数
  • CarWashingIndex: 洗车指数
  • ColdRiskIndex: 感冒指数
  • ComfortIndex: 舒适度指数
  • DatingIndex: 约会指数
  • DressingIndex: 穿衣指数
  • DrinkingIndex: 啤酒指数
  • DryingIndex: 晾晒指数
  • HairdressingIndex: 美发指数
  • HeatstrokeIndex: 中暑指数
  • KiteIndex: 放风筝指数
  • MakeUpIndex: 化妆指数
  • MoodIndex: 心情指数
  • MorningExerciseIndex: 晨练指数
  • NightLifeIndex: 夜生活指数
  • RainGearIndex: 雨具指数
  • RoadConditionIndex: 路况指数
  • ShoppingIndex: 逛街指数
  • SportIndex: 运动指数
  • TrafficIndex: 路况指数
  • TravelIndex: 旅游指数
  • UltravioletIndex: 紫外线指数/防晒指数
  • WashClothesIndex: 洗衣指数
  • WindColdIndex: 风寒指数
  • StreetStallIndex: 摆摊指数
  • TakeoutIndex: 送外卖指数
  • CyclingIndex: 骑行指数

meta 字段用于描述一些基本元数据,目前 created_at 表示当前请求的生活指数数据的生成时间