Your masjid · Prayer times

Your athan

Where your athan times come from (computed, or your full-year timetable), how they are computed and the rules on top of them. The source changes only when you send it.

Right on the key: Prayer times: read for a read, edit (secret key) for a write.

Your athan

GET/v1/masjid/athan

Where your athan times come from (source: calculation or timetable, your full-year athan timetable of the current year), how they are computed (calculation: the method, the asr rule, the high-latitude rule, the angles and the minutes added to each prayer) and the rules over the computed times (rules: per prayer, a fixed time, or a window). calculation and rules stay readable while the timetable gives your times.

Parameters

No parameters.

Returns

Your athan.

  • objectathan

    Always athan.

  • sourcecalculation | timetable

    Where your athan times come from: calculation (computed from calculation, then rules) or timetable (your full-year athan timetable of the current year).

  • calculationobject

    How your athan times are computed; kept, and editable, while a full-year athan timetable gives them.

    Show child attributes (15)
    • methodstring | null

      The calculation method: auto (the country default), custom (your own angles) or a named method; null before one was ever set.

    • methodVersioninteger | null

      The calibration generation of method: 0 (the original catalogue) or 2026 (re-measured on published tables).

    • madhabstring | null

      The asr rule: Shafi (shadow once) or Hanafi (twice).

    • highLatitudestring | null

      How fajr and isha are placed where the twilight never ends: MiddleOfTheNight, SeventhOfTheNight or TwilightAngle.

    • fajrAnglenumber | null

      The fajr angle, degrees; with custom.

    • fajrIntervalnumber | null

      Fajr as minutes before sunrise instead of an angle; null when unused.

    • ishaAnglenumber | null

      The isha angle, degrees; with custom.

    • ishaIntervalnumber | null

      Isha as minutes after maghrib instead of an angle; null when unused.

    • adjustmentsobject

      Minutes added to each computed athan time.

    • adjustments.fajrnumber | null

      Minutes added to the computed fajr; null when none.

    • adjustments.sunrisenumber | null

      Minutes added to the computed sunrise; null when none.

    • adjustments.dhuhrnumber | null

      Minutes added to the computed dhuhr; null when none.

    • adjustments.asrnumber | null

      Minutes added to the computed asr; null when none.

    • adjustments.maghribnumber | null

      Minutes added to the computed maghrib; null when none.

    • adjustments.ishanumber | null

      Minutes added to the computed isha; null when none.

  • rulesobject

    Rules that override or bound the computed athan times: a fixed time, or a window.

    Show child attributes (24)
    • fajrobject | null

      The fajr rule: one of equal, min and max; null when it has none.

    • fajr.equalstring | nulloptional

      The fajr athan at this time, HH:MM.

    • fajr.minstring | nulloptional

      The fajr athan never before this, HH:MM or <prayer>±minutes.

    • fajr.maxstring | nulloptional

      The fajr athan never after this, HH:MM or <prayer>±minutes.

    • sunriseobject | null

      The sunrise rule: one of equal, min and max; null when it has none.

    • sunrise.equalstring | nulloptional

      The sunrise athan at this time, HH:MM.

    • sunrise.minstring | nulloptional

      The sunrise athan never before this, HH:MM or <prayer>±minutes.

    • sunrise.maxstring | nulloptional

      The sunrise athan never after this, HH:MM or <prayer>±minutes.

    • dhuhrobject | null

      The dhuhr rule: one of equal, min and max; null when it has none.

    • dhuhr.equalstring | nulloptional

      The dhuhr athan at this time, HH:MM.

    • dhuhr.minstring | nulloptional

      The dhuhr athan never before this, HH:MM or <prayer>±minutes.

    • dhuhr.maxstring | nulloptional

      The dhuhr athan never after this, HH:MM or <prayer>±minutes.

    • asrobject | null

      The asr rule: one of equal, min and max; null when it has none.

    • asr.equalstring | nulloptional

      The asr athan at this time, HH:MM.

    • asr.minstring | nulloptional

      The asr athan never before this, HH:MM or <prayer>±minutes.

    • asr.maxstring | nulloptional

      The asr athan never after this, HH:MM or <prayer>±minutes.

    • maghribobject | null

      The maghrib rule: one of equal, min and max; null when it has none.

    • maghrib.equalstring | nulloptional

      The maghrib athan at this time, HH:MM.

    • maghrib.minstring | nulloptional

      The maghrib athan never before this, HH:MM or <prayer>±minutes.

    • maghrib.maxstring | nulloptional

      The maghrib athan never after this, HH:MM or <prayer>±minutes.

    • ishaobject | null

      The isha rule: one of equal, min and max; null when it has none.

    • isha.equalstring | nulloptional

      The isha athan at this time, HH:MM.

    • isha.minstring | nulloptional

      The isha athan never before this, HH:MM or <prayer>±minutes.

    • isha.maxstring | nulloptional

      The isha athan never after this, HH:MM or <prayer>±minutes.

GET /v1/masjid/athan
curl "https://hub.masjidbox.com/v1/masjid/athan" \
  -H "Authorization: Bearer $MASJIDBOX_KEY"
200 · MasjidAthan
{
  "object": "athan",
  "calculation": {
    "adjustments": {
      "asr": 0,
      "dhuhr": 2,
      "fajr": 0,
      "isha": 0,
      "maghrib": 3,
      "sunrise": 0
    },
    "fajrAngle": null,
    "fajrInterval": null,
    "highLatitude": "MiddleOfTheNight",
    "ishaAngle": null,
    "ishaInterval": null,
    "madhab": "Shafi",
    "method": "MuslimWorldLeague",
    "methodVersion": 2026
  },
  "rules": {
    "asr": null,
    "dhuhr": {
      "equal": "13:30"
    },
    "fajr": null,
    "isha": {
      "min": "maghrib+90"
    },
    "maghrib": null,
    "sunrise": null
  },
  "source": "calculation"
}

Change your athan

PATCH/v1/masjid/athan

JSON Merge Patch on each part: in calculation a field you send replaces it, adjustments merges per prayer (null removes one); in rules a prayer you send replaces its rule, null removes it; a field or a part you leave out stays. source changes only when you send it: calculation makes your times computed again, timetable makes them come from your full-year athan timetable of the current year, and is refused (409) while you have none: PUT it first. Changing the calculation or the rules never changes the source. An empty body changes nothing. Needs a secret key with Prayer times: edit. 30 writes an hour and 300 a day per organization.

Parameters

No parameters.

Request body

  • sourcecalculation | timetable

    Changes where your athan times come from; left out, it stays. timetable needs a timetable of the current year (409 otherwise).

  • calculationobject

    A change to the calculation method: a field you leave out stays.

    Show child attributes (15)
    • methodstring

      auto, custom or a named method (MuslimWorldLeague, Egyptian, Karachi, UmmAlQura, Diyanet, Maroc…); an unknown name is a 400.

    • methodVersioninteger

      The calibration generation, 0 or 2026; a new method starts at 2026.

    • madhabShafi | Hanafi

      The asr rule.

    • highLatitudeMiddleOfTheNight | SeventhOfTheNight | TwilightAngle

      The high-latitude rule.

    • fajrAnglenumber | null

      The fajr angle, 0 to 30 degrees; null removes it.

    • fajrIntervalinteger | null

      Fajr as 0 to 300 minutes before sunrise; null removes it.

    • ishaAnglenumber | null

      The isha angle, 0 to 30 degrees; null removes it.

    • ishaIntervalinteger | null

      Isha as 0 to 300 minutes after maghrib; null removes it.

    • adjustmentsobject

      Merged per prayer; a prayer you leave out stays.

    • adjustments.fajrinteger | null

      Minutes added to the computed fajr, -120 to 120; null removes them.

    • adjustments.sunriseinteger | null

      Minutes added to the computed sunrise, -120 to 120; null removes them.

    • adjustments.dhuhrinteger | null

      Minutes added to the computed dhuhr, -120 to 120; null removes them.

    • adjustments.asrinteger | null

      Minutes added to the computed asr, -120 to 120; null removes them.

    • adjustments.maghribinteger | null

      Minutes added to the computed maghrib, -120 to 120; null removes them.

    • adjustments.ishainteger | null

      Minutes added to the computed isha, -120 to 120; null removes them.

  • rulesobject

    A change to the athan rules: a prayer you leave out stays.

    Show child attributes (24)
    • fajrobject | null

      Replaces the fajr rule: one of equal, min and max, exactly; null removes it.

    • fajr.equalstring · HH:mm | null

      The fajr athan at this time, HH:MM.

    • fajr.minstring | null

      The fajr athan never before this, HH:MM or <prayer>±minutes.

    • fajr.maxstring | null

      The fajr athan never after this, HH:MM or <prayer>±minutes.

    • sunriseobject | null

      Replaces the sunrise rule: one of equal, min and max, exactly; null removes it.

    • sunrise.equalstring · HH:mm | null

      The sunrise athan at this time, HH:MM.

    • sunrise.minstring | null

      The sunrise athan never before this, HH:MM or <prayer>±minutes.

    • sunrise.maxstring | null

      The sunrise athan never after this, HH:MM or <prayer>±minutes.

    • dhuhrobject | null

      Replaces the dhuhr rule: one of equal, min and max, exactly; null removes it.

    • dhuhr.equalstring · HH:mm | null

      The dhuhr athan at this time, HH:MM.

    • dhuhr.minstring | null

      The dhuhr athan never before this, HH:MM or <prayer>±minutes.

    • dhuhr.maxstring | null

      The dhuhr athan never after this, HH:MM or <prayer>±minutes.

    • asrobject | null

      Replaces the asr rule: one of equal, min and max, exactly; null removes it.

    • asr.equalstring · HH:mm | null

      The asr athan at this time, HH:MM.

    • asr.minstring | null

      The asr athan never before this, HH:MM or <prayer>±minutes.

    • asr.maxstring | null

      The asr athan never after this, HH:MM or <prayer>±minutes.

    • maghribobject | null

      Replaces the maghrib rule: one of equal, min and max, exactly; null removes it.

    • maghrib.equalstring · HH:mm | null

      The maghrib athan at this time, HH:MM.

    • maghrib.minstring | null

      The maghrib athan never before this, HH:MM or <prayer>±minutes.

    • maghrib.maxstring | null

      The maghrib athan never after this, HH:MM or <prayer>±minutes.

    • ishaobject | null

      Replaces the isha rule: one of equal, min and max, exactly; null removes it.

    • isha.equalstring · HH:mm | null

      The isha athan at this time, HH:MM.

    • isha.minstring | null

      The isha athan never before this, HH:MM or <prayer>±minutes.

    • isha.maxstring | null

      The isha athan never after this, HH:MM or <prayer>±minutes.

Returns

Your athan after the write.

  • objectathan

    Always athan.

  • sourcecalculation | timetable

    Where your athan times come from: calculation (computed from calculation, then rules) or timetable (your full-year athan timetable of the current year).

  • calculationobject

    How your athan times are computed; kept, and editable, while a full-year athan timetable gives them.

    Show child attributes (15)
    • methodstring | null

      The calculation method: auto (the country default), custom (your own angles) or a named method; null before one was ever set.

    • methodVersioninteger | null

      The calibration generation of method: 0 (the original catalogue) or 2026 (re-measured on published tables).

    • madhabstring | null

      The asr rule: Shafi (shadow once) or Hanafi (twice).

    • highLatitudestring | null

      How fajr and isha are placed where the twilight never ends: MiddleOfTheNight, SeventhOfTheNight or TwilightAngle.

    • fajrAnglenumber | null

      The fajr angle, degrees; with custom.

    • fajrIntervalnumber | null

      Fajr as minutes before sunrise instead of an angle; null when unused.

    • ishaAnglenumber | null

      The isha angle, degrees; with custom.

    • ishaIntervalnumber | null

      Isha as minutes after maghrib instead of an angle; null when unused.

    • adjustmentsobject

      Minutes added to each computed athan time.

    • adjustments.fajrnumber | null

      Minutes added to the computed fajr; null when none.

    • adjustments.sunrisenumber | null

      Minutes added to the computed sunrise; null when none.

    • adjustments.dhuhrnumber | null

      Minutes added to the computed dhuhr; null when none.

    • adjustments.asrnumber | null

      Minutes added to the computed asr; null when none.

    • adjustments.maghribnumber | null

      Minutes added to the computed maghrib; null when none.

    • adjustments.ishanumber | null

      Minutes added to the computed isha; null when none.

  • rulesobject

    Rules that override or bound the computed athan times: a fixed time, or a window.

    Show child attributes (24)
    • fajrobject | null

      The fajr rule: one of equal, min and max; null when it has none.

    • fajr.equalstring | nulloptional

      The fajr athan at this time, HH:MM.

    • fajr.minstring | nulloptional

      The fajr athan never before this, HH:MM or <prayer>±minutes.

    • fajr.maxstring | nulloptional

      The fajr athan never after this, HH:MM or <prayer>±minutes.

    • sunriseobject | null

      The sunrise rule: one of equal, min and max; null when it has none.

    • sunrise.equalstring | nulloptional

      The sunrise athan at this time, HH:MM.

    • sunrise.minstring | nulloptional

      The sunrise athan never before this, HH:MM or <prayer>±minutes.

    • sunrise.maxstring | nulloptional

      The sunrise athan never after this, HH:MM or <prayer>±minutes.

    • dhuhrobject | null

      The dhuhr rule: one of equal, min and max; null when it has none.

    • dhuhr.equalstring | nulloptional

      The dhuhr athan at this time, HH:MM.

    • dhuhr.minstring | nulloptional

      The dhuhr athan never before this, HH:MM or <prayer>±minutes.

    • dhuhr.maxstring | nulloptional

      The dhuhr athan never after this, HH:MM or <prayer>±minutes.

    • asrobject | null

      The asr rule: one of equal, min and max; null when it has none.

    • asr.equalstring | nulloptional

      The asr athan at this time, HH:MM.

    • asr.minstring | nulloptional

      The asr athan never before this, HH:MM or <prayer>±minutes.

    • asr.maxstring | nulloptional

      The asr athan never after this, HH:MM or <prayer>±minutes.

    • maghribobject | null

      The maghrib rule: one of equal, min and max; null when it has none.

    • maghrib.equalstring | nulloptional

      The maghrib athan at this time, HH:MM.

    • maghrib.minstring | nulloptional

      The maghrib athan never before this, HH:MM or <prayer>±minutes.

    • maghrib.maxstring | nulloptional

      The maghrib athan never after this, HH:MM or <prayer>±minutes.

    • ishaobject | null

      The isha rule: one of equal, min and max; null when it has none.

    • isha.equalstring | nulloptional

      The isha athan at this time, HH:MM.

    • isha.minstring | nulloptional

      The isha athan never before this, HH:MM or <prayer>±minutes.

    • isha.maxstring | nulloptional

      The isha athan never after this, HH:MM or <prayer>±minutes.

PATCH /v1/masjid/athan
curl -X PATCH "https://hub.masjidbox.com/v1/masjid/athan" \
  -H "Authorization: Bearer $MASJIDBOX_KEY" \
  -H "Content-Type: application/json" \
  -d '{"calculation":{"madhab":"Hanafi"},"source":"calculation"}'
Example request · MasjidAthanPatch
{
  "calculation": {
    "madhab": "Hanafi"
  },
  "source": "calculation"
}
200 · MasjidAthan
{
  "object": "athan",
  "calculation": {
    "adjustments": {
      "asr": 0,
      "dhuhr": 2,
      "fajr": 0,
      "isha": 0,
      "maghrib": 3,
      "sunrise": 0
    },
    "fajrAngle": null,
    "fajrInterval": null,
    "highLatitude": "MiddleOfTheNight",
    "ishaAngle": null,
    "ishaInterval": null,
    "madhab": "Shafi",
    "method": "MuslimWorldLeague",
    "methodVersion": 2026
  },
  "rules": {
    "asr": null,
    "dhuhr": {
      "equal": "13:30"
    },
    "fajr": null,
    "isha": {
      "min": "maghrib+90"
    },
    "maghrib": null,
    "sunrise": null
  },
  "source": "calculation"
}