Authentication¶
griddy / nfl / endpoints / regular / authentication**
authentication
¶
Classes¶
Authentication
¶
Bases: BaseSDK
flowchart TD
griddy.nfl.endpoints.regular.authentication.Authentication[Authentication]
griddy.nfl.basesdk.BaseSDK[BaseSDK]
griddy.nfl.basesdk.BaseSDK --> griddy.nfl.endpoints.regular.authentication.Authentication
click griddy.nfl.endpoints.regular.authentication.Authentication href "" "griddy.nfl.endpoints.regular.authentication.Authentication"
click griddy.nfl.basesdk.BaseSDK href "" "griddy.nfl.basesdk.BaseSDK"
Token generation and refresh operations for NFL API access
Source code in griddy/nfl/basesdk.py
Functions¶
generate_token
¶
generate_token(
*,
client_key: str,
client_secret: str,
device_id: str,
device_info: str,
network_type: TokenRequestNetworkType,
retries: OptionalNullable[RetryConfig] = UNSET,
server_url: Optional[str] = None,
timeout_ms: Optional[int] = None,
http_headers: Optional[Mapping[str, str]] = None
) -> TokenResponse
Generate Initial Access Token
Creates a new access token and refresh token for a client device. This is the initial authentication endpoint that establishes a session for accessing NFL APIs. Requires client credentials and device information.
:param client_key: Client application identifier key :param client_secret: Client application secret for authentication :param device_id: Unique device identifier (UUID format) :param device_info: Base64-encoded JSON containing device information such as: {\"model\":\"desktop\",\"version\":\"Chrome\",\"osName\":\"Windows\",\"osVersion\":\"10\"} :param network_type: Type of network connection :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds :param http_headers: Additional headers to set or replace on requests.
Source code in griddy/nfl/endpoints/regular/authentication.py
generate_token_async
async
¶
generate_token_async(
*,
client_key: str,
client_secret: str,
device_id: str,
device_info: str,
network_type: TokenRequestNetworkType,
retries: OptionalNullable[RetryConfig] = UNSET,
server_url: Optional[str] = None,
timeout_ms: Optional[int] = None,
http_headers: Optional[Mapping[str, str]] = None
) -> TokenResponse
Generate Initial Access Token
Creates a new access token and refresh token for a client device. This is the initial authentication endpoint that establishes a session for accessing NFL APIs. Requires client credentials and device information.
:param client_key: Client application identifier key :param client_secret: Client application secret for authentication :param device_id: Unique device identifier (UUID format) :param device_info: Base64-encoded JSON containing device information such as: {\"model\":\"desktop\",\"version\":\"Chrome\",\"osName\":\"Windows\",\"osVersion\":\"10\"} :param network_type: Type of network connection :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds :param http_headers: Additional headers to set or replace on requests.
Source code in griddy/nfl/endpoints/regular/authentication.py
refresh_token
¶
refresh_token(
*,
client_key: str,
client_secret: str,
device_id: str,
device_info: str,
network_type: RefreshTokenRequestNetworkType,
refresh_token: str,
signature_timestamp: str,
uid: str,
uid_signature: str,
retries: OptionalNullable[RetryConfig] = UNSET,
server_url: Optional[str] = None,
timeout_ms: Optional[int] = None,
http_headers: Optional[Mapping[str, str]] = None
) -> TokenResponse
Refresh Access Token
Refreshes an existing access token using a valid refresh token. This endpoint extends the user's session by generating new access and refresh tokens. Requires the previous refresh token and signature verification.
:param client_key: Client application identifier key :param client_secret: Client application secret for authentication :param device_id: Unique device identifier (UUID format) :param device_info: Base64-encoded JSON containing device information such as: {\"model\":\"desktop\",\"version\":\"Chrome\",\"osName\":\"Windows\",\"osVersion\":\"10\"} :param network_type: Type of network connection :param refresh_token: Valid refresh token from previous authentication :param signature_timestamp: Unix timestamp for signature verification :param uid: User identifier hash :param uid_signature: HMAC signature for request verification :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds :param http_headers: Additional headers to set or replace on requests.
Source code in griddy/nfl/endpoints/regular/authentication.py
refresh_token_async
async
¶
refresh_token_async(
*,
client_key: str,
client_secret: str,
device_id: str,
device_info: str,
network_type: RefreshTokenRequestNetworkType,
refresh_token: str,
signature_timestamp: str,
uid: str,
uid_signature: str,
retries: OptionalNullable[RetryConfig] = UNSET,
server_url: Optional[str] = None,
timeout_ms: Optional[int] = None,
http_headers: Optional[Mapping[str, str]] = None
) -> TokenResponse
Refresh Access Token
Refreshes an existing access token using a valid refresh token. This endpoint extends the user's session by generating new access and refresh tokens. Requires the previous refresh token and signature verification.
:param client_key: Client application identifier key :param client_secret: Client application secret for authentication :param device_id: Unique device identifier (UUID format) :param device_info: Base64-encoded JSON containing device information such as: {\"model\":\"desktop\",\"version\":\"Chrome\",\"osName\":\"Windows\",\"osVersion\":\"10\"} :param network_type: Type of network connection :param refresh_token: Valid refresh token from previous authentication :param signature_timestamp: Unix timestamp for signature verification :param uid: User identifier hash :param uid_signature: HMAC signature for request verification :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds :param http_headers: Additional headers to set or replace on requests.