The Grill Scrible is a powerful and flexible backend Backend for a Blogging Website. Built using Django Rest Framework, it provides all the essential functionalities required to create and manage a dynamic blogging platform. With features like user authentication, tagging, and commenting system, The Grill Scrible is designed to empower bloggers and enhance the user experience.
The project is currently hosted on PythonAnyWhere server for testing purpose : https://pranavtiwari.pythonanywhere.com/
-
Django Rest Framework: A powerful and flexible toolkit for building Web APIs using Django.
-
Python: The programming language used for the backend development.
-
MySQL: A robust and scalable relational database for storing blog posts, user information, and related data. (provided by PythonAnyWhere server)
-
PythonAnyWhere: The server used for testing and demonstration purposes.
To start using The Grill Scrible, follow the steps below:
-
Clone the repository:
git clone https://github.com/your-username/the-grill-scrible.git
-
Install the project dependencies:
pip install -r requirements.txt
Tip
|
Fill in database details in settings.py |
-
Set up database
python manage.py makemigrations python manage.py migrate
-
Run the server:
TIP: python manage.py runserver
The backend API will be accessible at http://localhost:8000.
Purpose | Endpoints | Method | Sample | Authentication |
---|---|---|---|---|
Register user |
'account/register/' |
POST |
[Authentication: none] |
|
Login user |
'account/login/' |
POST |
[Authentication: Credentials] |
|
Logut user |
'account/logout/' |
POST |
[Authentication: JWT Access Token] |
|
Refresh Token |
'account/refresh/' |
POST |
[Authentication: JWT Refresh Token] |
|
Profile detail |
'account/profile/' |
GET |
[Authentication: Admin] |
|
Profile detail update |
'account/profile/' |
PUT |
[Authentication: Admin] |
Purpose | Endpoints | Method | Sample | Authentication |
---|---|---|---|---|
View all blog posts |
'blog/' |
GET |
[Authentication: none] |
|
Search a blog posts |
'blog/?search=<search-by>' |
GET |
https://pranavtiwari.pythonanywhere.com/blog/?search=DataScience |
[Authentication: none] |
Create a blog post |
'blog/' |
POST |
[Authentication: JWT Access Token] |
|
View an individual blog post |
'blog/<int:blog-id>/' |
GET |
http://pranavtiwari.pythonanywhere.com/blog/1/ [ex blog 1] |
[Authentication: none] |
Update a individual blog post |
'blog/<int:blog-id>/' |
PUT |
http://pranavtiwari.pythonanywhere.com/blog/1/ [ex blog 1] |
[Authentication: Author/JWT Access Token] |
Delete a individual blog post |
'blog/<int:blog-id>/' |
DELETE |
http://pranavtiwari.pythonanywhere.com/blog/1/ [ex blog 1] |
[Authentication: Author/JWT Access Token] |
Like a individual blog post |
'blog/<int:blog-id>/like' |
DELETE |
http://pranavtiwari.pythonanywhere.com/blog/1/like/ [ex blog 1] |
[Authentication: Only one like per IP Address] |
View all blog posts of logged in user |
blog/mylist/ |
GET |
[Authentication: JWT Access Token] |
Purpose | Endpoints | Method | Sample | Authentication |
---|---|---|---|---|
View all comments of a blog post |
'blog/<int:blog-id>/comments/' |
GET |
http://pranavtiwari.pythonanywhere.com/blog/1/comments/ [ex blog 1] |
[Authentication: none] |
Create a comment for a blog post |
'blog/<int:blog-id>/comments/' |
POST |
http://pranavtiwari.pythonanywhere.com/blog/1/comments/ [ex blog 1] |
[Authentication: none] |
View an individual comment post |
'blog/comments/<int:comment-id>/' |
GET |
http://pranavtiwari.pythonanywhere.com/blog/comments/1/ [ex blog 1] |
[Authentication: none] |
Delete a individual comment post |
'blog/comments/<int:comment-id>/' |
DELETE |
http://pranavtiwari.pythonanywhere.com/blog/comments/1/ [ex blog 1] |
[Authentication: Admin] |
Purpose | Endpoints | Method | Sample | Authentication |
---|---|---|---|---|
View all tags |
'blog/tags/' |
GET |
[Authentication: none] |
|
Create a tag |
'blog/tags/' |
POST |
[Authentication: Admin] |
|
View an individual tag |
'blog/tags/<int:tag-id>/' |
GET |
http://pranavtiwari.pythonanywhere.com/blog/tags/1/ [for comment 1] |
[Authentication: none] |
Update a individual tag |
'blog/tag/<int:tag-id>/' |
PUT |
http://pranavtiwari.pythonanywhere.com/blog/tag/1/ [ex blog 1] |
[Authentication: Admin] |
Delete a individual tag |
'blog/tag/<int:tag-id>/' |
DELETE |
http://pranavtiwari.pythonanywhere.com/blog/tag/1/ [ex blog 1] |
[Authentication: Admin] |
The Backend contain all essential features:
The Grill Scrible enables user registration, login, and logout functionality, ensuring secure access to the platform through JWT Authorization.
-
Can access all blogs and their associated comments
-
Can can like any blog
-
Can comment on any blog
Implement a powerful search feature that allows users to search for specific blog posts using author details, keywords or tags. https://pranavtiwari.pythonanywhere.com/blog/list/?search=DataScience