This is a Twitter clone whose backend is made in Node.js and Express Framework. Check the Website here.
- About our project
- Tech Stack Used💡
- Backend Key Features ✨
- Postman API documentation
- Preview💻
- Running the server⚙️
- 🔖Steps to Contribute ✅
- 🔑Guidelines✨
- Thanks to all the Contributors ❤️
Welcome to TWEETER, a social media website which provides users with the feature to grow their social connections, raise any issue or get updated of what's happening around. Users can join Tweeter by simply creating their account, having an updated profile, and can create any tweets. Tweeter also provides you the feature to have the experience of real-time chats with your connections.
- Email or Google OAuth Signup/Signin.
- JWT Authentication with complete integration of Refresh and Access tokens.
- PostgreSQL for the DB because of its open source nature and several useful features.
- Real time chat system using web-sockets (socket-io).
- PostgreSQL database implementation using SequelizeORM for its features like relations, eager and lazy loading, read replication and more.
Checkout Postman API documentation here.
tweeter_demo_vid.mp4
Get started on the local machine
- Clone the repository:
git clone https://github.com/[your-github-username]/tweeter-backend.git
To run the server, you need to have NodeJS installed on your machine. If you don't have it installed, you can follow the instructions here to install it.
-
Setup .env file in base directory:
PORT = 3000 DATABASE_URL = '' jwtsecretkey1 = '' PGDATABASE = '' PGUSER = '' PGPASSWORD = '' PGHOST = '' PGPORT = '' MAIL_ID = '' MAIL_PASS = '' GOOGLE_CLIENT_ID = '' GOOGLE_CLIENT_SECRET = '' GOOGLE_AUTH_URI = ''
-
Running with docker
- Using docker ( considering you have external DB setup )
docker build -t tweeter-backend . && docker run -p 3000:3000 --network=host tweeter-backend
- Using docker compose
docker-compose up
- Using docker ( considering you have external DB setup )
-
Running with local machine
-
Install dependencies
npm install
-
Run the server on localhost:
npm start
-
You can access the endpoints from your web browser following this url:
http://localhost:[PORT]
- Contribution is the best way to support and get involved in the community!
- Want to contribute to
TWEETER
? Please check our CONTRIBUTING.md.
We welcome contributions from the community. To contribute to Tweeter Backend, follow these steps:
- Fork the project on GitHub.
- Create a new branch with a descriptive name for your feature or fix.
- Make your changes and ensure that your code follows best practices.
- Test your changes thoroughly.
- Create a pull request (PR) to the main repository, explaining the changes you made and why they are valuable.
- Do not edit/delete someone else's script in this repository. You can only insert new files/folders into this repository.
- Give a meaningful name to whatever file or folder you are adding, changing, etc.
- Welcome to this repository, if you are here as an open-source program participant/contributor.
- Participants/contributors have to comment on issues they would like to work on, and mentors or the PA will assign you.
- Issues will be assigned on a first-come, first-serve basis.
- Participants/contributors can also open their issues using issue_template, but it needs to be verified and labeled by a mentor or PA. Please discuss this with the team once before opening your issues. We respect all your contributions, whether it is an Issue or a Pull Request.
- When you raise an issue, make sure you get it assigned to you before you start working on that project.
- Each participant/contributor will be assigned 1 issue (max) at a time to work.
- Participants are expected to follow project guidelines and coding style . Structured code is one of our top priorities.
- Try to explain your approach to solving any issue in the comments. This will increase the chances of you being assigned.
- Don't create issues that are already listed.
- Please don't pick up an issue already assigned to someone else. Work on the issues after it gets assigned to you.
- Make sure you discuss issues before working on the issue.
- Pull requests will be merged after being reviewed by a mentor or PA.
- It might take a day or two to review your pull request. Please have patience and be nice.
- Always create a pull request from a branch other than
master
. - Participants/contributors have to complete issues before they decided Deadline. If you fail to make a PR within the deadline, then the issue will be assigned to another person in the queue.
- While making PRs, don't forget to add a description of your work.
- Include the issue number (Fixes: issue number) in your commit message while creating a pull request.
- Make sure your solution to any issue is better in terms of performance and other parameters in comparison to the previous work.
- We all are here to learn. You are allowed to make mistakes. That's how you learn, right?
We would like to thank the open-source community and the developers of the technologies used in this project for their valuable contributions.