Following a team is the quickest way to keep up with a club you care about. Once you follow a team, its next five upcoming matches appear directly on your profile page so you always know when they play next. You can follow as many teams as you like, and unfollow them just as easily.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/danielsl4/TFG_DAM_2526/llms.txt
Use this file to discover all available pages before exploring further.
How following works
Any authenticated user can follow or unfollow any team. The action is a toggle — call the same endpoint once to follow, and again to unfollow. There is no separate follow and unfollow route. When you visit a team detail page, the response includes anisFollowing flag that tells the UI whether to display a “Follow” or “Unfollow” button. This flag is only populated when you are authenticated; unauthenticated visitors always see it as false.
Toggle follow on a team
Send aPOST request to /teams/:id/toggle-follow, replacing :id with the team’s numeric ID. Include your JWT token in the Authorization header.
- Follow a team
- Unfollow a team
Where followed teams appear
After following one or more teams, your profile page reflects the change in two places:- Followed teams list — a grid of team logos and names linking to each team’s detail page.
- Upcoming matches — the next five scheduled matches (status
pendiente) across all the teams you follow, drawn from the currently active season, ordered by date.
Checking the follow state via the API
When you fetch a team’s detail, theisFollowing field in the response reflects your current status:
false by the frontend).
Related pages
Authentication
Log in to unlock team following and other personalised features.
User profile
See all your followed teams and their upcoming matches in one place.