Code Monkey home page Code Monkey logo

nhl.api's Introduction

  • ๐Ÿ‘‹ Hi, Iโ€™m @Afischbacher
  • ๐Ÿ‘€ Iโ€™m interested in building cool stuff! ...
  • ๐ŸŒฑ Iโ€™m currently learning everything! ...
  • ๐Ÿ’ž๏ธ Iโ€™m looking to collaborate on anything! ...
  • ๐Ÿ“ซ How to reach me https://app.andrefischbacher.com ...

nhl.api's People

Contributors

afischbacher avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

nhl.api's Issues

Player stats request?

Just started using this package, first of all, fantastic job, very easy to use.

I'm looking to get player stats by year, it seems like the 3rd party API supports getting stats for a specific player.
https://github.com/dword4/nhlapi#people

Could this request be supported here also?

Option to disable live updates for live feed

I like that there is the live updating on the LiveGameFeedResult class, but this should at least be configurable to turn off, or slow down. I have certain use cases where I'm pulling in the live feed to download shot data and I don't need live updating. I do have another case where the live updating is nice, but 250ms is way too fast. If this could be fixed ASAP, that would be excellent.

Get game schedule for season

Currently, there are a couple of methods to get the current day's schedule and by date. There are a few additional endpoints that the NHL API exposes for getting schedules. In particular I'm looking to use the endpoint that gets the schedule for a particular season in order to know what games to download for that season.

Enhance player statistics

It would be cool to enhance player statistics to include faceoffs won (FOW) as it is used quite often in Yahoo Fantasy Leagues.

Currently as a workaround I need to iterate over all games and check the boxscore and calculate on my own.

Add current datetime to game events

(We spoke on Reddit about this and you requested I open an issue)

The previous API endpoints for retrieving live game data included a datetime field for each event. The newest endpoints don't seem to provide this information anymore. Examples below.

This makes it impossible to chronologically sort events across several games, for example.

Thank you!

Example of old event shape:

{
  "result": {
    "eventCode": "ANA89",
    "eventTypeId": "HIT",
    "description": "Tomas Nosek hit Adam Henrique",
    "event": "Hit"
  },
  "players": [
    {
      "playerType": "Hitter",
      "player": {
        "link": "/api/v1/people/8477931",
        "fullName": "Tomas Nosek",
        "id": 8477931
      }
    },
    {
      "playerType": "Hittee",
      "player": {
        "link": "/api/v1/people/8474641",
        "fullName": "Adam Henrique",
        "id": 8474641
      }
    }
  ],
  "about": {
    "eventIdx": 123,
    "dateTime": "2023-01-09T02:42:01Z",   <------------------------------------------------
    "eventId": 89,
    "period": 2,
    "periodType": "REGULAR",
    "ordinalNum": "2nd",
    "periodTime": "04:13",
    "periodTimeRemaining": "15:47",
    "goals": {
      "away": 2,
      "home": 1
    }
  },
  "coordinates": {
    "x": 32,
    "y": -39
  },
  "team": {
    "name": "Boston Bruins",
    "link": "/api/v1/teams/6",
    "id": 6,
    "triCode": "BOS"
  }
}

Example of new event shape:

{
  "eventId": 57,
  "period": 1,
  "periodDescriptor": {
    "number": 1,
    "periodType": "REG"
  },
  "timeInPeriod": "00:25",
  "timeRemaining": "19:35",
  "situationCode": "1551",
  "homeTeamDefendingSide": "left",
  "typeCode": 509,
  "typeDescKey": "penalty",
  "sortOrder": 13,
  "details": {
    "xCoord": -94,
    "yCoord": 23,
    "zoneCode": "O",
    "typeCode": "MIN",
    "descKey": "tripping",
    "duration": 2,
    "committedByPlayerId": 8478493,
    "drawnByPlayerId": 8481564,
    "eventOwnerTeamId": 30
  }
}

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.