Skip to content

raviverma2791747/Social-Media

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

 

Social Media App

Github top language Github language count Repository size Github issues Github forks Github stars

🚧 🚀 Django based Social Media App using Django Rest and React Framework. 🚧


About   |   Technologies   |   Requirements   |   Contributing   |   Author


🎯 About

This is a simple social media application. The user can register,login,post,comment and follow on this application.

🚀 Technologies

The following tools were used in this project:

✅ Requirements

Before starting 🏁, you need to have Git, Python 3.8, and the above Libraries installed.

👨‍💼 Contributing

For major changes, please open an issue first to discuss what you would like to change.

Instructions to run

  1. open terminal in root directory
  2. run command cd website
  3. run command npm run build
  4. run command cd ..
  5. run command python manage.py runserver
cd website
npm run build
cd ..
python manage.py runserver

API

Send all POST request with Headers X-CSRFToken : csrfcookie value

GetCSRFToken

localhost/api/getcsrf accepts GET request with no data

Register user

localhost/api/account/register accepts POST request with json data

{
   "username" : "myusername",
   "password" : "mypassword",
   "re_password" : "mypassword",
   "email" : "myemail",
   "first_name" : "myfirst",
   "last_name" : "mylast"
} 

Login user

localhost/api/account/login accepts POST request with json data

{
   "username" : "myusername",
   "password" : "mypassword",
}

IsAuthenticated user

localhost/api/account/isauthenticated accepts GET request with no data

Logout user

localhost/api/account/logout accepts POST request with no json data

Delete user

localhost/api/account/delete accepts DELETE request with no jsond data

Current User

localhost/api/profile/current_user accepts GET request

{
 'status' : 'success',
 'message' : '',
 'data' : {
   'username' : 'myusername'
 }
}
API Types Response
/api/account/register POST --

📝 License

This project is under license from MIT. For more details, see the LICENSE file.

Made with ❤️ by Ravi Verma

 

Back to top

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published