Stream highlights — cut a highlight of your own live broadcast
Cuts a permanent Highlight out of a streamer's own broadcast on Twitch — including the one still live — between two offsets in seconds, with a title.
Cuts a permanent Highlight out of a streamer's own broadcast on Twitch — including the one still live — between two offsets in seconds, with a title. Needs the streamer's Twitch sign-in: the first run answers needs_user with a link to sign in, and later runs reuse it.
Also known as: stream highlight, create a highlight, twitch highlight, highlight my stream, clip my stream, save a moment from my stream, vod highlight, highlight a past broadcast, speedrun pb highlight
Call it
bowmark.stream_highlights.create(options: CreateHighlightOptions): Promise<StreamHighlight>Functions
| Function | What it does |
|---|---|
create | Cuts a highlight from [startSeconds, endSeconds] of the signed-in streamer's broadcast (videoId, or the newest one — the live one while streaming) and titles it. |
Types
interface CreateHighlightOptions {
platform?: "twitch" // the default, and the only one today
videoId?: string // id or video link; omit for the newest broadcast (the live one, while live)
startSeconds: number // seconds into that broadcast
endSeconds: number
title: string
description?: string
language?: string // default "en"
tags?: string[]
game?: string // category name, e.g. "Wetrix"
}
interface StreamHighlight {
// "created" by this call; "existing" = a highlight with this exact title was
// already on the channel, nothing new made; "unknown" = no answer came back —
// check dashboardUrl. Calling again with the same title is always safe.
status: "created" | "existing" | "unknown"
platform: "twitch"
highlightId: string | null // null only when status is "unknown"
url: string | null
title: string
videoId: string
startSeconds: number
endSeconds: number
channel: string
dashboardUrl: string
warnings: string[]
}
type CallOptions = {
timeoutMs?: number // per-provider budget in ms, default 30000, clamped to 1000-55000.
// A provider slower than this is DROPPED from the results and
// NAMED in warnings — never silently absent
}Examples
// 10 seconds either side of a moment 4:12 into the live broadcast.
const at = 252;
const h = await bowmark.stream_highlights.create({
startSeconds: at - 10,
endSeconds: at + 10,
title: "Wetrix N64 · Classic 100k · PB 4:12.345",
game: "Wetrix",
});
return { status: h.status, url: h.url, warnings: h.warnings };Providers behind it
| Provider | |
|---|---|
twitch | Twitch |