API简介:输入出生日期和时间,返回西方星座、中国生肖、农历日期与生辰八字(年柱/月柱/日柱/时柱),支持公历与农历两种输入方式

接口问题联系相关负责人沟通修复:查看该接口开发者

接口地址:https://yunshangtool.cn/api/birth/analysis

返回格式:JSON

请求方式:GET

请求参数:https://yunshangtool.cn/api/birth/analysis?calendar=solar&year=1997&month=11&day=12&time=21:10&dayBoundary=zi

注:单纯检测接口是否可调通,返回的数据请自行检查

检测接口中...(检测服务是否可用)


状态码 累计次数 最后检测时间
正常 2 2026-03-11 16:17:13
故障 0 0000-00-00 00:00:00

您好!我们的平台聚合了上千位开发者提供的免费接口,我们已尽力确保接口的稳定性,但由于无法控制其他开发者的接口,可能会出现不稳定或服务中断的情况。对此,我们深感抱歉!我们正在积极改善这一问题,感谢您的理解与支持。
1. 由于开发者可能因盈利问题导致接口失效,我为此向您道歉
2. 我们竭尽全力改进平台的接口稳定性。
3. 为便于您使用,我们提供了智能生成对接代码和在线极速测试接口的功能。
4. 我们将继续努力提供更多可靠的接口,满足您的需求。
5. 若有任何问题,欢迎通过微信与我联系:13132131321。再次感谢您的支持与信任!


接口注意:接口故障请及时反馈,修复进度将通过短信通知。

非官方接口,请联系开发者获取技术支持

Bug修复:非官方接口,Bug反馈请联系开发者

会员线路:因调用量剧增,定制独享优质线路请 参考定制方案

专属线路 成本透明 0服务费

请求参数

接口名称 是否必填 接口类型 接口说明
calendar string solar(默认) 或 lunar
datetime string 公历输入,ISO时间,如 1999-07-16T08:30:00+08:00
date string 公历日期,YYYY-MM-DD
year int 公历年(与 month/day/time 组合)
month int 公历月(1-12)
day int 公历日
time int HH:mm 或 HH:mm:ss,默认 00:00:00
lunarYear int 农历年(calendar=lunar 时必填)
lunarMoth int 农历月(1-12,calendar=lunar 时必填)
lunarDay int 农历日(1-30,calendar=lunar 时必填)
isLeapMonth int 农历闰月标记,不传自动判定
dayBoundary string 换日规则:zi(默认) 或 midnight

返回示例

{
    "success": true,
    "data": {
        "input": {
            "birthDateTime": "1997-11-12 21:10:00",
            "timezone": "Asia\/Shanghai (UTC+08:00)",
            "timestamp": 879340200000
        },
        "westernZodiac": {
            "name": "天蝎座",
            "element": "水象",
            "dateRange": "10\/24-11\/22"
        },
        "chineseZodiac": {
            "animal": "牛",
            "lunarYear": 1997,
            "ganZhiYear": "丁丑"
        },
        "lunarDate": {
            "year": 1997,
            "monthNumber": 10,
            "monthName": "十月",
            "dayNumber": 13,
            "dayName": "十三",
            "isLeapMonth": false
        },
        "bazi": {
            "yearPillar": "丁丑",
            "monthPillar": "辛亥",
            "dayPillar": "戊午",
            "hourPillar": "癸亥",
            "eightCharacters": "丁丑 辛亥 戊午 癸亥",
            "dayMaster": "戊",
            "dayBoundary": "zi",
            "convention": "子初换日(23:00-00:59 视作次日)",
            "seasonBoundary": {
                "previous": {
                    "solarTerm": "立冬",
                    "monthNumber": 10,
                    "dateTimeCST": "1997-11-08 00:30:19"
                },
                "next": {
                    "solarTerm": "大雪",
                    "monthNumber": 11,
                    "dateTimeCST": "1997-12-07 16:47:19"
                }
            }
        },
        "meta": {
            "rawInput": "21:10",
            "dayBoundary": "zi",
            "calendar": "solar",
            "convertedSolarDate": "1997-11-12 21:10:00",
            "resolvedIsLeapMonth": null,
            "lunarResolution": null
        }
    }
}

返回参数

接口名称 接口类型 接口说明

开发者未填写此数据,无法生成 JSON 示例,请参考小白对接

小白教程

本教程帮助用户快速对接日期获取星座和生辰八字接口,现已支持智能生成代码

实时调试

部分视频、图片或其他接口报错、空值并不代表无法对接,请在本地尝试请求参数接口

在线调试

温馨提示:请修改请求参数,未修改可能返回报错

参数名称 参数值(修改后测试)
{
  "success": true,
  "data": {
    "input": {
      "birthDateTime": "1997-11-12 21:10:00",
      "timezone": "Asia/Shanghai (UTC+08:00)",
      "timestamp": 879340200000
    },
    "westernZodiac": {
      "name": "天蝎座",
      "element": "水象",
      "dateRange": "10/24-11/22"
    },
    "chineseZodiac": {
      "animal": "牛",
      "lunarYear": 1997,
      "ganZhiYear": "丁丑"
    },
    "lunarDate": {
      "year": 1997,
      "monthNumber": 10,
      "monthName": "十月",
      "dayNumber": 13,
      "dayName": "十三",
      "isLeapMonth": false
    },
    "bazi": {
      "yearPillar": "丁丑",
      "monthPillar": "辛亥",
      "dayPillar": "戊午",
      "hourPillar": "癸亥",
      "eightCharacters": "丁丑 辛亥 戊午 癸亥",
      "dayMaster": "戊",
      "dayBoundary": "zi",
      "convention": "子初换日(23:00-00:59 视作次日)",
      "seasonBoundary": {
        "previous": {
          "solarTerm": "立冬",
          "monthNumber": 10,
          "dateTimeCST": "1997-11-08 00:30:19"
        },
        "next": {
          "solarTerm": "大雪",
          "monthNumber": 11,
          "dateTimeCST": "1997-12-07 16:47:19"
        }
      }
    },
    "meta": {
      "rawInput": "21:10",
      "dayBoundary": "zi",
      "calendar": "solar",
      "convertedSolarDate": "1997-11-12 21:10:00",
      "resolvedIsLeapMonth": null,
      "lunarResolution": null
    }
  }
}