Type any player or club and get market value, EA FC rating, potential, and stats in one report, joined across sources that live in separate walled silos.
soccer-goat resolves a name once and fans out to Transfermarkt market value, EA Sports FC ratings and attribute stats, sofifa/fifacm potential, and ESPN context, then merges them into a single report. A local SQLite store unlocks cross-source queries no single site can answer: over/under-rated vs the market, potential growth gaps, and wonderkid scouting.
Quick Start
# confirm sources are reachable before a lookup
soccer-goat-pp-cli doctor --dry-run
# one-time: load the bundled potential dataset so potential populates offline
soccer-goat-pp-cli sync potential
# the headline: one name, full cross-source report (value + rating + potential)
soccer-goat-pp-cli player schjelderup
# the whole squad with values and ratings
soccer-goat-pp-cli team benfica
# head-to-head across every source
soccer-goat-pp-cli compare mbappe haaland
Unique Features
These capabilities aren't available in any other tool for this API.
Cross-source reports
-
player — Type any player name and get market value, EA FC rating, potential, and key stats in one report.
Reach for this first: it answers what's he worth, how good is he, how good will he get, in one call.
soccer-goat-pp-cli player schjelderup --json
-
team — Type a club name and get the full squad with each player's market value and rating, plus squad totals.
Use for scouting a whole squad's value and quality at once instead of N single lookups.
soccer-goat-pp-cli team benfica --json
-
compare — Side-by-side value, rating, potential, and stats for two players.
Settle debates with value + rating + potential + stats in one view.
soccer-goat-pp-cli compare mbappe haaland --json
Local joins that compound
-
over-under-rated — Flag players whose transfer-market value is far above or below their EA game rating.
Surfaces market bargains and hype the raw rating alone can't show.
soccer-goat-pp-cli over-under-rated --team benfica --json
-
potential-gap — Rank players by headroom (potential minus current rating).
Find who still has the most room to grow. Best-effort on potential source.
soccer-goat-pp-cli potential-gap --team benfica --json
-
wonderkids — Find young players with high potential and rising market value.
The scouting query football data tools can't run because the inputs live in different silos.
soccer-goat-pp-cli wonderkids --team benfica --max-age 21 --json
Recipes
Full player report
soccer-goat-pp-cli player schjelderup
One name in, market value + EA rating + potential + key stats out.
Squad board
soccer-goat-pp-cli team benfica --json --select players.name,players.marketValue,players.rating
Narrow a large squad payload to just name, value, and rating.
Find market bargains
soccer-goat-pp-cli over-under-rated --team benfica
Players the game rates high but the market rates low, and vice versa.
Scout wonderkids
soccer-goat-pp-cli wonderkids --max-age 21 --team benfica
Young, high-potential, rising-value players in one filtered list.
Usage
Run soccer-goat-pp-cli --help for the full command reference and flag list.
Paths & environment variables
This CLI separates local files into four path kinds:
| Kind | Contents |
|---|
config | User-editable settings such as config.toml and saved profiles |
data | Durable local data such as data.db |
state | Runtime state such as persisted queries, jobs, and teach.log |
cache | Regenerable HTTP/cache files |
Each kind resolves independently. The ladder is:
- Per-kind env var:
SOCCER_GOAT_CONFIG_DIR, SOCCER_GOAT_DATA_DIR, SOCCER_GOAT_STATE_DIR, or SOCCER_GOAT_CACHE_DIR
--home <dir> for this invocation
SOCCER_GOAT_HOME for a flat relocated root
- XDG env vars:
XDG_CONFIG_HOME, XDG_DATA_HOME, XDG_STATE_HOME, XDG_CACHE_HOME
- Platform defaults matching existing installs
For containers and agent sandboxes, prefer a single relocated root:
export SOCCER_GOAT_HOME=/srv/soccer-goat
soccer-goat-pp-cli doctor
Under SOCCER_GOAT_HOME=/srv/soccer-goat, the four dirs resolve to /srv/soccer-goat/config, /srv/soccer-goat/data, /srv/soccer-goat/state, and /srv/soccer-goat/cache.
MCP servers do not receive CLI flags from the host. Put relocation in the host env block:
{
"mcpServers": {
"soccer-goat": {
"command": "soccer-goat-pp-mcp",
"env": {
"SOCCER_GOAT_HOME": "/srv/soccer-goat"
}
}
}
}
Precedence matters in fleets: an ambient per-kind variable such as SOCCER_GOAT_DATA_DIR overrides an explicit --home for that kind. Use SOCCER_GOAT_HOME or the per-kind variables for durable fleet relocation; treat --home as the weaker per-invocation lever.
Relocation is one-way. Unsetting SOCCER_GOAT_HOME does not move files back to platform defaults, and doctor cannot find files left under a former root. Move the files manually before unsetting relocation variables.
Existing installs keep working because the platform-default rung matches the legacy layout. Run soccer-goat-pp-cli doctor --fail-on warn to check path warnings in automation.
Commands
clubs
Manage clubs
soccer-goat-pp-cli clubs <club_name> - Search Clubs
competitions
Manage competitions
soccer-goat-pp-cli competitions <competition_name> - Search Competitions
players
Manage players
soccer-goat-pp-cli players <player_name> - Search Players
Self-learning loop
This CLI caches per-question discovery so repeat queries skip the walk and structurally similar queries get answered via entity substitution. The loop also self-captures: every invocation is journaled locally, and failed-flag corrections plus fresh teaches surface as candidates on the next recall for confirm/reject judgment. Agents call recall before discovery and fire teach & after answering. See the ## Automatic learning section in SKILL.md for the full protocol.
soccer-goat-pp-cli recall <query> - Look up cached resources for a query before running discovery
soccer-goat-pp-cli teach - Record a query -> resource mapping (silent on success, safe to background with &)
soccer-goat-pp-cli learnings list - Inspect taught rows
soccer-goat-pp-cli learnings forget <query> - Undo a teach
soccer-goat-pp-cli learnings candidates - List auto-captured candidates awaiting confirm/reject
soccer-goat-pp-cli learnings stats - Local loop metrics: recall hit rate, teach-to-reuse, playbook resolution, candidate counts
soccer-goat-pp-cli teach-pattern - Install a query/resource template up front
soccer-goat-pp-cli teach-lookup - Add an entity mapping (e.g. country code, team alias) for pattern substitution
Pass --no-learn or set SOCCER_GOAT_NO_LEARN=true to disable the loop for deterministic flows.
The local store's schema version stamp is one-way: once this version of soccer-goat-pp-cli opens the database, older binaries refuse it with a version error — upgrade the binary rather than downgrading.
Output Formats
# Human-readable table (default in terminal, JSON when piped)
soccer-goat-pp-cli clubs mock-value
# JSON for scripting and agents
soccer-goat-pp-cli clubs mock-value --json
# Filter to specific fields
soccer-goat-pp-cli clubs mock-value --json --select id,name,status
# Dry run — show the request without sending
soccer-goat-pp-cli clubs mock-value --dry-run
# Agent mode — JSON + compact + no prompts in one flag
soccer-goat-pp-cli clubs mock-value --agent
Agent Usage
This CLI is designed for AI agent consumption:
- Non-interactive - never prompts, every input is a flag
- Pipeable -
--json output to stdout, errors to stderr
- Filterable -
--select id,name returns only fields you need
- Previewable -
--dry-run shows the request without sending
- Read-only by default - this CLI does not create, update, delete, publish, send, or mutate remote resources
- Offline-friendly - sync/search commands can use the local SQLite store when available
- Agent-safe by default - no colors or formatting unless
--human-friendly is set
Exit codes: 0 success, 2 usage error, 3 not found, 5 API error, 7 rate limited, 10 config error.
Runtime Endpoint
This CLI resolves endpoint placeholders at runtime, so one installed binary can target different tenants or API versions without regeneration.
Endpoint environment variables:
SOCCER_GOAT_PLAYER_ID resolves {player_id}
Base URL: https://transfermarkt-api.fly.dev
Health Check
soccer-goat-pp-cli doctor
Verifies configuration and connectivity to the API.
Configuration
Run soccer-goat-pp-cli doctor to see the resolved config, data, state, and cache directories. The platform-default config path is ~/.config/soccer-goat-pp-cli/config.toml; --home, SOCCER_GOAT_HOME, and per-kind env vars can relocate it.
Static request headers can be configured under headers; per-command header overrides take precedence.
Troubleshooting
Not found errors (exit code 3)
- Check the resource ID is correct
- Run the
list command to see available items
API-specific
- potential shows as unavailable — run
soccer-goat-pp-cli sync potential once to load the bundled potential dataset into the local store. After that, potential populates offline for ~18k players (joined on the EA player id). Players missing from the dataset (very young academy prospects) can still fall back to the live sofifa/fifacm path if you set a cleared-Cloudflare cookie in SOCCER_GOAT_FIFACM_COOKIE.
- Transfermarkt lookups fail or rate-limit — point at your own transfermarkt-api instance with SOCCER_GOAT_BASE_URL, or wait and retry; the public instance is shared.
- ESPN stats section is empty — ESPN soccer player coverage is thin; the report omits it cleanly and still returns value + rating + potential.