Skip to content

scholarX-Assesment/class-schedule-service

Repository files navigation

Class Schedule Service

Overview

The Class Schedule Service is a RESTful API that allows users to manage class schedules, teachers, and classes. It provides endpoints to create, retrieve, and delete class schedules, teachers, and classes.

Setup Instructions

Prerequisites

  • Python 3.8+
  • PostgreSQL
  • SQLAlchemy
  • FastAPI
  • Pydantic

Installation

  1. Clone the repository:

    git clone https://github.com/yourusername/class-schedule-service.git
    cd class-schedule-service
  2. Create and activate a virtual environment:

    python3 -m venv venv
    source venv/bin/activate
  3. Install the dependencies:

    pip install -r requirements.txt
  4. Set up the database:

    • Create a PostgreSQL database.
    • Update the DATABASE_URL in the config.py file with your database credentials.
  5. Run the database migrations:

    alembic upgrade head
  6. Start the FastAPI server:

    uvicorn main:app --reload
  7. Access the API documentation: Open your browser and navigate to http://127.0.0.1:8000/docs to view the interactive API documentation.

Running Tests

To run the tests, use the following command:

pytest

About

Class scheduler service for the eduction institute system

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published