Skip to main content

Push_auto_list

Push_Auto_List

This call returns a list of currently active automatic push entries (which can be used in "push_auto_remove" calls). It is closely related to push_auto_add.

It is called as such:

{
"push_auto_list": true //value is ignored
}

And is responded using two methods:

  • auto_push available in MistServer versions 3.6+ returns an auto_push_ID and information as an object
  • push_auto_list available in MistServer versions 3.5.1 and below returns an array of pushes set up by stream name and push target.

Required fields:

  • stream // String containing stream name or tag
  • target // String containing push target

Optional fields:

  • x-LSP-notes // String with notes
  • scheduletime // unix time in seconds the recording should start
  • completetime // unix time in seconds the recording should end
  • start_rule // Array with 3 values, 1: variable name, 2: variable operator, 3: variable value
  • end_rule // Array with 3 values, 1: variable name, 2: variable operator, 3: variable value
info

Start and end rule will require some explanation.

  • Variable name: This should be the name of the variable known to MistServer, that can be from variable substitutions or a custom variable. Do not add the $ sign.
  • Variable operator: Requires a corresponding number from the operator list
  • Variable value: This can be anything from a value to a string of values. Whether it makes sense is up to whatever the variable name value is. example: Variable hour gives the corresponding current server time hour from 0-23
`"start_rule":["hour",10,9]`,
`"end_rule":["hour",10,17]` ,

Would have the push be active from 9:00 to 17:00 (9:00 am to 5:00 pm)

Converted fields

  • startVariableName, startVariableOperator, startVariableValue will be converted into start_rule for backwards compatibility
  • endVariableName, endVariableOperator, endVariableValue will be converted into end_rule for backwards compatibility
  • scheduletime & completetime will be converted to an integer should they not already be one.

Any other value will be ignored for future compatibility.

{
"auto_push": {
"71d6b51b668e1f24973def9210cb5644": { //auto_push_ID generated if not provided
"stream": "mylivestream", //Stream name or #Tag that should be checked for pushing
"target": "/tmp/$stream/$yday_$datetime.mkv", //stream url or file location to push/record towards
"x-LSP-notes": "notes go here!", //Optional field for notes visible in the push panel
"start_rule":["hour",11,9],
"end_rule":["hour",11,17]
},
//Etcetera
},
"push_auto_list":[ //deprecated, still available for backwards compatibility.
["mylivestream", "/tmp/$stream/$yday_$datetime.mkv", scheduletime, completetime],
//Etcetera
]
}

Operator list

0: boolean true
1: boolean false
2: ==
3: !=
10: > (numerical comparison)
11: >= (numerical comparison)
12: < (numerical comparison)
13: <= (numerical comparison)
20 > (lexical comparison)
21: >= (lexical comparison)
22: < (lexical comparison)
23: <= (lexical comparison)