Skip to main content
The POST /query_club endpoint looks up a club in the SquadAssist database using an external or internal ID. Use it to resolve the club_id required by the valuation endpoints when you only have a Transfermarkt ID. The response returns the club’s SquadAssist ID, Transfermarkt ID, and the club’s name.

Request

The request body must be a JSON object containing at least one of the following fields.
transfermarkt_id
integer
The Transfermarkt club ID (a positive integer). You can find this in the Transfermarkt URL for a club — for example, rsca.be has the Transfermarkt ID 415.
squadassist_id
string
A SquadAssist internal club ID. Use this to verify or enrich a club ID you already have.

Response

squadassist_id
string
The SquadAssist internal club ID. Pass this as club_id in the valuation endpoints.
transfermarkt_id
integer or null
The Transfermarkt club ID associated with this club. null if no Transfermarkt ID is recorded.
name
string
The club’s name as it appears in SquadAssist.

Example

curl -X POST https://api.squadassist.ai/v1/query_club \
  -H "x-api-key: <your-api-key>" \
  -H "Content-Type: application/json" \
  -d '{"transfermarkt_id": 415}'

Errors

StatusBodyCause
400{"error": "At least one of transfermarkt_id or squadassist_id must be provided"}The request body contained neither identifier
400{"error": "transfermarkt_id must be an integer"}transfermarkt_id was provided but could not be parsed as an integer
400{"error": "transfermarkt_id must be a positive integer"}transfermarkt_id was zero or negative
400{"error": "transfermarkt_id is out of allowed range"}transfermarkt_id exceeded the maximum allowed value
400{"error": "Invalid squadassist_id"}The squadassist_id format is not valid
404{"error": "Club not found"}No club matched the provided identifier(s)