SEARCH ASTROLOGY API DOCS

Home
Indian Astrology

Advanced Panchang/monthly_panchang

The monthly_panchang API provides a panchang or Hindu calendar for a given year and month. The API response includes information such as the year, month, and details for each day of the month including the day, tithi (lunar day), nak (lunar mansion), sunrise time, and sunset time.

API Endpoint : monthly_panchang
Method : POST
Full URL :
https://json.astrologyapi.com/v1/monthly_panchang

Request Data

ParamsData typeDescriptions

month required

year required

hour required

min required

lat required

lon required

tzone required

int

int

int

int

float

float

float

panchang month, eg: 7

panchang year, eg: 2014

panchang hour, eg: 10

panchang minute, eg: 12

panchang place latitude, eg: 18.7250

panchang place longitude, eg: 72.250

panchang place timezone, eg: 5.5

Response Data

{
    "year": 1984,
    "month": 5,
    "panchang": [
        {
            "day": 1,
            "tithi": 29,
            "nak": 1,
            "sunrise": 6.1752,
            "sunSetTime": 19.0138
        },
        {
            "day": 2,
            "tithi": 0,
            "nak": 2,
            "sunrise": 6.1655,
            "sunSetTime": 19.0197
        },
        {
            "day": 3,
            "tithi": 1,
            "nak": 3,
            "sunrise": 6.1563,
            "sunSetTime": 19.0252
        },
        {
            "day": 4,
            "tithi": 2,
            "nak": 4,
            "sunrise": 6.1472,
            "sunSetTime": 19.0311
        },
        {
            "day": 5,
            "tithi": 3,
            "nak": 5,
            "sunrise": 6.1386,
            "sunSetTime": 19.0369
        },
        {
            "day": 6,
            "tithi": 4,
            "nak": 6,
            "sunrise": 6.13,
            "sunSetTime": 19.043
        },
        {
            "day": 7,
            "tithi": 5,
            "nak": 7,
            "sunrise": 6.1216,
            "sunSetTime": 19.0488
        },
        {
            "day": 8,
            "tithi": 6,
            "nak": 8,
            "sunrise": 6.1136,
            "sunSetTime": 19.055
        },
        {
            "day": 9,
            "tithi": 8,
            "nak": 9,
            "sunrise": 6.1058,
            "sunSetTime": 19.0611
        },
        {
            "day": 10,
            "tithi": 9,
            "nak": 10,
            "sunrise": 6.098,
            "sunSetTime": 19.0672
        },
        {
            "day": 11,
            "tithi": 10,
            "nak": 11,
            "sunrise": 6.0908,
            "sunSetTime": 19.0733
        },
        {
            "day": 12,
            "tithi": 11,
            "nak": 12,
            "sunrise": 6.0838,
            "sunSetTime": 19.0794
        },
        {
            "day": 13,
            "tithi": 12,
            "nak": 13,
            "sunrise": 6.0769,
            "sunSetTime": 19.0858
        },
        {
            "day": 14,
            "tithi": 13,
            "nak": 14,
            "sunrise": 6.0705,
            "sunSetTime": 19.0922
        },
        {
            "day": 15,
            "tithi": 14,
            "nak": 15,
            "sunrise": 6.0644,
            "sunSetTime": 19.0986
        },
        {
            "day": 16,
            "tithi": 15,
            "nak": 16,
            "sunrise": 6.0583,
            "sunSetTime": 19.105
        },
        {
            "day": 17,
            "tithi": 16,
            "nak": 17,
            "sunrise": 6.0527,
            "sunSetTime": 19.1113
        },
        {
            "day": 18,
            "tithi": 17,
            "nak": 18,
            "sunrise": 6.0472,
            "sunSetTime": 19.1177
        },
        {
            "day": 19,
            "tithi": 18,
            "nak": 19,
            "sunrise": 6.0422,
            "sunSetTime": 19.1241
        },
        {
            "day": 20,
            "tithi": 19,
            "nak": 20,
            "sunrise": 6.0375,
            "sunSetTime": 19.1305
        },
        {
            "day": 21,
            "tithi": 20,
            "nak": 21,
            "sunrise": 6.0327,
            "sunSetTime": 19.1372
        },
        {
            "day": 22,
            "tithi": 21,
            "nak": 22,
            "sunrise": 6.0286,
            "sunSetTime": 19.1436
        },
        {
            "day": 23,
            "tithi": 22,
            "nak": 23,
            "sunrise": 6.0247,
            "sunSetTime": 19.1502
        },
        {
            "day": 24,
            "tithi": 23,
            "nak": 24,
            "sunrise": 6.0211,
            "sunSetTime": 19.1566
        },
        {
            "day": 25,
            "tithi": 24,
            "nak": 25,
            "sunrise": 6.0177,
            "sunSetTime": 19.1633
        },
        {
            "day": 26,
            "tithi": 25,
            "nak": 26,
            "sunrise": 6.0147,
            "sunSetTime": 19.1697
        },
        {
            "day": 27,
            "tithi": 26,
            "nak": 26,
            "sunrise": 6.0119,
            "sunSetTime": 19.1763
        },
        {
            "day": 28,
            "tithi": 27,
            "nak": 0,
            "sunrise": 6.0094,
            "sunSetTime": 19.1827
        },
        {
            "day": 29,
            "tithi": 28,
            "nak": 1,
            "sunrise": 6.0072,
            "sunSetTime": 19.1891
        },
        {
            "day": 30,
            "tithi": 29,
            "nak": 2,
            "sunrise": 6.0052,
            "sunSetTime": 19.1955
        },
        {
            "day": 31,
            "tithi": 0,
            "nak": 3,
            "sunrise": 6.0036,
            "sunSetTime": 19.2019
        }
    ]
}
POST
var api = 'monthly_panchang';
var userId = '<Your User Id>';
var apiKey = '<Your Api Key>';
var data = {
  day: 6,
  month: 1,
  year: 2000,
  hour: 7,
  min: 45,
  lat: 19.132,
  lon: 72.342,
  tzone: 5.5,
};

var auth = "Basic " + new Buffer(userId + ":" + apiKey).toString("base64");

var request = $.ajax({
url: "https://json.astrologyapi.com/v1/"+api,
method: "POST",
dataType:'json',
headers: {
    "authorization": auth,
    "Content-Type":'application/json'
},
    data:JSON.stringify(data)
});

request.then( function(resp){
    console.log(resp);
}, function(err){
    console.log(err);
});