A microblog website clone for use with Made Tech Core Skills
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
bin
lib
spec
.rspec
Dockerfile
Gemfile
Gemfile.lock
Guardfile
Makefile
README.md
config.ru
docker-compose.yml

README.md

Chirper

A super simple file based "Popular Microblogging Website" clone

Endpoints

  • get /timeline
    • Returns all the Chirps
    • Example response: [{id: 1, username: 'Foo', body: 'Bar', favourites: 10}]
  • post /create-chirp
    • Creates a new Chirp
    • Example request: {username: 'Foo', body: 'Bar'}
  • favourite /favourite
    • Favourites a chirp
    • Example request: {id: 10}

Developing Chirper

Prerequisites

  • Docker
  • Docker Compose

Run the tests

make test

Serving

make serve

This runs the Chirper API on port 4567

The chirp file will be prepopulated with the following Chirps:

[
  {
    "id": 0,
    "username": "Cats4Lyf",
    "body": "Cats are great",
    "favourites": 0
  },
  {
    "id": 1,
    "username": "Dogs4Eva",
    "body": "All dogs are good dogs",
    "favourites": 0
  }
]