https://github.com/mgobeaalcoba/fast_api_python
Programming and hosting a Rest API with Python's FastApi
https://github.com/mgobeaalcoba/fast_api_python
api-rest fastapi python3
Last synced: 2 months ago
JSON representation
Programming and hosting a Rest API with Python's FastApi
- Host: GitHub
- URL: https://github.com/mgobeaalcoba/fast_api_python
- Owner: Mgobeaalcoba
- License: mit
- Created: 2023-05-27T22:31:26.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-06-18T21:38:30.000Z (about 3 years ago)
- Last Synced: 2026-01-01T01:14:17.188Z (6 months ago)
- Topics: api-rest, fastapi, python3
- Language: Python
- Homepage:
- Size: 896 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# FastAPI Python Web Application
This repository contains a FastAPI web application built using Python. The application is designed to showcase the features and functionality of FastAPI, a modern, fast (high-performance) web framework for building APIs with Python 3.7+ based on standard Python type hints.
## Features
- FastAPI's automatic request and response validation
- Asynchronous support for efficient handling of concurrent requests
- Easy-to-use and intuitive API route definition
- Built-in support for Swagger UI and interactive API documentation
- Dependency injection for handling complex application dependencies
- Integration with popular databases and ORMs
- Exception handling and error responses
- Authentication and authorization mechanisms
- Testable code with built-in test client
## Requirements
- Python 3.7+
- FastAPI
- Uvicorn
- (Additional requirements depending on the project)
## Getting Started
1. Clone the repository:
```bash
git clone https://github.com/Mgobeaalcoba/fast_api_python.git
```
2. Change into the project directory:
```bash
cd fast_api_python
```
3. Create a virtual environment (optional but recommended):
```bash
python -m venv venv
```
4. Activate the virtual environment:
- For Windows:
```bash
venv\Scripts\activate
```
- For macOS/Linux:
```bash
source venv/bin/activate
```
5. Install the required dependencies:
```bash
pip install -r requirements.txt
```
6. Run the application:
```bash
uvicorn main:app --reload
```
7. Open your web browser and visit `http://localhost:8000` to interact with the FastAPI application.
## Project Structure
The project structure follows a recommended layout for FastAPI applications:
- `app`: This directory contains the main FastAPI application code.
- `api`: API-related modules and routes.
- `models`: Data models and schemas.
- `services`: Business logic and services.
- `utils`: Utility functions and helpers.
- `tests`: Test modules and files for testing the application.
- `main.py`: Entrypoint to start the FastAPI application.
- `requirements.txt`: List of project dependencies.
## Contributing
Contributions to this FastAPI Python web application are always welcome. Here are a few ways you can help:
- Report bugs and issues
- Suggest new features and enhancements
- Fix bugs and submit pull requests
Please make sure to follow the existing code style and conventions when making contributions.
## License
This project is licensed under the [MIT License](LICENSE).