Skip to content

ZeroOne3010/speeding-hsl-busses

Repository files navigation

Puksun bussit -Twitter-botti

Botti, joka (päällä ollessaan) kertoo Twitteriin @PuksunBussit-käyttäjänä, jos bussit kaahaavat Pukinmäessä kuvan alueella:

{
  "type": "FeatureCollection",
  "features": [
    {
      "type": "Feature",
      "id": 1,
      "properties": {
        "ID": 0
      },
      "geometry": {
        "type": "Polygon",
        "coordinates": [
          [
            [
              24.990907,
              60.247617
            ],
            [
              24.990907,
              60.243575
            ],
            [
              24.994711,
              60.243575
            ],
            [
              24.994711,
              60.247617
            ],
            [
              24.990907,
              60.247617
            ]
          ]
        ]
      }
    }
  ]
}

Techy stuff

Ensure ts-node is installed: npm install -g ts-node. Then build with npm install and run with npm start. Run tests with npm test. Remember to fill in the Twitter secrets into secrets.ts.

Uses the Digitransit API: https://digitransit.fi/en/developers/apis/4-realtime-api/vehicle-positions/

Relies on the following libraries:

About

A Twitter bot that tweets when an HSL bus is speeding.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published