micropvr_control is a standard management and monitoring tool for micropvr. Requires the JSON RPC API enabled.
Example of use (getting a list of record files for a channel with ID 4):
micropvr_control -H 127.0.0.1 -f get_records -a 4 -d
Arguments for launching micropvr_control
-hh- make a brief statement.-V- get a version.-H- micropvr API host. If the option is not set, 127.0.0 will be used. 1.-p- micropvr API port. If the option is not set, 4089 will be used.-q“silent mode”: do not display messages in the standard stream.-dDebugging mode: print the response from the server into a standard stream as JSON documents.-do not request confirmation for removal and cancellation operations.-f- the name of the API function. The list of functions is given below.-Unnamed arguments of the function. Set in a strictly defined order through the space.-AAHNamed arguments of the function. Set in any order through a space in the formatname_argument=argument. For example,-A channel_ID=8 record_location=/tmp/pvr. Argument names are case sensitive.
No more than one option should be indicated - or -AAH. Otherwise, correct behavior is not guaranteed.
Micropvr_control functions
List of records
Command name and parameters: get_records [channel_id].
It displays a list of record files for channel_id. If channel_id is not specified, it displays all records files.
Cancellation of channel recording
Command name and parameters: cancel_task channel_id [record_location].
Cancels all running tasks for the channel ID channel_id and record_location directory. If record_location is not set, it cancels all tasks for a given channel.
Deletion of records
Command name and parameters: delete_records [timestamp] [channel_id].
Deletes files that are not actively recorded for channel_id and whose recording was started no later than timestamp. If channel_id and timestamp are not specified, it deletes all records.
Deletion of obsolete records
Command name and parameters: delete_records_days ndays [channel_id].
Deletes files that are not actively recorded for channel_id in the oldest days. If channel_id is not specified, it deletes all records from the oldest days.