梦幻英超API [英] Fantasy Premier League API

查看:114
本文介绍了梦幻英超API的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有人知道幻想英超联赛网站是否有API吗?找到了一些旧帖子,但链接不再起作用.应用商店上有几个应用,所以一定要有东西吗?

Does anyone know if there is an API for the fantasy Premier league website? Found a few old posts but the links don't work anymore. There are a couple of apps on the app store so must be something ?

推荐答案

编辑

似乎在2019/2020赛季,他们将URL从drf重命名为api.这是新的URL:

It seems for the 2019/2020 season, they renamed the URLs from drf to api. Here are the new URLS:

所有球员/球队数据以及更多信息:

All player/team data and more:

  • https://fantasy.premierleague.com/api/bootstrap-static/
  • Specific player: https://fantasy.premierleague.com/api/element-summary/[player_id]/
  • Example first player: https://fantasy.premierleague.com/api/element-summary/1/

原始

这些是目前可以使用的新功能:

These are new ones that currently work:

  • All player/team data and more: https://fantasy.premierleague.com/drf/bootstrap-static
  • Specific player: https://fantasy.premierleague.com/drf/element-summary/[player_id]
  • Example Ospina: https://fantasy.premierleague.com/drf/element-summary/1

编辑: 要了解有关链接的信息,您可以检查由fpl网站客户端调用的API. 在Chrome上,查看->开发人员->开发人员工具.然后单击网络选项卡.之后,单击您团队中的球员信息,然后在网络"选项卡上查看正在拨打的电话(请参见下图).

EDIT: To find out about the links, you can check the APIs called by the fpl website client. On Chrome, go to view -> developer -> developer tools. Then click on the network tab. After that, click on a player info in your team, and check the call that is being made on the network tab (see pic below).

编辑2 :您可以在此处看到一个Python实现示例,您可以在其中获得有关某个联赛的有趣统计信息.您可以将其用作起点. https://github.com/spinach/FantasyPremierLeague-Api_Python

EDIT 2: You can see an example of implementation in Python here where you get interesting statistics about a certain league. You can use it as a starting point. https://github.com/spinach/FantasyPremierLeague-Api_Python

这篇关于梦幻英超API的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆