사주(四柱) API
하나의 출생 순간을 고전 체계 전체로: 사주, 각 지지가 품은 천간, 납음, 십이운성, 여덟 글자 전체의 오행 균형, 이름 있는 격국 기반 강약 판정, 신살, 그리고 지지와 천간의 상호작용까지. 한 번의 호출, JSON 출력, 21개 언어 지원.
사주(四柱) API
이 endpoint는 날짜 표가 아니라 역법 데이터에서 정확한 입춘과 節의 순간을 계산해 출생을 확정하므로, 경계 하루 안팎의 출생도 올바른 연도와 월에 배치된다. 일주와 시주는 출생지 시계를 따르며 23:00에 넘어간다. 이 네 기둥에서 지지를 열어 각각 하나에서 세 개의 지장간을, 전통이 부여한 역할과 가중치와 함께 꺼낸다 - 차트의 오행 대부분이 실제로 있는 곳이다. 이어서 각 기둥의 납음, 일간의 각 지지에 대한 십이운성, 세 가지 별도의 오행 집계, 세 가지 고전 기준을 가중치 없이 보고하는 扶抑 강약 판독, 연주와 일주 두 기준으로 계산한 여섯 가지 신살, 그리고 존재하는 모든 합·충·해·형을 도출한다.
POST/v1/bazi/chart
curl -X POST https://api.astroway.info/v1/bazi/chart \
-H "X-Api-Key: aw_live_..." \
-H "Content-Type: application/json" \
-d '{
"date": "1990-05-15",
"time": "14:30:00",
"timezoneOffset": 8,
"language": "en"
}' {
"ok": true,
"data": {
"solarYear": 1990,
"pillars": [
{ "name": "year", "pillar": "Geng-Wu", "animalName": "Horse", "stemElementName": "Metal" },
{ "name": "month", "pillar": "Xin-Si", "animalName": "Snake", "stemElementName": "Metal" }
],
"dayMaster": { "stem": "Geng", "element": "Metal", "polarity": "Yang" },
"elementBalance": {
"weighted": { "Wood": 0.4, "Fire": 1.6, "Earth": 1.6, "Metal": 3.3, "Water": 1.1 },
"missingElements": []
},
"strength": { "verdict": "strong", "supportRatio": 0.557, "hasSeason": false, "hasRoot": true },
"symbolicStars": { "byDayPillar": [ { "english": "Canopy", "pillars": ["day"] } ] },
"interactions": [ { "english": "Six Harmony", "members": ["Wu","Wei"], "producesElement": "Earth" } ]
}
} Parameters
| name | type | Required | |
|---|---|---|---|
| date | string (YYYY-MM-DD) | yes | Birth date. |
| time | string (HH:MM:SS) | no | Local clock time at birth. Without it there is no hour pillar and the analysis runs on six characters, which every field of the response says. |
| timezoneOffset | number (hours) | no | The UTC offset the clock was actually running on. A 1988 Beijing birth ran on +9 under summer time; no arithmetic recovers that from the date. |
| longitude | number | no | Birth longitude, east positive. Inert unless trueSolarTime is set. |
| trueSolarTime | boolean | no | Cut the double-hour from the sun over the birth place. Reaches the day and hour only: the year and month turn on world instants. |
| stageSchool | string | no | classical (陽順陰逆, default) or unified (陰陽同生同死) for the twelve life stages. |
| language | string | no | Any of 21 codes. Animals, elements, polarity and stage names come back translated; stems and branches stay in pinyin. |
When to use it
차트를 렌더링할 때 일곱 번 왕복하는 대신 이걸 써. 표 하나만 필요할 때는 옆에 있는 단일 목적 endpoint들이 있어. 사용자가 표준시 자오선에서 멀리 태어났다면 trueSolarTime과 함께 경도를 넘겨줘: 중국은 60도에 걸쳐 하나의 시간대를 쓰고, 카슈가르 출생은 태양 정오에서 거의 세 시간 어긋나 - 이건 해석에서 통째로 한 시진 차이야.
Notes
전승이 실제로 갈리는 곳에서는 두 해석을 모두 제공하고, 조용히 하나를 고르는 대신 응답에 그 분기를 명시한다: 십이운성에서 음간의 진행 방향, 두 양인 배치, 庚의 천을귀인, 午未 합의 오행, 그리고 강약 임계값 - 이는 정전의 규칙이 아니라 이 API의 관례다. 우리의 네 가지 관례 답변은 모든 응답의 고지문에 선언되어 있고, Jade Almanac CC0 검증 세트로 검증했으며, 결과는 관례 페이지에 있다.
Try the 사주(BaZi) 차트 API
Grab a key and make your first call in under a minute.