# Range

## Function

This API is used to retrieve the parameter range for the Appearance Frequency page.

## Request Message

None.

Sample:

    POST /API/Maintenance/AutoReboot/Range HTTP/1.1

    {
        "version": "1.0",
        "data": {}
    }

## Response Message

### Parameter Description

##### Table 1

Parameter | Range | Type | Description
--- | --- | --- | ---
group_info_list |  | array | The groups that participate in the statistics. For details, see Table 2.
channel | "CH1"…"CH1x" "IP_CH1"…" IP_CH1x" "WIFI_CH1"…" WIFI_CH1x" | array | The channels that participate in the statistics.
frequency_interval | 1 ~ 1440 | int | Counting interval, within this interval, no duplicate counting will occur. Unit: minutes.
similarity | 1 ~ 100 | int | Filter condition: Similarity.
max_statistics |  | int | Maximum count for strangers.
alarm_switch |  | bool | Linked alarm switch.
age_filter_switch |  | bool | Age filtering switch.
alarm_min_age | 1 ~ 18 | int | Filter condition: Minimum age.
frequency_threshold_value | 2 ~ 20 | int | The threshold for personnel presence within a cycle time ("cyclde"), and an alarm will be triggered once the threshold is reached.
cyclde | 1 ~ 90 | int | Detection and alarm cycle. When the number of occurrences within the current cycle reaches the threshold value ("frequency_threshold_value"), an alarm will be triggered.
buzzer |  | bool | Interlinked switch for buzzer.
io_output |  | bool | Interlinked switch for IO output.
alarm_out | "Local->1"…"Local->x" "IP_CH1->1"…"IP_CHx->x" | array | Linked IO ID.
voice_prompts |  | bool | voice prompts interlinked switch.
voice_prompts_index | Max len: 12 | int array | File index.
voice_prompts_select | Max len: 12 | int array | Channels to be linked to be played.
voice_prompts_speaker_select | Max len: 12 | int array | Speakers to be linked to be played.
voice_prompts_time |  | array | Play time range. There can be no time conflicts in the 12 time periods. For details, see Table 3.
voice_prompts_speaker_select | Max len: 12 | int array | ip speaker to be linked to be played.

##### Table 2

Parameter | Range | Type | Description
--- | --- | --- | ---
name | len:0 ~ 127 | string | Group name.
group_id |  | int | Group id.
is_selected |  | bool | Whether the group is selected.

##### Table 3

Parameter | Range | Type | Description
--- | --- | --- | ---
start_hour | 0 ~ 23 | int |
start_minute | 0 ~ 59 | int |
start_second | 0 ~ 59 | int |
end_hour | 0 ~ 23 | int |
end_minute | 0 ~ 59 | int |
end_second | 0 ~ 59 | int |

Sample:

    HTTP/1.1 200 OK
    Content-Type: application/json

    {
        "result": "success",
        "data": {
            "group_info_list": {
                "type": "array",
                "min_size": 0,
                "max_size": 64,
                "items": [{
                    "name": {
                        "type": "string",
                        "min_len": 0,
                        "max_len": 127
                    },
                    "group_id": {
                        "type": "uint32",
                        "min": 1,
                        "max": 4294967295
                    },
                    "is_selected": {"type": "bool"}
                }]
            },
            "channel": {
                "type": "array",
                "min_size": 0,
                "max_size": 32,
                "items": {
                    "type": "string",
                    "items": [
                        "CH1",
                        "CH2",
                        "CH3",
                        "CH4",
                        "CH5",
                        "CH6",
                        "CH7",
                        "CH8",
                        "CH9",
                        "CH10",
                        "CH11",
                        "CH12",
                        "CH13",
                        "CH14",
                        "CH15",
                        "CH16",
                        "CH17",
                        "CH18",
                        "CH19",
                        "CH20",
                        "CH21",
                        "CH22",
                        "CH23",
                        "CH24",
                        "CH25",
                        "CH26",
                        "CH27",
                        "CH28",
                        "CH29",
                        "CH30",
                        "CH31",
                        "CH32"
                    ]
                }
            },
            "frequency_interval": {
                "type": "int32",
                "min": 1,
                "max": 1440
            },
            "similarity": {
                "type": "int32",
                "min": 1,
                "max": 100
            },
            "max_statistics": {
                "type": "int32",
                "min": 1,
                "max": 10000
            },
            "alarm_switch": {"type": "bool"},
            "age_filter_switch": {"type": "bool"},
            "alarm_min_age": {
                "type": "int32",
                "min": 1,
                "max": 18
            },
            "frequency_threshold_value": {
                "type": "int32",
                "min": 2,
                "max": 20
            },
            "cycle": {
                "type": "int32",
                "min": 1,
                "max": 90
            },
            "buzzer": {"type": "bool"},
            "io_output": {"type": "bool"},
            "alarm_out": {
                "type": "array",
                "min_size": 0,
                "max_size": 65,
                "items": {
                    "type": "string",
                    "items": [
                        "Local->1",
                        "172.16.11.178->1",
                        "172.16.11.178->2",
                        "172.16.11.132->1",
                        "172.20.51.21->1"
                    ]
                }
            },
            "voice_prompts": {"type": "bool"},
            "voice_prompts_index": {
                "type": "array",
                "min_size": 0,
                "max_size": 12,
                "items": {
                    "type": "int32",
                    "min": 0,
                    "max": 65535
                }
            },
            "voice_prompts_select": {
                "type": "array",
                "min_size": 0,
                "max_size": 12,
                "items": {
                    "type": "uint32",
                    "min": 0,
                    "max": 4294967295
                }
            },
            "voice_prompts_speaker_select": {
                "type": "array",
                "min_size": 0,
                "max_size": 12,
                "items": {
                    "type": "uint32",
                    "min": 0,
                    "max": 4294967295
                }
            },
            "voice_prompts_time": {
                "type": "array",
                "min_size": 0,
                "max_size": 12,
                "items": []
            },
            "voice_prompts_speaker_select": {
                "type": "array",
                "min_size": 0,
                "max_size": 12,
                "items": {
                    "type": "uint32",
                    "min": 0,
                    "max": 4294967295
                }
            }
        }
    }

## Error Code

See Response Messages Body and Common error_code for more information.