Skip to content

Repository files navigation

Jogging-Tracker-API

About The Project

Jogging-Tracker-API is a RESTful API that tracks jogging times of users.

Functionality requirements:

  • Authentication: Create account / login / logout.
  • When logged in, a user can view, edit and delete entered jogging times.
  • Implement three roles with different permission levels: a regular user would only be able to CRUD on their owned records, a moderator would be able to CRUD users, and an admin would be able to CRUD all records and users.
  • Each time entry when entered has a date, distance, and time.
  • Filter by dates from-to.
  • Report on average speed & distance per week.

Built with

Getting Started

This is an list of needed instructions to set up your project locally, to get a local copy up and running follow these instructions.

Installation

Clone the repository

git clone git@github.com:GeekMind00/Jogging-Tracker-API.git

Navigate to repository directory

$ cd Jogging-Tracker-API

Project Setup

Install all gems:

$ bundle install

Update the database with new data model:

$ rails db:migrate

Start the web server on http://localhost:3000 by default:

$ rails server

Usage

HTTP verbsPaths Used for
POST/signupCreate a user
POST/loginAuthenticate a user
DELETE/logoutTerminate a user's session
GET/usersList all users
GET/users/:idShow a single user
POST/usersCreate a user
PUT/users/:idUpdate a user
DELETE/users/:idDelete a user
GET/jogging_records?from=date&to=dateList all jogging records
GET/jogging_records/:idShow a single jogging record
POST/jogging_recordsCreate a jogging_record
PUT/jogging_records/:idUpdate a jogging record
DELETE/jogging_records/:idDelete a jogging record
GET/weekly_reportShow weekly report of jogging records

Postman Use Case Examples

JoggingTracker-API Collection

About

Jogging-Tracker-API is a RESTful API that tracks jogging times of users.

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages