Giter Site home page Giter Site logo

kyruus-interview's Introduction

README

This repository contains the outlines of a web API. Review the problem statement below. When you arrive at Kyruus, you will design and implement a solution which satisfies the design criteria.

Problem statement

We would like to build a simple service for managing doctors and their schedules. Requirements:

  • For each doctor we would initially like to store the following:
    • id
    • name
    • locations - represented as a collection of address strings
    • schedule - weekly schedule indicating the hours they are available each day of the week
  • CRUD operations for doctors
  • Ability to book an appointment with a doctor (a tuple of (doctor, location, time))
  • Ability to cancel an appointment with a doctor
  • Ability to get all appointments for a doctor

Expectations/assumptions:

  • The API will be internally-facing and used by other applications/services that we trust
  • The API will be single-tenant (it only contains data for a single customer)
  • A doctor is available at any of his locations for any of his available times
  • A doctor can only have one appointment at a time
  • A doctor can travel instantaneously between locations
  • No UI/front-end is expected

Getting started

Prerequisites

If you did not receive this question as a zipfile, first fork the repository. Then, check out your repository:

$ git clone [email protected]:<your_user>/<your_repo>.git

Create a branch for your work

$ git checkout -b'<your_branch_name>' origin/master

When you've unzipped the zipfile or forked the repository, familiarize yourself with the project structure and the code we've provided as a starting point.
The example package shows the syntax of Flask routes.

To install requirements in a virtual environment begin by running

$ virtualenv doctor_service

Followed by installing requirements:

$ pip install -r requirements.txt

This is a Flask application which comes with some built-in commands.
To start your application, run

$ python manage.py runserver

To execute unit tests, run

$ python manage.py test

Extra questions

Below are a few questions which expand the scope of the service. Please pick one and describe your approach.

  • What are some real-world constraints to booking appointments that would add complexity to this API and how would they impact the design.
  • How would our design change if this API was opened up to external users?
  • What concerns are there with multi-tenant data management and how could we modify the design to increase data security?

Suggestions

  • Start simple
  • Document your assumptions and their impact on the design
  • Stub out areas that are not related to core functionality and describe their expected behavior
  • You may choose any means of persistence (ex: database, third-party service, etc.) or choose to exclude it (e.g. in-memory only). We recognize that integrating with a persistence layer may be time-consuming and by omitting it, more time can be allocated to service development.
  • You may use any third-party libraries you feel are appropriate

Who do I talk to?

  • If you have any questions prior to your interview, please reach out to your designated Kyruus recruiting contact and he/she will get back to you as soon as possible.
  • If you have any feedback on the interview question after you're done, let us know, we're always looking into improving the interview process. Thanks!

kyruus-interview's People

Contributors

jay-bhambhani avatar

Watchers

 avatar

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.