Skip to main content
GET
/
appointments
/
doctors
List Doctor's Appointments
curl --request GET \
  --url https://api.example.com/appointments/doctors \
  --header 'Authorization: <authorization>'
{
  "success": true,
  "data": [
    {
      "_id": "65f8a1b2c3d4e5f6789012ef",
      "name": "General Consultation",
      "date": "2024-03-15",
      "time": "14:30",
      "recording_id": "rec_123",
      "recording_url": "https://storage.example.com/recording.mp3",
      "recording_key": "recordings/rec_123.mp3",
      "status": "recording",
      "doctor_id": "doctor_uid_123",
      "patient_id": "65f8a1b2c3d4e5f6789012ab",
      "notes": "Patient consultation notes",
      "language": "de",
      "notes_type": "soap_clinical_notes_de",
      "appointment_type": "in_person"
    }
  ]
}

Overview

Returns all appointments associated with a specific doctor. The endpoint searches for appointments using both ObjectId and string formats for the doctor ID to ensure compatibility.

Authentication

Authorization
string
required
Bearer token for authenticated access
Authorization: Bearer your_jwt_token_here

Query Parameters

uid
string
required
Doctor’s user ID. Can be in ObjectId format or string format.

Response

success
boolean
Whether the request was successful
data
array
Array of appointment objects for the specified doctor
error
string
Error message (only present when success is false)

Example Response

{
  "success": true,
  "data": [
    {
      "_id": "65f8a1b2c3d4e5f6789012ef",
      "name": "General Consultation",
      "date": "2024-03-15",
      "time": "14:30",
      "recording_id": "rec_123",
      "recording_url": "https://storage.example.com/recording.mp3",
      "recording_key": "recordings/rec_123.mp3",
      "status": "recording",
      "doctor_id": "doctor_uid_123",
      "patient_id": "65f8a1b2c3d4e5f6789012ab",
      "notes": "Patient consultation notes",
      "language": "de",
      "notes_type": "soap_clinical_notes_de",
      "appointment_type": "in_person"
    }
  ]
}

Error Responses

{
  "success": false,
  "error": "Missing UID query parameter"
}
{
  "success": false,
  "error": "Error fetching appointments"
}