EMielke76 / jasmine_dragon_api

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

"So I was thinking about names for my new tea shop… how about… the Jasmine Dragon? It’s dramatic, poetic… has a nice ring to it." --Uncle Iroh, "Avatar: The Last Airbender"

languages PRs rspec simplecov All Contributors

Table of contents

Overview

A REST API webservice built to facilitate subscriptions to a tea-delivery service. Tea information is provided to the mock-front end via consumption of an external API found here

This project is a technical challenge presented by the Turing School of Software and Design. Original specs and requirements may be found here

Challenge Specs

At a minimum, the following functionality must be built:

  • An endpoint to subscribe a customer to a tea subscription
  • An endpoint to cancel a customer’s tea subscription
  • An endpoint to see all of a customer’s subsciptions (active and cancelled)

Additional Endpoints Created:

  • GET All teas.
  • GET A single tea.
  • PATCH Update a users' subscription frequency or status.
  • DELETE Delete a subscription.

Additional Functionality implimented:

  • Consumed external API for tea data, seralized and exposed two endpoints for said data.
  • Created dynamic pricing for subscriptions based on frequency.
  • Prepped to handle User data storage via Bcrypt encryption.

DB Schema

image

API Docs

Click here to see the documentation related to this API, including example request and response payloads.

Setup

  1. Fork and Clone the repo
  2. Install gem packages: $ bundle install
  3. Setup the database: $ rails db:{drop,create,migrate,seed}
  4. Run $ bundle exec rspec to run the full test suite. note If there is an error when running the test suite related to VCR Cassettes, navigate to the spec directory and delete the fixtures directory found within. This should alleviate any issues related to the VCR API mock-calls.
  5. Open a server with $ rails s

Technologies

Versions

  • Ruby 2.7.2
  • Rails 5.2.5

Development tools employed

Languages

  • Ruby

Testing tools

Development Principles

  • OOP
  • TDD
  • MVC
  • REST

Contributors

About


Languages

Language:Ruby 78.5%Language:HTML 21.5%