/ice-cream-api

Find the best ice cream shops by location using Yelp API.

Primary LanguageTypeScript

Ice Cream shops API

Find the ice cream shop closest to you!

Production demo:

Getting Started

Prerequisites

Node.js, NPM / Yarn and Docker installed

node -v
yarn -v
docker -v

Installing

Get a development env running You'll need to create a Yelp APP KEY. Create one signing up here: https://www.yelp.com/fusion

  • Create a .env file
  • Copy the content of the .env.example file and paste in your .env
  • Paste your YELP APP KEY in the YELP_APP_KEY field

Run:

docker-compose up

If you are running without docker-compose, fill all the other fields in .env file and run the following command:

yarn dev:server

Running the tests

yarn test

Building the project

yarn build

Resources

All endpoints are using redis as a cache provider.

List shops by city.

GET /shops?location=${city}

Get shop details by id.

GET /shops/${id}

List shop reviews.

GET /shops/${id}/reviews

Invalidate application cache.

DEL /shops

Built With

  • Express - Node.js web application framework
  • Yarn - Package manager that doubles down as project manager
  • Redis - Open source (BSD licensed), in-memory data structure store
  • Yelp API - Data from over 50 million businesses
  • Jest - JavaScript Testing Framework with a focus on simplicity
  • Typescript - Open-source language which builds on JavaScript
  • Babel - JavaScript compiler

Authors

See also the list of contributors who participated in this project.

License

This project is licensed under the MIT License - see the LICENSE.md file for details