The birth input, field by field
| Field | Type | Rule | Example |
|---|---|---|---|
date | string | YYYY-MM-DD, the LOCAL calendar date | "1973-04-24" |
time | string | HH:MM or HH:MM:SS, 24-hour, LOCAL | "17:25:00" |
tz_offset_minutes | integer | -840..840, east-positive | 330 |
lat | number | -90..90, north-positive | 19.076 |
lng | number | -180..180, east-positive | 72.8777 |
The schema is strict: any field it does not declare is rejected with 400 VALIDATION_ERROR, not ignored. That is deliberate - a silently dropped ayanamsa or timezone field would return a chart computed under assumptions you did not ask for. The builder warns before you hit it.
Endpoints that take more than a birth
Many endpoints add their own fields next to the five birth fields: division for a varga chart, levels for dasha depth, house_system for Western houses, year for Varshphal, transit_at for transits. The builder pre-fills those from the endpoint's own sample request - the payload the playground sends upstream - and lists every other field the endpoint accepts, marking the required ones.
A few endpoints (muhurta and other day-level calculations) take a date and a place but no time; the builder drops time for those. Couple endpoints (person_a, person_b) nest two birth inputs and are not covered here - build each person with this tool and wrap them.
What comes back
Every success response is the same envelope:
{
"request_id": "...",
"data": { },
"interpretation": null,
"meta": { "engine_version": "...", "computed_at": "..." }
}Your result is always under data. The Node and Python snippets destructure it for you. Errors use { request_id, error: { code, message, details } } instead; paste either into the response explorer to see what each field means.
Common mistakes
- Sending a UTC time with a local offset.
timeis the local wall-clock time; the API does the UTC conversion with your offset. Converting first and then sendingtz_offset_minutes: 330shifts the chart by 5.5 hours. - Numbers as strings.
"lat": "19.07"fails validation; send JSON numbers. - Single-digit parts.
"7:05"and"1973-4-24"fail the patterns. Pad to07:05and1973-04-24. - Coordinates rounded too hard. Four decimal places of latitude is about 11 m and two is about 1 km, both fine. One decimal (about 11 km) or a region's centre instead of the town shifts the ascendant measurably.
- Putting the key in client code. The snippets read
ASTRONODE_API_KEYfrom the environment. Call the API from your server, never from a browser or mobile bundle.
FAQ
- Can I choose the ayanamsa or zodiac in the request?
- No. Each endpoint family uses its tradition's convention (Lahiri for Vedic, KP-Newcomb for
/v1/kp/*, tropical for Western) and reports it in the response. See the ayanamsa calculator. - Are seconds required in
time? - No -
HH:MMandHH:MM:SSare both accepted. The builder always sends seconds so the body is unambiguous. - Which keys do the snippets use?
- The curl uses an
aie_test_placeholder and the code readsASTRONODE_API_KEYfrom the environment. Test keys come with every account; live keys need a paid plan.