Skip to content

aparlay/laravel

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 

Repository files navigation

Social Media app

please create a project skeleton with the latest version of laravel.

Project Description

our social media app is going to provide some rest api under version 1 routes would be

  • POST v1/login login [Public]
  • POST v1/video create new video [Authenticated API]
  • PUT v1/video/{id}/like like a video [Authenticated API]
  • GET v1/liked/videos list of videos the login user liked. [Authenticated API]

The goal is to create a simple RESTful api that provide above endpoint. consider all the things you need for a production grade project and implement the endpoint. Login endpoint should accept username/password and generate JWT in response for other authenticated endpoint clients will send this JWT as Bearer token in header.

when you complete the project create a PR and send it for our review.

Models

this project is going to work with Monogdb as data storage.

we have to entity in our database.

Collections

we have three collection in our database videos, likes, users

Videos

  • _id ObjectID
  • name String
  • file String
  • created_at UTCDateTime
  • created_by ObjectID

Likes

  • _id ObjectID
  • video_id ObjectID
  • created_at UTCDateTime
  • created_by ObjectID

Users

  • _id ObjectID
  • username String
  • password_hash String
  • created_at UTCDateTime
  • OTHER REQUIRED FIELDS FOR AUTHENTICATION

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published