Docs / Reference · public.masjids.retrieve · generated from openapi.json
Retrieve a masjid
GET/v1/masjids/{id}
The canonical public representation of one masjid. Identify a masjid by its id, never by its coordinates: they are given with 4 to 7 decimals and may differ by less than a metre from one key to another.
Path parameters
| Name | Type | Description |
|---|---|---|
id | string · required | The masjid id, msj_…, as search, nearby or a previous read gave it. |
Response
The masjid.
| Field | Description |
|---|---|
hasDonationCampaignboolean | Whether GET /v1/masjids/{id}/donation-campaign answers a campaign. Changes when a campaign is enabled or disabled, never per donation. |
idstring | The masjid id, msj_…. |
linksobject | Outbound links: report always, the others absent when unknown. |
links.claimstring · optional | Where the masjid claims or updates its page. Link the attribution to it ("Masjid data provided by Masjidbox"). |
links.donatestring · optional | The donation page. Absent when unknown. |
links.reportstring | Where a user reports an error in this masjid's times. Always present: the page takes the report, or invites the masjid to claim its page when nobody manages it yet. Link a "Report an error" next to the attribution. To preselect the form, append any of ?prayer=&kind=&day= to the link: prayer is one of fajr, dhuhr, asr, maghrib, isha, jumua or other; kind is adhan or iqamah; day is the day the time is wrong, YYYY-MM-DD, from a week before the masjid's today to 30 days after. |
links.websitestring · optional | The masjid's own website. Absent when unknown. |
locationobject | Where the masjid is. Coordinates come as a pair or not at all. |
location.addressstring · optional | The postal address, one line. |
location.citystring · optional | The city. |
location.countrystring · optional | ISO 3166-1 alpha-2, upper case. |
location.latitudenumber · optional | Latitude, decimal degrees. Given with 4 to 7 decimal places; the precision is not significant and may differ by less than a metre from one key to another. Identify a masjid by its id, never by its coordinates. |
location.longitudenumber · optional | Longitude, decimal degrees. Given with 4 to 7 decimal places; the precision is not significant and may differ by less than a metre from one key to another. Identify a masjid by its id, never by its coordinates. |
namestring | The masjid name. |
objectmasjid | Always masjid. |
timezonestring · optional | The masjid's IANA timezone, in which its prayer times are given. |
curl "https://hub.masjidbox.com/v1/masjids/msj_abc123defg" \
-H "Authorization: Bearer $MASJIDBOX_KEY"{
"hasDonationCampaign": true,
"id": "msj_abc123defg",
"links": {
"claim": "https://app.masjidbox.com/register?claim=abc123defg",
"donate": "https://masjidbox.com/donate/abc123defg",
"report": "https://hub.masjidbox.com/report/msj_abc123defg",
"website": "https://www.eastlondonmosque.org.uk"
},
"location": {
"address": "82-92 Whitechapel Rd, London E1 1JQ",
"city": "London",
"country": "GB",
"latitude": 51.5173,
"longitude": -0.0652
},
"name": "East London Mosque",
"object": "masjid",
"timezone": "Europe/London"
}