# Get

## Function

This API is used to get IPC ftp update parameters.

## Request Message

None.

Sample:

    POST /API/IPCMaintaint/FtpIpcUpgrade/Get HTTP/1.1

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

## Response Message

### Parameter Description

##### Table 1

Parameter | Range | Type | Description
--- | --- | --- | ---
ftp_auto_upgrade |  | bool | ftp auto upgrade IPC switch.
check_for_updates |  | bool | ftp automatic upgrade IPC prompt switch.
online_upgrade |  | bool | A new interface for judging whether to use FTP or HTTP to upgrade IPC online.
channel_info |  | object | Total channel information object, see Table 2 for details.

##### Table 2

Parameter | Range | Type | Description
--- | --- | --- | ---
CH1 |  | object | A channel information object, see Table 3 for details.
... |  | object |
IP_CH1 |  | object |
... |  | object |
WIFI_CH1 |  | object |
... |  | object |

##### Table 3

Parameter | Range | Type | Description
--- | --- | --- | ---
sup_ftp_auto_upgrade |  | bool | Whether the channel IPC supports automatic upgrade.
ftp_ipc_new_ver |  | bool | Whether there is a new version of channel IPC.
upgrade_result | len:0-32 | string | update result.

> Tips:

> The response message of the Get request may not contain all the fields in the above table, and the fields not included indicate that the device does not support this parameter configuration.

Sample:

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

    {
        "result": "success",
        "data": {
            "online_upgrade": true,
            "ftp_auto_upgrade": false,
            "check_for_updates": false,
            "channel_info": {
                "CH3": {
                    "reason": "Not support"
                },
                "CH7": {
                    "reason": "Not support"
                },
                "CH8": {
                    "sup_ftp_auto_upgrade": true,
                    "upgrade_result": "cannot_upgrade",
                    "ftp_ipc_new_ver": false
                },
                "CH10": {
                    "reason": "Not support"
                },
                "CH11": {
                    "sup_ftp_auto_upgrade": false
                },
                "CH14": {
                    "reason": "Not support"
                },
                "CH15": {
                    "sup_ftp_auto_upgrade": true,
                    "upgrade_result": "cannot_upgrade",
                    "ftp_ipc_new_ver": false
                },
                "CH16": {
                    "sup_ftp_auto_upgrade": true,
                    "upgrade_result": "",
                    "ftp_ipc_new_ver": false
                }
            }
        }
    }

## Error Code

See Response Messages Body and Common error_code for more information.