Documentation
¶
Index ¶
- func DisplayUpcoming() error
- func DisplayUser() error
- func DisplayWatchlist() error
- func GetAccessToken() (string, error)
- func HaveSettings() bool
- func Login() error
- func WriteSettings(settings Settings) error
- type AccessTokenResponse
- type DeviceCodeResponse
- type Episode
- type GetUpcomingResponse
- type GetUserResponse
- type GetWatchlistResponse
- type Settings
- type Show
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DisplayWatchlist ¶
func DisplayWatchlist() error
DisplayWatchlist displays the upcoming episodes
Types ¶
type AccessTokenResponse ¶
type AccessTokenResponse struct {
Result string `json:"result"`
Message string `json:"message"`
AccessToken string `json:"access_token"`
}
AccessTokenResponse is the struct to store the response of the access token call
type DeviceCodeResponse ¶
type DeviceCodeResponse struct {
Result string `json:"result"`
Message string `json:"message"`
DeviceCode string `json:"device_code"`
UserCode string `json:"user_code"`
VerificationURL string `json:"verification_url"`
ExpiresIn int64 `json:"expires_in"`
Interval int64 `json:"interval"`
}
DeviceCodeResponse is the struct to store the response of the device code call
type Episode ¶
type Episode struct {
ID int `json:"id"`
Name string `json:"name"`
Number int `json:"number"`
SeasonNumber int `json:"season_number"`
AirDate string `json:"air_date"`
AirTime string `json:"air_time"`
Network string `json:"network"`
IsNew bool `json:"is_new"`
Seen bool `json:"seen"`
Show Show `json:"show"`
}
Episode is the struct to store an episode
type GetUpcomingResponse ¶
type GetUpcomingResponse struct {
Result string `json:"result"`
Episodes []Episode `json:"episodes"`
Message string `json:"message"`
Code int `json:"code"`
}
GetUpcomingResponse stores the get response of the upcoming
type GetUserResponse ¶
type GetUserResponse struct {
Result string `json:"result"`
User User `json:"user"`
Message string `json:"message"`
Code int `json:"code"`
}
GetUserResponse stores the get response of the user
type GetWatchlistResponse ¶
type GetWatchlistResponse struct {
Result string `json:"result"`
Episodes []Episode `json:"episodes"`
Message string `json:"message"`
Code int `json:"code"`
}
GetWatchlistResponse stores the get response of the watchlist
Click to show internal directories.
Click to hide internal directories.