Med_Sal API
This documentation descripes the API work in the med_sal project
http://127.0.0.1:8000/api/v1 => 127.0.0.1:8000/api/v1/
appointments
specific appointment
GETread
This HTTP GET request retrieves details of a specific appointment by providing the appointment ID in the URL.
This endpoint is for authenticated users.
The response will contain details such as appointment ID, timing, date, status, creation and update timestamps, service details, user details, location ID, provider details, and provider business name.
The response will be in JSON format with a status code of 200.
DELETEdelete
This endpoint sends an HTTP DELETE request to remove the appointment with the ID 34.
This endpoint is for admins.
The response returns a status code of 204 with a Content-Type of text/xml.
POSTcreate
Create Appointment
This endpoint allows you to create a new appointment.
This endpoint is for authenticated users.
Request Body
from_time
(string, required): The start time of the appointment.to_time
(string, required): The end time of the appointment.service
(integer, required): The ID of the service for the appointment.diagonsis
(string, optional): The diagnosis for the appointment.date
(string, required): The date of the appointment.note
(string, optional): Any additional notes for the appointment.
Response
id
(integer): The ID of the created appointment.from_time
(string): The start time of the appointment.to_time
(string): The end time of the appointment.date
(string): The date of the appointment.status
(string): The status of the appointment.created_at
(string): The timestamp of when the appointment was created.updated_at
(string): The timestamp of when the appointment was last updated.service
(integer): The ID of the service for the appointment.user
(integer): The ID of the user for the appointment.user_email
(string): The email of the user for the appointment.service_title
(string): The title of the service for the appointment.location_id
(integer): The ID of the location for the appointment.provider_id
(integer): The ID of the provider for the appointment.provider_email
(string): The email of the provider for the appointment.provider_business_name
(string): The business name of the provider for the appointment.