Hubfly spaceDocs
Console

Recording and clips

A channel can record everything it plays to a Hubfly space Storage bucket, keep a DVR window so viewers can rewind, and cut clips from that window while the show is still live. Recordings and clips land in Storage as video assets you can play, share or put back on air in a playlist.

Before you start

Recordings and clips are written through a storage link with write or read_write access. Link a bucket under Recordings → Storage buckets; it needs storage:admin on the Storage project. See Link a Storage bucket.

Record a channel

A channel's recording settings:

FieldMeaning
enabledRecord whenever the channel is live.
storageLinkThe storage link to write to (ssl_…), with write access.
prefixWhere in the bucket recordings go, for example recordings/main/.
splitMinutes5–720. A long show is saved in parts of this length (60 by default).
registerAssetRegister each part as a video asset in Storage.

Set them on the channel under Channels, or with the API or the CLI:

bash
echo '{"recording": {"enabled": true, "storageLink": "ssl_vod00001", "prefix": "recordings/main/",
  "splitMinutes": 60, "registerAsset": true}}' | hubfly stream channels update acme-tv Main --file -

Start and stop recording

To record only part of a show, start and stop recording live. This overrides enabled until you change it again:

bash
hubfly stream control acme-tv --record-start sch_main0001
hubfly stream control acme-tv --record-stop sch_main0001

These send the recording.start and recording.stop control ops (field channel), which need stream:operate. A schedule can run them to record a show at a set time.

Where recordings go

  • Each finished part is uploaded to the linked bucket under the channel's prefix. The recording.completed event gives its object_key.
  • With registerAsset, Hubfly space registers each part as a Storage video asset (no second upload) and starts its HLS encoding, so you can play it, share it or add it to a playlist.
  • Recordings are ordinary objects in your bucket and count against your Storage quota. The stream server does not bill the upload.
  • Deleting the stream server removes its DVR and local files. Recordings already in Storage stay.

A recording shows Recording while it runs, then Uploading. In the API its status is recording, uploading, completed, registered (the Storage asset exists) or failed.

DVR

dvrMinutes (0–360) keeps the last minutes of a channel on the media node. Viewers can rewind within that window, and clips are cut from it. The HLS playlist becomes a sliding window with the time of every segment.

bash
hubfly stream channels update acme-tv Main --dvr 120

Cut a clip

A clip is a piece of the DVR window saved to Storage while the channel is live, such as a goal or a quote. It needs DVR on the channel and stream:operate.

  • In the Dashboard: under Recordings, cut a clip: choose the channel, a name, when it starts (seconds ago) and its length, and where to save it.
  • From and to are RFC 3339 times, or negative offsets from now: -90s, -2m, -500ms, -1h.
  • Name: up to 200 characters. It becomes the asset's title in Storage.
  • Storage: the channel's recording link, or another storage link with write access.
bash
hubfly stream clips create acme-tv --channel sch_main0001 --from -90s --to -0s --name "Winning goal"
hubfly stream clips create acme-tv --channel sch_main0001 \
  --from 2026-11-02T18:42:10Z --to 2026-11-02T18:43:00Z --name "Opening" --storage-link ssl_vod00001

With the API, POST …/stream/clips/create takes {channelId, from, to, name, storageLinkId} and returns {clipId} (sclp_…). In a POST …/stream/control request, the same work is the clip.create op. Schedules cannot cut clips.

STREAM_NOT_LIVE

A clip of a channel without DVR, or of a time the DVR window does not hold, is refused with 409 STREAM_NOT_LIVE. Turn on DVR before the moment you want to clip.

List and delete

bash
hubfly stream recordings acme-tv --channel sch_main0001
hubfly stream recordings acme-tv --kind clip
hubfly stream recordings delete acme-tv <recording>                  # removes the record only
hubfly stream recordings delete acme-tv <recording> --delete-object  # also deletes the file and asset in Storage
  • GET …/stream/recordings lists recordings and clips (filter with kind and channelId), with their storage link, bucket, object key and Storage asset.
  • Each part of a recording is its own entry, with an id such as srec_7h2k9q#1; clips use their sclp_ id. Encode # as %23 in a URL.
  • DELETE …/stream/recordings/:recordingId/delete removes the record and keeps the file. With deleteObject: true it also deletes the object and its asset in Storage, which needs storage:write on the Storage project.

Events

EventData
recording.startedrecording, channel
recording.completedrecording, channel, storage_link, object_key, part, bytes, duration_ms, started_at, ended_at, register_asset. Sent once per part.
recording.failedrecording, channel, error
clip.completed, clip.failedclip, channel, storage_link, object_key, bytes, duration_ms, name, error?

Receive them with webhooks, for example to post a new recording to your site. See Recordings and storage in the API reference.

Something unclear or out of date? Emailsupport@hubfly.spaceBack to top