Time of Adzan

Time of Adzan for schedulers

Another system — the NAIST room scheduler, a spreadsheet, a script — can put jamaah, bookings and announcements into your rooms with a secret key. The people nearby are told, exactly as if you had added it in the app.

1. Make a key

In the Time of Adzan app: Settings → Integration keys → New key…. Name it for what will use it. The key is shown once; copy it into the other system. It looks like toa_ and 40 letters and digits.

The key acts as you, on the rooms you own or are an admin of (including rooms in a group you run) — nothing else. If you stop being an admin of a room, the key stops working on it. Revoke a key in the same screen and it stops at once.

Keep it like a password: whoever has it can change your rooms' queue and bookings.

2. Call it

Send the key as Authorization: Bearer toa_…. Everything is under https://time-of-adzan.pages.dev/api/v1. Answers are JSON with "ok": true, or "ok": false and an error and message.

curl -H "Authorization: Bearer toa_YOURKEY" \
  https://time-of-adzan.pages.dev/api/v1/rooms

That lists your rooms, with the id each call below needs.

Jamaah and activities

POST /api/v1/rooms/{room}/queue
{ "prayer": "Dhuhr", "time": "12:30", "imam": "Ust. Ahmad",
  "externalId": "naist-evt-1042" }
GET    /api/v1/rooms/{room}/queue
DELETE /api/v1/rooms/{room}/queue/{id}

To remove an entry by your own id, use the link form below: do=remove_jamaah&externalId=naist-evt-1042.

Bookings

For a room that is only open when booked.

POST /api/v1/rooms/{room}/bookings
{ "start": "2026-10-16 13:00", "end": "2026-10-16 14:00",
  "note": "Friday prayer", "repeat": "weekly", "weeks": 10,
  "externalId": "naist-series-7" }

weeks — how many weeks (up to 520); 0 means every week with no end. Without repeat it is a single booking. A booking can be given as start and duration (minutes) instead of end.

GET    /api/v1/rooms/{room}/bookings
DELETE /api/v1/rooms/{room}/bookings/{id}

Announcement and settings

POST   /api/v1/rooms/{room}/announcement
{ "text": "Closed for cleaning", "hours": 2 }
DELETE /api/v1/rooms/{room}/announcement

PATCH  /api/v1/rooms/{room}
{ "availability": "booked", "startsAt": "2026-10-20 08:00",
  "expiresAt": "2026-10-20 12:00", "suspended": false,
  "cardFrom": "19:00", "cardUntil": "08:00" }

The room's name, position and admins are changed in the app, not here.

As a link

For a system that can only open a link, every call also exists as one URL, with the key in it. Use it only where the link stays private.

https://time-of-adzan.pages.dev/api/v1/command
  ?key=toa_YOURKEY&do=add_jamaah&room=ROOMID
  &prayer=Dhuhr&time=12:30&externalId=naist-evt-1042

do is one of: rooms, room, queue, add_jamaah, remove_jamaah (id or externalId), bookings, add_booking, remove_booking, announce, clear_announcement, update_room, whoami. The other fields are the same as above.

Good to know