Code Monkey home page Code Monkey logo

c3projects--java--videostoreapi's Introduction

Project: VideoStoreAPI

The overall goal of this project is to create a system that a video store (remember those?) could use to track their inventory of rental videos and their collection of customers.

We will use Java to construct a RESTful API. The goal of this API is to quickly serve information about the store's video collection, customer information, and to update rental status. This repository provides two JSON datafiles to serve as the initial seeds for this system.

movies.json contains information about the videos available to rent at the store. The data is presented as an array of objects, with each object having the following key-value pairs:

  • title: The title of the film
  • overview: A short plot synopsis
  • release_date: When the film was originally released
  • inventory: How many copies of the film the video store owns

customers.json contains information about the customers that have rented with the store in the past. The data is presented as, you guessed it, an array of objects, with each object have the following key-value pairs:

  • id: A unique identifier
  • name: The customer's name
  • registered_at: When the customer first visited the store
  • The customer's physical address, composed of:
    • address
    • city
    • state
    • postal_code
  • phone: Primary contact phone number
  • account_credit: For reason we'd rather not get into, the store owes all of their customers a little bit of money; this amount is made available to customers as credit toward future rentals.

Project Baseline

  • Read the API Requirements below and create a pseudo-code "routes" file that
    • defines the endpoints your API will need
    • the HTTP verbs each endpoint will use
    • and any data that must be provided to the endpoint in order for it to do its work.
  • Create a new Java/Spring app to serve as the API.
  • Create a route that responds to /zomg that serves a json-encoded "it works!" method.
  • Seed your database using the provided json data.

API Requirements

The API you build should have the following capabilities. The schema of your database/datastore, and the structure of the endpoints are completely up to you.

Authentication

  • There is not an authentication requirement for this project; assume all users interacting with the API are video store employees.

Customers

  • Retrive a list of all customers
  • Retrive a subset of customers
    • Given a sort column, return n customer records
    • Sort columns are
      • name
      • registered_at
      • postal_code

Movies

  • Retrieve a list of all movies
  • Retrieve a subset of movies
    • Given a sort column, return n movie records
    • Sort columns are
      • title
      • release_date
  • Look a movie up by title to see
    • its synopsis
    • release date
    • and inventory total

Interface

  • This part of the project is purely an API; all interactions should happen over HTTP requests. There is no front-end, user-facing interface.

Testing

  • All endpoints must be tested.
  • We will use JUnit for tests.
  • There isn't a coverage requirement for this project, beyond demonstrating that every endpoint is covered by some manner of tests.

c3projects--java--videostoreapi's People

Contributors

a-lmx avatar jnf avatar

Watchers

 avatar

Forkers

corinnepingul

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.