Skip to content

Satora1/Twatter-backend

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

alt text

TWITTER CLONE (BACKEND)

Authors

Features

  • Creating and storing users
  • Authorization and Authentication of Users
  • Adding posts (twatts)
  • Creating groups

Tech Stack

Server: Java, Hibernate, Spring Boot, Spring Security, REST API

API Reference

Twatts (posts) API

Get 10 latest posts by page number

  GET /twatts
Parameter Type Description
page int Required. Page number

Get post by id

  GET /twatts/${id}
Parameter Type Description
id Long Required. Id of item to fetch

Get post by user

  GET /twatts/user/${username}
Parameter Type Description
username String Required. name of user the posts belong to

Add new post

  POST /twatts/

Delete post by id

  DELETE /twatts/${id}
Parameter Type Description
id Long Required. Id of item to delete

User API

Get user by id

  GET /user/${id}
Parameter Type Description
id Long Required. User id

Get current user by Access token

  GET /user/me

Add a friend to given user

  POST /{userId}/addFriend/{friendId}

Delete a friend from given user

  DELETE /{userId}/addFriend/{friendId}

Group API

Get all groups

  GET /groups/

Add a group

  POST /groups/

Get group by id

  GET /groups/{groupId}

Delete a group by id

  DELETE /groups/{groupId}

####Add a user to group

  POST /{groupId}/addUser/{userId}

####Remove a user from group

  DELETE /{groupId}/addUser/{userId}

Used By

This project is used by its Frontend equivalent :

Releases

No releases published

Packages

No packages published

Languages