OneBhakthi API docs

Everything you need to read the Bhagavad Gita, the Panchang and daily horoscopes from your own app or website.

Getting started

All calls go to https://www.onebhakthi.org/api/v1 and return JSON. Every call needs a key.

  1. Get a free key. Sign in with Google and it appears in under a minute.
  2. Send it in the X-API-Key header.
  3. Make your first call.
Your first call
curl "https://www.onebhakthi.org/api/v1/gita/2/47?lang=en" \
  -H "X-API-Key: ob_live_your_key"

Your API key

A key looks like ob_live_…. Send it in the X-API-Key header, never in the web address, so it does not end up in logs or browser history.

  • We show a key once, when you make it. We keep only a scrambled copy, so we cannot show it again.
  • You can make a key for each app, and revoke any of them from your dashboard. A revoked key stops working at once.
  • Keep keys out of code you publish. If a key leaks, revoke it and make a new one.
  • Calls from a browser tell us the website address they came from. Calls from servers and mobile apps do not. Our own systems never store IP addresses.

Limits and plans

A key on the Free plan gets 5,000 calls a day, which resets at midnight UK time, and 120 calls a minute. That is plenty for an app. Calls that fail on our side (a 5xx error) are given back and do not count. If you need more, or your product earns money, see the plans. Whole chapters come back in one call with /gita/{chapter}, which is kinder to your limit than 78 separate verse calls.

Every response tells you where you stand.

HeaderMeaning
X-RateLimit-LimitYour calls per day
X-RateLimit-RemainingCalls left today
X-RateLimit-ResetSeconds until the daily count resets
Retry-AfterOn a 429, how many seconds to wait

Responses can be cached by your own app for a few minutes, because the text does not change. Fair use is simple: no scraping the whole text to republish it as your own, and credit the translators shown in each response.

Errors

Errors always look the same, and never include anything about our systems.

{
  "error": {
    "code": "daily_limit",
    "message": "This key has reached its daily limit. It resets at midnight UK time."
  }
}
StatusCodeWhat it means
400bad_requestSomething in the request is wrong: a language we do not have, a search that is too short or too long, a number out of range. The message says which.
401missing_keyNo key was sent. Use the X-API-Key header.
401invalid_keyThe key is wrong or malformed.
401key_revokedThe key was revoked. Make a new one on your dashboard.
403key_suspendedWe have paused the key. Please contact us.
404not_foundNo such chapter or verse.
413, 415payload_too_large, unsupported_media_typeA POST body that is too big, or not sent as JSON with Content-Type: application/json.
422no_sunriseA sunrise-based Panchang cannot be worked out because the Sun does not rise or set that day at that place (near the poles).
429rate_limitedToo many calls in a minute. Wait for Retry-After seconds.
429daily_limitThe key used up its calls for today. It resets at midnight UK time.
502, 503upstream_error, unavailable, reading_not_readyA problem on our side, or no horoscopes are stored yet. Try again shortly. These calls are not counted against your limit.

Gita API

The Bhagavad Gita: 18 chapters and 701 verses, each with its Sanskrit, who speaks it, and translations in English, Tamil and Hindi. Pick the languages with lang: en, ta, hi, several separated by commas (lang=ta,en), or lang=all. English is the default.

Chapters

GET/api/v1/gita/chapters

The 18 chapters with their verse counts and chapter names (Tamil names and introductions today).

Example response
{
  "chapters": [
    {
      "chapter": 1,
      "verse_count": 47,
      "names": [ { "lang": "ta", "name": "அர்ஜுன விஷாத யோகம்", "situation": "…", "source": "Subramania Bharati" } ]
    },
    …
  ],
  "attribution": "Texts: Tamil by Subramania Bharati (public domain). Served by OneBhakthi API."
}

A whole chapter

GET/api/v1/gita/{chapter}
ParameterWhereWhat it does
chapterpath1 to 18
langqueryLanguages, comma separated. Default en
X-API-KeyheaderYour key

Returns verse_count, the chapter names, and every verse in order, each shaped like the single verse below.

Get a verse

GET/api/v1/gita/{chapter}/{verse}

Returns one verse with its Sanskrit, the speaker and the translations you ask for.

ParameterWhereWhat it does
chapterpath1 to 18
versepathVerse number in that chapter
langqueryLanguages, comma separated: en, ta, hi, or all. Default en
X-API-KeyheaderYour key
Example response
{
  "chapter": 2,
  "verse": 47,
  "speaker": "krishna",
  "sanskrit": "कर्मण्येवाधिकारस्ते मा फलेषु कदाचन । …",
  "translations": [
    {
      "lang": "ta",
      "text": "தொழில் செய்யத்தான் உனக்கு அதிகாரமுண்டு. …",
      "source": "Subramania Bharati"
    },
    {
      "lang": "en",
      "text": "Thy business is with the action only, never with its fruits; …",
      "source": "Annie Besant and Bhagavan Das (1922)"
    }
  ],
  "attribution": "Texts: Sanskrit as printed in the Besant and Bhagavan Das edition (1922, public domain); Tamil by Subramania Bharati (public domain); English by Annie Besant and Bhagavan Das (1922, public domain). Served by OneBhakthi API."
}

speaker is one of krishna, arjuna, sanjaya or dhritarashtra. If a language you asked for has no text for that verse, it is listed in unavailable and the rest still comes back:

{
  "chapter": 18,
  "verse": 49,
  "speaker": "krishna",
  "sanskrit": "असक्तबुद्धिः सर्वत्र …",
  "translations": [ { "lang": "en", "text": "He whose Reason is everywhere unattached, …", "source": "…" } ],
  "unavailable": ["ta"],
  "attribution": "…"
}

Try it

Languages

Stays in this page only and is sent only to OneBhakthi. The call counts towards your daily limit.

Request: GET /api/v1/gita/2/47?lang=en,ta

GET/api/v1/gita/search?q=duty&lang=en

Finds verses whose translation contains your words. Searches one language at a time.

ParameterWhereWhat it does
qqueryThe words to find, 2 to 80 characters
langqueryOne of en, ta, hi. Default en
limitquery1 to 50. Default 20
offsetquery0 to 1000, for the next page. Default 0
Example response
{
  "query": "duty",
  "lang": "en",
  "count": 1,
  "results": [
    {
      "chapter": 2,
      "verse": 7,
      "lang": "en",
      "text": "My heart is weighed down with the vice of faintness; my mind is confused as to duty. …",
      "source": "Annie Besant and Bhagavan Das (1922)"
    }
  ],
  "attribution": "Texts: English by Annie Besant and Bhagavan Das (1922, public domain). Served by OneBhakthi API."
}

Search words are used to find results and then forgotten. We do not store them.

Languages and sources

GET/api/v1/gita/sources

Every response names its sources. Here is the full list.

TextSourceVersesNotes
Sanskrit and EnglishAnnie Besant and Bhagavan Das, The Bhagavad-Gita, 4th edition, 1922. Public domain.701This edition counts 35 verses in Chapter 13, one more than the usual 34.
TamilSubramania Bharati (Bharathiar). Public domain.697Exactly as printed. The book has no text for 13.35, 18.49, 18.58 or 18.61. Chapter names and introductions are in Tamil.
HindiMachine translation of the English above, checked verse by verse.701There is no printed Hindi edition behind it. Every response says so.

Please credit the translators shown in each response. A line such as “Powered by OneBhakthi API” with a link is welcome, and never required.

Astrology API

The Panchang, moon dates, birth signs and daily horoscopes, in English, Tamil and Hindi. Everything except the horoscopes is worked out from the real positions of the Sun and Moon, for any place on Earth and any date from 1900 to 2100. Nothing is looked up, and nothing you send is stored.

EndpointWhat it gives you
GET /astrology/panchangThe day: tithi, nakshatra, yoga, karana, sunrise and sunset, Rahu Kalam and more
GET /astrology/moonMoon phase, coming Ekadashi, Purnima and Amavasya, Mercury retrograde
POST /astrology/birthSun sign, Moon sign and birth nakshatra from a birth date, time and place
GET /astrology/horoscopeThe daily or weekly reading for a sign, written by OneBhakthi AI

How every Astrology call works

  • Place. Send lat and lon in degrees, with east and north positive. We work out the time zone from them. Send timezone, for example Europe/London, if you want to choose it. Two decimal places (about 1 km) is plenty, so please do not send more than you need.
  • Dates. Written 2026-10-06, meaning that calendar day at the place. If you leave date out, you get today at the place.
  • Times. Every time is written with its local offset, rounded to the minute, such as 2026-10-06T07:09:00+01:00. A time after midnight carries the next day's date.
  • Languages. lang=en (default), ta or hi. English uses the usual spellings (Ekadashi, Ashlesha). Tamil and Hindi use their own script. Fields such as number and key never change with the language, so use those in code.
  • Sunrise to sunrise. A Hindu day runs from one sunrise to the next. The tithi, nakshatra, yoga and karana of the day are the ones in force at sunrise, and each comes with the exact time it ends. That is how the published panchangs do it.
  • Ayanamsha. Lahiri (Chitrapaksha), the official Indian value.

Panchang

GET/api/v1/astrology/panchang?lat=51.5074&lon=-0.1278&date=2026-10-06
ParameterWhereWhat it does
latqueryLatitude, -90 to 90. Required
lonqueryLongitude, -180 to 180, east positive. Required
datequeryThe day, 1900-01-01 to 2100-12-31. Default: today at the place
timezonequeryA time zone name. Default: worked out from lat and lon
langqueryen, ta or hi. Default en
Example response (shortened)
{
  "date": "2026-10-06",
  "lang": "en",
  "place": { "lat": 51.5074, "lon": -0.1278, "timezone": "Europe/London", "utc_offset": "+01:00" },
  "ayanamsha": { "name": "lahiri", "degrees": 24.2309 },
  "weekday": { "number": 2, "name": "Tuesday", "ruler": { "key": "mars", "name": "Mars" } },
  "sun": {
    "sunrise": "2026-10-06T07:09:00+01:00",
    "sunset": "2026-10-06T18:27:00+01:00",
    "next_sunrise": "2026-10-07T07:11:00+01:00",
    "sign": { "number": 6, "name": "Kanya", "western": "Virgo" }
  },
  "moon": {
    "moonrise": "2026-10-07T03:11:00+01:00",
    "moonset": "2026-10-06T16:51:00+01:00",
    "sign": { "number": 4, "name": "Karka", "western": "Cancer" },
    "signs": [ { "number": 4, "name": "Karka", "start": "…", "end": "2026-10-06T17:48:00+01:00", "at_sunrise": true }, … ]
  },
  "tithi": {
    "number": 11, "lunar_day": 26, "name": "Ekadashi",
    "paksha": { "key": "krishna", "name": "Krishna" },
    "start": "2026-10-05T21:38:00+01:00",
    "end": "2026-10-06T20:05:00+01:00",
    "at_sunrise": true
  },
  "tithis": [ { "name": "Ekadashi", "at_sunrise": true, … }, { "name": "Dwadashi", "at_sunrise": false, … } ],
  "nakshatra": {
    "number": 9, "name": "Ashlesha",
    "lord": { "key": "mercury", "name": "Mercury" },
    "start": "2026-10-05T18:40:00+01:00",
    "end": "2026-10-06T17:48:00+01:00",
    "at_sunrise": true
  },
  "nakshatras": [ … ],
  "yoga": { "number": 22, "name": "Sadhya", "start": "…", "end": "2026-10-07T00:31:00+01:00", "at_sunrise": true },
  "yogas": [ … ],
  "karana": { "number": 51, "name": "Bava", "start": "…", "end": "2026-10-06T08:50:00+01:00", "at_sunrise": true },
  "karanas": [ … ],
  "month": {
    "amanta": { "number": 6, "name": "Bhadrapada", "adhika": false },
    "purnimanta": { "number": 7, "name": "Ashvina", "adhika": false }
  },
  "samvat": { "shaka": 1948, "vikram": 2083 },
  "season": { "ritu": { "number": 3, "name": "Varsha" }, "ayana": { "key": "dakshinayana", "name": "Dakshinayana" } },
  "periods": {
    "rahu_kalam": { "start": "2026-10-06T15:38:00+01:00", "end": "2026-10-06T17:02:00+01:00" },
    "yamagandam": { "start": "…", "end": "…" },
    "gulika_kalam": { "start": "…", "end": "…" },
    "abhijit_muhurta": { "start": "2026-10-06T12:26:00+01:00", "end": "2026-10-06T13:11:00+01:00", "applicable": true },
    "choghadiya": [ { "key": "rog", "name": "Rog", "nature": "inauspicious", "start": "…", "end": "…" }, … ]
  },
  "attribution": "Computed by OneBhakthi from the positions of the Sun and Moon, using the Lahiri ayanamsha. Served by OneBhakthi API."
}
FieldWhat it is
tithi, nakshatra, yoga, karanaThe one in force at sunrise, with the times it starts and ends. The start can be the evening before.
tithis, nakshatras, yogas, karanasEvery one that runs during the day, in order. The first has at_sunrise true. The last can end after the next sunrise.
tithi.number1 to 15 within the half of the month (paksha), the way tithis are named. lunar_day is 1 to 30 across the whole month.
moon.signsThe Moon's sign during the day, the same way. sun.sign is the Sun's sidereal sign at sunrise.
monthThe lunar month counted both ways: amanta (new moon to new moon) and purnimanta (full moon to full moon). adhika is true in an extra month.
samvatShaka and Vikram years, both starting at Chaitra.
seasonThe Vedic ritu, from the lunar month (Chaitra and Vaishakha are Vasanta, and so on), and the ayana, from the Sun's sidereal sign.
periodsRahu Kalam, Yamagandam, Gulika Kalam, Abhijit Muhurta and the eight daytime Choghadiya periods, each as start and end.
  • moonrise and moonset are the first of each between this sunrise and the next, or null if there is none. They use the centre of the Moon at the horizon, as Drik Panchang does.
  • Many traditions do not use Abhijit Muhurta on a Wednesday. We still give the times, with applicable set to false.
  • Near the poles there are days with no sunrise or no sunset. Then a sunrise-based Panchang cannot be worked out and you get a 422 with the code no_sunrise.

Moon and observances

GET/api/v1/astrology/moon?lat=51.5074&lon=-0.1278&days=45
ParameterWhereWhat it does
lat, lonqueryThe place. Required
datequeryStart day. Default: today at the place. The phase is for midday that day (for this moment if you send no date)
daysqueryHow many days of observances to list, 1 to 120. Default 45
timezone, langqueryAs for the Panchang
Example response (shortened)
{
  "date": "2026-10-06",
  "lang": "en",
  "place": { "lat": 51.5074, "lon": -0.1278, "timezone": "Europe/London", "utc_offset": "+01:00" },
  "at": "2026-10-06T12:00:00+01:00",
  "phase": { "key": "waning_crescent", "name": "Waning Crescent", "illumination": 0.195, "age_days": 25.31 },
  "next_new_moon": "2026-10-10T16:51:00+01:00",
  "next_full_moon": "2026-10-26T04:11:00+00:00",
  "observances": [
    {
      "type": "ekadashi",
      "tithi": { "number": 11, "name": "Ekadashi", "paksha": { "key": "krishna", "name": "Krishna" } },
      "date": "2026-10-06",
      "sunrise_dates": ["2026-10-06"],
      "starts": "2026-10-05T21:38:00+01:00",
      "ends": "2026-10-06T20:05:00+01:00",
      "month": {
        "amanta": { "number": 6, "name": "Bhadrapada", "adhika": false },
        "purnimanta": { "number": 7, "name": "Ashvina", "adhika": false }
      }
    },
    { "type": "amavasya", "date": "2026-10-10", … },
    { "type": "ekadashi", "date": "2026-10-22", … },
    { "type": "purnima", "date": "2026-10-25", … }
  ],
  "mercury_retrograde": {
    "active": false,
    "current": null,
    "next": { "starts": "2026-10-24T08:15:00+01:00", "ends": "2026-11-13T15:53:00+00:00" }
  },
  "attribution": "…"
}
  • phase names are in English. Use key for your own labels.
  • observances lists every Ekadashi, Purnima and Amavasya in the period. starts and ends are when the tithi begins and ends. For Purnima and Amavasya, ends is the moment of the full moon or new moon.
  • date is the first day on which the tithi is in force at sunrise. sunrise_dates lists all such days. Usually that is one. Sometimes a long tithi covers two sunrises, and traditions then choose by their own rule, for example Smarta and Vaishnava Ekadashi. When a tithi begins and ends between two sunrises, the list is empty and date is the day it begins. We give you the facts. Your own tradition's rule picks the day.
  • mercury_retrograde says whether Mercury is moving backwards now, and gives the start and end of this period and of the next.

Birth basics

POST/api/v1/astrology/birth

Sun sign, Moon sign and birth nakshatra. Birth details are personal, so they go in the request body and never in the web address.

FieldWhat it does
dateDate of birth, written 1990-05-14. Required
timeTime of birth on a 24-hour clock, written 06:30. Optional, see below
lat, lonPlace of birth, as numbers. Required
timezoneTime zone name. Default: worked out from the place, with its history (daylight saving, old standard times)
langen, ta or hi. Default en
Request
curl -X POST "https://www.onebhakthi.org/api/v1/astrology/birth" \
  -H "X-API-Key: ob_live_your_key" \
  -H "Content-Type: application/json" \
  -d '{ "date": "1990-05-14", "time": "06:30", "lat": 13.0827, "lon": 80.2707 }'
Example response (shortened)
{
  "lang": "en",
  "birth": { "time_given": true, "timezone": "Asia/Kolkata", "utc_offset": "+05:30" },
  "ayanamsha": { "name": "lahiri", "degrees": 23.7225 },
  "sun_sign": {
    "vedic": { "number": 1, "name": "Mesha", "western": "Aries" },
    "western": { "number": 2, "name": "Taurus" }
  },
  "moon_sign": {
    "number": 9, "name": "Dhanu", "western": "Sagittarius",
    "ruler": { "key": "jupiter", "name": "Jupiter" }
  },
  "nakshatra": {
    "number": 20, "name": "Purva Ashadha", "pada": 1,
    "lord": { "key": "venus", "name": "Venus" }
  },
  "certain": { "moon_sign": true, "nakshatra": true, "sun_sign": true },
  "attribution": "…"
}
  • sun_sign.vedic is the sidereal sign used in Vedic astrology. sun_sign.western is the usual Western sign. moon_sign is the rashi.
  • The Sanskrit name is in name and the matching Western sign is in western.
  • No birth time? The Moon changes sign about every two and a half days, so a date alone is often enough. When it is not, we say so: certain shows false and the response lists every possibility that day. We never guess quietly.
  • We use the details to work out the answer and then drop them. They are not stored, not logged, and not repeated in the response, which is never cached.
If the birth time is missing and it matters (shortened)
{
  …
  "moon_sign": { "number": 4, "name": "Karka", "western": "Cancer", … },
  "certain": { "moon_sign": false, "nakshatra": false, "sun_sign": true },
  "note": "No birth time was sent, so these are for midday. On this date the answer changes during the day. …",
  "possible_moon_signs": [
    { "number": 4, "name": "Karka", "western": "Cancer" },
    { "number": 5, "name": "Simha", "western": "Leo" }
  ],
  "possible_nakshatras": [ { "number": 9, "name": "Ashlesha" }, { "number": 10, "name": "Magha" } ],
  "possible_padas": [1, 2, 3, 4]
}

Horoscopes

GET/api/v1/astrology/horoscope?sign=aries&period=daily&lang=en
ParameterWhereWhat it does
signqueryaries to pisces, or the Sanskrit name (mesha, vrishabha…), or 1 to 12, or all for every sign in one call. Required
periodquerydaily or weekly. Default daily
langqueryen, ta or hi. Default en
Example response (shortened)
{
  "period": "daily",
  "date": "2026-10-06",
  "lang": "en",
  "basis": "moon_sign",
  "audience": "UK",
  "ai_generated": true,
  "disclaimer": "Written by OneBhakthi AI for guidance and enjoyment. It is not advice. Please do not use it for medical, legal or money decisions.",
  "horoscope": {
    "sign": {
      "number": 1, "name": "Mesha", "western": "Aries",
      "ruler": { "key": "mars", "name": "Mars" },
      "element": "fire", "modality": "cardinal"
    },
    "scores": { "energy": "high", "focus": "medium", "mind_clarity": "low" },
    "highlight": "…",
    "text": "…",
    "habit": "…",
    "share_text": "…",
    "windows": {
      "timezone": "Europe/London",
      "best": { "start": "12:26", "end": "13:11", "description": "…" },
      "caution": { "start": "15:38", "end": "17:02", "description": "…" }
    }
  }
}
  • These are the readings OneBhakthi AI writes each morning, UK time. This call only reads what is already written. It never asks an AI to write anything new.
  • They are for the Moon sign (rashi), the way Vedic daily readings work, and they are written for a UK audience. The clock times in windows are London time.
  • They are labelled ai_generated and come with a disclaimer. Please show both to your users and do not present the readings as written by a person.
  • Each new set is written just after midnight UTC. Until then you get the previous set, with a note, and date (or week_starts) says which one it is. If nothing at all is stored you get a 503 with the code reading_not_ready, which is not counted against your limit.
  • With sign=all the answer has a horoscopes list instead of a single horoscope. Weekly readings carry week_starts and an overview instead of date and windows.

Accuracy and sources

We checked the work, and we say how.

  • Against NASA. We compared 16 tithi change times spread across 2026 with NASA JPL Horizons. The biggest difference was 47 seconds and the middle one 26 seconds. The Sun is within 2 arcseconds.
  • Against Drik Panchang. We compared 90 of its daily pages for 16 places between 2024 and 2027: London, Leicester, Chennai, New Delhi, Mumbai, Colombo, Singapore, Kuala Lumpur, Dubai, Nairobi, Johannesburg, Sydney, Auckland, Toronto, New York and Los Angeles. The tithi, nakshatra, yoga and karana at sunrise had the same name every time. Sunrise, sunset, moonrise, moonset, Rahu Kalam, Yamagandam, Gulika Kalam and Abhijit Muhurta agreed to within about a minute. When a tithi, karana or nakshatra changes, ours was on average a minute later (never more than about two), and yoga agreed on average. Published panchangs differ from one another by a minute or two, so allow for that when you compare.
  • Lunar months and years. The lunar month, adhika month, Shaka and Vikram year and ayana matched Drik on all 90 days. Over 110 years (1950 to 2059) the month and year sequence stays consistent, and every extra (adhika) month we tested came out right, including 2012, 2015, 2018, 2020, 2023 and 2026. The year changes with the lunar month at sunrise, so on a rare new-year day when Pratipada begins and ends between two sunrises, a published panchang may show the new year one day earlier.
  • One difference on purpose. The Vedic ritu follows the Indian lunar calendar. Drik Panchang turns it around for places south of the equator. We do not.
  • Not covered. Tamil Nadu's Vakya Panchangam and some printed panchangs use older table-based methods that can differ by much more. Festival dates can differ by a day between traditions. For an observance, please follow your own temple or priest.
  • Ayanamsha. The official Lahiri value (23.85706 degrees at 2000). Drik Panchang prints a figure 0.007 degrees higher, a difference of about 40 seconds in Moon timings.
  • Built with the open-source Astronomy Engine library by Don Cross (MIT licence), checked against NASA as above.

Coming soon

Coming soon

Pooja API

Pooja guides, steps and the items needed.

Coming soon

Festivals API

Festival dates and what each one is about.

They will use the same key, the same limits and the same sign in. Tell us what you want most on your dashboard.