Skip to content

Latest commit

 

History

History
55 lines (41 loc) · 680 Bytes

README.md

File metadata and controls

55 lines (41 loc) · 680 Bytes

Scroller2

infinite scroll project for understanding networks fall 2017

API Routes

GET

  • /
    • Send all data
{
    "api_status": "ok",
    "data": {
        "state": true,
        "speed": 10,
        "direction": "up"
    }
}
  • /state

    • If device is on (true) or off (false)

      {
      "state": true
      }
  • /speed

    • Number that controls scroll rate

      {
      "speed": 10
      }
  • /direction

    • Scroll up the page ("up") or down the page ("down")

      {
      "direction": "up"
      }

POST

  • /submit
    • Update state, speed, direction
    • Should be x-www-form-urlencoded