老黄历查询 - 即刻数据

v1.0.0

老黄历查询。输入阳历日期和时间,查询农历日期、黄历宜忌、黄黑道、吉神凶煞、生肖、星座、节气、喜神福神财神方位等信息。适用场景:用户说“查一下 2024-02-02 的老黄历”“今天宜忌是什么”“某天适合结婚搬家吗”等。数据由即刻数据(jikeapi.cn)开放接口提供。

0· 22· 1 versions· 0 current· 0 all-time· Updated 6h ago· MIT-0
byjikeapi@jikeapi-cn

老黄历查询 - 即刻数据

数据由 即刻数据 提供,帮助 AI 客户端快速接入可靠数据服务。

输入阳历日期和时间,查询:农历日期、黄历宜忌、黄黑道、吉神凶煞、生肖、星座、节气、喜神/福神/财神方位

前置配置

export JIKE_CALENDAR_LUNAR_QUERY_KEY=你的AppKey
# 或使用通用 Key
export JIKE_APPKEY=你的AppKey

使用方法

python3 scripts/calendar_lunar_query.py --date 2024-02-02
python3 scripts/calendar_lunar_query.py --date 2024-02-02 --time 10:30:00
python3 scripts/calendar_lunar_query.py --date 2024-02-02 --time 10:30:00 --json

直接调用 API:

GET https://api.jikeapi.cn/v1/calendar/lunar/detail?date=2024-02-02&time=10:30:00&appkey=YOUR_APPKEY

AI 使用步骤

  1. 从用户消息中提取阳历日期,格式化为 YYYY-MM-DD
  2. 如果用户提供时间,格式化为 HH:MM:SS;未提供时默认 00:00:00
  3. 执行 python3 scripts/calendar_lunar_query.py --date <日期> [--time <时间>]
  4. 返回农历、宜忌、黄黑道、节气、神位和节日信息。

返回字段

字段含义
solar_date公历日期时间
solar_full_string公历完整描述
lunar_string农历日期
lunar_full_string农历完整描述
lunar_day_yi当日宜
lunar_day_ji当日忌
lunar_day_tian_shen_type黄道/黑道
lunar_day_tian_shen_luck吉凶
lunar_day_position_xi喜神方位
lunar_day_position_fu福神方位
lunar_day_position_cai财神方位

脚本位置

scripts/calendar_lunar_query.py

Version tags

calendarvk97b1qcqjcm4qf92369jb09thd85sd0gjikeapivk97b1qcqjcm4qf92369jb09thd85sd0glatestvk97b1qcqjcm4qf92369jb09thd85sd0glunarvk97b1qcqjcm4qf92369jb09thd85sd0g

Runtime requirements

📅 Clawdis
Binspython3
EnvJIKE_CALENDAR_LUNAR_QUERY_KEY
Primary envJIKE_CALENDAR_LUNAR_QUERY_KEY