# Squads API

This endpoint returns the competition squads for a specific season. Per each competition, this endpoint will return the following information:

* Name of the competition
* Team name & Id
* Player forename, lastname and Id
* Shirt Number
* Nationality

## Endpoint URLs

Squads:

* **seasonId**

`https://dde-api.data.imgarena.com/soccer/seasons/{seasonId}/squads`

This allows clients to determine which players are associated to which team and seasonId.

* **teamId**

`https://dde-api.data.imgarena.com/soccer/squads/{teamId}`

This allows clients to call by teamId

## Polling Frequency

We recommend the following frequency for your REST requests to ensure that you have the most up-to-date information at all times:<br>

<table><thead><tr><th>REST Endpoint</th><th width="120">Frequency</th><th>Description</th></tr></thead><tbody><tr><td><code>/soccer/seasons/{seasonId}/squads</code></td><td>Once per 24 hours</td><td>Updated on any change to a team and their squad such as a player being called up, a player transfer etc.</td></tr></tbody></table>

## Required Headers

| Key           | Value                                            |
| ------------- | ------------------------------------------------ |
| Accept        | application/vnd.imggaming.dde.api+json;version=1 |
| Content-Type  | application/json                                 |
| Authorization | Bearer eyvhaoudfgpdfgo\*                         |

## Response Model

For sample JSON files and details of each value with descriptions within the payloads, utilise the following Swagger Pages:

JSON Schema - <https://app.swaggerhub.com/apis/IMG_Arena/IMGA-DDE-SOCCER/1#/football/get_soccer_seasons__seasonId__squads>

JSON Schema with value descriptions - <https://app.swaggerhub.com/apis/IMG_Arena/IMGA-DDE-SOCCER/1#/SeasonSquad>
