Перейти до вмісту
AstroWay/api v2.283.3 · docs
усі системи в нормі

Main door pada and its result

POST
/vastu/entrance
request.sh
curl -X POST https://api.astroway.info/v1/vastu/entrance \
-H "X-Api-Key: aw_live_..." \
-H "Content-Type: application/json" \
-d '{ "side": "N", "position": 0.45 }'

Which of the 32 outer padas a main door sits in, its deity in both schools, and the result Brihat Samhita 53.72-75 gives for a door there. Send the pada (N3) or the wall and the door centre as a fraction of it; two ways of fitting 8 doors onto a 9-cell wall are offered, and a door near a pada edge is flagged.

fields
string

Comma-separated dotted paths, relative to data, to keep in the response. A path is applied to every element of an array, so planets.name means the name of each planet. Paths that match nothing come back in _fields_unmatched; a list where nothing matches at all is a 400, because an empty object would be a confident wrong answer.

Example
planets.name,planets.longitude
precision
integer
<= 15

Round every non-integer number in the response to this many decimal places. Integers are left alone, because an id is not a measurement. Ecliptic longitudes ship with fourteen decimals by default; 2 is about a tenth of an arcminute.

Example
4
Media type application/json
object
side
string
Allowed values: E S W N
position
number
<= 1
pada
string
/^[NESW][1-8]$/
method
string
Allowed values: eight-per-side mandala-cells
Example
{
"side": "N",
"position": 0.45
}

Successful calculation

Media type application/json
object
ok
boolean
data
object
side
string
nullable
position
number
nullable
pada
string
nullable
devata
string
nullable
devataMayamata
string
nullable
effect
string
nullable
verdict
string
nullable
source
string
nullable
edgeDistance
number
nullable
method
string
nullable
warnings
Array
nullable
notes
Array<string>
nullable
Example
{
"ok": true,
"data": {
"side": "N",
"position": 4,
"pada": "N4",
"devata": "Bhallāṭa",
"devataMayamata": "Bhallāṭaka",
"effect": "Every virtue.",
"verdict": "auspicious",
"source": "Brihat Samhita, tr. N. Chidambaram Iyer (1884) 53.75",
"edgeDistance": 0.05,
"method": "eight-per-side",
"warnings": [],
"notes": [
"The verdict is our classification of the effect the verse states. Brihat Samhita and Mayamata name a few padas differently; devataMayamata gives the second name."
]
}
}

Validation error

Media type application/json
Example
{
"ok": false,
"error": {
"code": "INVALID_INPUT",
"message": "Validation failed: date: Date must be YYYY-MM-DD",
"details": [
{
"path": "date",
"message": "Date must be YYYY-MM-DD"
}
]
}
}

Missing or invalid API key

Media type application/json
Example
{
"ok": false,
"error": {
"code": "INVALID_API_KEY",
"message": "Invalid API key"
}
}