A CRUD application that allows multiple users to share pictures on an online platform. The application also allows users to comment on each other post's and delete a particular post whenever they want.
These steps can be followed to locally installing and setting up the project.
- Clone the repo
cd repo-name
- Create a virtualenv:
$ mkvirtualenv env
or$ python -m venv env
- Activate env :
$ source env/bin/activate
- Install dependencies :
$ pip install -r requirements.txt
- Run project :
uvicorn main:app --reload
These steps can be followed to locally setup the API endpoints. This is independent of the above mentioned production setup.
Currently the REST API has the following endpoints available for access:-
Endpoint | Functionality |
---|---|
\login | Endpoint to signin an user with username and password |
\users | Endpoint to register an user. |
\posts | Endpoint to create a post. |
\posts\all | Endpoint to fetch all posts. |
\posts\image | Endpoint to upload an image. |
\posts\delete{id} | Endpoint to delete a particular post using its id. |
\comments\all{post_id} | Endpoint to fetch all comments of a particular post. |
\comments\create | Endpoint to create a comment. |