var Transport = http.Transport{ Proxy: func(req *http.Request) (*url.URL, error) { if path.Ext(req.URL.Path) != ".mp4" { log.Println(req.Method, req.URL) } return http.ProxyFromEnvironment(req) }, }
func Id(rawUrl string) (string, error)
hulu.com/movie/05e76ad8-c3dd-4c3e-bab9-df3cf71c6871 hulu.com/movie/alien-romulus-05e76ad8-c3dd-4c3e-bab9-df3cf71c6871
type DeepLink struct { EabId string `json:"eab_id"` Message string }
type Playlist struct { DashPrServer string `json:"dash_pr_server"` WvServer string `json:"wv_server"` Message string StreamUrl string `json:"stream_url"` // MPD }
func (p *Playlist) PlayReady(data []byte) ([]byte, error)
func (p *Playlist) Widevine(data []byte) ([]byte, error)
type Session struct { DeviceToken string `json:"device_token"` UserToken string `json:"user_token"` }
func (s *Session) DeepLink(id string) (*DeepLink, error)
func (s *Session) Playlist(deep *DeepLink) (*Playlist, error)
1080p (FHD) L3, SL2000 1440p (QHD) L1, SL3000 2160p (UHD) L1, SL3000
func (s *Session) Refresh() error
returns user_token only
func (s *Session) Unmarshal(data SessionData) error
type SessionData []byte
func FetchSession(email, password string) (SessionData, error)