Skip to content

Built for people who want to own their automations. Join the waitlist for an invite.

Package listing

@kody/twitch

src/get-channel.ts

14 lines · 521 B · TypeScript
import { lookupChannels } from './client.ts'

/**
 * Look up Twitch channel information (title, game, tags) by login or id.
 * Omitting selectors returns the authenticated user's channel.
 *
 * @example
 * import getChannel from 'kody:@kody/twitch/get-channel'
 * const [channel] = await getChannel({ login: 'twitchdev' })
 * // => { broadcasterLogin: 'twitchdev', title: '...', gameName: '...' }
 */
export default async function twitchGetChannel(params: Record<string, unknown> = {}) {
	return lookupChannels(params)
}