Files
plexpy/src/plex_api_client/models/operations/getgeodata.py

101 lines
3.0 KiB
Python

"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
from __future__ import annotations
import httpx
from plex_api_client.types import BaseModel
from typing import Optional, TypedDict
from typing_extensions import NotRequired
GET_GEO_DATA_SERVERS = [
"https://plex.tv/api/v2/",
]
class GetGeoDataGeoDataTypedDict(TypedDict):
r"""Geo location data"""
code: str
r"""The ISO 3166-1 alpha-2 code of the country."""
continent_code: str
r"""The continent code where the country is located."""
country: str
r"""The official name of the country."""
city: str
r"""The name of the city."""
time_zone: str
r"""The time zone of the country."""
postal_code: str
r"""The postal code of the location."""
subdivisions: str
r"""The name of the primary administrative subdivision."""
coordinates: str
r"""The geographical coordinates (latitude, longitude) of the location."""
european_union_member: NotRequired[bool]
r"""Indicates if the country is a member of the European Union."""
in_privacy_restricted_country: NotRequired[bool]
r"""Indicates if the country has privacy restrictions."""
in_privacy_restricted_region: NotRequired[bool]
r"""Indicates if the region has privacy restrictions."""
class GetGeoDataGeoData(BaseModel):
r"""Geo location data"""
code: str
r"""The ISO 3166-1 alpha-2 code of the country."""
continent_code: str
r"""The continent code where the country is located."""
country: str
r"""The official name of the country."""
city: str
r"""The name of the city."""
time_zone: str
r"""The time zone of the country."""
postal_code: str
r"""The postal code of the location."""
subdivisions: str
r"""The name of the primary administrative subdivision."""
coordinates: str
r"""The geographical coordinates (latitude, longitude) of the location."""
european_union_member: Optional[bool] = False
r"""Indicates if the country is a member of the European Union."""
in_privacy_restricted_country: Optional[bool] = False
r"""Indicates if the country has privacy restrictions."""
in_privacy_restricted_region: Optional[bool] = False
r"""Indicates if the region has privacy restrictions."""
class GetGeoDataResponseTypedDict(TypedDict):
content_type: str
r"""HTTP response content type for this operation"""
status_code: int
r"""HTTP response status code for this operation"""
raw_response: httpx.Response
r"""Raw HTTP response; suitable for custom response parsing"""
geo_data: NotRequired[GetGeoDataGeoDataTypedDict]
r"""Gets the geo location data of the user"""
class GetGeoDataResponse(BaseModel):
content_type: str
r"""HTTP response content type for this operation"""
status_code: int
r"""HTTP response status code for this operation"""
raw_response: httpx.Response
r"""Raw HTTP response; suitable for custom response parsing"""
geo_data: Optional[GetGeoDataGeoData] = None
r"""Gets the geo location data of the user"""