func AcquireLicense(challenge []byte, token *ProfileToken, activePlayback *Playback) ([]byte, error)
SL2000 max 2160p
func GetStream(token *ProfileToken, activePlayback *Playback) (*url.URL, error)
type AccountToken struct { AccessToken string `json:"access_token"` RefreshToken string `json:"refresh_token"` AccountId string `json:"account_id"` Jti string `json:"jti"` }
func PerformLogin(username string, password string) (*AccountToken, error)
func (*AccountToken) CachePath() string
type ContentPackage struct { DurationInSeconds int `json:"durationInSeconds"` Id int `json:"id"` IsDescribedVideo bool `json:"isDescribedVideo"` Language string `json:"language"` }
type Experience struct { Id string `json:"id"` Sku string `json:"sku"` BrandId string `json:"brandId"` DisplayName string `json:"displayName"` }
type FirstContent struct { Id int `json:"id,string"` }
type Media struct { FirstContent FirstContent `json:"firstContent"` Id int `json:"id,string"` }
func GetMedia(showId int) (*Media, error)
func ParseMedia(rawUrl string) (*Media, error)
https://crave.ca/en/movie/anaconda-2025-59881 https://crave.ca/en/play/anaconda-2025-3300246 https://crave.ca/movie/anaconda-2025-59881 https://crave.ca/play/anaconda-2025-3300246 https://crave.ca/play/heated-rivalry/ill-believe-in-anything-s1e5-3233873
func (*Media) CachePath() string
type Playback struct { ContentId int `json:"contentId,string"` ContentPackage ContentPackage `json:"contentPackage"` DestinationId int `json:"destinationId"` Error string // 2026-05-03 }
func GetPlayback(token *ProfileToken, activeMedia *Media) (*Playback, error)
func (*Playback) CachePath() string
type Profile struct { Id string `json:"id"` AccountId string `json:"accountId"` Nickname string `json:"nickname"` HasPin bool `json:"hasPin"` Master bool `json:"master"` Maturity string `json:"maturity"` Onboarded bool `json:"onboarded"` UiLanguage string `json:"uiLanguage"` PlaybackLanguages []string `json:"playbackLanguages"` LastModifiedDate string `json:"lastModifiedDate"` AvatarUrl string `json:"avatarUrl"` }
func GetProfiles(account *AccountToken) ([]Profile, error)
func (p *Profile) String() string
type ProfileToken struct { AccessToken string `json:"access_token"` RefreshToken string `json:"refresh_token"` Scope string `json:"scope"` TokenType string `json:"token_type"` ExpiresIn int `json:"expires_in"` }
func SwitchProfile(account *AccountToken, profileId string) (*ProfileToken, error)
func (*ProfileToken) CachePath() string
type Subscription struct { Type string `json:"type"` Experience Experience `json:"experience"` SubscriptionState string `json:"subscriptionState"` StoreName string `json:"storeName"` ExpirationDate string `json:"expirationDate"` AutoRenewStatus bool `json:"autoRenewStatus"` }
func GetSubscriptions(token *ProfileToken) ([]Subscription, error)
func (s *Subscription) String() string