连接器指南阅读约 4 分钟40 个 MCP 工具7 种语言

API-Football 接入 MCP:从任意 AI 代理驱动 API-Football

让你的 AI 通过 API-Football 关注足球:实时比分和比赛事件、赛程、积分榜、球队和球员统计、首发阵容、伤病、转会、历史交锋、比赛预测和博彩公司赔率,覆盖全球的联赛和杯赛。使用你 API-Sports 账户的 API 密钥。

HC作者:HelpCode 团队更新于 4 分钟阅读 在 GitHub 开源

无需信用卡 · 7 天试用 · 提供自托管方案

API-Football

API-Football

Live and historical football (soccer) data from API-Football v3 (API-Sports): leagues, standings, fixtures with live scores & events, teams, players & statistics, predictions, injuries, transfers and betting odds.

个工具

40

区域

INTL

类别

体育

身份验证

API Key

所需环境变量

API_FOOTBALL_KEY
在 Cloud 上一键安装

7 天免费试用 · 无需信用卡

  • 7 天免费试用
    无需信用卡
  • 符合 GDPR,SOC 2 就绪
    数据驻留欧盟,审计日志
  • 在 GitHub 开源
    开源 · AGPL-3.0
  • 支持 ChatGPT、Claude、Gemini
    任何兼容 MCP 的客户端

跳过安装。2 分钟内即可运行。

在 cloud.anythingmcp.com 开始免费试用,一键添加 API-Football,然后将你的 AI 客户端(Claude、ChatGPT、Copilot 或 Cursor)指向生成的 MCP 端点。无需 Docker,无需 git clone,无需任何工程经验。

开始免费试用

摘要

让你的 AI 通过 API-Football 关注足球:实时比分和比赛事件、赛程、积分榜、球队和球员统计、首发阵容、伤病、转会、历史交锋、比赛预测和博彩公司赔率,覆盖全球的联赛和杯赛。使用你 API-Sports 账户的 API 密钥。

试试这样问

API-Football 的示例提示

点击任意提示即可复制,然后粘贴到 Claude、ChatGPT、Cursor、Gemini、Copilot 或 OpenClaw 中,在该连接器上运行。

API-Football · 通过 MCP 实时
分享
Opus 4.7

Claude 是 AI,可能会出错。请核对回答。

💡 无需安装? 直接使用 cloud.anythingmcp.com。 登录、点击 Connectors → API-Football、粘贴凭证、生成 MCP API key,即可完成。无 Docker、无 git clone、无本地服务器。

API-Football

让你的 AI 通过 API-Football 关注足球:实时比分和比赛事件、赛程、积分榜、球队和球员统计、首发阵容、伤病、转会、历史交锋、比赛预测和博彩公司赔率,覆盖全球的联赛和杯赛。使用你 API-Sports 账户的 API 密钥。

设置

  1. 在 dashboard.api-football.com 免费注册账户。登录后,控制台会显示你的 API 密钥。试用连接器用免费套餐就够了。
  2. 把密钥粘贴到 API_FOOTBALL_KEY,然后安装连接器。密钥会以 x-apisports-key 请求头发送给 API-Sports。请使用 API-Sports 控制台里的密钥:通过 API 市场购买的密钥使用不同的请求头,在这里无法使用。
  3. 先调用 af_status。它会显示你的套餐、每日请求上限和已用数量,本身不计入配额。
  4. 做任何分析时,先从 af_analysis_playbook 开始。它不调用 API,会按请求类型返回要依次使用的工具:赛前预览或预测、赛后报告、球队状态、积分榜、最佳球员、球员球探、阵容名单、伤病、转会、赔率或实时比赛。

先把名称换成 ID:几乎每个工具都需要数字 ID,AI 绝不应该猜测。它用 af_leagues 加 search 过滤条件查找赛事(例如德甲 ID 为 78,世界杯 ID 为 1),同时得到可用的赛季;用 af_teams 查找球队。用球队 ID 并把 next 设为 1 调用 af_fixtures,会返回下一场比赛及其 fixture ID,af_predictions、af_fixture_lineups、af_fixture_events、af_fixture_statistics 和 af_fixture_players 都需要这个 ID。球员数据来自按球队和赛季查询的 af_players,按姓名搜索则用 af_player_profiles。

赛季和时间:season 是赛季开始的 4 位年份:2025 表示 2025/26 赛季,2026 年世界杯就是 2026。日期格式为 YYYY-MM-DD。除非 AI 传入 timezone(取值来自 af_timezone),时间均为 UTC。

每日配额:每次调用数据工具都是向 API-Sports 发出一次请求,计入你套餐的每日配额。连接器的说明按免费套餐设定,即每天 100 次请求;付费套餐额度更高。af_status 和 af_analysis_playbook 不消耗配额。一份完整的赛前预览(预测、赔率、首发阵容、双方的球队统计和伤病、射手榜、球员统计、历史交锋)大约需要 12 次调用,而 af_players 这类分页结果每页算一次请求,所以精确的过滤条件(联赛、赛季、球队、日期)能省下不少配额。

预测和赔率是数据,不是投注建议:af_predictions 针对一场比赛返回 API-Football 自己计算的胜、平、负概率、建议和状态对比。af_odds_prematch 和 af_odds_live 返回博彩公司的赔率,AI 可以把赔率换算成隐含概率,再与预测对比。两者都不能保证比赛结果。小型比赛或还很远的比赛可能没有赔率;af_odds_mapping 列出有赔率的比赛,af_odds_bookmakers、af_odds_bets 和 af_odds_live_bets 列出博彩公司和投注类型。

数据覆盖范围:首发阵容通常在开球前约 1 小时确定。在 af_injuries 中,Missing Fixture 表示球员缺阵,Questionable 表示出战存疑。没有裁判工具:裁判只出现在比赛数据中,而且往往很晚才公布。俱乐部的历史交锋数据很完整,国家队则很少。

只读:全部 40 个工具都只读取数据,不会修改你的 API-Sports 账户,安装时也没有默认关闭的工具。

常见错误:API-Football 可能返回 HTTP 200 但实际失败;这时原因写在 errors 字段中,response 为空。token 条目表示密钥错误或缺失:请检查 API_FOOTBALL_KEY。plan 条目表示该赛季或功能不在你的套餐内:在 API-Sports 控制台升级套餐,或改问套餐覆盖的赛季。每日配额用完后,调用会一直失败,直到配额重置;af_status 可以查看剩余次数。errors 为空而 response 也为空,表示没有符合过滤条件的数据,例如赔率尚未公布或赛季尚未开始。

本连接器不会下注,不覆盖 API-Sports 的其他运动项目,也不会推送实时通知:只有在 AI 查询时才获取实时比分。它也不是 football-data.org 连接器,后者使用 football-data.org 自己的令牌。

前提条件: API_FOOTBALL_KEY

本地安装连接器

curl -fsSL https://raw.githubusercontent.com/HelpCode-ai/anythingmcp/main/docker-compose.quickstart.yml -o docker-compose.yml
printf 'JWT_SECRET=%s\nENCRYPTION_KEY=%s\n' "$(openssl rand -hex 32)" "$(openssl rand -hex 32)" > .env
docker compose up -d

打开 http://localhost:3000/connectors/store,选择 API-Football 并填入前提条件中列出的环境变量。

可用工具

ToolWhat it does
af_analysis_playbookSTART HERE for football analysis (optional but recommended): returns, with NO API call, the exact ordered list of af_* tools to run for a…
af_statusAccount status: subscription plan, daily request limit and current usage
af_timezoneList of all valid timezone strings accepted by the timezone parameter of other endpoints
af_countriesList available countries (name, code, flag)
af_leaguesFind LEAGUES & cups + their available seasons and numeric id (needed by standings/fixtures/topscorers/etc)
af_leagues_seasonsList of all season years available across the API (e.g. 2010..2024)
af_teamsFind TEAMS + their numeric id (needed by almost every other tool)
af_team_statisticsA team's season STATISTICS in a competition: form, played, W-D-L, goals for/against (+ averages, home/away split), clean sheets, streaks…
af_team_seasonsList of season years for which a given team has data
af_team_countriesList of countries available for the teams endpoint
af_venuesSearch stadiums/venues (name, address, city, capacity, surface)
af_standingsLeague TABLE / STANDINGS for a season: rank, points, W-D-L, goal difference, form. league=<id>, season=<year>
af_fixturesFootball MATCHES & scores
af_fixtures_roundsList of round names for a league+season (e.g. 'Regular Season - 1')
af_head_to_headHEAD-TO-HEAD history between two teams (h2h='idA-idB'): past meetings with scores, competitions and venues
af_fixture_statisticsTeam match STATISTICS for a fixture: shots, shots on target, possession %, corners, fouls, offsides, passes & accuracy
af_fixture_eventsMatch TIMELINE for a fixture: goals (with assist), cards, substitutions and VAR, each with minute & player
af_fixture_lineupsStarting XI, bench, FORMATION and coach for a fixture
af_fixture_playersPer-player match stats & RATINGS for a fixture (goals, shots, passes, duels, rating)
af_injuriesINJURIES & suspensions, who is OUT or doubtful
af_predictionsTHE match-prediction endpoint for one fixture id (win/draw/loss %, advice, predicted winner, and a form/attack/defence comparison of the…
af_coachsSearch coaches and their career
af_playersPLAYER statistics for a season: goals, assists, rating, minutes, shots, passes, dribbles, duels, cards
af_player_seasonsSeason years available for a player (or all seasons if no player given)
af_player_squadsCurrent squad of a team, or the teams a player belongs to
af_player_teamsList of teams a player has played for
af_player_profilesPlayer personal data (name, age, nationality, height...)
af_topscorersTOP SCORERS / golden boot of a competition: goals, penalties, appearances, minutes-per-goal
af_topassistsTop 20 assist providers of a league+season
af_topyellowcardsTop 20 players by yellow cards in a league+season
af_topredcardsTop 20 players by red cards in a league+season
af_transfersTransfer history
af_trophiesTrophies won
af_sidelinedPast absences (injuries/suspensions) for players/coaches
af_odds_prematchPre-match betting ODDS for a fixture across bookmakers & markets (fixture=<id>; optional bookmaker=/bet=)
af_odds_liveIn-play (live) odds updated in real time
af_odds_live_betsCatalogue of available in-play bet (market) types for live odds
af_odds_mappingMapping of fixtures that have pre-match odds available
af_odds_bookmakersList of available bookmakers (id + name) for the odds endpoints
af_odds_betsList of available pre-match bet (market) types (id + name)

示例提示

  • “给我做一份阿根廷下一场比赛的完整预览:胜负概率、博彩公司赔率、预计首发、伤病情况和两队近期状态。”
  • “给我看德甲目前的积分榜和本赛季射手榜前 10 名。”
  • “现在有哪些意甲比赛正在进行?比分是多少,目前谁进了球?”
  • “皇家马德里现在有谁因伤或停赛缺阵?俱乐部在上一个转会窗口签下了哪些球员?”

下一步

这份指南对你有帮助吗?

你的 API-Football 智能体只差一次点击。

安装连接器,粘贴密钥,向你的 AI 客户端提问。免费试用 7 天,无需信用卡。

相关指南

连接器

如何通过 MCP 将 API-Football 连接到 ChatGPT

让你的 AI 通过 API-Football 关注足球:实时比分和比赛事件、赛程、积分榜、球队和球员统计、首发阵容、伤病、转会、历史交锋、比赛预测和博彩公司赔率,覆盖全球的联赛和杯赛。使用你 API-Sports 账户的 API 密钥。

连接器

如何通过 MCP 将 API-Football 连接到 Claude

让你的 AI 通过 API-Football 关注足球:实时比分和比赛事件、赛程、积分榜、球队和球员统计、首发阵容、伤病、转会、历史交锋、比赛预测和博彩公司赔率,覆盖全球的联赛和杯赛。使用你 API-Sports 账户的 API 密钥。

连接器

如何通过 MCP 将 API-Football 连接到 Cursor

让你的 AI 通过 API-Football 关注足球:实时比分和比赛事件、赛程、积分榜、球队和球员统计、首发阵容、伤病、转会、历史交锋、比赛预测和博彩公司赔率,覆盖全球的联赛和杯赛。使用你 API-Sports 账户的 API 密钥。

连接器

如何通过 MCP 将 API-Football 连接到 Gemini

让你的 AI 通过 API-Football 关注足球:实时比分和比赛事件、赛程、积分榜、球队和球员统计、首发阵容、伤病、转会、历史交锋、比赛预测和博彩公司赔率,覆盖全球的联赛和杯赛。使用你 API-Sports 账户的 API 密钥。

连接器

如何通过 MCP 将 API-Football 连接到 Meta Muse

让你的 AI 通过 API-Football 关注足球:实时比分和比赛事件、赛程、积分榜、球队和球员统计、首发阵容、伤病、转会、历史交锋、比赛预测和博彩公司赔率,覆盖全球的联赛和杯赛。使用你 API-Sports 账户的 API 密钥。

连接器

Billbee 接入 MCP:从任意 AI 代理驱动 Billbee

让你的 AI 处理 Billbee 订单管理:按日期或平台订单号查找你所有电商平台和网店的订单,按 SKU 或 EAN 查询商品的价格和库存,查看客户的订单历史,并列出你的物流服务商。只读,使用 Billbee API 密钥、登录邮箱和 API 密码。