Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mr-sunglasses/flask-mongo-api
https://github.com/mr-sunglasses/flask-mongo-api
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/mr-sunglasses/flask-mongo-api
- Owner: Mr-Sunglasses
- Created: 2023-03-24T18:28:40.000Z (almost 2 years ago)
- Default Branch: master
- Last Pushed: 2023-03-26T17:13:23.000Z (almost 2 years ago)
- Last Synced: 2024-05-02T10:24:17.028Z (8 months ago)
- Language: Python
- Size: 59.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Users API written with Python and MONGODB
```
git clonecd
pip3 install -r requirements.txt
python3 app.py
```# ENV
```dotenv
SECRET_KEY = YOUR_SECRET_KEY
MONGO_URI = YOUR_MONGODB_URL
```# USING docker
```docker
docker build -t image_name .docker run -e SECRET_KEY="YOUR_SECRET_KEY" -e MONGO_URI = "YOUR_MONGODB_URL" image_name:latest
```
# API USUAGE
```docker
○ GET /users - Returns a list of all users.
○ GET /users/ - Returns the user with the specified ID.
○ POST /users - Creates a new user with the specified data.
○ PUT /users/ - Updates the user with the specified ID with the new data.
○ DELETE /users/ - Deletes the user with the specified ID.
```