The BeerData API is a dynamic and efficient application designed to provide users with seamless access to a diverse dataset of beer-related information.
-
Clone the repository:
git clone https://github.com/Saurabh254/python-api.git
-
Navigate to the project directory
cd python-api
-
Setting up virtual environment
python -m venv virt source virt/bin/activate python -m pip install -r requirements.txt
- Run the app
uvicorn app.main:app
- Open your browser and navigate to http://localhost:8000/docs to access the app documentation
/import/{page_number}
- Insert a page into the database along with its associated data.
/remove/{page_number}
- page_number (int): The page number to be inserted. Remove a page from the database along with its associated data.
/page/{page_number}
- Retrieve information about a specific page of beer data.
/{page_number}?abv={abv_value}&ibu={ibu_value}
- page_number (int): Page number to be viewed.
- abv (float, optional): ABV value to be filtered. Defaults to None.
- ibu (int, optional): IBU value to be filtered. Defaults to None.
Dependencies
- Python 3.x
- FastAPI
- SQLAlchemy
- Fork the repository.
- Create a new branch for your feature or bug fix.
- Make changes and commit.
- Push your branch to your fork.
- Create a pull request.