Skip to content

Games

griddy / nfl / endpoints / ngs / games**

games

NGS Games endpoints for live scores and game center data.

Classes

NgsGames

NgsGames(
    sdk_config: SDKConfiguration,
    parent_ref: Optional[object] = None,
)

Bases: NgsBaseSDK


              flowchart TD
              griddy.nfl.endpoints.ngs.games.NgsGames[NgsGames]
              griddy.nfl.endpoints.ngs.NgsBaseSDK[NgsBaseSDK]
              griddy.nfl.basesdk.BaseSDK[BaseSDK]

                              griddy.nfl.endpoints.ngs.NgsBaseSDK --> griddy.nfl.endpoints.ngs.games.NgsGames
                                griddy.nfl.basesdk.BaseSDK --> griddy.nfl.endpoints.ngs.NgsBaseSDK
                



              click griddy.nfl.endpoints.ngs.games.NgsGames href "" "griddy.nfl.endpoints.ngs.games.NgsGames"
              click griddy.nfl.endpoints.ngs.NgsBaseSDK href "" "griddy.nfl.endpoints.ngs.NgsBaseSDK"
              click griddy.nfl.basesdk.BaseSDK href "" "griddy.nfl.basesdk.BaseSDK"
            

NGS Games endpoints for live scores and game center data.

Provides access to: - Live game scores - Game center overview with detailed NGS metrics

Source code in griddy/nfl/basesdk.py
def __init__(
    self,
    sdk_config: SDKConfiguration,
    parent_ref: Optional[object] = None,
) -> None:
    self.sdk_configuration = sdk_config
    self.parent_ref = parent_ref
Functions
get_live_scores
get_live_scores(
    *,
    season: int,
    season_type: str,
    week: int,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None
) -> NgsLiveScoresResponse

Get live game scores for a specific week.

Returns live scores for all games in the specified week, including quarter-by-quarter scoring, game status, and team information.

PARAMETER DESCRIPTION
season

The season year (e.g., 2025)

TYPE: int

season_type

Season type (REG, PRE, POST)

TYPE: str

week

Week number

TYPE: int

retries

Override the default retry configuration

TYPE: OptionalNullable[RetryConfig] DEFAULT: UNSET

server_url

Override the default server URL

TYPE: Optional[str] DEFAULT: None

timeout_ms

Override the default timeout

TYPE: Optional[int] DEFAULT: None

http_headers

Additional headers to send

TYPE: Optional[Mapping[str, str]] DEFAULT: None

RETURNS DESCRIPTION
NgsLiveScoresResponse

NgsLiveScoresResponse with game scores

Source code in griddy/nfl/endpoints/ngs/games.py
def get_live_scores(
    self,
    *,
    season: int,
    season_type: str,
    week: int,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None,
) -> models.NgsLiveScoresResponse:
    """Get live game scores for a specific week.

    Returns live scores for all games in the specified week, including
    quarter-by-quarter scoring, game status, and team information.

    Args:
        season: The season year (e.g., 2025)
        season_type: Season type (REG, PRE, POST)
        week: Week number
        retries: Override the default retry configuration
        server_url: Override the default server URL
        timeout_ms: Override the default timeout
        http_headers: Additional headers to send

    Returns:
        NgsLiveScoresResponse with game scores
    """
    config = EndpointConfig(
        method="GET",
        path="/api/live/games/scores",
        operation_id="getNgsLiveScores",
        request=models.GetNgsLiveScoresRequest(
            season=season,
            season_type=season_type,
            week=week,
        ),
        response_type=models.NgsLiveScoresResponse,
        error_status_codes=NGS_ERROR_CODES,
        request_has_query_params=True,
        server_url=server_url,
        timeout_ms=timeout_ms,
        http_headers=http_headers,
        retries=retries,
    )
    return self._execute_endpoint(config)
get_live_scores_async async
get_live_scores_async(
    *,
    season: int,
    season_type: str,
    week: int,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None
) -> NgsLiveScoresResponse

Get live game scores for a specific week (async).

Returns live scores for all games in the specified week, including quarter-by-quarter scoring, game status, and team information.

PARAMETER DESCRIPTION
season

The season year (e.g., 2025)

TYPE: int

season_type

Season type (REG, PRE, POST)

TYPE: str

week

Week number

TYPE: int

retries

Override the default retry configuration

TYPE: OptionalNullable[RetryConfig] DEFAULT: UNSET

server_url

Override the default server URL

TYPE: Optional[str] DEFAULT: None

timeout_ms

Override the default timeout

TYPE: Optional[int] DEFAULT: None

http_headers

Additional headers to send

TYPE: Optional[Mapping[str, str]] DEFAULT: None

RETURNS DESCRIPTION
NgsLiveScoresResponse

NgsLiveScoresResponse with game scores

Source code in griddy/nfl/endpoints/ngs/games.py
async def get_live_scores_async(
    self,
    *,
    season: int,
    season_type: str,
    week: int,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None,
) -> models.NgsLiveScoresResponse:
    """Get live game scores for a specific week (async).

    Returns live scores for all games in the specified week, including
    quarter-by-quarter scoring, game status, and team information.

    Args:
        season: The season year (e.g., 2025)
        season_type: Season type (REG, PRE, POST)
        week: Week number
        retries: Override the default retry configuration
        server_url: Override the default server URL
        timeout_ms: Override the default timeout
        http_headers: Additional headers to send

    Returns:
        NgsLiveScoresResponse with game scores
    """
    config = EndpointConfig(
        method="GET",
        path="/api/live/games/scores",
        operation_id="getNgsLiveScores",
        request=models.GetNgsLiveScoresRequest(
            season=season,
            season_type=season_type,
            week=week,
        ),
        response_type=models.NgsLiveScoresResponse,
        error_status_codes=NGS_ERROR_CODES,
        request_has_query_params=True,
        server_url=server_url,
        timeout_ms=timeout_ms,
        http_headers=http_headers,
        retries=retries,
    )
    return await self._execute_endpoint_async(config)
get_overview
get_overview(
    *,
    game_id: int,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None
) -> NgsGameCenterOverviewResponse

Get detailed game center overview with NGS metrics.

Returns comprehensive game data including: - Passer statistics with zone breakdowns - Rusher statistics with location maps - Receiver statistics with separation metrics - Pass rusher statistics - Game leaders (speed, sacks, pass distance)

PARAMETER DESCRIPTION
game_id

The unique game identifier (e.g., 2025112700)

TYPE: int

retries

Override the default retry configuration

TYPE: OptionalNullable[RetryConfig] DEFAULT: UNSET

server_url

Override the default server URL

TYPE: Optional[str] DEFAULT: None

timeout_ms

Override the default timeout

TYPE: Optional[int] DEFAULT: None

http_headers

Additional headers to send

TYPE: Optional[Mapping[str, str]] DEFAULT: None

RETURNS DESCRIPTION
NgsGameCenterOverviewResponse

NgsGameCenterOverviewResponse with game overview data

Source code in griddy/nfl/endpoints/ngs/games.py
def get_overview(
    self,
    *,
    game_id: int,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None,
) -> models.NgsGameCenterOverviewResponse:
    """Get detailed game center overview with NGS metrics.

    Returns comprehensive game data including:
    - Passer statistics with zone breakdowns
    - Rusher statistics with location maps
    - Receiver statistics with separation metrics
    - Pass rusher statistics
    - Game leaders (speed, sacks, pass distance)

    Args:
        game_id: The unique game identifier (e.g., 2025112700)
        retries: Override the default retry configuration
        server_url: Override the default server URL
        timeout_ms: Override the default timeout
        http_headers: Additional headers to send

    Returns:
        NgsGameCenterOverviewResponse with game overview data
    """
    config = EndpointConfig(
        method="GET",
        path="/api/gamecenter/overview",
        operation_id="getNgsGameOverview",
        request=models.GetNgsGameOverviewRequest(game_id=game_id),
        response_type=models.NgsGameCenterOverviewResponse,
        error_status_codes=NGS_ERROR_CODES,
        request_has_query_params=True,
        server_url=server_url,
        timeout_ms=timeout_ms,
        http_headers=http_headers,
        retries=retries,
        return_raw_json=False,
    )
    return self._execute_endpoint(config)
get_overview_async async
get_overview_async(
    *,
    game_id: int,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None
) -> NgsGameCenterOverviewResponse

Get detailed game center overview with NGS metrics (async).

Returns comprehensive game data including: - Passer statistics with zone breakdowns - Rusher statistics with location maps - Receiver statistics with separation metrics - Pass rusher statistics - Game leaders (speed, sacks, pass distance)

PARAMETER DESCRIPTION
game_id

The unique game identifier (e.g., 2025112700)

TYPE: int

retries

Override the default retry configuration

TYPE: OptionalNullable[RetryConfig] DEFAULT: UNSET

server_url

Override the default server URL

TYPE: Optional[str] DEFAULT: None

timeout_ms

Override the default timeout

TYPE: Optional[int] DEFAULT: None

http_headers

Additional headers to send

TYPE: Optional[Mapping[str, str]] DEFAULT: None

RETURNS DESCRIPTION
NgsGameCenterOverviewResponse

NgsGameCenterOverviewResponse with game overview data

Source code in griddy/nfl/endpoints/ngs/games.py
async def get_overview_async(
    self,
    *,
    game_id: int,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None,
) -> models.NgsGameCenterOverviewResponse:
    """Get detailed game center overview with NGS metrics (async).

    Returns comprehensive game data including:
    - Passer statistics with zone breakdowns
    - Rusher statistics with location maps
    - Receiver statistics with separation metrics
    - Pass rusher statistics
    - Game leaders (speed, sacks, pass distance)

    Args:
        game_id: The unique game identifier (e.g., 2025112700)
        retries: Override the default retry configuration
        server_url: Override the default server URL
        timeout_ms: Override the default timeout
        http_headers: Additional headers to send

    Returns:
        NgsGameCenterOverviewResponse with game overview data
    """
    config = EndpointConfig(
        method="GET",
        path="/api/gamecenter/overview",
        operation_id="getNgsGameOverview",
        request=models.GetNgsGameOverviewRequest(game_id=game_id),
        response_type=models.NgsGameCenterOverviewResponse,
        error_status_codes=NGS_ERROR_CODES,
        request_has_query_params=True,
        server_url=server_url,
        timeout_ms=timeout_ms,
        http_headers=http_headers,
        retries=retries,
        return_raw_json=False,
    )
    return await self._execute_endpoint_async(config)