Teamwork is an internal social network for employees of an organization. The goal of this application is to facilitate more interaction between colleagues and promote team bonding.
Heroku: https://teamworkapps-backend.herokuapp.com/api/v1
API documentation: https://teamwork-capstone-project.herokuapp.com/api-docs/
Features
Technology
Installation
Testing
API End Points
Below are the teamwork features app
- Admin can create an employee user account.
- Admin/Employees can sign in.
- Employees can post gifs.
- Employees can write and post articles.
- Employees can edit their articles.
- Employees can delete their articles.
- Employees can delete their gifs post.
- Employees can comment on other colleagues' article post.
- Employees can comment on other colleagues' gif post.
- Employees can view all articles and gifs, showing the most recently posted articles or gifs
first.
- Employees can view a specific article.
- Employees can view a specific gif post.
- Employees can view all articles that belong to a category (tag).
- Employees can flag a comment, article and/or gif as inappropriate.
- Admin can delete a comment, article and/or gif flagged as inappropriate.
Modern JavaScript technologies were adopted in this project
ES2015: Also known as ES6 or ECMASCRIPT 6, is a new and widely used version of Javascript that makes it compete healthily with other languages. See here for more infromation.
NodeJS: Node.js is an open-source, cross-platform JavaScript run-time environment which allows you enjoy the features of Javascript off the web browsers and implement server-side web development. Visit here for more information.
ExressJS: This is the web application framework for Node.js Visit here for more information
Postgres Database: PostgreSQL is a powerful, open source object-relational database system with over 30 years of active development that has earned it a strong reputation for reliability, feature robustness, and performance.
Codes are written in accordance with Airbnb JavaScript style guide, see here for details.
- Clone this repository into your local machine:
https://github.com/marusoft/teamwork
- Navigate into the cloned repository in your machine:
cd teamwork
- Install dependencies by running.
npm install
-
Create a .env file in the root directory and setup your database credentials and token key. Check
.env.example
for instruction. -
Start the application by running
npm run start:dev
- Install
postman
to test all endpoints
- run test using
npm run test
HTTP VERB | ENDPOINT | FUNCTIONALITY |
---|---|---|
POST | api/v1/auth/create-user | Create a user |
POST | api/v1/auth/signin | Login a user |
POST | api/v1/gifs | Employees can post gifs. |
DELETE | api/v1/gifs/<:gifId> | Employees can delete their gifs post. |
POST | api/v1/gifs/<:gifId>/comment | Employees can comment on other colleagues' gif post. |
GET | api/v1/gifs/<:gifId> | Employees can view a specific gif post. |
POST | api/v1/articles | Employees can write and post articles. |
DELETE | api/v1/articles/<:articleId> | Employees can delete their articles. |
POST | api/v1/articles/<:articleId/comment | Employees can comment on other colleagues' article post. |
GET | api/v1/articles/<:articleId> | Employees can view a specific article post. |
PATCH | api/v1/articles/<:articleId> | Employees can edit their articles. |
GET | api/v1/articles?category=category> | Employees can view all articles that belong to a category (tag). |
GET | api/v1/articles | Employees can view all articles. |
GET | api/v1/feed | Employees can view all articles and gifs, showing the most recently posted articles or gifs first. |
- Alimi Kehinde Morufudeen