Forum Discussion

17 Replies

  • @lounatic99 You’re welcome. Curious which page source you inspected to find that? I really would like to see if the match history data can return more than five games.

  • Viktors89's avatar
    Viktors89
    5 years ago

    Thanks for the tips guys, will work on this for my team. Already lost track of this ticket!

  • PlayoffError's avatar
    PlayoffError
    Hero
    5 years ago

    Did you ever find a way to see more than the last five matches?

  • lounatic99's avatar
    lounatic99
    5 years ago
    @PlayoffError no just 5... it's all that shows on the EA site too. You could store to a DB and keep adding new games though.
  • PlayoffError's avatar
    PlayoffError
    Hero
    5 years ago

    Got it.  I was hoping to get the entire history, but I guess getting the info for games moving forward will have to do.  Thanks!

  • FB_ItsJanks's avatar
    FB_ItsJanks
    5 years ago

    I am trying to figure out a way to essentially scrape all the club match history into a google sheet. I am super new to coding and this whole curl and query java script. If you could let me toward the right direction that would be great!

  • Match history is challenging because you can only get the last five results, so you’ll have to archive the data every five games or less.

    You can open a command prompt in windows and simply copy and paste the cURL command above, substituting your team ID. Obtain your team ID by searching for your club on the official EASHL ranking page. You also have to change the match type in the command to either 10 or 5. 5 is for normal games and 10 is for the club championship games (I think the window for those just closed)

    The data comes back as a JSON string which you can paste into a JSON formatter online to see how the data is structured.

    Also, you can save the data as a file with a .json extension and excel can process it for you; but I haven’t spent much time doing that myself 

  • FB_ItsJanks's avatar
    FB_ItsJanks
    5 years ago

    So i took your idea and went a different route a bit and it worked. I want to thank you from the bottom of my heart for helping me out with this. There is only one small problem which I need to work on. All of this is manual. I am trying to look up a script where it can do this for me automatically. Thank you for leading me in the right place with your line code. This is helped the league I'm a part of out a ton! 

    here is the URL to the google sheets doc https://docs.google.com/spreadsheets/d/1Uk8hVjL0yCxU4u7Xt5NqHRnsNLB9QXPSmY9RqNELe6k

  • You’re welcome! PM me and maybe I can help you take it a step further. I signed up for a free online database where I store my data at jsonbin.io. Once saved there you can at least have an archive.

  • Rx7RaVeN1's avatar
    Rx7RaVeN1
    5 years ago

    @GeorgeandpfunkI attempted to PM you but receive an access denied page.

    Similar to what others are doing, I have a project (python/postgresql/flask) going to mess with the JSON data from match history. Was wondering if you would be interested in providing some guidance parsing the JSON data?

  • Of course! I sent you one that seems to have worked, let me know if you got it 

  • missilecommand's avatar
    missilecommand
    5 years ago

    hey, i was wondering if you would be able to point me in the right direction. I converter the json to xml, then used gist for url so that i could importxml in google sheets. I cant figure out how to have the objects listed along with the values. Its just values only.

  • missilecommand's avatar
    missilecommand
    5 years ago

    So did a bunch of learning and actually got it to work pretty nicely using google sheets. Using an add on to fetch the api, and a butt load of formulas to get the data appealing. I also made image buttons so teams can actually do it themselves. Then the league doesnt want to because they are worried something might happen, told them it would never be a big issue, but they are computer illiterate.

  • missilecommand's avatar
    missilecommand
    5 years ago

    Fist shot is the api data collector in its own work book. Then i import the range for the specific team, followed by a bunch of query functions to filter by date state category and combine that data incase of lagouts. This page wont be seen by user, runs in back ground. Then last shot is the one users will see and they only have to click the images.

About NHL Franchise Discussion

Long-time fan? Tell us about your knowledge with the sport and the game franchise in our NHL Franchise community forum.17,623 PostsLatest Activity: 3 years ago