Перейти к основному содержимому
POST/api/astro/general_prediction/1 кредит

Общие предсказания

Текстовое толкование характера и жизни по натальной карте: темперамент лунного знака, что означает каждая из девяти планет в своём доме и что означает каждый из двенадцати управителей домов в доме, куда он попал. Это текстовый аналог /api/astro/chart_analysis/, который возвращает почти ту же структуру в виде данных. Текст взят из опубликованных источников — раздел о лунном знаке для одного толкования ссылается на «How to Judge a Horoscope» Б. В. Рамана, а для другого на второй источник, — поэтому одна и та же карта всегда даёт один и тот же текст. Передайте момент рождения, место и смещение UTC; других параметров нет. Всё возвращается HTML-фрагментами с жирными заголовками и переносами строк — их можно сразу вставлять на страницу. Обратите внимание: на этом эндпоинте поле смещения UTC называется `timezone`, а не `timezone_as_float`.

https://api.occultapi.com/api/astro/general_prediction/
Попробовать запрос

Аутентификация

Передавайте ключ в заголовке X-API-Key. Ключ — это серверные учётные данные: никогда не вставляйте его в JavaScript на стороне браузера или в мобильное приложение.

X-API-Key: yt_live_a1b2c3d4_…
Content-Type: application/json

Поля запроса

ПолеТипОбязательноПримечания
date_timestring (date-time)обязательный

Момент расчёта в формате ISO 8601. ВСЕГДА указывайте смещение или суффикс Z: значение без часового пояса интерпретируется как Asia/Kolkata (UTC+05:30), а не UTC, и может вернуть результат за предыдущий день со статусом 200. '2026-09-01T06:00:00Z' и '2026-09-01 06:00:00' — разные моменты, и ответы для них будут разными.

Ограничение ФОРМАТА. DRF DateTimeField: только ISO-8601 (входные форматы DRF по умолчанию), например "2026-09-01T06:00:00+05:30", "2026-09-01T06:00:00Z" или "2026-09-01 06:00:00" (без часового пояса подразумевается UTC).

keysarrayобязательный

Какие расчёты вернуть — списком названий. См. таблицу ключей этого эндпоинта; нераспознанное название отклоняет весь запрос. Один вызов стоит один кредит, сколько бы ключей вы ни запросили, поэтому запрашивайте всё нужное сразу, а не несколькими вызовами.

get_prediction_details

Массив строк; ключ здесь всего один.

latitudenumber (double)обязательный

Широта места в десятичных градусах. Положительные значения — север, отрицательные — юг. Пример: 26.9124 для Джайпура, 40.7128 для Нью-Йорка. Минуты и секунды не принимаются — сначала переведите значение в десятичные градусы.

min -90 · max 90

longitudenumber (double)обязательный

Долгота места в десятичных градусах. Положительные значения — восток, отрицательные — запад. Пример: 75.7873 для Джайпура, -74.0060 для Нью-Йорка. Следите за знаком: без минуса Нью-Йорк окажется в Китае.

min -180 · max 180

timezonenumber (double)обязательный

Смещение UTC для места, в часах, десятичным числом. Пример: 5.5 для Индии (UTC+05:30). По смыслу совпадает с timezone_as_float: другие эндпоинты называют это поле иначе.

Доступные ключи (1)

Перечислите в keys ровно те расчёты, которые вам нужны. Один неизвестный ключ — и отклоняется весь запрос. Сколько бы ключей вы ни запросили, спишется 1 кредит, так что собирайте их в один вызов.

КлючДоп. поляОписание
get_prediction_details—Полное текстовое толкование — объект из четырёх HTML-строк. 'Janma rasi_1' и 'Janma rasi_2' дают два независимых толкования умственных, физических и общих склонностей по лунному знаку; 'Planets' — толкование каждой из девяти планет в занимаемом ею доме с отсчётом от асцендента; 'Houses' — толкование каждого из двенадцати управителей домов в доме, где он находится. Каждое значение — один HTML-фрагмент с жирными подзаголовками.

Пример запроса

curl -X POST https://api.occultapi.com/api/astro/general_prediction/ \
  -H "X-API-Key: $OCCULT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"keys":["get_prediction_details"],"date_time":"2025-07-09T10:26:45.109Z","latitude":26.9124,"longitude":75.7873,"timezone":0}'

Ответ

{
  "_truncated": true,
  "_note": "Response shortened for the catalogue.",
  "preview": "{\"data\": {\"get_prediction_details\": {\"Janma rasi_1\": \"<html><b>General Predictions</b><br><b>Source: How to judge a horoscope - BV. Raman</b><br><b>Mental Tendencies</b><br>Those born in Sagittarius have an inclination for philosophy and occult studies. They can acquire great<br><b>Physical Tendencies</b><br>Persons born in this sign are generally inclined towards corpulence. They possess almond eyes and their hair is brown. They are usually good looking. Evenly set teeth, a happy smile, and fullness of the figure characterise the natives of Dhanus.<br><b>General Tendencies</b><br>They are of a phlegmatic temperament. They are too conventional and also businesslike. They are prompt and uphold conservative views. They are sympathetic and loving, and possess good foresight. At times they are restless and over-anxious. They are too callous and enthusiastic. They hate all external show. They are God-fearing, honest, humble and free from hypocrisy. They exercise strict control over their food and drinks and in regard to their relations with the opposite sex. They are prone to be misunderstood unintentionally by others. In late years they must be careful about their lungs as they are liable to suffer from rheumatic pains and the like.<br>\", \"Janma rasi_2\": \"<html><b>General Predictions</b><br><b>Source: ChinmayaAstrolger.com</b><br><b>Specific Characteristics</b><br> You will have a sober mind, good judgement and a quick intellect. But richness of intellect and lack of concern for method may lead you to profusion and disorder. You will have versatility and capacity of general work. You will have a few enemies - sort of jealous people - but will always remain a victor over the vanquished. You will have studies in the fields of arts, literature, law and philosophy. You will have restless activities of mind, together with the rich creative power. You will have much romance, fertile imagination and life in foreign / distant lands. These may conduce to high renown and give wealth and good fortune. You are likely to gain through an inheritance or a legacy. Your chief characteristics are philosophical and literary pursuits and in-depth researches of a scientific nature. You have a taste for lofty speculation and your strong passions are well-controlled. Your mind will be philosophical and the temperament sober. Although riches will be difficult to acquire in initial stages, riches are certain to you. You will have a few steadfast friends.<br><b>Mental Qualities</b><br>You will be inclined to philosophy and religion, eclectic. You will not have much of interest in the intricacies of analytical sciences. Rather than becoming a store-house of information, you will acquire the superior capacity to have a quick overview of varied circumstances. You will be just, frank, generous, magnanimous and even-tempered.<br><b>Physical Attributes</b><br> According to your Horoscope, you will have a tall, upright and well-proportioned figure. You will have an elongated face, rounded forehead with grey, brown or blue eyes - sparkling and expressive. You will have fair complexion and receding hairline balding about the temples. You will be of athletic building and will be fond of athletics and other expeditious activities.<br><b>General State of Health</b><br> Your zodiacal sign has governance over genito-urinary system, external generative organs, excretory system, cervix, coccyx and prostrate gland. These are your vulnerable areas. Elimination or disorder in connection with elimination will determine your remaining in desired state of health or suffering from disease. You should take special care and exercise fullest possible control over your intake of food and drink, and also over your arousal of strong passions - which may increase the level of toxins in the body. You should have plenty of sleep and should remain in a relaxed state of mind. You should take more of leeks, radishes, garlic, ginger and ginseng.Since the Ascendant has no affliction in your c"
}

Записано с реального вызова ровно с этим запросом. Результаты лежат в data под теми ключами, которые вы запросили.

Ошибки

Ошибки списания кредитов приходят в виде { "error": "…", "message": "<code>", "is_error": true }. Людям показывайте error, а логику стройте на message. Подробнее — в справочнике ошибок.