jgaussens / caradisiac

Workshop about api

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CARADISIAC

Drive comfortably

Table of Contents generated with DocToc

Introduction

caradisiac.com provides a tone of technical records related to car specification.

Objective - Workshop in 1 sentence

Build an api that get the list of SUV with the higher rate and the higher volume (car boot)

The api

  • must listen port 9292
  • must provide endpoint /populate to index records to Elasticsearch
  • must provide endpoint /suv that return list of paginated higher rate and higher volume suv

How to do that?

By indexing technical records from caradisiac to Elasticsearch and build an api with Node.js

Stack

Node.js + ES6 + Elasticsearch

Just tell me what to do

  • Fork the project via github
  • Clone your forked repository project https://github.com/YOUR_USERNAME/caradisiac
cd /path/to/workspace
❯ git clone git@github.com:YOUR_USERNAME/caradisiac.git
  • Follow the steps
  • commit your different modifications:
cd /path/to/workspace/caradisiac
❯ git add -A && git commit -m "feat(es): index in bulk all car records"

(why following a commit message convention?)

  • Don't forget to push before the end of the workshop and before the end of the dedicated sessions
❯ git push origin master

Note: if you catch an error about authentication, add your ssh to your github profile.

  1. If you need some helps on git commands, read git - the simple guide

Examples of steps to do

Populate

  1. use the package node-car-api to get all records in json format
  2. index - with bulk - all records to Elasticsearch

List of suv

  1. Build an api that provide endpoint /populate
  2. Build an api that provide endpoint /suv
  3. The /suv endpoint could be a ES query to fetch the right data

MVP

  1. Build an api that provide endpoint /populate
  2. Build an api that provide endpoint /suv

Client-side (bonus)

Display the list of the cars with React

Don't forget

Focus on api

Licence

Uncopyrighted

About

Workshop about api


Languages

Language:JavaScript 97.0%Language:CSS 3.0%