Simple REST API for a photo gallery app. Users can create an account and manage their photo collection.
Please update docker-compose.yml
with AWS credentias for S3 file uploads.
Run locally with Docker Compose:
docker-compose up
Method | Endpoint | Functionanlity |
---|---|---|
POST | /api-token-auth |
Request jwt token |
Method | Endpoint | Functionality |
---|---|---|
GET | /api/user |
List users |
GET | /api/user/create |
Creates a user |
GET | /api/user/profile/{pk} |
Retrieve a user |
PUT | /api/user/update/{pk} |
Edit a user |
DELETE | /api/user/destroy/{pk} |
Delete a user |
Method | Endpoint | Functionality |
---|---|---|
POST | /api/user/images/upload |
Upload an image, image_type private or public. |
GET | /api/user/images/public |
List of public image URLs |
After updating the data model, make migrations and migrate.
python manage.py makemigrations && python manage.py migrate
Create super user
python manage.py createsuperuser
Run tests
python manage.py test
- Django
- Django REST framework
- Django Storages for uploading to AWS S3
- SQLite database
- Amazon Web Services
- S3 for images
- Elastic Beanstalk for hosting
- Docker
The following resources where helpful in making this API: