Skip to content

News

griddy / nfl / endpoints / ngs / news**

news

NGS News endpoints for articles and videos.

Note: These endpoints use a different server (api.nfl.com) than the other NGS endpoints.

Classes

NgsNews

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

Bases: BaseSDK


              flowchart TD
              griddy.nfl.endpoints.ngs.news.NgsNews[NgsNews]
              griddy.nfl.basesdk.BaseSDK[BaseSDK]

                              griddy.nfl.basesdk.BaseSDK --> griddy.nfl.endpoints.ngs.news.NgsNews
                


              click griddy.nfl.endpoints.ngs.news.NgsNews href "" "griddy.nfl.endpoints.ngs.news.NgsNews"
              click griddy.nfl.basesdk.BaseSDK href "" "griddy.nfl.basesdk.BaseSDK"
            

NGS News endpoints for articles and videos.

Note: This sub-SDK uses api.nfl.com instead of nextgenstats.nfl.com.

Provides access to: - Mixed content (articles and videos) - Articles - Video clips

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_mixed_content
get_mixed_content(
    *,
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None
) -> NgsMixedContentResponse

Get mixed NGS content (articles and videos).

PARAMETER DESCRIPTION
limit

Number of items to return (default: 16)

TYPE: int DEFAULT: 16

offset

Offset for pagination (default: 0)

TYPE: int DEFAULT: 0

Source code in griddy/nfl/endpoints/ngs/news.py
def get_mixed_content(
    self,
    *,
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None,
) -> models.NgsMixedContentResponse:
    """Get mixed NGS content (articles and videos).

    Args:
        limit: Number of items to return (default: 16)
        offset: Offset for pagination (default: 0)
    """
    config = EndpointConfig(
        method="GET",
        path="/content/v1/mixed/next-gen-stats",
        operation_id="getNgsMixedContent",
        request=models.GetNgsMixedContentRequest(limit=limit, offset=offset),
        response_type=models.NgsMixedContentResponse,
        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_mixed_content_async async
get_mixed_content_async(
    *,
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None
) -> NgsMixedContentResponse

Get mixed NGS content (async).

Source code in griddy/nfl/endpoints/ngs/news.py
async def get_mixed_content_async(
    self,
    *,
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None,
) -> models.NgsMixedContentResponse:
    """Get mixed NGS content (async)."""
    config = EndpointConfig(
        method="GET",
        path="/content/v1/mixed/next-gen-stats",
        operation_id="getNgsMixedContent",
        request=models.GetNgsMixedContentRequest(limit=limit, offset=offset),
        response_type=models.NgsMixedContentResponse,
        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)
get_articles
get_articles(
    *,
    category: str = "next-gen-stats-news",
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None
) -> NgsArticlesResponse

Get NGS articles.

PARAMETER DESCRIPTION
category

Article category slug (default: "next-gen-stats-news")

TYPE: str DEFAULT: 'next-gen-stats-news'

limit

Number of items to return (default: 16)

TYPE: int DEFAULT: 16

offset

Offset for pagination (default: 0)

TYPE: int DEFAULT: 0

Source code in griddy/nfl/endpoints/ngs/news.py
def get_articles(
    self,
    *,
    category: str = "next-gen-stats-news",
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None,
) -> models.NgsArticlesResponse:
    """Get NGS articles.

    Args:
        category: Article category slug (default: "next-gen-stats-news")
        limit: Number of items to return (default: 16)
        offset: Offset for pagination (default: 0)
    """
    config = EndpointConfig(
        method="GET",
        path="/content/v1/articles",
        operation_id="getNgsArticles",
        request=models.GetNgsArticlesRequest(
            category=category, limit=limit, offset=offset
        ),
        response_type=models.NgsArticlesResponse,
        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_articles_async async
get_articles_async(
    *,
    category: str = "next-gen-stats-news",
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None
) -> NgsArticlesResponse

Get NGS articles (async).

Source code in griddy/nfl/endpoints/ngs/news.py
async def get_articles_async(
    self,
    *,
    category: str = "next-gen-stats-news",
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None,
) -> models.NgsArticlesResponse:
    """Get NGS articles (async)."""
    config = EndpointConfig(
        method="GET",
        path="/content/v1/articles",
        operation_id="getNgsArticles",
        request=models.GetNgsArticlesRequest(
            category=category, limit=limit, offset=offset
        ),
        response_type=models.NgsArticlesResponse,
        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)
get_video_clips
get_video_clips(
    *,
    video_channel: str = "next-gen-stats-vc",
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None
) -> NgsVideosResponse

Get NGS video clips.

PARAMETER DESCRIPTION
video_channel

Video channel slug (default: "next-gen-stats-vc")

TYPE: str DEFAULT: 'next-gen-stats-vc'

limit

Number of items to return (default: 16)

TYPE: int DEFAULT: 16

offset

Offset for pagination (default: 0)

TYPE: int DEFAULT: 0

Source code in griddy/nfl/endpoints/ngs/news.py
def get_video_clips(
    self,
    *,
    video_channel: str = "next-gen-stats-vc",
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None,
) -> models.NgsVideosResponse:
    """Get NGS video clips.

    Args:
        video_channel: Video channel slug (default: "next-gen-stats-vc")
        limit: Number of items to return (default: 16)
        offset: Offset for pagination (default: 0)
    """
    config = EndpointConfig(
        method="GET",
        path="/content/v1/videos/clips",
        operation_id="getNgsVideoClips",
        request=models.GetNgsVideoClipsRequest(
            video_channel=video_channel, limit=limit, offset=offset
        ),
        response_type=models.NgsVideosResponse,
        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_video_clips_async async
get_video_clips_async(
    *,
    video_channel: str = "next-gen-stats-vc",
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None
) -> NgsVideosResponse

Get NGS video clips (async).

Source code in griddy/nfl/endpoints/ngs/news.py
async def get_video_clips_async(
    self,
    *,
    video_channel: str = "next-gen-stats-vc",
    limit: int = 16,
    offset: int = 0,
    retries: OptionalNullable[RetryConfig] = UNSET,
    server_url: Optional[str] = None,
    timeout_ms: Optional[int] = None,
    http_headers: Optional[Mapping[str, str]] = None,
) -> models.NgsVideosResponse:
    """Get NGS video clips (async)."""
    config = EndpointConfig(
        method="GET",
        path="/content/v1/videos/clips",
        operation_id="getNgsVideoClips",
        request=models.GetNgsVideoClipsRequest(
            video_channel=video_channel, limit=limit, offset=offset
        ),
        response_type=models.NgsVideosResponse,
        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)