Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Will the player endpoints be added anytime soon? #43

Open
SuperFexy opened this issue Nov 5, 2017 · 7 comments
Open

Will the player endpoints be added anytime soon? #43

SuperFexy opened this issue Nov 5, 2017 · 7 comments

Comments

@SuperFexy
Copy link

I noticed the player.py file is empty. Do you plan to add the player endpoints to this library?

@abudd82
Copy link

abudd82 commented Nov 8, 2017

+1, interested in being able to pull a team's roster.

@Abundnce10
Copy link

Here's what I'm interested in from a player perspective (maybe it's already available). I'm specifically interested in pulling in weekly metrics for a specific player. For example, if you go to the 'Player' tab and then click on the 'Scoring Leaders' sub tab you get a break down of statistics (i.e. passing, rushing, receiving, etc.) for each player. And you can filter on the entire season or a given week. Do you know what the endpoint it to pull in data for a given player for a given week?

@HeyParkerJ
Copy link

@Abundnce10 For that use case, you might want to look at https://github.com/BurntSushi/nflgame. It pulls player stats from a source closer to the "source of truth".

@Abundnce10
Copy link

@HardcoreParkore Sweet, thanks for the link! Ultimately, I'm looking to create a Chrome Extension that inject's my own popup icon next to each player so that I can more easily look at more data from within the 'My Team' view. I was hoping to utilize an ESPN endpoint, since the request will originate from the same domain. Do you think I'll run into any issues trying to query the NFL Game Center JSON data? I'm also planning on making the extension public (or possibly selling subscriptions if I find there's demand for it), so I want to use a data source that won't mind if it's being hit by a couple thousand different users.

@danabrey
Copy link

@Abundnce10 nflgame doesn't provide a public API that you can hit, it merely gives you the tools to query for and store the data from the publicly accessible NFL Game Center data.

I like the sound of the extension you're planning. I think it would certainly require building your own service that responds to requests for stats, though - I don't think ESPN exposes an endpoint that provides that data.

@Abundnce10
Copy link

@danabrey correct me if I'm wrong but I believe this repo is utilizing ESPN's private API endpoints, correct? If that's the case, I'm guessing there must be endpoints for a specific player that just haven't been discovered/documented. For example, when I look at the 'Scoring Leaders' view with the 'Players' tab I see stats for individual players available on a weekly basis, so I'm guessing there is some kind of API endpoint where you can pass in a player ID and week number to get stats for a given week.

I've tried looking through the network calls when that view renders but I can't seem to find any endpoints for a given player. I'm not sure how @rbarton65 originally discovered the endpoints exposed in this repo, but if anyone can help finding a player-specific endpoint I'm happy to add code to the player.py file and make a pull request. Let me know if anyone finds anything!

@danabrey
Copy link

@Abundnce10 I was talking about the NFL Game Center JSON, in reply to you asking if you'd run into any issues pulling data from there :)

There's interesting discussion on Reddit involving @rbarton65 about how endpoints were initially discovered.

It's unlikely that the data in all views is covered by an HTTP-accessible API endpoint, to me - stats pages like that could well just be rendered on the server. There's a playerInfo endpoint but that doesn't return any statistical information such as passing or rushing yards.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants