variable coverPreview

Codec for <CoverPreview>.

Examples

Ask for three frames of a recording

import { assertStringIncludes } from "@std/assert";
import { coverPreview } from "@hertzg/reolink-api/protocol/params";

const xml = coverPreview.encode({
  channelId: 0,
  streamType: "mainStream",
  startTime: { year: 2026, month: 10, day: 9, hour: 8, minute: 0, second: 0 },
  frameList: [0, 10, 20],
});

assertStringIncludes(xml, "<frameList><frameNo>0</frameNo>");

Type

XmlParam<"CoverPreview", CoverPreview>

Usage

import { coverPreview } from "protocol/params/mod.ts";