Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mohamedhany99/file-management-service-django5
https://github.com/mohamedhany99/file-management-service-django5
Last synced: 20 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/mohamedhany99/file-management-service-django5
- Owner: Mohamedhany99
- Created: 2024-12-05T13:26:52.000Z (29 days ago)
- Default Branch: master
- Last Pushed: 2024-12-05T15:48:42.000Z (28 days ago)
- Last Synced: 2024-12-05T16:35:18.235Z (28 days ago)
- Language: Python
- Size: 6.84 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# File Service API
A Django REST API service that handles file management operations and provides random line retrieval functionality with multiple response format support.
## Features
- File Upload and Management
- Random Line Retrieval from Files
- Multiple Response Format Support (JSON, XML, Plain Text)
- Line Statistics (line number and most common letter)## Tech Stack
- Python
- Django
- Django REST Framework
- SQLite (Default Django Database)## API Endpoints
### File Management
- `POST /upload/`: Upload new files.
- `GET /random-line/`: Get a Random line of a random uploaded file.
- `GET /random-line-backwards/`: Get a random line backwards from a random uploaded file.
- `GET /longest-20-lines//`: get the 20 longest lines in a specified file.
- `GET /longest-100-lines/`: get the 100 longest lines in all the files.## Setup and Installation
1. Clone the repository
```bash
git clone
cd file_service
```
2. Create and activate a virtual environment
```bash
python -m venv venv
source venv/bin/activate # On Windows use: venv\Scripts\activate
```
3. Install dependencies
```bash
pip install -r requirements.txt
```
4. Run migrations
```bashpython manage.py migrate
```
5. Start the development server
```bash
python manage.py runserver
```