Get Chinese Astrology

v1.0.1
com.getchineseastrology/get-chinese-astrology Checked 3 days ago Published 24 days ago

BaZi, zodiac year, compatibility, five elements, Kua, I Ching, Zi Wei and Flying Stars charts.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

get_bazi_chart BaZi chart

Calculates the Four Pillars (BaZi) chart for a birth date, an optional birth time and the birthplace time zone. Returns the year, month, day and hour pillars, the Day Master, each stem's Ten Gods relation to it, the hidden stems in each branch and the five-element count.

ParameterTypeDescription
birthDate *stringBirth date as YYYY-MM-DD, from 1901-02-19 to 2100-02-08.
timestringLocal birth time as HH:MM on a 24-hour clock. Without it the chart has no hour pillar and is read at midday.
timeZonestringIANA time zone of the birthplace, such as Asia/Shanghai, Asia/Tokyo or America/New_York. Asia/Shanghai when absent.

get_zodiac_year Chinese zodiac year

Returns the Chinese zodiac year for a birth date or a calendar year: the animal, Heavenly Stem, element, yin or yang, the Chinese New Year dates that open and close the year and the Li Chun date. A birth date also reports whether Chinese New Year and Li Chun give different animals.

ParameterTypeDescription
datestringBirth date as YYYY-MM-DD, from 1901-02-19 to 2100-02-08. The year can be given instead.
yearintegerZodiac year from 1901 to 2099, opened by Chinese New Year of that year. The date can be given instead.

check_animal_compatibility Animal compatibility

Compares two Chinese zodiac animals, or the animals of two birth years, and names their relationship: Six Harmony, Three Harmony, clash, harm, break, punishment or neutral. Returns the relation types, the phase interaction, the distance on the twelve-animal circle and a written reading of the pair.

ParameterTypeDescription
firstAnimalstringFirst zodiac animal, paired with secondAnimal.
firstYearintegerFirst birth year from 1901 to 2100, paired with secondYear.
secondAnimalstringSecond zodiac animal, paired with firstAnimal.
secondYearintegerSecond birth year from 1901 to 2100, paired with firstYear.

count_five_elements Five elements count

Counts Wood, Fire, Earth, Metal and Water across the visible characters of the Four Pillars chart for a birth date, with an optional birth time and UTC offset. Returns each count with its relation to the Day Master, the leading element, the elements missing from view and the Day Master.

ParameterTypeDescription
date *stringBirth date as YYYY-MM-DD, from 1901-02-19 to 2100-02-08.
timestringLocal birth time as HH:MM on a 24-hour clock. Without it the count covers six characters instead of eight.
utcOffsetstringFixed UTC offset of the birthplace as +HH:MM or -HH:MM, used for solar-term boundaries. +08:00 when absent.

get_kua_number Kua number

Returns the feng shui Kua number for a birth date and calculation table: its trigram, element, East or West group, and the four favourable and four unfavourable directions. Birthdays before Chinese New Year use the preceding Chinese year.

ParameterTypeDescription
birthDate *stringBirth date as YYYY-MM-DD, from 1901-02-19 to 2099-12-31.
formula *stringCalculation table: male or female.

cast_i_ching I Ching reading

Reads an I Ching hexagram from six line values, bottom line first: 6 is a changing Yin line, 7 a Yang line, 8 a Yin line and 9 a changing Yang line. Without line values it makes a random three-coin cast. Returns the primary and relating hexagrams, the changing lines and their classical texts.

ParameterTypeDescription
linesarraySix line values from 6 to 9, bottom line first. A cast is made when absent.

get_zi_wei_chart Zi Wei Dou Shu chart

Builds a Zi Wei Dou Shu chart for a birth date, a birth time and a traditional calculation table. Returns the lunar date, the Five Element bureau, the Life and Body palace branches and the major stars with their brightness and transformations in each of the twelve palaces.

ParameterTypeDescription
birthDate *stringBirth date as YYYY-MM-DD, from 1900-01-01 to 2099-12-31.
gender *stringTraditional calculation table: male or female.
time *stringLocal birth time as HH:MM on a 24-hour clock.

get_flying_stars Annual flying stars

Returns the annual Flying Stars chart for a year: the star in each of the nine palaces, the centre star and the moment Li Chun begins the year. The grid has south at the top.

ParameterTypeDescription
year *integerYear from 1900 to 2099.