Skip to content

The Doctor Service is a component of the hospital management system, responsible for managing information related to doctors.

Notifications You must be signed in to change notification settings

iamrosada/hospital-management

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 

Repository files navigation

Doctor Service

The Doctor Service is a component of the hospital management system, responsible for managing information related to doctors.

Table of Contents

Overview

The Doctor Service provides functionalities for creating, updating, listing, deleting, and retrieving information about doctors.

Getting Started

Prerequisites

  • Go (version 1.16 or higher)
  • MySQL

Installation

  1. Clone the repository:

    git clone https://github.com/iamrosada/hospital-management.git
  2. Navigate to the doctor-service directory:

    cd hospital-management/doctor-service
  3. Install dependencies:

    go get -u ./...
  4. Build and run the application:

    go run main.go

Usage

Endpoints

  • Create Doctor:

    POST /doctors

    Example request body:

    {
      "name": "Dr. John Doe",
      "bi": "123456789",
      "specialty": "Cardiology",
      "experience": 10,
      "email": "john.doe@example.com",
      "phone_number": "+1234567890"
    }
  • List Doctors:

    GET /doctors
  • Get Doctor by ID:

    GET /doctors/{id}
  • Update Doctor by ID:

    PUT /doctors/{id}

    Example request body:

    {
      "name": "Dr. Jane Smith",
      "bi": "987654321",
      "specialty": "Orthopedics",
      "experience": 15,
      "email": "jane.smith@example.com",
      "phone_number": "+9876543210"
    }
  • Delete Doctor by ID:

    DELETE /doctors/{id}

Contributing

Contributions are welcome! If you have any suggestions, improvements, or find any issues, please open an issue or submit a pull request.

License

This project is licensed under the MIT License - see the LICENSE file for details.

About

The Doctor Service is a component of the hospital management system, responsible for managing information related to doctors.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages