class Session
extends EventEmitter
Re-export
import { Session } from "https://deno.land/x/youtubei@v9.3.0-deno/deno.ts";
Represents an InnerTube session. This holds all the data needed to make requests to YouTube.
Constructors
new
Session(context: Context,
api_key: string,
api_version: string,
account_index: number,
player?: Player,
cookie?: string,
fetch?: FetchFunction,
cache?: ICache,
Properties
Methods
on(type: "auth", listener: OAuthAuthEventHandler): void
on(type: "auth-pending", listener: OAuthAuthPendingEventHandler): void
on(type: "auth-error", listener: OAuthAuthErrorEventHandler): void
on(type: "update-credentials", listener: OAuthAuthEventHandler): void
once(type: "auth", listener: OAuthAuthEventHandler): void
once(type: "auth-pending", listener: OAuthAuthPendingEventHandler): void
once(type: "auth-error", listener: OAuthAuthErrorEventHandler): void
signIn(credentials?: Credentials): Promise<void>
Static Methods
create(options?: SessionOptions)
getSessionData()
lang?,
location?,
account_index?,
visitor_data?,
enable_safety_mode?,
generate_session_locally?,
device_category?: DeviceCategory,
client_name?: ClientType,
tz?: string,
fetch?: FetchFunction,
on_behalf_of_user?: string,