UNPKG

@twurple/api

Version:

Interact with Twitch's API.

47 lines 1.68 kB
import { DataObject } from '@twurple/common'; import { type HelixGameData } from '../../interfaces/endpoints/game.external'; import { type HelixStreamData } from '../../interfaces/endpoints/stream.external'; import type { HelixPaginatedRequest } from '../../utils/pagination/HelixPaginatedRequest'; import type { HelixPaginatedResult } from '../../utils/pagination/HelixPaginatedResult'; import type { HelixPagination } from '../../utils/pagination/HelixPagination'; import type { HelixStream } from '../stream/HelixStream'; /** * A game as displayed on Twitch. */ export declare class HelixGame extends DataObject<HelixGameData> { /** * The ID of the game. */ get id(): string; /** * The name of the game. */ get name(): string; /** * The URL of the box art of the game. */ get boxArtUrl(): string; /** * The IGDB ID of the game, or null if the game doesn't have an IGDB ID assigned at Twitch. */ get igdbId(): string | null; /** * Builds the URL of the box art of the game using the given dimensions. * * @param width The width of the box art. * @param height The height of the box art. */ getBoxArtUrl(width: number, height: number): string; /** * Gets streams that are currently playing the game. * * @param pagination * @expandParams */ getStreams(pagination?: HelixPagination): Promise<HelixPaginatedResult<HelixStream>>; /** * Creates a paginator for streams that are currently playing the game. */ getStreamsPaginated(): HelixPaginatedRequest<HelixStreamData, HelixStream>; } //# sourceMappingURL=HelixGame.d.ts.map