football.py 文件源码

python
阅读 19 收藏 0 点赞 0 评论 0

项目:Pancake-Cogs 作者: UltimatePancake 项目源码 文件源码
def _get_league_fixtures_timeframe(self, server_id: str, league_id: str, timeframe: str):
        """Retrieves specific league matchday fixtures from API

        Optional timeframe parameter:
        The value of the timeFrame argument must start with either p(ast) or n(ext), representing a timeframe either in the past or future. It is followed by a number in the range 1..99. It defaults to n7 in the fixture resource and is unset for fixture as a subresource.
        For instance: p6 would return all fixtures in the last 6 days, whereas n23 would result in returning all fixtures in the next 23 days."""
        params = {'timeFrame': timeframe}
        url = self.api_url + 'competitions/{}/fixtures'.format(league_id)

        return await self._make_request(url, params, server_id)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号