Overview

Panchang API returns complete Hindu calendar data — tithi, nakshatra, yoga, karana, festivals, muhurtas, sunrise/sunset, choghadiya, and sankranti — for any date, city, or coordinate. It serves the global Hindu diaspora across 67 countries, not just India.

Rule of thumb: most gateway endpoints under /v1/... use POST. Public read-only endpoints use GET — including GET /health, GET /status, and GET /v1/demo/today.

All responses use a standard JSON envelope with data, meta, and optional dev_notes fields. Error responses always carry a machine-readable error and a docs_url link.

All sidereal calculations use the Lahiri ayanamsha, consistent with the standard adopted by the Government of India's Calendar Reform Committee. Festival and observance data is generated by an 11-layer deterministic rule engine, regression-tested against retained validation evidence.

New to Hindu calendar terminology? Jump to the Glossary for plain-language definitions of every term used in API responses — tithi, nakshatra, yoga, muhurat, choghadiya, and more.

Need conceptual help before wiring endpoints? Use the Guides Knowledge Hub alongside Documentation for field context, accuracy methodology, and integration planning.
5,680+ cities · 67+ countries
11 festival layers
Hindu · Jain · Sikh · Buddhist
Section-wiseAccuracy
<50msP50 cached, India region
99.9%Uptime SLA
LahiriAyanamsha standard
v5.0Engine version

Code Examples

All examples below call the Daily Panchang endpoint for Ujjain on 2026-04-15. Swap YOUR_API_KEY, the date, and city to match your use case.

💻
Your App date + city + key POST request
🔱
Panchang API panchang.devdarsha.com JSON response
📱
Your Users calendar · widget · app

Get Started in 4 Steps

Go from signup to production in a few minutes.

1 Get your API key

Sign up free - no credit card needed. Your key is ready instantly.

2 Make your first call

POST with a date, city, and your key. One request, full response.

3 See the response

Tithi, nakshatra, sunrise, festivals - all in one JSON object.

4 Ship it

Integrate into your app. Upgrade your plan as you scale.

curl Copy
curl
curl -X POST "https://panchang.devdarsha.com/v1/panchang/daily" \
  -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"date":"2026-04-15","city_id":"ujjain"}'
javascript Copy
javascript
// Use header auth - never put api_key in client-side code
const response = await fetch("https://panchang.devdarsha.com/v1/panchang/daily", {
  method: "POST",
  headers: {
    "X-Api-Key": "YOUR_API_KEY",
    "Content-Type": "application/json"
  },
  body: JSON.stringify({
    date: "2026-04-15",
    city_id: "ujjain"
  })
});

const data = await response.json();
console.log(data.data.tithi[0].name);    // "Trayodashi"
console.log(data.data.sun.rise);         // "15-04-2026 05:46:10"
console.log(data.data.festivals.total);  // 2
python Copy
python
import requests

response = requests.post(
    "https://panchang.devdarsha.com/v1/panchang/daily",
    headers={"X-Api-Key": "YOUR_API_KEY"},
    json={"date": "2026-04-15", "city_id": "ujjain"}
)

data = response.json()
print(data["data"]["tithi"][0]["name"])    # Trayodashi
print(data["data"]["sun"]["rise"])         # 15-04-2026 05:16:44
print(data["data"]["festivals"]["total"])  # 2

Sample Response (condensed)

Here is a representative slice of a real Daily Panchang response for Ujjain, April 15, 2026:

json Copy
json
{
  "data": {
    "date":     "2026-04-15",
    "city":     "Ujjain",
    "tithi":    [{ "name": "Trayodashi", "paksha": "Krishna", "end": "15-04-2026 22:32:21" }],
    "nakshatra":[{ "name": "Purva Bhadrapada" }, { "name": "Uttara Bhadrapada" }],
    "yoga":     [{ "name": "Brahma" }, { "name": "Indra" }],
    "sun":      { "rise": "15-04-2026 05:16:44", "set": "15-04-2026 17:56:48" },
    "muhurat":  { "rahu_kaal": { "start": "11:36:46", "end": "13:11:46" } },
    "festivals":{ "total": 2, "data": [{ "name": "Bhauma Pradosh" }, { "name": "Masik Shivratri" }] }
  },
  "meta": {
    "version":           "v1",
    "computed_at":       "2026-04-15T00:00:00.000Z",
    "resolved_timezone": "Asia/Kolkata",
    "data_source":       "live",
    "cache_age_seconds": 0
  }
}
Attached JSON PayloadExpand to inspect the full cached response
json
{
    "data": {
        "date": "2026-04-15",
        "weekday": "Wednesday",
        "timezone": "Asia/Kolkata",
        "utc_offset": "+05:30",
        "city": "Ujjain",
        "city_id": "ujjain",
        "bengali_date": {
            "day": 1,
            "month": "Baishakh",
            "year": 1433
        },
        "calendars": {
            "vikram_samvat": 2083,
            "shaka_samvat": 1948,
            "bengali": {
                "year": 1433,
                "month": "Chaitra",
                "day": 26
            },
            "hijri": {
                "year": 1447,
                "month": 10,
                "day": 17,
                "month_name": "Rajab",
                "note": "Tabular Kuwaiti method. Moon-sighted calendars may differ by ±1–2 days."
            }
        },
        "sun": {
            "rise": "15-04-2026 05:16:44",
            "set": "15-04-2026 17:56:48",
            "longitude": 25.05,
            "rashi": "Mesha"
        },
        "moon": {
            "rise": "15-04-2026 03:33:09",
            "set": "15-04-2026 15:57:40",
            "rashi": "Kumbha"
        },
        "lunar_month": {
            "name": "Chaitra",
            "adhik": false
        },
        "adhik": false,
        "lunar_month_label": "Chaitra",
        "lunar_context": {
            "lunar_month": "Chaitra",
            "is_adhik": false,
            "adhik": false,
            "lunar_month_label": "Chaitra"
        },
        "flags": {
            "is_purnima": false,
            "is_amavasya": false,
            "is_ekadashi": false,
            "is_sankashti": false,
            "is_parana": false
        },
        "tithi": [
            {
                "number": 28,
                "name": "Trayodashi",
                "paksha": "Krishna",
                "start": "15-04-2026 05:16:44",
                "end": "15-04-2026 22:32:21"
            }
        ],
        "nakshatra": [
            {
                "number": 25,
                "name": "Purva Bhadrapada",
                "start": "15-04-2026 05:16:44",
                "end": "15-04-2026 15:22:21"
            },
            {
                "number": 26,
                "name": "Uttara Bhadrapada",
                "start": "15-04-2026 15:23:21",
                "end": "16-04-2026 13:58:21"
            }
        ],
        "yoga": [
            {
                "number": 25,
                "name": "Brahma",
                "start": "15-04-2026 05:16:44",
                "end": "15-04-2026 13:23:36"
            },
            {
                "number": 26,
                "name": "Indra",
                "start": "15-04-2026 13:24:36",
                "end": "16-04-2026 10:35:51"
            }
        ],
        "karana": [
            {
                "number": 55,
                "name": "Garaja",
                "start": "15-04-2026 05:16:44",
                "end": "15-04-2026 11:28:36"
            },
            {
                "number": 56,
                "name": "Vanija",
                "start": "15-04-2026 11:28:36",
                "end": "16-04-2026 05:16:44"
            }
        ],
        "muhurat": {
            "rahu_kaal": {
                "start": "15-04-2026 11:36:46",
                "end": "15-04-2026 13:11:46"
            },
            "gulika_kaal": {
                "start": "15-04-2026 10:01:45",
                "end": "15-04-2026 11:36:46"
            },
            "yamaganda_kaal": {
                "start": "15-04-2026 06:51:44",
                "end": "15-04-2026 08:26:45"
            },
            "abhijit": {
                "start": null,
                "end": null
            },
            "brahma": {
                "start": "15-04-2026 03:40:44",
                "end": "15-04-2026 04:28:44"
            },
            "vijaya": {
                "start": "15-04-2026 14:08:46",
                "end": "15-04-2026 14:59:27"
            },
            "varjyam": {
                "start": "15-04-2026 11:36:46",
                "end": "15-04-2026 12:52:46"
            },
            "durmuhurta": {
                "start": "15-04-2026 06:46:44",
                "end": "15-04-2026 08:16:44"
            },
            "amrit_siddhi": {
                "start": "15-04-2026 16:15:27",
                "end": "15-04-2026 16:40:47"
            }
        },
        "choghadiya": {
            "day": [
                {
                    "type": "Labh",
                    "quality": "Beneficial",
                    "start": "15-04-2026 05:16:44",
                    "end": "15-04-2026 06:51:44"
                },
                {
                    "type": "Amrit",
                    "quality": "Very Auspicious",
                    "start": "15-04-2026 06:51:44",
                    "end": "15-04-2026 08:26:45"
                },
                {
                    "type": "Kaal",
                    "quality": "Inauspicious",
                    "start": "15-04-2026 08:26:45",
                    "end": "15-04-2026 10:01:45"
                },
                {
                    "type": "Shubh",
                    "quality": "Auspicious",
                    "start": "15-04-2026 10:01:45",
                    "end": "15-04-2026 11:36:46"
                },
                {
                    "type": "Rog",
                    "quality": "Inauspicious",
                    "start": "15-04-2026 11:36:46",
                    "end": "15-04-2026 13:11:46"
                },
                {
                    "type": "Udveg",
                    "quality": "Inauspicious",
                    "start": "15-04-2026 13:11:46",
                    "end": "15-04-2026 14:46:47"
                },
                {
                    "type": "Char",
                    "quality": "Neutral",
                    "start": "15-04-2026 14:46:47",
                    "end": "15-04-2026 16:21:47"
                },
                {
                    "type": "Labh",
                    "quality": "Beneficial",
                    "start": "15-04-2026 16:21:47",
                    "end": "15-04-2026 17:56:48"
                }
            ],
            "night": [
                {
                    "type": "Rog",
                    "quality": "Inauspicious",
                    "start": "15-04-2026 17:56:48",
                    "end": "15-04-2026 19:21:47"
                },
                {
                    "type": "Udveg",
                    "quality": "Inauspicious",
                    "start": "15-04-2026 19:21:47",
                    "end": "15-04-2026 20:46:47"
                },
                {
                    "type": "Char",
                    "quality": "Neutral",
                    "start": "15-04-2026 20:46:47",
                    "end": "15-04-2026 22:11:46"
                },
                {
                    "type": "Labh",
                    "quality": "Beneficial",
                    "start": "15-04-2026 22:11:46",
                    "end": "15-04-2026 23:36:46"
                },
                {
                    "type": "Amrit",
                    "quality": "Very Auspicious",
                    "start": "15-04-2026 23:36:46",
                    "end": "16-04-2026 01:01:45"
                },
                {
                    "type": "Kaal",
                    "quality": "Inauspicious",
                    "start": "16-04-2026 01:01:45",
                    "end": "16-04-2026 02:26:45"
                },
                {
                    "type": "Shubh",
                    "quality": "Auspicious",
                    "start": "16-04-2026 02:26:45",
                    "end": "16-04-2026 03:51:44"
                },
                {
                    "type": "Rog",
                    "quality": "Inauspicious",
                    "start": "16-04-2026 03:51:44",
                    "end": "16-04-2026 05:16:44"
                }
            ]
        },
        "festivals": {
            "total": 2,
            "data": [
                {
                    "id": "2026-04-15_PRADOSH",
                    "name": "Bhauma Pradosh",
                    "slug": "bhauma-pradosh",
                    "type": "vrat",
                    "category": "hindu_shaiva",
                    "observed_in": [
                        "all-india"
                    ],
                    "start": "15-04-2026 16:26:48",
                    "end": "15-04-2026 18:56:48",
                    "duration_note": "2h 30m",
                    "note": "Pradosh: 1.5 hrs before sunset to 1 hr after"
                },
                {
                    "id": "2026-04-15_MASIK_SHIVRATRI",
                    "name": "Masik Shivratri",
                    "slug": "masik-shivratri",
                    "type": "vrat",
                    "category": "hindu_shaiva",
                    "observed_in": [
                        "all-india"
                    ],
                    "start": "15-04-2026 22:33:25",
                    "end": "16-04-2026 20:12:48",
                    "duration_note": "21h 39m (ends next day)"
                }
            ]
        },
        "metadata": {
            "api_version": "2.0",
            "engine": "v5.0",
            "ayanamsha": "Lahiri",
            "ayanamsa_used": 24.21733,
            "resolved_via": "exact_match",
            "resolved_lat": 22.5726,
            "resolved_lon": 88.3639,
            "offline": true,
            "region_variant": "east_india",
            "region_resolved_via": "exact_match",
            "compute_time_ms": 45,
            "last_updated": "2026-04-14T19:52:18.392Z"
        }
    },
    "meta": {
        "version": "1.0",
        "computed_at": "2026-04-14T19:52:18.393Z",
        "resolved_timezone": "Asia/Kolkata",
        "data_source": "live",
        "cache_age_seconds": 0
    },
    "dev_notes": [],
    "profile": "emerald",
    "features": {
        "muhurat": true,
        "choghadiya": true,
        "metadata": true,
        "monthly_api": true
    }
}

Authentication

Every protected endpoint requires an API key. Send it in the X-Api-Key request header and keep requests server-side.

How to get a key

  1. Sign up — free, no credit card.
  2. Open the Dashboard and create a key. You can name, rotate, and revoke keys from there.
  3. Copy the key once — it is shown in full only at creation time. Store it as a server-side secret.

The same lifecycle is also available programmatically — see API Keys below.

Recommended method

Pass your key as an X-Api-Key request header. This keeps keys out of URLs, browser history, proxy logs, and analytics exports.

bash
POST https://panchang.devdarsha.com/v1/panchang/daily
X-Api-Key: YOUR_API_KEY

Deprecated migration mode

URL query-string API keys are deprecated and will be blocked after first-party callers finish migration. Do not build new integrations with ?api_key=....

bash
# Use header auth instead
curl -X POST "https://panchang.devdarsha.com/v1/panchang/daily" \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"date":"2026-06-15","city_id":"chennai"}'
Keep API keys server-side Do not ship keys in browser JavaScript. Query strings can be logged by proxies, servers, and browser history, so client apps should call your backend and let the backend call DevDarsha with X-Api-Key.

Base URL

text
https://panchang.devdarsha.com/v1

Quick Start

For all /v1/... endpoints, send a JSON body with your request fields and authenticate using X-Api-Key. Use city_id for supported cities, or pass lat and lon for coordinate-based lookups (Amethyst plans and above; Free is city_id only). Add faith_filter and timezone when you want more specific results.

Prefer working code? View official DevDarsha API code examples on GitHub — copy-paste examples in Node.js, Python, PHP, WordPress, and cURL.

Use a supported city

The canonical gateway format when the location exists in the city directory.

curl
curl -X POST "https://panchang.devdarsha.com/v1/panchang/daily" \
  -H "x-api-key: YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"date":"2026-03-27","city_id":"ujjain"}'
Required: date Required: city_id Required: x-api-key header

Use exact coordinates

Best when you need Panchang calculations for places outside the city directory.

curl
curl -X POST "https://panchang.devdarsha.com/v1/panchang/daily" \
  -H "x-api-key: YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"date":"2026-03-27","lat":22.5726,"lon":88.3639}'
Required: date Required: lat Required: lon Required: x-api-key header

Common URL Combinations

Use these request bodies when you want to layer tradition-specific filtering or timezone-aware output onto the standard daily gateway call.

Add a faith filter

Return festival and observance data narrowed to a specific tradition.

curl
curl -X POST "https://panchang.devdarsha.com/v1/panchang/daily" \
  -H "x-api-key: YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"date":"2026-03-27","city_id":"ujjain","faith_filter":"hindu"}'
Optional: faith_filter Example: hindu

Add a timezone override

Use this when you want output times resolved for a specific IANA timezone.

curl
curl -X POST "https://panchang.devdarsha.com/v1/panchang/daily" \
  -H "x-api-key: YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"date":"2026-03-27","city_id":"ujjain","faith_filter":"hindu","timezone":"Asia/Kolkata"}'
Optional: faith_filter Optional: timezone Example: Asia/Kolkata

Plans & Feature Gates

Each plan controls how many calls you can make, how fast you can call, which endpoints you can reach, and which lookup modes are available. Full pricing and discounts live on pricing.

Access gates

  • Free: daily endpoint only, supported city_id only (no coordinates), and a near-term demo date window (today-3 .. today+7). Free is for evaluation, not production.
  • Amethyst and above: coordinate (lat/lon) lookup is available.
  • Endpoints: monthly requires Amethyst+; yearly requires Sapphire+.
  • Paid public date window: 2025-01-01 through 2030-12-31 across all paid plans.

Quotas & rate limits

PlanMonthly callsCalls/minuteOverageTrial
Free2,00010Not available
Amethyst50,00060₹10 / 1,000 calls7 days, no card
Sapphire3,00,000180₹5 / 1,000 calls7 days, no card
Emerald20,00,000600₹2.50 / 1,000 calls7 days, no card

Trial: Paid plans start with a 7-day free trial. If you do not add a payment method, the account auto-downgrades to Free on day 8.

Quota cost per call

Each call costs 1 request, except the yearly endpoint:

  • POST /v1/panchang/daily — 1 request
  • POST /v1/panchang/monthly — 1 request
  • POST /v1/panchang/yearly12 requests per call
  • GET /v1/demo/today, GET /health, GET /status — free, no quota cost

A cache hit still consumes quota. The actual cost charged is echoed back in the X-Quota-Cost response header.

Separately, a coverage meter limits the distinct location-date pairs an account may retrieve per month (an anti-extraction control). It is independent of the per-call quota above — it is not a per-day charge.

Feature availability

FeatureFreeAmethystSapphireEmerald
Daily PanchangYesYesYesYes
Monthly PanchangYesYesYes
Yearly PanchangYesYes
Muhurat timingsYesYesYes
Core festivalsYesYesYes
All festival layersYesYes
Regional festivalsYesYes
Eclipse dataYesYes
Faith filterYesYesYes
city_id lookupYesYesYesYes
lat/lon lookupYesYesYes
SLA guarantee99.9%

If you call an endpoint or feature that is not on your plan, the response is 403 plan_required. See Error Codes.

Need higher volume or a custom SLA? White-label tiers (Aura / Nova / Cosmos) are sales-only — email [email protected].

Signup

POST /v1/signup

Create a new DevDarsha account programmatically. Returns an account record and a first API key. No authentication required.

Most users will sign up through the website signup form instead — this endpoint is for partners and SDKs that provision accounts on a user's behalf.

Request Body (JSON)

FieldTypeRequiredDescription
emailstringRequiredValid email address. Becomes the account login.
passwordstringRequiredMinimum 8 characters.
namestringOptionalDisplay name shown in dashboard and invoices.
planstringOptionalfree (default), amethyst, sapphire, or emerald. Paid plans start a 7-day trial.

Example Request

curl
curl -X POST "https://panchang.devdarsha.com/v1/signup" \
  -H "Content-Type: application/json" \
  -d '{"email":"[email protected]","password":"a-strong-password","plan":"free"}'

Response

json
{
  "data": {
    "account": { "id": "acc_...", "email": "[email protected]", "plan": "free" },
    "api_key": "sk_live_..."
  },
  "meta": { "version": "v1", "computed_at": "2026-04-29T10:00:00Z" }
}
Save the key now.

The full api_key is returned only once at signup. After this, the dashboard shows a masked preview. If you lose it, create a new key and revoke the old one.

Show once

API Key Management

POST /v1/keys

List, create, rotate, and revoke API keys for your account. All key endpoints require an existing API key with admin scope (your first key has admin scope by default). You can also manage keys from the Dashboard.

Operations

OperationMethod & pathDescription
CreatePOST /v1/keysCreate a new key with an optional name and scope.
ListPOST /v1/keys/listList your keys (masked previews only — never the full secret).
RotatePOST /v1/keys/rotateIssue a replacement key for an existing key id. Old key keeps working for 24 h.
RevokePOST /v1/keys/revokePermanently invalidate a key. Cannot be undone.

Create a key

curl
curl -X POST "https://panchang.devdarsha.com/v1/keys" \
  -H "X-Api-Key: YOUR_ADMIN_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name":"production-server","scope":"read"}'

Request fields

FieldTypeRequiredDescription
namestringOptionalFriendly label, e.g. production-server.
scopestringOptionalread (default) or admin. Admin keys can manage other keys.
key_idstringRequired for rotate/revokePublic id of the key (e.g. key_abc123) — never the secret.

Response (create / rotate)

json
{
  "data": {
    "key_id": "key_abc123",
    "api_key": "sk_live_...",
    "name": "production-server",
    "scope": "read",
    "created_at": "2026-04-29T10:00:00Z"
  },
  "meta": { "version": "v1" }
}
Full secret returned once.

The api_key field is returned only on create and rotate. List operations show a masked preview such as sk_live_...wXyZ. Treat keys like passwords.

Show once

Usage

GET /v1/usage

Returns the current month's usage and remaining quota for the authenticated key. Useful for surfacing a quota meter in your own dashboard or alerting before you run out.

Example Request

curl
curl "https://panchang.devdarsha.com/v1/usage" \
  -H "X-Api-Key: YOUR_API_KEY"

Response

json
{
  "data": {
    "plan": "amethyst",
    "period_start": "2026-04-01T00:00:00Z",
    "period_end":   "2026-05-01T00:00:00Z",
    "calls_used":      12480,
    "calls_included":  50000,
    "calls_remaining": 37520,
    "overage_units":   0,
    "overage_inr":     0
  },
  "meta": { "version": "v1", "computed_at": "2026-04-29T10:00:00Z" }
}

Response fields

FieldTypeDescription
planstringActive plan slug.
period_start / period_endstringISO 8601 boundaries of the current billing month (UTC).
calls_usedintegerRequests consumed this period (yearly endpoint counts as 12 each).
calls_includedintegerCalls included in the plan.
calls_remainingintegercalls_included − calls_used. Negative values mean you are in overage.
overage_unitsintegerCalls past calls_included on overage-eligible plans.
overage_inrnumberOverage charge in INR for the period so far.

Daily Panchang

POST /v1/panchang/daily

Returns the complete Panchang for a single date and location. This is the core endpoint — a single call returns the five classical Panchang elements (tithi, vara, nakshatra, yoga, karana), plus muhurtas, choghadiya, festival data, sunrise/sunset times, and regional calendar conversions (Vikram Samvat, Shaka Samvat, Bengali, Hijri). Not familiar with these terms? See the Glossary.

Calendar system: All festival and vrat dates follow the Purnimanta lunar calendar — the standard used across North and Central India. If your users are in South India (where the Amanta system is traditional), some festival dates may appear 1–2 days earlier or later compared to local printed almanacs. This is expected behaviour, not a bug. Amanta support is planned for v1.1.

Request Body (JSON)

FieldTypeRequiredDescription
datestringRequiredISO 8601 date: YYYY-MM-DD
city_idstringOne of city_id or lat+lonCity slug, e.g. ujjain, mumbai. See City IDs.
latnumberOne of city_id or lat+lonLatitude in decimal degrees - Amethyst+ plans only
lonnumberOne of city_id or lat+lonLongitude in decimal degrees - Amethyst+ plans only
faith_filterstringOptionalhindu | islamic | sikh | buddhist | christian | all (default: all)
timezonestringOptionalIANA timezone override, e.g. Asia/Kolkata. Defaults to city's local timezone.

Authentication is passed separately via the X-Api-Key header, not in the JSON body or URL.

Response Fields

FieldTypeDescription
data.tithiarrayTithi objects: number, name, paksha, start, end
data.nakshatraarrayActive nakshatras for the day with start/end times
data.yogaarrayActive yogas with start/end times
data.karanaarrayActive karanas with start/end times
data.pakshastringShukla (waxing) or Krishna (waning)
data.lunar_monthobjectLunar month name and adhik (leap) flag
data.sunobjectSunrise, sunset, solar longitude, and rashi
data.moonobjectMoonrise, moonset, and lunar rashi
data.festivalsobjecttotal count and data array of festival objects
data.muhuratobjectRahu kaal, gulika, yamaganda, abhijit, brahma, vijaya, and more
data.choghadiyaobjectday and night arrays of 8 choghadiya slots each
data.sankrantiobject | nullSolar ingress details if applicable, otherwise null
data.bengali_dateobjectBengali calendar equivalent — kept for backward compatibility. Use data.calendars.bengali in new code.
data.calendarsobjectAll regional calendar equivalents for the day. Includes Vikram Samvat, Shaka Samvat, Bengali, and Hijri. Prefer this over top-level data.bengali_date in new code.
data.calendars.vikram_samvatintegerVikram Samvat year, e.g. 2083 for Gregorian 2026
data.calendars.shaka_samvatintegerShaka Samvat year, e.g. 1948 for Gregorian 2026
data.calendars.bengaliobjectBengali calendar date — same data as data.bengali_date
data.calendars.hijriobjectHijri date using the tabular Kuwaiti method. Disclosed variance: ±1–2 days from moon-sighted calendars.
data.metadataobjectEngine version, ayanamsha value, resolved coordinates, compute time, and region details
data.metadata.enginestringPanchang engine version, e.g. v5.0
data.metadata.api_versionstringEngine-internal response schema version (e.g. "2.0"). This is not the gateway API version — the gateway API is always /v1/.... Do not use this field for version negotiation.
data.metadata.region_variantstringAuto-detected regional ruleset used for festival calculations. Possible values: north_india, south_india, west_india, east_india, default. Affects which festivals appear and their dates.
data.metadata.resolved_viastringHow the city or location was matched: exact_match (city_id found directly), fuzzy_match (closest city slug), or coordinate (lat/lon used)
data.metadata.offlinebooleantrue when the result was computed entirely on-engine without calling any external service
meta.versionstringAPI version string
meta.computed_atstringISO 8601 computation timestamp
meta.resolved_timezonestringIANA timezone used for computation
meta.data_sourcestringcache, engine, or live
meta.cache_age_secondsnumberSeconds since cached (0 if computed live)

Monthly Panchang Amethyst+

POST /v1/panchang/monthly

Returns Panchang data for every day of a given Gregorian month. The response contains a month-level envelope with a days array — each element has the same structure as a single Daily response. Typical use: building calendar views, generating monthly Panchang PDFs, or pre-fetching a full month for offline use.

Quota cost: 1 request per call. Not available on the Free plan.

Request Body (JSON)

FieldTypeRequiredDescription
yearintegerRequired4-digit year
monthintegerRequired1–12
city_idstringRequiredCity slug
faith_filterstringOptionalSame values as Daily — filters festival data
timezonestringOptionalIANA timezone override

Authenticate with the X-Api-Key header.

Example Request

curlCopy
curl
curl -X POST "https://panchang.devdarsha.com/v1/panchang/monthly" \
  -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"year":2026,"month":4,"city_id":"ujjain"}'
javascriptCopy
javascript
const res = await fetch("https://panchang.devdarsha.com/v1/panchang/monthly", {
  method: "POST",
  headers: {
    "X-Api-Key": "YOUR_API_KEY",
    "Content-Type": "application/json"
  },
  body: JSON.stringify({ year: 2026, month: 4, city_id: "ujjain" })
});
const { data } = await res.json();
// data.days — one object per calendar day, same shape as Daily
console.log(data.days.length);              // 30
console.log(data.days[0].tithi[0].name);   // "Trayodashi"
console.log(data.days[0].sun.rise);        // "01-04-2026 05:46:10"
pythonCopy
python
import requests

resp = requests.post(
    "https://panchang.devdarsha.com/v1/panchang/monthly",
    headers={"X-Api-Key": "YOUR_API_KEY"},
    json={"year": 2026, "month": 4, "city_id": "ujjain"}
)
data = resp.json()["data"]
print(len(data["days"]))                    # 30
print(data["days"][0]["tithi"][0]["name"]) # Trayodashi

Sample Response (condensed)

April 2026, Ujjain — first day shown; 29 more follow in the days array.

jsonCopy
json
{
  "data": {
    "year": 2026,
    "month": 4,
    "city": "Ujjain",
    "days": [
      {
        "date": "2026-04-01",
        "tithi":    [{ "name": "Trayodashi", "paksha": "Krishna" }],
        "nakshatra":[{ "name": "Purva Bhadrapada" }],
        "sun":      { "rise": "01-04-2026 05:46:10", "set": "01-04-2026 18:04:30" },
        "festivals":{ "total": 0, "data": [] }
      }
      // ... 29 more day objects
    ]
  },
  "meta": {
    "version": "v1",
    "computed_at": "2026-04-01T00:00:00.000Z",
    "resolved_timezone": "Asia/Kolkata",
    "data_source": "engine",
    "cache_age_seconds": 0
  }
}

Yearly Panchang Sapphire+

POST /v1/panchang/yearly
Same convention as Daily & Monthly: Send your request fields as a JSON body with Content-Type: application/json. Query-string parameters are also accepted and take precedence when both are present.

Returns Panchang data for every day of a full calendar year. The response contains all 365 (or 366) daily Panchang objects for the given year and city. Typical use: year-view calendar apps, annual festival lists, or pre-caching a year of data for fast rendering.

Quota cost: 12 requests flat per call regardless of year length. Available on Sapphire and Emerald plans only.

Request Body (JSON)

FieldTypeRequiredDescription
city_idstringRequiredCity slug, e.g. ujjain
yearintegerRequired4-digit year, e.g. 2026
faith_filterstringOptionalSame values as Daily — filters festival data

Authenticate with the X-Api-Key header.

Example Request

curlCopy
curl
curl -X POST "https://panchang.devdarsha.com/v1/panchang/yearly" \
  -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"year":2026,"city_id":"ujjain"}'
javascriptCopy
javascript
const res = await fetch("https://panchang.devdarsha.com/v1/panchang/yearly", {
  method: "POST",
  headers: {
    "X-Api-Key": "YOUR_API_KEY",
    "Content-Type": "application/json"
  },
  body: JSON.stringify({ year: 2026, city_id: "ujjain" })
});
const { data } = await res.json();
// data.months — array of 12 month objects, each with a days array
console.log(data.months.length);                      // 12
console.log(data.months[0].month_name);               // "January"
console.log(data.months[0].days[0].tithi[0].name);    // first day tithi
pythonCopy
python
import requests

resp = requests.post(
    "https://panchang.devdarsha.com/v1/panchang/yearly",
    headers={"X-Api-Key": "YOUR_API_KEY"},
    json={"year": 2026, "city_id": "ujjain"}
)
data = resp.json()["data"]
print(len(data["months"]))                             # 12
print(data["months"][0]["month_name"])                 # January
print(data["months"][0]["days"][0]["tithi"][0]["name"])

Sample Response (condensed)

Full year 2026, Ujjain — January shown; 11 more month objects follow.

jsonCopy
json
{
  "data": {
    "year": 2026,
    "months": [
      {
        "month": 1,
        "month_name": "January",
        "days": [
          {
            "date": "2026-01-01",
            "tithi":    [{ "name": "Dwadashi", "paksha": "Krishna" }],
            "nakshatra":[{ "name": "Purva Ashadha" }],
            "sun":      { "rise": "01-01-2026 06:54:14", "set": "01-01-2026 17:44:32" },
            "festivals":{ "total": 1, "data": [{ "name": "New Year" }] }
          }
          // ... 30 more day objects
        ]
      }
      // ... months 2–12
    ]
  },
  "meta": {
    "version": "1.0",
    "computed_at": "2026-01-01T00:00:00.000Z",
    "resolved_timezone": "Asia/Kolkata",
    "data_source": "live",
    "cache_age_seconds": 0
  }
}

Demo

GET /v1/demo/today

Returns today's Panchang for a default profile. No authentication, no quota cost. Useful for kicking the tyres or wiring up a test in your CI before you have a key. Response shape matches the Daily Panchang envelope, so you can swap to /v1/panchang/daily without changing parsing code.

curl
curl https://panchang.devdarsha.com/v1/demo/today

Demo responses are heavily cached and may be a few seconds stale. For production traffic, use POST /v1/panchang/daily with your key.

Health Check

GET /health

Returns gateway and upstream engine status. No authentication required. Always responds with X-Data-Source: live. Use this endpoint to monitor API availability in your own dashboards.

json
{ "status": "ok", "engine": "ok", "redis": "ok" }

Status

GET /status

Public status feed used by the DevDarsha status page. No authentication required. Returns current incident state, recent uptime, and degraded-mode flags. Polite polling (≥ 60 s) is recommended; this endpoint is rate-limited per IP.

json
{
  "status":     "operational",
  "degraded":   false,
  "incidents":  [],
  "uptime_30d": 99.98,
  "checked_at": "2026-04-29T10:00:00Z"
}

Possible status values: operational, degraded, partial_outage, major_outage, maintenance. When degraded is true, regular API responses also carry X-Degraded-* headers — see Response Headers.

Accuracy Manifest

GET /v1/accuracy/manifest

Returns a signed JSON document describing the public release-validation snapshot for DevDarsha Engine v5.0.0. No authentication required. Responses are cached for 24 hours and include a SHA-256 hash for tamper detection.

Use this endpoint to verify the public validation boundary before going live, or to display release-corpus pass rates in your own dashboard.

Release statement: Engine v5.0.0 is production-ready for deterministic panchang generation across the 2020-2030 launch corpus, with 100% pass rate on structural, range, ordering, muhurat, choghadiya, and festival-emission invariants across 28,126 profile-days.

The four sections

Section keyWhat it coversPublic validation method
sun_moonSunrise and sunset calculation integrityDeterministic release-validation invariant sweep
tithi_etcTithi, nakshatra, yoga, karanaDeterministic release-validation invariant sweep
muhuratRequired muhurat windows and choghadiya slot orderingDeterministic release-validation invariant sweep
festivalsFestival emission validity and daily engine stabilityDeterministic release-validation invariant sweep

Example request

curl
curl https://panchang.devdarsha.com/v1/accuracy/manifest

Response shape

json
{
  "schema": "devdarsha-public-accuracy-manifest-v2",
  "generated_at": "2026-05-10T08:51:12.551Z",
  "snapshot_date": "2026-05-10",
  "engine_version": "5.0.0",
  "ayanamsa": "Lahiri 1955",
  "system": "Purnimanta",
  "profiles": ["Kolkata", "Mumbai", "Delhi", "..."],
  "window": {
    "start_date": "2020-01-01",
    "end_date": "2030-12-31",
    "profile_day_count": 28126
  },
  "sections": {
    "sun_moon":  { "tested": 56252, "passed": 56252, "pass_rate": 100 },
    "tithi_etc": { "tested": 112504, "passed": 112504, "pass_rate": 100 },
    "muhurat":   { "tested": 56252, "passed": 56252, "pass_rate": 100 },
    "festivals": { "tested": 28126, "passed": 28126, "pass_rate": 100 }
  },
  "hash": "sha256:a1b2c3d4..."
}

Response fields

FieldTypeDescription
window.profile_day_countintegerNumber of date/profile combinations covered by the release-validation corpus
sections[key].testedintegerNumber of validation checks run for this section
sections[key].passedintegerNumber of validation checks that passed
sections[key].pass_ratenumberPublic pass rate for the covered release-validation corpus
sections[key].coveragestringPlain-language summary of the public validation boundary for that section
validation_boundaryobjectPublic scope, evidence policy, and high-risk-use note for the manifest
hashstringSHA-256 of the manifest body (excluding the hash field itself). Compare with the static copy at /accuracy-manifest.sig to detect tampering.
Signed copy. A browser-readable manifest viewer is available at https://panchang.devdarsha.com/accuracy-manifest. The raw JSON is available at /accuracy-manifest.sig and can be downloaded from the viewer when needed. Public artifacts summarize release validation; detailed internal artifacts and retained audit evidence are maintained by DevDarsha.

Feedback Endpoint

POST /v1/feedback

Submit feedback about the API. Does not require authentication.

FieldTypeRequiredDescription
namestringRequiredYour name
emailstringRequiredYour email
planstringRequiredfree | amethyst | sapphire | emerald | none
messagestringRequiredFeedback text (10–2000 chars)

Contact

POST /v1/contact

Send a sales, partnership, or support enquiry. Mirrors the contact form on the website. No authentication required. Submissions are rate-limited per IP and per email.

Request Body (JSON)

FieldTypeRequiredDescription
namestringRequiredYour name (2–120 chars).
emailstringRequiredReply-to email.
subjectstringOptionalShort topic line.
messagestringRequiredBody of the enquiry (10–4000 chars).
topicstringOptionalsales, support, partnership, or other.

Example Request

curl
curl -X POST "https://panchang.devdarsha.com/v1/contact" \
  -H "Content-Type: application/json" \
  -d '{"name":"Aanya","email":"[email protected]","topic":"sales","message":"Volume pricing for 5M calls/month?"}'

Responds with 202 Accepted on success. Replies usually arrive within 1 business day at the email you supplied.

Billing & Webhooks

POST /v1/billing/...

Most users will manage subscriptions, invoices, and payment methods from the Dashboard. The endpoints below let you do the same programmatically and let payment providers notify DevDarsha when something changes.

Operations

OperationMethod & pathDescription
Start checkoutPOST /v1/billing/checkoutCreate a hosted checkout session for a paid plan. Returns a redirect URL.
Subscription statusPOST /v1/billing/subscriptionCurrent plan, renewal date, trial state, payment method preview.
List invoicesPOST /v1/billing/invoicesPast invoices with INR amount and PDF link. (GST line items will be added once GST registration is active.)
CancelPOST /v1/billing/cancelCancel at end of the current billing period.
WebhooksPOST /v1/billing/webhookReceives events from your configured payment provider — see below.

All operations except webhook require an authenticated admin key.

Start a checkout

curl
curl -X POST "https://panchang.devdarsha.com/v1/billing/checkout" \
  -H "X-Api-Key: YOUR_ADMIN_KEY" \
  -H "Content-Type: application/json" \
  -d '{"plan":"sapphire","return_url":"https://example.com/billing/done"}'

Checkout fields

FieldTypeRequiredDescription
planstringRequiredamethyst, sapphire, or emerald.
return_urlstringRequiredHTTPS URL the customer is sent to after checkout completes or is cancelled.

Webhook events

Configure your webhook endpoint in the Dashboard. DevDarsha forwards normalized billing events as JSON. Always verify the X-Webhook-Signature header against your webhook secret before trusting the body. Events are at-least-once — make handlers idempotent on event.id.

EventWhen
subscription.activatedTrial converted or first payment captured.
subscription.renewedRecurring payment succeeded.
subscription.cancelledUser cancelled or trial ended without a payment method.
invoice.paidAn invoice was paid in full.
invoice.payment_failedA scheduled charge failed; retry will follow.
plan.changedUser upgraded or downgraded.
India GST (planned, not yet active). GST is not currently charged on the Service and the Company does not currently issue tax invoices containing a GSTIN, HSN, or SAC code. If GST registration becomes applicable to the Company in future, invoice.paid events will be extended to include the GSTIN, HSN/SAC code, and tax breakdown, and this section will be updated. See the Terms of Service and Refund Policy for current billing details.

Response Envelope

All successful responses use this shape:

json
{
  "data":  { /* endpoint-specific payload */ },
  "meta": {
    "version":            "1.0.0",
    "computed_at":        "2026-03-27T00:00:00.000Z",
    "resolved_timezone":  "Asia/Kolkata",
    "data_source":        "engine",
    "cache_age_seconds":  0
  }
}

Note: meta.version may appear as "1.0", "1.0.0", or "v1" depending on the endpoint — all refer to API version 1. Use the URL path (/v1/...) for version routing, not this field.

Error responses always use:

json
{
  "error":    "snake_case_code",
  "message":  "Human-readable description.",
  "docs_url": "https://platform.devdarsha.com/documentation#errors"
}

Error Codes

HTTPerrorMeaning
400missing_parameterA required parameter is absent (usually date)
400invalid_dateDate format is not YYYY-MM-DD or is out of range
400invalid_jsonPOST body is malformed JSON
400invalid_parameterA parameter value is invalid (e.g. month out of 1-12)
400missing_locationNeither city_id nor both lat and lon were provided
400request_too_largeThe requested date range is too large to process
401missing_api_keyNo api_key provided
401invalid_api_keyKey not found or revoked
403plan_requiredYour plan does not include this endpoint
403coordinate_access_restrictedCoordinate (lat/lon) lookup needs Amethyst or above; Free is city_id only
403free_demo_date_window_exceededFree is limited to near-term demo dates (today-3 .. today+7)
403public_date_window_exceededPaid public access supports dates from 2025-01-01 through 2030-12-31
403key_suspended / account_suspended / key_expiredThe API key or account is suspended or expired
403subscription_lapsedSubscription has lapsed; renew to restore access
405method_not_allowedWrong HTTP method for this route
429monthly_limit_exceededMonthly request quota exhausted
429rate_limit_exceededPer-minute rate limit hit
429daily_burst_limit_exceededPer-day burst limit hit
429date_limit_exceededToo many unique dates queried today
429coverage_limit_exceededMonthly distinct location-date coverage limit reached
429coverage_daily_limit_exceededDaily distinct location-date coverage ceiling reached
429city_year_cap_exceededDistinct city-year cap reached for the yearly endpoint this month
429ip_abuse_detectedToo many keys created/used from one IP
502upstream_errorEngine returned an unexpected error
503service_unavailableGateway is in degraded mode
503coverage_enforcement_unavailableCoverage enforcement is temporarily unavailable; retry shortly

City IDs

Panchang API supports 5,681 cities across 67 countries, covering India and the global Hindu diaspora - including the USA, Canada, UK, Malaysia, Bangladesh, and more. Pass city_id as a lowercase slug for any supported city.

city_id - Simple

Named city lookup
Use a pre-defined slug for any of the 5,681 supported cities. Fastest, most reliable for known locations.

json
json
{ "city_id": "mumbai" }

lat + lon - Precise

Coordinate lookup
Use decimal degree coordinates for any location worldwide. Best for custom or unlisted locations. Amethyst+ plans only.

json
json
{ "lat": 19.0760, "lon": 72.8777 }

Common city_id values

city_idCityState
kolkataKolkataWest Bengal
mumbaiMumbaiMaharashtra
delhiNew DelhiDelhi
bangaloreBengaluruKarnataka
chennaiChennaiTamil Nadu
hyderabadHyderabadTelangana
ahmedabadAhmedabadGujarat
punePuneMaharashtra
jaipurJaipurRajasthan
varanasiVaranasiUttar Pradesh
City not listed?
Use lat + lon for worldwide coordinates on Amethyst+. To request a named city_id
Contact us on : [email protected].

Faith Filter

Use faith_filter to return only festivals relevant to a specific tradition:

ValueDescription
allReturn all festivals (default)
hinduHindu festivals only
islamicIslamic festivals only
sikhSikh festivals and Gurpurabs
buddhistBuddhist observances
christianChristian festivals only

Versioning & Sunset Policy

The current API version is v1. All routes are prefixed /v1/. We use URI versioning — when a backwards-incompatible version exists, you opt in by changing the prefix (e.g. /v2/...), never by toggling a header.

  • Current: No warnings. Fully supported.
  • Deprecated: Minimum 12-month notice for breaking changes. Responses carry:
    • Sunset — RFC 8594 HTTP date when the version stops responding.
    • Link: <...>; rel="successor-version" — pointer to the recommended next version.
    • X-API-Deprecated: true and X-API-Sunset-Date for older clients.
    • A dev_notes entry on every response with migration guidance.
  • Sunset: Returns 410 Gone with a JSON error body and a Link header pointing at the successor version.
  • Security emergencies: A version may be sunset on shorter notice if there is a critical security issue with no safe forward fix.

Full versioning policy: api-versioning-policy

Rate Limits

PlanMonthly callsCalls/minuteOverage
Free2,00010Not available
Amethyst50,00060₹10 / 1,000 calls
Sapphire3,00,000180₹5 / 1,000 calls
Emerald20,00,000600₹2.50 / 1,000 calls

When rate-limited, a Retry-After header specifies seconds until the window resets. Quotas reset on the 1st of each month. To check live consumption from your app, call GET /v1/usage.

Response Headers

HeaderDescription
X-Quota-CostRequests consumed by this call (1 for daily, 1 for monthly, 12 for yearly)
X-Data-Sourcecache or engine or live
X-Cache-AgeSeconds since the cached result was generated
X-Request-IDUnique UUID for this request — include in support tickets
X-RateLimit-LimitYour per-minute limit
X-RateLimit-RemainingRequests remaining this minute
X-RateLimit-ResetUnix timestamp when the window resets
Retry-AfterPresent on 429 responses. Seconds to wait before retrying.
X-Degradedtrue when the API is serving from a fallback path (e.g. cache-only). Body is still valid; freshness may be reduced.
X-Degraded-ReasonShort slug describing why, e.g. cache_only, partial_outage. Mirrors the /status feed.
SunsetPresent on deprecated versions. RFC 8594 HTTP date when this version stops responding.
LinkPresent on deprecated/sunset versions with rel="successor-version" pointing at the recommended replacement.
Cache-ControlAlways private, no-store

Panchang Glossary

A quick reference for the Sanskrit and Vedic calendar terms used throughout this API and its responses.

TermMeaning
TithiLunar day, derived from the angular separation between the moon and sun. There are 30 tithis in a lunar month.
NakshatraOne of 27 lunar mansions - the segment of sky the moon occupies on a given day.
YogaA sum-based angular relationship between the sun and moon. There are 27 yogas, each ranging from auspicious to inauspicious.
KaranaA half-tithi subdivision. Each tithi contains two karanas, each with its own quality.
PakshaShukla = waxing (bright) fortnight. Krishna = waning (dark) fortnight of the lunar month.
VaraThe weekday in the traditional Hindu calendar (e.g. Somavar = Monday, Mangalavar = Tuesday).
MuhurtaAn auspicious time window calculated astronomically. Used to schedule ceremonies, travel, and important events.
ChoghadiyaVedic time-division system splitting the day and night into 8 slots each, classified as Very Auspicious, Auspicious, Neutral, or Inauspicious.
SankrantiSolar ingress - the moment the sun moves from one zodiac sign (rashi) to the next. Makar Sankranti is the most widely observed.
Ayanamsha (Lahiri)The offset applied to convert tropical (Western) longitudes to sidereal (Vedic) longitudes. Panchang API uses the Lahiri value - the standard adopted by the Government of India's Calendar Reform Committee.
Support requests. Email [email protected] or use the Feedback form. For debugging, include X-Request-ID. For account or billing questions, open your Dashboard.