The Features Menu :: SD Card


param.cgi?cmd=getsdinfo

Get SD Card Parameter

  • sdstatus: SD card mounted [0, 1]
  • sdfreespace: Available space on SD card
  • sdtotalspace: Total space on SD card

Example

GET: http://admin:instar@192.168.2.168/param.cgi?cmd=getsdinfo

cmd="getsdinfo";
sdstatus="1";
sdfreespace="26341867520";
sdtotalspace="32028753920";
response="200";
GET: http://192.168.2.168/param.cgi?cmd=getsdinfo&user=admin&pwd=instar

cmd="getsdinfo";
sdstatus="1";
sdfreespace="15773270016";
sdtotalspace="15804137472";
response="200";

param.cgi?cmd=sdfrmt

Format SD Card

  • fs: Optional parameter to select the filesystem format - defaults to exFAT [exfat, fat32]

Example

GET: http://admin:instar@192.168.2.168/param.cgi?cmd=sdfrmt&fs=exfat
GET: http://192.168.2.168/param.cgi?cmd=sdfrmt&user=admin&pwd=instar

cmd="sdfrmt";
response="200";

param.cgi?cmd=sdstop

Unmount SD Card

Example

GET: http://admin:instar@192.168.2.168/param.cgi?cmd=sdstop
GET: http://192.168.2.168/param.cgi?cmd=sdstop&user=admin&pwd=instar

cmd="sdstop";
response="200";

param.cgi?cmd=sdstart

Mount SD Card

Example

GET: http://admin:instar@192.168.2.168/param.cgi?cmd=sdstart
GET: http://192.168.2.168/param.cgi?cmd=sdstart&user=admin&pwd=instar

cmd="sdstart";
response="200";

param.cgi?cmd=getsdattr

Automatically delete files on SD card after x days

  • sd_autodelete: Enable / disable automated file deletion [1, 0]
  • sd_rstorage_enable: Enable / disable deletion of files older than specified in the param below [1, 0]
  • sd_rstorage_duration: Maximum storage duration of images and recordings [1-30]

Example

GET: http://admin:instar@192.168.2.168/param.cgi?cmd=getsdattr

cmd="getsdattr";
sd_autodelete="1";
sd_rstorage_enable="1";
sd_rstorage_duration="5";
response="200";
GET: http://192.168.2.168/param.cgi?cmd=getsdattr&user=admin&pwd=instar

cmd="getsdattr";
sd_autodelete="1";
sd_rstorage_enable="0";
sd_rstorage_duration="10";
response="200";
SET: http://admin:instar@192.168.2.168/param.cgi?cmd=setsdattr&sd_autodelete=0&sd_rstorage_enable=0&sd_rstorage_duration=10

cmd="setsdattr";
response="200";

param.cgi?cmd=getsdaction

Set SD Storage Parameter

Recording options on SD card:

  • enable: De/Activate alarm recording [0, 1]
  • interval: Recording interval / Cooldown time [1 - 86400] s
  • type: rec, manualrec, snap, timedsnap
    • rec: Alarm video recording
    • manualrec: Manual video recording
    • snap: Alarm snapshot recording
    • timedsnap: Manual snapshot recording

Example

GET: http://admin:instar@192.168.2.168/param.cgi?cmd=getsdaction

cmd="getsdaction";
enable['snap']="0";
interval['snap']="120";
enable['timersnap']="0";
interval['timersnap']="30";
enable['rec']="0";
interval['rec']="0";
enable['manualrec']="1";
interval['manualrec']="0";
response="200";
GET: http://192.168.2.168/param.cgi?cmd=getsdaction&type=rec&user=admin&pwd=instar

cmd="getsdaction";
enable="0";
interval="120";
response="200";
SET: http://admin:instar@192.168.2.168/param.cgi?cmd=setsdaction&type=snap&enable=0&interval=60

cmd="setsdaction";
response="200";

param.cgi?cmd=getsdactionattr

Set SD Alarm Snapshot Count

  • snapcount: Number of Snapshots per Alarm Event [1,10]

Example

GET: http://admin:instar@192.168.2.168/param.cgi?cmd=getsdactionattr

cmd="getsdactionattr";
snapcount="5";
response="200";
GET: http://192.168.2.168/param.cgi?cmd=getsdactionattr&user=admin&pwd=instar

cmd="getsdactionattr";
snapcount="5";
response="200";
SET: http://admin:instar@192.168.2.168/param.cgi?cmd=setsdaction&snapcount=10

cmd="setsdaction";
response="200";

param.cgi?cmd=getsdevents

Get alarm event by trigger

  • count: Return the count of alarm events recorded
  • trigger: Only return events with the selected trigger - see FAQ for Alarmserver Triggers
  • object: Only return events with the selected detected object [0 = none, 1 = person, 2 = car, 4 = animal ]
  • max: Maximum amount of events returned. If max is not supplied, 512 is used,
  • start: Define the start of an event selection window as a UNIX Timestamp
  • end: Define the end of the event selection window as a UNIX Timestamp
  • type: Type of event [0 = alarm, 1 = planned, 2 = scheduled]

Example

GET: http://192.168.2.168/param.cgi?cmd=getsdevents&count=1&user=admin&pwd=instar

cmd="getsdevents";
count="10";
response="200";
GET: http://admin:instar@192.168.2.168/param.cgi?cmd=getsdevents&trigger=1&max=1

cmd="getsdevents";
id[0]="1";
time[0]="1758093343";
type[0]="0";
trigger[0]="3841";
object[0]="0";
action[0]="2";
response="200";
GET: http://admin:instar@192.168.2.168/param.cgi?cmd=getsdevents&object=1&max=4

cmd="getsdevents";
id[0]="3";
time[0]="1758093372";
type[0]="0";
trigger[0]="256";
object[0]="1";
action[0]="0";
id[1]="5";
time[1]="1758093403";
type[1]="0";
trigger[1]="512";
object[1]="1";
action[1]="2";
id[2]="6";
time[2]="1758093405";
type[2]="0";
trigger[2]="512";
object[2]="1";
action[2]="0";
id[3]="7";
time[3]="1758093419";
type[3]="0";
trigger[3]="1024";
object[3]="1";
action[3]="0";
response="200";
GET: http://admin:instar@192.168.2.201/param.cgi?cmd=getsdevents&start=1758066660&end=1758107660

cmd="getsdevents";
id[0]="1";
time[0]="1758093343";
type[0]="0";
trigger[0]="3841";
object[0]="0";
action[0]="2";
id[1]="2";
time[1]="1758093358";
type[1]="0";
trigger[1]="2560";
object[1]="0";
action[1]="0";
id[2]="3";
time[2]="1758093372";
type[2]="0";
trigger[2]="256";
object[2]="1";
action[2]="0";
id[3]="4";
time[3]="1758093390";
type[3]="0";
trigger[3]="2306";
object[3]="0";
action[3]="0";
response="200";

param.cgi?cmd=getsdeventinfo

Get Information for alarm event by ID

  • id: ID of the alarm event you want to inspect

Example

GET: http://admin:instar@192.168.2.168/param.cgi?cmd=getsdeventinfo&id=10

cmd="getsdeventinfo";
time="1758094227";
type="0";
trigger="256";
object="0";
faces="";
plates="";
action="2";
fileid[0]="19";
filename[0]="20250917/record/A_2025-09-17_15-30-26.mp4";
fileid[1]="20";
filename[1]="20250917/images/A_2025-09-17_15-30-27.jpeg";
fileid[2]="21";
filename[2]="20250917/images/A_2025-09-17_15-30-28.jpeg";
fileid[3]="22";
filename[3]="20250917/images/A_2025-09-17_15-30-29.jpeg";
fileid[4]="23";
filename[4]="20250917/images/A_2025-09-17_15-30-30.jpeg";
fileid[5]="24";
filename[5]="20250917/images/A_2025-09-17_15-30-31.jpeg";
response="200";

param.cgi?cmd=getsdfiles

Get alarm recordings information

  • count: Return the count of alarm recordings recorded
  • max: Maximum amount of recordings returned. If max is not supplied, 512 is used,
  • start: Define the start of an event selection window as a UNIX Timestamp
  • end: Define the end of the recordings selection window as a UNIX Timestamp
  • type: Type of recording [0 = Snapshot/JPG, 1 = Video/MP4]

Example

GET: http://192.168.2.168/param.cgi?cmd=getsdfiles&count=1&user=admin&pwd=instar

cmd="getsdfiles";
count="7";
response="200";
GET: http://admin:instar@192.168.2.201/param.cgi?cmd=getsdfiles&type=1

cmd="getsdfiles";
id[0]="1";
event[0]="1";
type[0]="1";
time[0]="1758108465";
name[0]="20250917/record/A_2025-09-17_19-27-45.mp4";
viewed[0]="0";
id[1]="7";
event[1]="0";
type[1]="1";
time[1]="1758108472";
name[1]="20250917/record/M_2025-09-17_19-27-52.mp4";
viewed[1]="0";
response="200";
GET: http://admin:instar@192.168.2.201/param.cgi?cmd=getsdfiles&start=1758066660&end=1758107660

cmd="getsdfiles";
id[0]="1";
time[0]="1758093343";
type[0]="0";
trigger[0]="3841";
object[0]="0";
action[0]="2";
id[1]="2";
time[1]="1758093358";
type[1]="0";
trigger[1]="2560";
object[1]="0";
action[1]="0";
id[2]="3";
time[2]="1758093372";
type[2]="0";
trigger[2]="256";
object[2]="1";
action[2]="0";
id[3]="4";
time[3]="1758093390";
type[3]="0";
trigger[3]="2306";
object[3]="0";
action[3]="0";
response="200";

param.cgi?cmd=getsdfileinfo

Get Information for alarm recorded file by ID or recording path

  • id: ID of the recording you want to inspect
  • name: Path of the recording you want to inspect

Example

GET: http://admin:instar@192.168.2.168/param.cgi?cmd=getsdfileinfo&id=1

cmd="getsdfileinfo";
id="1";
event="1";
type="1";
time="1758108465";
name="20250917/record/A_2025-09-17_19-27-45.mp4";
viewed="0";
codec="h265";
length="7";
size="950336";
response="200";
GET: http://admin:instar@192.168.2.168/param.cgi?cmd=getsdfileinfo&name=20250917%2Frecord%2FA_2025-09-17_19-27-45.mp4

cmd="getsdfileinfo";
id="1";
event="1";
type="1";
time="1758108465";
name="20250917/record/A_2025-09-17_19-27-45.mp4";
viewed="0";
codec="h265";
length="7";
size="950336";
response="200";

param.cgi?cmd=deletesd

Delete recorded file from the internal SD card

  • path: Recording path can be retrieved by the getsdfileinfo command above - e.g. 20250917/record/A_2025-09-17_19-27-45.mp4

Example

GET: http://admin:instar@192.168.2.168/param.cgi?cmd=deletesd&path=20250917%2Frecord%2FA_2025-09-17_19-27-45.mp4

cmd="deletesd";
response="200";