Team Season Stats Example

Use case - Retrieve TeamSeasonStat in 2014 regular season

Field Selector:

{
    id,
    fullName,
    teamSeasonStats{id,passingStats{attempts,completions},rushingStats{attempts,yardsPerAttempt}}
}

Query:

{
    "$query":
        {
            "abbr": "SEA",
            "teamSeasonStats.season": 2014,
            "teamSeasonStats.seasonType": "REG"
        }
    "$teamSeasonStats" : {
        "$query" : {
            "season": 2014,
            "seasonType": "REG"            
        }
    }        
}

Request:

GET  /teams?fs={id,fullName,teamSeasonStats{id,passingStats{attempts,completions},rushingStats{attempts,yardsPerAttempt}}}&s={
    "$query":{"abbr": "SEA","teamSeasonStats.season": 2014,"teamSeasonStats.seasonType": "REG"},"$teamSeasonStats" : {"$query" : {"season": 2014,"seasonType": "REG"}}}

Response:

{
    "pager" : {},
    "data" : [
        {
            "id": "525f365e-77fa-4e93-8413-f69705b19ade",
            "fullName": "Seattle Seahawks",
            "teamSeasonStats": [
                {
                    "id": "13a25169-509c-408e-9306-832641609f49",
                    "passingStats": {
                        "attempts": 10,
                        "completions": 6
                    },
                    "rushingStats": {
                        "attempts": 2,
                        "yardsPerAttempt": 2
                    }
                }    
            ]
        }
    ]
}

To perform queries based on specific team season stats, use the /teamSeasonStats endpoint instead.