temetro

Appointments

Manage the clinic's schedule.

MethodPathPermission
GET/api/appointmentsappointment:read
POST/api/appointmentsappointment:write
PUT/api/appointments/{id}appointment:write
DELETE/api/appointments/{id}appointment:delete

The appointment object

FieldTypeNotes
idstringAssigned by the server
fileNumberstringPatient's file number (may be empty for ad-hoc bookings)
namestringRequired. Patient name
initialsstringRequired. 1–4 characters
datestringRequired. YYYY-MM-DD
timestringRequired. HH:mm
typestringRequired. Visit type, e.g. "Follow-up"
providerstringRequired. Provider display name
statusenumconfirmed (default) | checked-in | completed | cancelled

Examples

# List
curl -b cookies.txt http://localhost:4000/api/appointments

# Create
curl -b cookies.txt -X POST http://localhost:4000/api/appointments \
  -H "Content-Type: application/json" \
  -d '{
    "fileNumber": "1042",
    "name": "Hodan Warsame",
    "initials": "HW",
    "date": "2026-06-15",
    "time": "10:30",
    "type": "Follow-up",
    "provider": "Dr. Amina Yusuf"
  }'

# Update (e.g. check the patient in)
curl -b cookies.txt -X PUT http://localhost:4000/api/appointments/APPT_ID \
  -H "Content-Type: application/json" \
  -d '{ "...full appointment...": "", "status": "checked-in" }'

# Delete
curl -b cookies.txt -X DELETE http://localhost:4000/api/appointments/APPT_ID
const created = await fetch('http://localhost:4000/api/appointments', {
  method: 'POST',
  credentials: 'include',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({
    fileNumber: '1042',
    name: 'Hodan Warsame',
    initials: 'HW',
    date: '2026-06-15',
    time: '10:30',
    type: 'Follow-up',
    provider: 'Dr. Amina Yusuf',
  }),
}).then((r) => r.json());

Create returns 201 with the appointment; update returns the updated object; delete returns 204. Reception has full access to appointments — scheduling is front-desk work.

On this page