GET /convert
Convert the current Gregorian date to the corresponding Lenorian date using the UTC timezone
Response
{
"status": 200,
"message": "OK",
"ok": true,
"body": {
"timezone": "utc",
"year": {
"value": 0,
"leapYear": true,
"totalDays": 366
},
"month": {
"index": 8,
"name": "November",
"value": 9
},
"monthDay": {
"index": 21,
"value": 22
},
"weekday": {
"index": 1,
"name": "Veneday"
},
"shortDate": "0000-09-22",
"fullDate": "Veneday, 22 November 0",
"holiday": "Universal Declaration of Human Rights Day",
"yearDay": 265
}
}
Optional query parameters
Field | Type | Format | Description |
---|---|---|---|
gdate | Date | YYYY-MM-DD | Convert a Gregorian date to a Lenorian date; always uses UTC |
time | Integer | Unix time | Convert an Unix timestamp (in seconds) to a Lenorian date |
offset | Integer | Switch to local time by specifying the timezone offset (in minutes) from UTC |
Response body fields details
Field | Type | Range | Value | Format |
---|---|---|---|---|
timezone | String | utc / local | ||
year.value | Integer | [ -∞ ; ∞ ] | ||
year.leapYear | Boolean | |||
year.totalDays | Integer | 365 or 366 | ||
month.index | Integer | [ 0 ; 11 ] | ||
month.value | Integer | [ 1 ; 12 ] | ||
month.name | String | |||
monthDay.index | Integer | [ 0 ; 30 ] | ||
monthDay.value | Integer | [ 1 ; 31 ] | ||
weekDay.index | Integer | [ 0 ; 7 ] | ||
weekDay.name | String | |||
shortDate | String | YYYY-MM-DD | ||
fullDate | String | weekday day month year | ||
holiday | String | |||
yearDay | Integer | [ 0 ; 365 ] |