football-docs 0.3.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +22 -6
- package/bin/serve.js +2 -2
- package/data/docs.db +0 -0
- package/docs/fotmob/identity-surfaces.md +62 -0
- package/docs/impect/identity-surfaces.md +61 -0
- package/docs/opta/identity-surfaces.md +71 -0
- package/docs/skillcorner/identity-surfaces.md +60 -0
- package/docs/soccerdonna/identity-surfaces.md +66 -0
- package/docs/sportmonks/identity-surfaces.md +65 -0
- package/docs/statsbomb/api-access.md +41 -14
- package/docs/statsbomb/api-endpoints.md +120 -0
- package/docs/statsbomb/data-model.md +54 -11
- package/docs/statsbomb/event-types.md +42 -1
- package/docs/statsbomb/identity-surfaces.md +81 -0
- package/docs/statsbomb/iq-metrics-glossary.md +223 -0
- package/docs/statsbomb/player-mapping.md +148 -0
- package/docs/statsbomb/player-match-stats.md +245 -0
- package/docs/statsbomb/player-season-stats.md +269 -0
- package/docs/statsbomb/team-match-stats.md +217 -0
- package/docs/statsbomb/team-season-stats.md +213 -0
- package/docs/statsbomb/xg-model.md +33 -3
- package/docs/transfermarkt/identity-surfaces.md +69 -0
- package/docs/wyscout/identity-surfaces.md +64 -0
- package/package.json +17 -6
- package/providers.json +45 -0
package/README.md
CHANGED
|
@@ -4,10 +4,20 @@ Searchable football data provider documentation for AI coding agents. Like [Cont
|
|
|
4
4
|
|
|
5
5
|
**Who it's for:** Developers and analysts who use AI coding tools (Claude Code, Cursor, VS Code Copilot, Windsurf) to work with football data. Works with any tool that supports MCP.
|
|
6
6
|
|
|
7
|
-
**What it does:** Gives your AI agent a searchable index of documentation for
|
|
7
|
+
**What it does:** Gives your AI agent a searchable index of documentation for 15 football data providers — event types, qualifier IDs, coordinate systems, API endpoints, data models, identity surfaces, and cross-provider comparisons. Your agent looks up the real docs instead of guessing from training data.
|
|
8
8
|
|
|
9
9
|
**Why not just let the AI figure it out?** LLMs get football data specifics wrong constantly — Opta qualifier IDs, StatsBomb coordinate ranges, API endpoint URLs, library method signatures. These are mutable facts that change across versions. football-docs gives the agent verified, sourced documentation with provenance tracking so you know where every answer came from.
|
|
10
10
|
|
|
11
|
+
## Provider identity facts
|
|
12
|
+
|
|
13
|
+
football-docs is the public source for provider identity-surface facts: access
|
|
14
|
+
shape, ID schemes, matching fields, provider quirks, and provenance rules.
|
|
15
|
+
Curated Reep-derived notes belong here when they can be stated without private
|
|
16
|
+
register state. They should say whether a fact comes from public docs, public
|
|
17
|
+
page evidence, licensed feed shape, or a reviewed public-safe observation, and
|
|
18
|
+
must not include private paths, credentials, scraper state, action ledgers, mint
|
|
19
|
+
salts, or raw restricted payloads.
|
|
20
|
+
|
|
11
21
|
MCP ([Model Context Protocol](https://modelcontextprotocol.io)) is a standard for connecting AI coding tools to external data sources.
|
|
12
22
|
|
|
13
23
|
## Quick start
|
|
@@ -92,6 +102,7 @@ Add to `claude_desktop_config.json`:
|
|
|
92
102
|
- "What is Opta qualifier 76?" (big chance)
|
|
93
103
|
- "How does StatsBomb represent shot events?"
|
|
94
104
|
- "Compare Opta and Wyscout coordinate systems"
|
|
105
|
+
- "Which provider IDs are safe identity bridges for Transfermarkt players?"
|
|
95
106
|
- "Does SportMonks have xG data?"
|
|
96
107
|
- "What event types does kloppy map to GenericEvent?"
|
|
97
108
|
- "How does SPADL represent a tackle?"
|
|
@@ -100,18 +111,23 @@ Add to `claude_desktop_config.json`:
|
|
|
100
111
|
|
|
101
112
|
| Provider | Chunks | Categories |
|
|
102
113
|
|----------|--------|------------|
|
|
103
|
-
| StatsBomb |
|
|
114
|
+
| StatsBomb | 150 | event-types, data-model, coordinate-system, api-access, xg-model, identity-surfaces |
|
|
104
115
|
| kloppy | 100 | data-model, usage, provider-mapping |
|
|
105
|
-
| SportMonks |
|
|
116
|
+
| SportMonks | 78 | event-types, data-model, api-access, identity-surfaces |
|
|
106
117
|
| databallpy | 63 | data-model, overview, usage |
|
|
107
118
|
| mplsoccer | 62 | overview, pitch-types, visualizations |
|
|
108
|
-
| Wyscout |
|
|
119
|
+
| Wyscout | 68 | event-types, data-model, coordinate-system, api-access, identity-surfaces |
|
|
109
120
|
| Free sources | 45 | overview, fbref, understat |
|
|
110
121
|
| soccerdata | 40 | overview, data-sources, usage |
|
|
111
|
-
| Opta |
|
|
122
|
+
| Opta | 36 | event-types, qualifiers, coordinate-system, api-access, identity-surfaces |
|
|
112
123
|
| socceraction | 26 | SPADL format, VAEP, Expected Threat |
|
|
124
|
+
| FotMob | 7 | identity-surfaces |
|
|
125
|
+
| Impect | 7 | identity-surfaces |
|
|
126
|
+
| SkillCorner | 7 | identity-surfaces |
|
|
127
|
+
| Soccerdonna | 7 | identity-surfaces |
|
|
128
|
+
| Transfermarkt | 7 | identity-surfaces |
|
|
113
129
|
|
|
114
|
-
**
|
|
130
|
+
**703 searchable chunks** across 15 providers.
|
|
115
131
|
|
|
116
132
|
## Contributing
|
|
117
133
|
|
package/bin/serve.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { resolve, dirname } from "node:path";
|
|
3
|
-
import { fileURLToPath } from "node:url";
|
|
3
|
+
import { fileURLToPath, pathToFileURL } from "node:url";
|
|
4
4
|
|
|
5
5
|
const __dirname = dirname(fileURLToPath(import.meta.url));
|
|
6
|
-
await import(resolve(__dirname, "..", "dist", "index.js"));
|
|
6
|
+
await import(pathToFileURL(resolve(__dirname, "..", "dist", "index.js")).href);
|
package/data/docs.db
CHANGED
|
Binary file
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
---
|
|
2
|
+
source_type: curated
|
|
3
|
+
source_url: null
|
|
4
|
+
upstream_version: null
|
|
5
|
+
crawled_at: null
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# FotMob Identity Surfaces
|
|
9
|
+
|
|
10
|
+
FotMob is useful as a public consumer-facing corroborator for fixtures, teams,
|
|
11
|
+
players, and competition pages. It should generally be treated as a bridge and
|
|
12
|
+
lookup surface rather than as the canonical ontology source.
|
|
13
|
+
|
|
14
|
+
## Access Surface
|
|
15
|
+
|
|
16
|
+
FotMob identity evidence usually comes from public web pages or undocumented
|
|
17
|
+
consumer-facing endpoints. Treat access and response shape as mutable, record
|
|
18
|
+
the public URL or endpoint family and snapshot date, and avoid publishing
|
|
19
|
+
scraping bypass or rate-limit evasion details.
|
|
20
|
+
|
|
21
|
+
## Stable Identity Surfaces
|
|
22
|
+
|
|
23
|
+
| Entity | Common surface | Notes |
|
|
24
|
+
|---|---|---|
|
|
25
|
+
| Competition | league or tournament ID | Useful public bridge. Check country, gender, season, and competition type. |
|
|
26
|
+
| Season | season ID or season path parameter where exposed | Treat as provider-scoped and audit URL/API stability. |
|
|
27
|
+
| Match | match ID | Strong public match corroborator when fixture fields align. |
|
|
28
|
+
| Team | team ID | Useful for clubs and national teams. Check side type and country. |
|
|
29
|
+
| Player | player ID | Useful public profile bridge. Corroborate with DOB, nationality, team, and position from stronger sources. |
|
|
30
|
+
| Coach or staff | manager profile where exposed | Treat as role evidence unless profile attributes are strong enough. |
|
|
31
|
+
|
|
32
|
+
## ID Scheme Notes
|
|
33
|
+
|
|
34
|
+
FotMob IDs are provider-scoped numeric IDs. Match, team, player, league, and
|
|
35
|
+
season IDs are useful bridges, while URL slugs and display labels are handles.
|
|
36
|
+
Because the public endpoint contract is undocumented, store source URL,
|
|
37
|
+
endpoint family, and snapshot date alongside any bridge evidence.
|
|
38
|
+
|
|
39
|
+
## Useful Matching Fields
|
|
40
|
+
|
|
41
|
+
- Match: FotMob match ID, date/time, home and away teams, score, league, season,
|
|
42
|
+
venue, status, lineups, and player stats.
|
|
43
|
+
- Team: team ID, official/display name, country, league participation, squad,
|
|
44
|
+
and fixtures.
|
|
45
|
+
- Player: player ID, full name, date of birth where present, nationality,
|
|
46
|
+
position, current team, shirt number, and match participation.
|
|
47
|
+
|
|
48
|
+
## Known Quirks
|
|
49
|
+
|
|
50
|
+
- FotMob is optimised for product display. Display names, slugs, and grouping
|
|
51
|
+
labels may change.
|
|
52
|
+
- Profile and current-team surfaces are point-in-time facts. Keep a snapshot
|
|
53
|
+
date when using them.
|
|
54
|
+
- Public endpoints may be undocumented. Treat access and response shape as
|
|
55
|
+
mutable unless the provider documents the contract.
|
|
56
|
+
|
|
57
|
+
## Reep Next Usage
|
|
58
|
+
|
|
59
|
+
Use this page as the public provider-fact reference for FotMob identity
|
|
60
|
+
surfaces, public URL families, and matching cautions. Reep Next can cite those
|
|
61
|
+
facts, but private endpoint handling, scrape internals, rate-limit tactics,
|
|
62
|
+
review outcomes, and register decisions belong outside football-docs.
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
---
|
|
2
|
+
source_type: curated
|
|
3
|
+
source_url: null
|
|
4
|
+
upstream_version: null
|
|
5
|
+
crawled_at: null
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# Impect Identity Surfaces
|
|
9
|
+
|
|
10
|
+
Impect is primarily useful as a commercial match and event data provider. Public
|
|
11
|
+
documentation for identity surfaces is limited, so this page records cautious
|
|
12
|
+
curated guidance for entity-resolution work that has legitimate data access.
|
|
13
|
+
|
|
14
|
+
## Access Surface
|
|
15
|
+
|
|
16
|
+
Access is through licensed Impect deliveries or customer APIs. Public
|
|
17
|
+
football-docs examples should stay synthetic or describe field families only.
|
|
18
|
+
Record delivery date, competition scope, and whether IDs are documented as
|
|
19
|
+
stable across deliveries before using them as durable bridges.
|
|
20
|
+
|
|
21
|
+
## Stable Identity Surfaces
|
|
22
|
+
|
|
23
|
+
| Entity | Common surface | Notes |
|
|
24
|
+
|---|---|---|
|
|
25
|
+
| Competition | provider competition key | Check whether the feed exposes stable competition IDs or only customer-specific names. |
|
|
26
|
+
| Season | provider season or competition-edition key | Treat as provider scoped until audited. |
|
|
27
|
+
| Match | provider match key | Strong bridge if the key is stable in the delivered feed and fixture fields align. |
|
|
28
|
+
| Team | provider team key | Corroborate with match participation, name, country, and side type. |
|
|
29
|
+
| Player | provider player key | Corroborate with lineup/event participation and biographical attributes from another authority. |
|
|
30
|
+
| Staff | provider staff or official key if exposed | Treat as role evidence unless profile attributes are available. |
|
|
31
|
+
|
|
32
|
+
## ID Scheme Notes
|
|
33
|
+
|
|
34
|
+
Treat Impect match, team, player, season, and competition keys as opaque
|
|
35
|
+
provider-scoped IDs. Some deliveries may be customer-shaped; do not assume a key
|
|
36
|
+
is globally stable until that is confirmed in the contract or repeated exports.
|
|
37
|
+
|
|
38
|
+
## Useful Matching Fields
|
|
39
|
+
|
|
40
|
+
- Match: provider match key, date, home and away teams, score, competition,
|
|
41
|
+
season, venue, and delivery snapshot.
|
|
42
|
+
- Team: provider team key, names, country, competition participation, and match
|
|
43
|
+
relationship evidence.
|
|
44
|
+
- Player: provider player key, display name, team in match, lineup status,
|
|
45
|
+
shirt number, position, and event participation.
|
|
46
|
+
|
|
47
|
+
## Known Quirks
|
|
48
|
+
|
|
49
|
+
- Commercial data extracts may be customer-shaped. Confirm whether IDs are
|
|
50
|
+
stable across deliveries before using them as durable bridges.
|
|
51
|
+
- Event participation is strong relationship evidence, but it does not prove
|
|
52
|
+
person identity without attribute or external-provider corroboration.
|
|
53
|
+
- If profile attributes are thin, keep Impect as a corroborator rather than a
|
|
54
|
+
canonical mint source.
|
|
55
|
+
|
|
56
|
+
## Reep Next Usage
|
|
57
|
+
|
|
58
|
+
Use this page as the public provider-fact reference for Impect identity field
|
|
59
|
+
families and matching cautions. Reep Next can cite those public-safe field
|
|
60
|
+
shapes, but customer deliveries, private IDs, raw feed payloads, and register
|
|
61
|
+
review outcomes belong outside football-docs.
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
---
|
|
2
|
+
source_type: curated
|
|
3
|
+
source_url: null
|
|
4
|
+
upstream_version: null
|
|
5
|
+
crawled_at: null
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# Opta / Stats Perform Identity Surfaces
|
|
9
|
+
|
|
10
|
+
Opta data usually has the strongest structured identity spine for professional
|
|
11
|
+
football projects that have licensed access to the SDAPI feeds. Treat Opta as a
|
|
12
|
+
canonical schedule and structure source only when the local entitlement and
|
|
13
|
+
coverage audit prove that the relevant competition family is complete.
|
|
14
|
+
|
|
15
|
+
## Access Surface
|
|
16
|
+
|
|
17
|
+
Primary access is through licensed Stats Perform / Opta feeds or customer
|
|
18
|
+
exports. Public-facing Opta Analyst surfaces can be useful for examples, but
|
|
19
|
+
they are not a substitute for an entitlement-safe feed contract. Record the feed
|
|
20
|
+
family, extraction date, and competition coverage when using Opta identity facts.
|
|
21
|
+
|
|
22
|
+
## Stable Identity Surfaces
|
|
23
|
+
|
|
24
|
+
| Entity | Common surface | Notes |
|
|
25
|
+
|---|---|---|
|
|
26
|
+
| Competition | competition or tournament identifiers | Use with tournament-calendar metadata. Names and display labels vary by locale and feed. |
|
|
27
|
+
| Season | tournament calendar UUID | Strong season or tournament-edition key. Split-stage competitions may need parent and child season modelling outside Opta. |
|
|
28
|
+
| Stage or round | stage, phase, group, round, or schedule metadata | Opta is often authoritative for schedule-stage shape, but label strings still need normalisation. |
|
|
29
|
+
| Match | fixture or match UUID | Best canonical match key when schedule coverage is complete. Fixture tuples should corroborate, not define, identity. |
|
|
30
|
+
| Team | contestant UUID | Can represent clubs, national teams, youth teams, reserve sides, or historical contestants. Use type/scope attributes. |
|
|
31
|
+
| Player | person UUID | Strong person key inside Opta. Still corroborate against names, DOB, nationality, and relationship evidence before cross-provider bridging. |
|
|
32
|
+
| Coach or staff | person UUID plus role surface | Person UUIDs can span player and coach roles. Keep role edges separate from person identity. |
|
|
33
|
+
|
|
34
|
+
## ID Scheme Notes
|
|
35
|
+
|
|
36
|
+
Opta identifiers are opaque provider keys. Do not parse semantic meaning from
|
|
37
|
+
their string shape, and do not assume that display labels, stage labels, or
|
|
38
|
+
contestant names are stable identifiers. Match, contestant, person, competition,
|
|
39
|
+
and tournament-calendar IDs should be stored with provider, feed family, and
|
|
40
|
+
snapshot metadata.
|
|
41
|
+
|
|
42
|
+
## Useful Matching Fields
|
|
43
|
+
|
|
44
|
+
- Match: date/time, home and away contestant UUIDs, score, competition, season,
|
|
45
|
+
stage, venue, and status.
|
|
46
|
+
- Team: contestant UUID, official name, short name, country, gender, age class,
|
|
47
|
+
national-team or club scope, and active period where available.
|
|
48
|
+
- Person: Opta person UUID, full name, short name, date of birth, nationality,
|
|
49
|
+
position, gender, and squad or career memberships.
|
|
50
|
+
- Relationships: schedule team participation, squads, lineups, coaching staff,
|
|
51
|
+
substitutions, and career memberships.
|
|
52
|
+
|
|
53
|
+
## Known Quirks
|
|
54
|
+
|
|
55
|
+
- Opta labels are provider display labels, not ontology. Do not mint a separate
|
|
56
|
+
competition or team solely because the feed label differs from another
|
|
57
|
+
provider.
|
|
58
|
+
- Some competitions have full schedule and squad coverage but sparse match-event
|
|
59
|
+
or lineup tables in a local mirror. Check all person substrates before
|
|
60
|
+
assuming people cannot be resolved.
|
|
61
|
+
- National teams need explicit team scope and country attributes. Do not encode
|
|
62
|
+
the full national-team concept only in a club-shaped team type.
|
|
63
|
+
- Some person facts are current-point-in-time surfaces, especially active squad
|
|
64
|
+
or career listings. Record the snapshot date when using them.
|
|
65
|
+
|
|
66
|
+
## Reep Next Usage
|
|
67
|
+
|
|
68
|
+
Use this page as the public provider-fact reference for Opta identity surfaces:
|
|
69
|
+
access shape, ID families, matching fields, and known quirks. Reep Next
|
|
70
|
+
acceptance policy, canonical-feed assignments, minting, review cases, action
|
|
71
|
+
ledgers, and private feed observations belong outside football-docs.
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
---
|
|
2
|
+
source_type: curated
|
|
3
|
+
source_url: null
|
|
4
|
+
upstream_version: null
|
|
5
|
+
crawled_at: null
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# SkillCorner Identity Surfaces
|
|
9
|
+
|
|
10
|
+
SkillCorner is mainly a tracking and physical-data provider. Its identity
|
|
11
|
+
surfaces are most useful for linking delivered match, team, and player rows back
|
|
12
|
+
to an existing register rather than minting a full football ontology.
|
|
13
|
+
|
|
14
|
+
## Access Surface
|
|
15
|
+
|
|
16
|
+
Access is through licensed SkillCorner APIs or delivered tracking/physical-data
|
|
17
|
+
files. Public guidance should use synthetic examples or high-level field names,
|
|
18
|
+
not proprietary tracking payloads. Record delivery date, match scope, and data
|
|
19
|
+
product when using SkillCorner identity evidence.
|
|
20
|
+
|
|
21
|
+
## Stable Identity Surfaces
|
|
22
|
+
|
|
23
|
+
| Entity | Common surface | Notes |
|
|
24
|
+
|---|---|---|
|
|
25
|
+
| Competition | provider competition key where present | Often secondary to match delivery scope. Audit before treating as canonical. |
|
|
26
|
+
| Season | provider season or delivery context | Keep provider-scoped unless a stable season key is documented in the extract. |
|
|
27
|
+
| Match | provider match key | Strong bridge when fixture fields and delivery metadata agree. |
|
|
28
|
+
| Team | provider team key | Corroborate with match participation and team names. |
|
|
29
|
+
| Player | provider player key | Corroborate with tracking roster, shirt number, position, and external person attributes. |
|
|
30
|
+
|
|
31
|
+
## ID Scheme Notes
|
|
32
|
+
|
|
33
|
+
SkillCorner IDs should be treated as opaque and provider-scoped. Match delivery
|
|
34
|
+
IDs, team IDs, and player IDs are strongest when paired with the delivery
|
|
35
|
+
snapshot and fixture context. A tracking roster key is not automatically a
|
|
36
|
+
season membership or person identity without corroborating attributes.
|
|
37
|
+
|
|
38
|
+
## Useful Matching Fields
|
|
39
|
+
|
|
40
|
+
- Match: provider match key, date, competition, season, home and away teams,
|
|
41
|
+
score where present, and data delivery snapshot.
|
|
42
|
+
- Team: provider team key, name, side in match, and relationship to match.
|
|
43
|
+
- Player: provider player key, name, team in match, shirt number, position,
|
|
44
|
+
starter/substitute status where supplied, and tracking samples.
|
|
45
|
+
|
|
46
|
+
## Known Quirks
|
|
47
|
+
|
|
48
|
+
- Tracking feeds can expose matchday rosters without enough biographical detail
|
|
49
|
+
for safe person minting. Use them as relationship evidence unless another
|
|
50
|
+
source supplies the identity attributes.
|
|
51
|
+
- Delivery metadata may be more reliable than display names for reproducible
|
|
52
|
+
matching.
|
|
53
|
+
- A match-level tracking file is not proof of a season-long membership edge.
|
|
54
|
+
|
|
55
|
+
## Reep Next Usage
|
|
56
|
+
|
|
57
|
+
Use this page as the public provider-fact reference for SkillCorner identity
|
|
58
|
+
surfaces in tracking and physical-data deliveries. Reep Next can cite the field
|
|
59
|
+
families and matching cautions, but raw tracking payloads, private delivery
|
|
60
|
+
examples, and register review outputs belong outside football-docs.
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
---
|
|
2
|
+
source_type: curated
|
|
3
|
+
source_url: null
|
|
4
|
+
upstream_version: null
|
|
5
|
+
crawled_at: null
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# Soccerdonna Identity Surfaces
|
|
9
|
+
|
|
10
|
+
Soccerdonna is a useful public corroborator for women's football, particularly
|
|
11
|
+
for teams, competitions, player profiles, staff pages, and match reports. Treat
|
|
12
|
+
it as a public evidence provider whose coverage and structure vary by
|
|
13
|
+
competition and era.
|
|
14
|
+
|
|
15
|
+
## Access Surface
|
|
16
|
+
|
|
17
|
+
Soccerdonna is a public website surface. Use public profile pages, competition
|
|
18
|
+
pages, and match reports as corroborating evidence, with the page URL and
|
|
19
|
+
snapshot date recorded. Do not publish private scraping state, retry logs, or
|
|
20
|
+
local mirror paths.
|
|
21
|
+
|
|
22
|
+
## Stable Identity Surfaces
|
|
23
|
+
|
|
24
|
+
| Entity | Common surface | Notes |
|
|
25
|
+
|---|---|---|
|
|
26
|
+
| Competition | competition page ID or slug | Useful corroborator. Canonical competition shape should still follow the chosen match feed. |
|
|
27
|
+
| Season | season-scoped competition URL parameters | Can corroborate season membership but may not match a register season hierarchy exactly. |
|
|
28
|
+
| Stage or round | match-report round labels | Useful for stage naming after normalisation. Raw labels should not be minted directly. |
|
|
29
|
+
| Match | match-report or `spielbericht` ID | Strong public match corroborator when date, teams, and score align. |
|
|
30
|
+
| Team | team profile ID | Useful for women's clubs and competition participation. Check gender and side type explicitly. |
|
|
31
|
+
| Player | player profile ID | Useful for names, DOB where present, nationality, position, and career/team membership evidence. |
|
|
32
|
+
| Coach or staff | staff profile ID | Useful for coaching roles, but role labels need a normalised public vocabulary. |
|
|
33
|
+
|
|
34
|
+
## ID Scheme Notes
|
|
35
|
+
|
|
36
|
+
Treat profile, team, competition, and match-report IDs as provider-scoped
|
|
37
|
+
bridges. URL text and slugs are handles, not identity. Season and competition
|
|
38
|
+
URL parameters are useful context, but the target register still decides whether
|
|
39
|
+
they map to a season, stage, or competition entity.
|
|
40
|
+
|
|
41
|
+
## Useful Matching Fields
|
|
42
|
+
|
|
43
|
+
- Match reports: date, home team, away team, score, competition, round label,
|
|
44
|
+
lineups, substitutions, and staff.
|
|
45
|
+
- Player and coach profiles: full name, display name, date of birth,
|
|
46
|
+
nationality, position or role, profile URL, and career memberships.
|
|
47
|
+
- Team pages: official name, competition entries, country, gender context, and
|
|
48
|
+
match participation.
|
|
49
|
+
|
|
50
|
+
## Known Quirks
|
|
51
|
+
|
|
52
|
+
- DOB coverage varies by era and competition. Missing DOB should create review
|
|
53
|
+
residue rather than forcing a weak name-only bridge.
|
|
54
|
+
- Round labels need normalisation before stage minting. Preserve the raw label
|
|
55
|
+
as evidence where useful.
|
|
56
|
+
- Soccerdonna can expose people through match reports before profile data has
|
|
57
|
+
enough identity attributes to bridge safely.
|
|
58
|
+
- Some pages are better corroborators than canonical mint sources because their
|
|
59
|
+
season and competition hierarchy can differ from the schedule feed.
|
|
60
|
+
|
|
61
|
+
## Reep Next Usage
|
|
62
|
+
|
|
63
|
+
Use this page as the public provider-fact reference for Soccerdonna profile,
|
|
64
|
+
team, competition, and match-report identity surfaces. Reep Next can cite those
|
|
65
|
+
facts while keeping review decisions, private scrape state, action logs, and
|
|
66
|
+
women's-football implementation plans outside football-docs.
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
---
|
|
2
|
+
source_type: curated
|
|
3
|
+
source_url: https://docs.sportmonks.com/v3
|
|
4
|
+
upstream_version: null
|
|
5
|
+
crawled_at: null
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# SportMonks Identity Surfaces
|
|
9
|
+
|
|
10
|
+
SportMonks exposes a broad REST API with stable numeric IDs for leagues,
|
|
11
|
+
seasons, stages, fixtures, participants, players, coaches, venues, and related
|
|
12
|
+
entities. It is a useful bridge and corroborator, especially where public API
|
|
13
|
+
access is available.
|
|
14
|
+
|
|
15
|
+
## Access Surface
|
|
16
|
+
|
|
17
|
+
Primary access is the documented SportMonks football API. Include expansions can
|
|
18
|
+
make identity, relationship, and event evidence available from the same request,
|
|
19
|
+
but callers should still record the endpoint, include set, plan scope, and
|
|
20
|
+
request date because coverage depends on subscription tier.
|
|
21
|
+
|
|
22
|
+
## Stable Identity Surfaces
|
|
23
|
+
|
|
24
|
+
| Entity | Common surface | Notes |
|
|
25
|
+
|---|---|---|
|
|
26
|
+
| Competition | league ID | Strong provider key. League names and display categories should be normalised. |
|
|
27
|
+
| Season | season ID | Strong provider key under a league. Use start/end years and league relationship for review. |
|
|
28
|
+
| Stage or round | stage ID, round ID, group ID | Useful provider structure, but may differ from a canonical schedule feed. |
|
|
29
|
+
| Match | fixture ID | Strong match bridge when date, participants, score, and competition align. |
|
|
30
|
+
| Team | participant ID | Can represent clubs or national teams. Check participant type and country. |
|
|
31
|
+
| Player | player ID | Strong provider key only if not reused or contaminated by previous bridge errors. Corroborate with attributes. |
|
|
32
|
+
| Coach or staff | coach ID | Treat as person identity with role-specific evidence. |
|
|
33
|
+
|
|
34
|
+
## ID Scheme Notes
|
|
35
|
+
|
|
36
|
+
SportMonks IDs are numeric provider IDs. Keep them provider-scoped and do not
|
|
37
|
+
merge by bare number across providers. League, season, stage, round, fixture,
|
|
38
|
+
participant, player, coach, and venue IDs should be stored with the source
|
|
39
|
+
endpoint and include path that supplied them.
|
|
40
|
+
|
|
41
|
+
## Useful Matching Fields
|
|
42
|
+
|
|
43
|
+
- Fixture: `fixture.id`, league, season, stage, round, participants, start time,
|
|
44
|
+
scores, state, venue, and lineups.
|
|
45
|
+
- Participant: ID, name, short code, country, gender or type where present, and
|
|
46
|
+
fixture participation.
|
|
47
|
+
- Player: ID, display name, common name, date of birth, nationality, position,
|
|
48
|
+
height, weight, image URL, and team/lineup relationships.
|
|
49
|
+
|
|
50
|
+
## Known Quirks
|
|
51
|
+
|
|
52
|
+
- Broad APIs can carry legacy or contaminated bridges if a downstream register
|
|
53
|
+
previously joined the wrong person. Validate same-provider ID uniqueness.
|
|
54
|
+
- Include-based responses can make relationship evidence easy to retrieve, but
|
|
55
|
+
consumers must still distinguish lineup, squad, current team, and historical
|
|
56
|
+
membership semantics.
|
|
57
|
+
- Stages and rounds are provider shape. Keep the canonical ontology decision
|
|
58
|
+
separate from the SportMonks response nesting.
|
|
59
|
+
|
|
60
|
+
## Reep Next Usage
|
|
61
|
+
|
|
62
|
+
Use this page as the public provider-fact reference for SportMonks ID families,
|
|
63
|
+
API identity surfaces, include paths, and matching cautions. Reep Next can cite
|
|
64
|
+
those facts, but contaminated-bridge review, private validation output, API
|
|
65
|
+
keys, paid-tier payloads, and register decisions belong outside football-docs.
|
|
@@ -172,32 +172,59 @@ The nested JSON objects (pass, shot, carry, etc.) are flattened with underscores
|
|
|
172
172
|
## 3. Commercial REST API
|
|
173
173
|
|
|
174
174
|
**Access**: Requires a paid license from StatsBomb (contact sales@statsbomb.com)
|
|
175
|
-
**Base URL**: `https://data.statsbomb.com/api/v2/`
|
|
176
175
|
|
|
177
176
|
### Authentication
|
|
178
177
|
|
|
179
|
-
HTTP Basic Auth with username (email) and password provided by StatsBomb.
|
|
178
|
+
HTTP Basic Auth with username (email) and password provided by StatsBomb. The
|
|
179
|
+
same credentials work across every endpoint.
|
|
180
180
|
|
|
181
181
|
### Endpoints
|
|
182
182
|
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
|
183
|
+
There is **no single base URL or global API version**. Each resource is
|
|
184
|
+
independently versioned and the API spans **two hostnames**
|
|
185
|
+
(`data.statsbombservices.com` and `data.statsbomb.com`). The full host/version
|
|
186
|
+
matrix, query parameters, and caveats (including a host typo in StatsBomb's own
|
|
187
|
+
Team Stats spec) are documented in **`api-endpoints.md`**. Summary:
|
|
188
|
+
|
|
189
|
+
| Resource | Path (see api-endpoints.md for host + version) |
|
|
190
|
+
|----------|-----------------------------------------------|
|
|
191
|
+
| Competitions | `/api/v4/competitions` |
|
|
192
|
+
| Matches | `/api/v6/competitions/{cid}/seasons/{sid}/matches` |
|
|
193
|
+
| Lineups | `/api/v4/lineups/{mid}` |
|
|
194
|
+
| Events | `/api/v8/events/{mid}` |
|
|
195
|
+
| 360 Frames | `/api/v2/360-frames/{mid}` |
|
|
196
|
+
| Player Mapping | `/api/v1/player-mapping?<params>` |
|
|
197
|
+
| Player Match / Season Stats | `/api/v5/matches/{mid}/player-stats`, `/api/v4/competitions/{cid}/seasons/{sid}/player-stats` |
|
|
198
|
+
| Team Match / Season Stats | `/api/v1/matches/{mid}/team-stats`, `/api/v2/competitions/{cid}/seasons/{sid}/team-stats` |
|
|
190
199
|
|
|
191
200
|
### Response Format
|
|
192
201
|
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
202
|
+
For competitions, matches, lineups, events, and 360 frames the commercial API
|
|
203
|
+
returns the same JSON structure as the open data files (more competitions,
|
|
204
|
+
fresher data). The **stats endpoints and player-mapping have no open-data
|
|
205
|
+
equivalent** — see the parity table below and the dedicated docs
|
|
206
|
+
(`player-match-stats.md`, `player-season-stats.md`, `team-match-stats.md`,
|
|
207
|
+
`team-season-stats.md`, `player-mapping.md`, `iq-metrics-glossary.md`).
|
|
208
|
+
|
|
209
|
+
### Open Data vs Commercial parity
|
|
210
|
+
|
|
211
|
+
| Capability | Open Data | Commercial API |
|
|
212
|
+
|---|---|---|
|
|
213
|
+
| Competitions / Matches / Lineups / Events / 360 | Yes (selective comps) | Yes (licensed scope) |
|
|
214
|
+
| Player & Team Match/Season Stats (IQ metrics) | **No** | Yes |
|
|
215
|
+
| Player Mapping (live/offline IDs) | **No** | Yes |
|
|
216
|
+
| Freshness | Irregular GitHub updates | Near-live for licensed comps |
|
|
217
|
+
|
|
218
|
+
Code written against open data cannot read OBV, xGChain, PPDA, PSxG, the IQ
|
|
219
|
+
metric catalogues, or live/offline IDs — these exist only in the commercial
|
|
220
|
+
feed.
|
|
197
221
|
|
|
198
222
|
### Rate Limits
|
|
199
223
|
|
|
200
|
-
The commercial API has rate limits that vary by license tier. StatsBomb
|
|
224
|
+
The commercial API has rate limits that vary by license tier. StatsBomb
|
|
225
|
+
recommends caching responses locally and polling the Competitions/Matches
|
|
226
|
+
`*_updated` / `last_updated` timestamps to refetch only changed data (see
|
|
227
|
+
`api-endpoints.md` → Incremental sync).
|
|
201
228
|
|
|
202
229
|
---
|
|
203
230
|
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
---
|
|
2
|
+
source_type: curated
|
|
3
|
+
source_url: https://github.com/statsbomb/open-data
|
|
4
|
+
upstream_version: null
|
|
5
|
+
crawled_at: null
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# StatsBomb Commercial REST API Endpoints
|
|
9
|
+
|
|
10
|
+
Reference for the StatsBomb commercial REST API surface. Each resource is
|
|
11
|
+
**independently versioned** and the API spans **two hostnames** — there is no
|
|
12
|
+
single global API version or base path.
|
|
13
|
+
|
|
14
|
+
> This page describes these endpoint versions: Competitions v4.0.0, Matches
|
|
15
|
+
> v6.0.0, Lineups v4.0.1, Events v8.0.0, 360 Frames v2.0.0, Player Mapping
|
|
16
|
+
> v1.0.0, Player Match Stats v5.0.0, Player Season Stats v4.0.0, Team Match
|
|
17
|
+
> Stats v1.0.0, Team Season Stats v2.0.0. StatsBomb increments the version
|
|
18
|
+
> segment per resource when the response shape changes, so the URL itself
|
|
19
|
+
> tells you which version a feed is; a higher version than listed here may
|
|
20
|
+
> carry additional fields not described on this page.
|
|
21
|
+
|
|
22
|
+
## Authentication
|
|
23
|
+
|
|
24
|
+
All endpoints use **HTTP Basic Auth** with the username (email) and password
|
|
25
|
+
issued by StatsBomb. The same credentials work across every endpoint. Access
|
|
26
|
+
requires a paid licence; licensed scope determines which competitions/seasons
|
|
27
|
+
return data.
|
|
28
|
+
|
|
29
|
+
`statsbombpy` and `StatsBombR` wrap these endpoints. With `statsbombpy`, set
|
|
30
|
+
`SB_USERNAME`/`SB_PASSWORD` env vars or pass `creds={"user":..., "passwd":...}`.
|
|
31
|
+
|
|
32
|
+
## Endpoint matrix
|
|
33
|
+
|
|
34
|
+
`{cid}` = competition_id, `{sid}` = season_id, `{mid}` = match_id.
|
|
35
|
+
|
|
36
|
+
| Resource | Method + path | Host | Spec version |
|
|
37
|
+
|---|---|---|---|
|
|
38
|
+
| Competitions | `GET /api/v4/competitions` | `data.statsbombservices.com` | v4.0.0 |
|
|
39
|
+
| Matches | `GET /api/v6/competitions/{cid}/seasons/{sid}/matches` | `data.statsbombservices.com` | v6.0.0 |
|
|
40
|
+
| Lineups | `GET /api/v4/lineups/{mid}` | `data.statsbomb.com` | v4.0.1 |
|
|
41
|
+
| Events | `GET /api/v8/events/{mid}` | `data.statsbombservices.com` | v8.0.0 |
|
|
42
|
+
| 360 Frames | `GET /api/v2/360-frames/{mid}` | `data.statsbombservices.com` | v2.0.0 |
|
|
43
|
+
| Player Mapping | `GET /api/v1/player-mapping?<params>` | `data.statsbomb.com` | v1.0.0 |
|
|
44
|
+
| Player Match Stats | `GET /api/v5/matches/{mid}/player-stats` | `data.statsbombservices.com` | v5.0.0 |
|
|
45
|
+
| Player Season Stats | `GET /api/v4/competitions/{cid}/seasons/{sid}/player-stats` | `data.statsbombservices.com` | v4.0.0 |
|
|
46
|
+
| Team Match Stats | `GET /api/v1/matches/{mid}/team-stats` | `data.statsbomb.com` | v1.0.0 |
|
|
47
|
+
| Team Season Stats | `GET /api/v2/competitions/{cid}/seasons/{sid}/team-stats` | `data.statsbombservices.com` | v2.0.0 |
|
|
48
|
+
|
|
49
|
+
Older versions of a resource are generally reachable by lowering the version
|
|
50
|
+
segment (e.g. `/api/v7/events/{mid}`), subject to StatsBomb retaining them.
|
|
51
|
+
|
|
52
|
+
### Host and typo caveats
|
|
53
|
+
|
|
54
|
+
- **Two active hosts.** Most resources are on `data.statsbombservices.com`;
|
|
55
|
+
Lineups and Player Mapping are documented on `data.statsbomb.com`. The hosts
|
|
56
|
+
are not interchangeable in the specs — use the one documented per resource and
|
|
57
|
+
verify against live behaviour.
|
|
58
|
+
- **Team Match Stats typo.** The Team Match Stats v1.0.0 PDF prints the host as
|
|
59
|
+
`data.statsbom.com` (missing a `b`). This is a documentation typo; the
|
|
60
|
+
intended host is almost certainly `data.statsbomb.com`. Treat with caution and
|
|
61
|
+
confirm against StatsBomb support.
|
|
62
|
+
|
|
63
|
+
## Response format
|
|
64
|
+
|
|
65
|
+
Every endpoint returns a JSON **array** of objects. The shape mirrors the
|
|
66
|
+
StatsBomb Open Data JSON for the entities that exist in open data
|
|
67
|
+
(competitions, matches, lineups, events, 360-frames). The four stats endpoints
|
|
68
|
+
and player-mapping have no open-data equivalent.
|
|
69
|
+
|
|
70
|
+
| Resource | Array element | Documented in |
|
|
71
|
+
|---|---|---|
|
|
72
|
+
| Competitions | competition-season object | `data-model.md` |
|
|
73
|
+
| Matches | match object (incl. `collection_status`, `metadata`) | `data-model.md` |
|
|
74
|
+
| Lineups | per-team lineup (lineup/formations/events arrays) | `data-model.md` |
|
|
75
|
+
| Events | event object (v8 fields incl. OBV, pass clusters) | `event-types.md` |
|
|
76
|
+
| 360 Frames | freeze-frame object per event_uuid | `data-model.md`, `coordinate-system.md` |
|
|
77
|
+
| Player Mapping | competition-season-team block per player | `player-mapping.md` |
|
|
78
|
+
| Player Match/Season Stats | one row per player | `player-match-stats.md`, `player-season-stats.md` |
|
|
79
|
+
| Team Match/Season Stats | one row per team | `team-match-stats.md`, `team-season-stats.md` |
|
|
80
|
+
|
|
81
|
+
## Open Data vs commercial parity
|
|
82
|
+
|
|
83
|
+
The free Open Data repository (`github.com/statsbomb/open-data`) mirrors only a
|
|
84
|
+
subset of the commercial API:
|
|
85
|
+
|
|
86
|
+
| Capability | Open Data | Commercial API |
|
|
87
|
+
|---|---|---|
|
|
88
|
+
| Competitions / Matches / Lineups / Events / 360 | Yes (selective competitions) | Yes (licensed scope) |
|
|
89
|
+
| Player Match Stats | **No** | Yes (`/matches/{mid}/player-stats`) |
|
|
90
|
+
| Player Season Stats | **No** | Yes (`/competitions/{cid}/seasons/{sid}/player-stats`) |
|
|
91
|
+
| Team Match Stats | **No** | Yes (`/matches/{mid}/team-stats`) |
|
|
92
|
+
| Team Season Stats | **No** | Yes (`/competitions/{cid}/seasons/{sid}/team-stats`) |
|
|
93
|
+
| Player Mapping (live/offline IDs) | **No** | Yes (`/player-mapping`) |
|
|
94
|
+
| Data freshness | Irregular GitHub updates | Near-live for licensed comps |
|
|
95
|
+
|
|
96
|
+
The pre-computed IQ metric catalogues (OBV, xGChain, PPDA, PSxG, GSAA, etc.)
|
|
97
|
+
and the live/offline ID mapping **only exist in the commercial feed**. Code
|
|
98
|
+
written against open data cannot read these fields — do not assume their
|
|
99
|
+
presence from open-data examples.
|
|
100
|
+
|
|
101
|
+
## Incremental sync
|
|
102
|
+
|
|
103
|
+
The Competitions response carries `match_updated`, `match_updated_360`,
|
|
104
|
+
`match_available`, and `match_available_360` timestamps per competition-season;
|
|
105
|
+
the Matches response carries `last_updated` / `last_updated_360` per match.
|
|
106
|
+
Poll Competitions, diff the timestamps, then refetch only changed
|
|
107
|
+
competition-seasons/matches rather than re-pulling everything.
|
|
108
|
+
|
|
109
|
+
`match_status` must be `"available"` before Events can be fetched for a match;
|
|
110
|
+
`match_status_360` of `"available"` is required before 360 frames exist. See the
|
|
111
|
+
collection/match status enums in `data-model.md`.
|
|
112
|
+
|
|
113
|
+
## Player Mapping request rules
|
|
114
|
+
|
|
115
|
+
`/api/v1/player-mapping` requires at least one query parameter (no params = no
|
|
116
|
+
data). `all-account-data=true` is required to return the full licensed set
|
|
117
|
+
(otherwise the response is trimmed for trialling). If a query would return
|
|
118
|
+
**more than 5000 records the response is streamed to a file** as JSON rather
|
|
119
|
+
than returned inline. See `player-mapping.md` for parameters and the
|
|
120
|
+
live/offline ID model.
|