Doctor Schedules
Function-calling namespace: doctorSchedules
- Base URL:
https://api.aivida.in - Engine endpoint:
POST /api - Auth: Stack token middleware enabled in
optionalmode. - Send token in header:
x-stack-access-token: <access_token>(orAuthorization: Bearer <access_token>). - In
optionalmode: no token is allowed; invalid token is rejected with401.
create
Source: backend/endpoints/doctor-schedules/create
Input Fields
| Field | Type | Required | Constraints |
|---|---|---|---|
doctorId | string | Yes | - |
organizationId | string | Yes | - |
date | string | Yes | format: YYYY-MM-DD |
slots | array<object> | Yes | - |
Nested Field Structures
slots item
| Field | Type | Required | Constraints |
|---|---|---|---|
startTime | string | No | format: HH:mm |
endTime | string | No | format: HH:mm |
isAvailable | boolean | No | - |
appointmentId | string | No | - |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "doctorSchedules",
"apiName": "create",
"data": {
"doctorId": "doctor_123",
"organizationId": "org_123",
"date": "2026-03-12",
"slots": [
{
"startTime": "10:30",
"endTime": "10:30",
"isAvailable": true,
"appointmentId": "appointment_123"
}
]
}
}'Example Response
{ "status": "ok", "data": {} }delete
Source: backend/endpoints/doctor-schedules/delete
Input Fields
| Field | Type | Required | Constraints |
|---|---|---|---|
id | string | Yes | - |
organizationId | string | Yes | - |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "doctorSchedules",
"apiName": "delete",
"data": {
"id": "id_123",
"organizationId": "org_123"
}
}'Example Response
{ "status": "ok", "data": {} }getAvailableSlots
Source: backend/endpoints/doctor-schedules/get-available-slots
Input schema type: unknown
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "doctorSchedules",
"apiName": "getAvailableSlots",
"data": {}
}'Example Response
{ "status": "ok", "data": {} }getById
Source: backend/endpoints/doctor-schedules/get-by-id
Input Fields
| Field | Type | Required | Constraints |
|---|---|---|---|
id | string | Yes | - |
organizationId | string | Yes | - |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "doctorSchedules",
"apiName": "getById",
"data": {
"id": "id_123",
"organizationId": "org_123"
}
}'Example Response
{ "status": "ok", "data": {} }listByOrganization
Source: backend/endpoints/doctor-schedules/list-by-organization
Input Fields
| Field | Type | Required | Constraints |
|---|---|---|---|
organizationId | string | Yes | - |
page | integer | No | - |
pageSize | integer | No | - |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "doctorSchedules",
"apiName": "listByOrganization",
"data": {
"organizationId": "org_123"
}
}'Example Response
{ "status": "ok", "data": {} }update
Source: backend/endpoints/doctor-schedules/update
Input Fields
| Field | Type | Required | Constraints |
|---|---|---|---|
id | string | Yes | - |
organizationId | string | Yes | - |
doctorId | string | No | nullable |
date | string | No | format: YYYY-MM-DD; nullable |
slots | array<object> | No | nullable |
Nested Field Structures
slots item
| Field | Type | Required | Constraints |
|---|---|---|---|
startTime | string | No | format: HH:mm |
endTime | string | No | format: HH:mm |
isAvailable | boolean | No | - |
appointmentId | string | No | - |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "doctorSchedules",
"apiName": "update",
"data": {
"id": "id_123",
"organizationId": "org_123"
}
}'Example Response
{ "status": "ok", "data": {} }