-
Notifications
You must be signed in to change notification settings - Fork 46
Home
- General instructions
-
API pages - Requests and Responses
- Cradle module
- DDNS module
- Device module
- DHCP module
- Diagnosis module
- Dialup module
- Filemanager module
- Global module
- Host module
- Language module
- Monitoring module
- Net module
- Online-update module
- OTA module
- Pb module
- PIN module
- Redirection module
- Sdcard module
- Security module
- SMS module
- Sntp module
- STK module
- The user module
- USSD module
- Voice module
- Webserver module
- WLAN module
- Comments
- API usage
- Error numbers
- Other
- Modification of WebUI files on the example of unlocking Polish in a configuration file
- Automatic PIN administration - modification of the autorun.sh script
- List of configuration pages on the HiLink device
- List of JavaScript files
- Sources of Knowledge
The HiLink API can be divided into two variants:
- Information option: This variant usually requires downloading ( GET ) the appropriate page from the modem ( http://hi.link or http://192.168.8.1 ). That is, getting a response right away.
- Control / configuration variant: It requires sending ( POST ) the request with the address of the appropriate page to the modem. In response to a successful response, we usually receive - OK .
The information variant and control variant usually have the same addresses.
Some versions of the software may require a valid token to verify the session (I did not find any information when the token changes, the token can be disabled by editing configuration files)
As far as I was able to determine this HiLink software is unified. This means that, for example, the HiLink modem contains the same WebUI files as the HiLink router and vice versa. Of course, this does not mean that we turn on, for example, WiFi. Some API pages are blocked by hardware or configuration files.
The following list of API addresses is based on JavaScript files contained in the modified WebUI for the E3372s-153 modem. From the same files are specified requests and responses. The answers below are supplemented in a few cases based on the responses of the E3372s-153 modem.
The list has been sorted alphabetically by module name to which the API data refers.
Getting basic information about cradle (?)
- url: http://192.168.8.1/api/cradle/basic-info
- method: GET
- request: none
- reply:
<response>
<connectionmode></connectionmode>
<pppoeuser></pppoeuser>
<pppoepwd></pppoepwd>
<dialmode></dialmode>
<maxidletime></maxidletime>
<pppoemtu></pppoemtu>
<dynamicipmtu></dynamicipmtu>
<ipaddress></ipaddress>
<netmask></netmask>
<gateway></gateway>
<primarydns></primarydns>
<secondarydns></secondarydns>
<staticipmtu></staticipmtu>
<dynamicsetdnsmanual></dynamicsetdnsmanual>
<dynamicprimarydns></dynamicprimarydns>
<dynamicsecondarydns></dynamicsecondarydns>
</response>
- Comments:
- pppoeuser , pppoepwd cannot contain some characters, so you must replace them by the formula:
- ' & ' - ' & amp; '
- " ' " -' & apos; '
- ' " ' - ' & quot; '
- ' < ' - ' & lt; '
- ' > ' - ' & gt; '
- connectionmode:
- 0 - automatic
- 1 - PPPoE + Dynamic IP address
- 2 - PPPoE
- 3 - Dynamic IP address
- 4 - Static IP address
- 5 - LAN only
- dialmode:
- 0 - automatic
- 1 - On request
- pppoeuser , pppoepwd cannot contain some characters, so you must replace them by the formula:
Cradle network settings (?)
- url: http://192.168.8.1/api/cradle/basic-info
- method: POST
- request:
<request>
<connectionmode></connectionmode>
<pppoeuser></pppoeuser>
<pppoepwd></pppoepwd>
<dialmode></dialmode>
<maxidletime></maxidletime>
<pppoemtu></pppoemtu>
<dynamicipmtu></dynamicipmtu>
<ipaddress></ipaddress>
<netmask></netmask>
<gateway></gateway>
<primarydns></primarydns>
<secondarydns></secondarydns>
<staticipmtu></staticipmtu>
<dynamicsetdnsmanual></dynamicsetdnsmanual>
<dynamicprimarydns></dynamicprimarydns>
<dynamicsecondarydns></dynamicsecondarydns>
</request>
- reply:
<response>OK</response>
- Comments:
- pppoeuser , pppoepwd cannot contain some characters, so you must replace them by the formula:
- ' & ' - ' & amp; '
- " ' " -' & apos; '
- ' " ' - ' & quot; ',
- ' < ' - ' & lt; '
- ' > ' - ' & gt; '
- connectionmode:
- 0 - automatic
- 1 - PPPoE + Dynamic IP address
- 2 - PPPoE
- 3 - Dynamic IP address
- 4 - Static IP address
- 5 - LAN only
- dialmode:
- 0 - automatic
- 1 - On request
- pppoeuser , pppoepwd cannot contain some characters, so you must replace them by the formula:
Set the device's MAC address
- url: http://192.168.8.1/api/cradle/current-mac
- method: POST
- request:
<request>
<currentmac>00:00:00:00:00:00</currentmac>
</request>
- reply:
<response>OK</response>
- Notes: none
Get information about the factory MAC address of the device
- url: http://192.168.8.1/api/cradle/factory-mac
- method: GET
- request: none
- reply:
<response>
<factorymac></factorymac>
</response>
- Notes: none
Getting information about MAC addresses
- url: http://192.168.8.1/api/cradle/mac-info
- method: GET
- request: none
- reply:
<response>
<currentmac></currentmac>
<hostmac></hostmac>
</response>
- Notes: none
Get cradle status information (?)
- url: http://192.168.8.1/api/cradle/status-info
- method: GET
- request: none
- reply:
<response>
<cradlestatus></cradlestatus>
<connectstatus></connectstatus>
<connectionmode></connectionmode>
<currenttime></currenttime>
<ipaddress></ipaddress>
<netmask></netmask>
<gateway></gateway>
<primarydns></primarydns>
<secondarydns></secondarydns>
</response>
- Comments:
- connectstatus:
- 900 - connecting
- 901 - connected
- 902 - disconnected
- 903 - disconnection
- 904 - connection error
- 905 - no PPPoE account
- 906 - incorrect PPPoE account
- connectionmode:
- 0 - automatic
- 1 - PPPoE + Dynamic IP address
- 2 - PPPoE
- 3 - Dynamic IP address
- 4 - Static IP address
- 5 - LAN only
- connectstatus:
Download DNS list download
- url: http://192.168.8.1/api/ddns/ddns-list
- method: GET
- request: none
- reply:
<response>
<ddnss>
<ddns>
<index></index>
<provider></provider>
<status></status>
<domainname></domainname>
<username></username>
<password></password>
</ddns>
<ddns>
...
</ddns>
...
</ddnss>
</response>
- Notes: none
DNS setup
- url: http://192.168.8.1/api/ddns/ddns-list
- method: POST
- request:
<request>
<ddnss>
<ddns>
<index></index>
<provider></provider>
<status></status>
<domainname></domainname>
<username></username>
<password></password>
</ddns>
<ddns>
...
</ddns>
...
</ddnss>
</request>
- reply:
<response>OK</response>
- Notes: none
Checking for new version availability?
- url: http://192.168.8.1/api/device/autorun-version
- method: GET
- request: none
- reply:
<response>
<Version>22.001.25.00.03</Version>
</response>
Notes: none
Basic information
- url: http://192.168.8.1/api/device/basic_information
- method: GET
- request: none
- reply:
<response>
<productfamily>LTE</productfamily>
<classify>hilink</classify>
<multimode>0</multimode>
</response>
- Comments:
- productfamily:
- 1 or CDMA - CDMA mode
- 2 or WCDMA or LTE - WCDMA / LTE mode
- multimode:
- 1 - single mode?
- 2 - multi mode?
- productfamily:
Retrieve the path of the event logging file
- url: http://192.168.8.1/api/device/compresslogfile
- method: GET
- request: none
- reply:
<response>
<LogPath>http://192.168.8.1/FS:/app/webroot/data/userdata/device/WebApp.zip</LogPath>
</response>
- Notes: none
Modem restart, configuration restore, configuration backup, device shutdown
- url: http://192.168.8.1/api/device/control
- method: POST
- request:
<request>
<Control></Control>
</request>
- reply:
<response>OK</response>
- Comments:
- Control:
- 1 - device restart
- 1 2 - configuration restoration (no information on how to provide the file with the saved configuration. Maybe it uses the file http://192.168.8.1/nvram.bak )
- 1 3 - configuration backup (configuration is available at http://192.168.8.1/nvram.bak . File is with base64 encoding)
- 1 4 - turning off the device
Checking the status of the device quick start mode
- url: http://192.168.8.1/api/device/fastbootswitch
- method: GET
- request: none
- reply:
<response>
<fastbootswitch></fastbootswitch>
</response>
- Notes: none
Set the device's quick start status
- url: http://192.168.8.1/api/device/fastbootswitch
- method: POST
- request:
<request>
<fastbootswitch></fastbootswitch>
</request>
- reply:
<response>OK</response>
- Notes: none
Device Information
- url: http://192.168.8.1/api/device/information
- method: GET
- request: none
- reply:
<response>
<DeviceName>E3372</DeviceName>
<SerialNumber>L8FBY14926014416</SerialNumber>
<Imei>866133021233764</Imei>
<Imsi>260060064970338</Imsi>
<Iccid>89480610500149703380</Iccid>
<Msisdn></Msisdn>
<HardwareVersion>CL1E3372SM Ver.A</HardwareVersion>
<SoftwareVersion>22.286.53.01.161</SoftwareVersion>
<WebUIVersion>16.100.05.00.03</WebUIVersion>
<MacAddress1>00:0D:87:8E:4B:AC</MacAddress1>
<MacAddress2></MacAddress2>
<ProductFamily>LTE</ProductFamily>
<Classify>hilink</Classify>
<supportmode>LTE|WCDMA|GSM</supportmode>
<workmode>LTE</workmode>
</response>
- Notes: none
Switching the modem into debug / NDIS mode
- url: http://192.168.8.1/api/device/mode
- method: POST
- request:
<request>
<mode>1</mode>
</request>
- reply:
<response>OK</response>
- Notes: With the modem plugged into the router, the internet connection will disappear when you turn on debug mode.
- mode:
- 0 - project mode (normal operation?)
- 1 - debug / NDIS mode (access to serial ports)
- mode:
Download event logging file settings
- url: http://192.168.8.1/api/device/logsetting
- method: GET
- request: none
- reply:
<response>
<Where>2</Where>
<Size>1000</Size>
<Modules>
<Module>
<name>ats</name>
<desc>AT Server</desc>
<mask>0</mask>
<file></file>
</Module>
<Module>
...
</Module>
...
</Modules>
</response>
- Notes: none
Event logging file settings
- url: http://192.168.8.1/api/device/logsetting
- method: POST
- request:
<request>
<Where>2</Where>
<Size>1000</Size>
<Modules>
<Module>
<name>ats</name>
<desc>AT Server</desc>
<mask>0</mask>
<file></file>
</Module>
<Module>
...
</Module>
...
</Modules>
</request>
- reply:
<response>OK</response>
- Notes: none
Checking the status of the energy saving mode
- url: http://192.168.8.1/api/device/powersaveswitch
- method: GET
- request: none
- reply:
<response>
<powersaveswitch></powersaveswitch>
</response>
- Notes: none
Setting the power saving mode status
- url: http://192.168.8.1/api/device/powersaveswitch
- method: POST
- request:
<request>
<powersaveswitch></powersaveswitch>
</request>
- reply:
<response>OK</response>
- Notes: none
Signal parameters
- url: http://192.168.8.1/api/device/signal
- method: GET
- request: none
- reply:
<response>
<pci>40</pci>
<sc></sc>
<cell_id>2123610</cell_id>
<rsrq>-6dB</rsrq>
<rsrp>-91dBm</rsrp>
<rssi>-71dBm</rssi>
<sinr>14dB</sinr>
<rscp></rscp>
<ecio></ecio>
<mode>7</mode>
</response>
- Notes: none
Checking the USB tethering module status
- url: http://192.168.8.1/api/device/usb-tethering-switch
- method: GET
- request: none
- reply:
<response>
<tetheringswitch></tetheringswitch>
</response>
- Notes: none
Checking USB tethering status
- url: http://192.168.8.1/api/device/usb-tethering
- method: GET
- request: none
- reply:
<response>
<tethering></tethering>
</response>
- Notes: none
Set USB tethering status
- url: http://192.168.8.1/api/device/usb-tethering
- method: POST
- request:
<request>
<tethering></tethering>
</request>
- reply:
<response>OK</response>
- Notes: none
Get DHCP settings
- url: http://192.168.8.1/api/dhcp/settings
- method: GET
- request: none
- reply:
<response>
<DhcpIPAddress>192.168.8.1</DhcpIPAddress>
<DhcpLanNetmask>255.255.255.0</DhcpLanNetmask>
<DhcpStatus>1</DhcpStatus>
<DhcpStartIPAddress>192.168.8.100</DhcpStartIPAddress>
<DhcpEndIPAddress>192.168.8.200</DhcpEndIPAddress>
<DhcpLeaseTime>86400</DhcpLeaseTime>
<DnsStatus>1</DnsStatus>
<PrimaryDns>192.168.8.1</PrimaryDns>
<SecondaryDns>192.168.8.1</SecondaryDns>
</response>
- Comments:
- DhcpStatus:
- 0 - DHCP server off
- 1 - DHCP server enabled
- DhcpLeaseTime: release time must be between 86400 and 604800 . The default is 86400 .
- DhcpStatus:
DHCP setting
- url: http://192.168.8.1/api/dhcp/settings
- method: POST
- request:
<request>
<DhcpIPAddress></DhcpIPAddress>
<DhcpLanNetmask></DhcpLanNetmask>
<DhcpStatus></DhcpStatus>
<DhcpStartIPAddress></DhcpStartIPAddress>
<DhcpEndIPAddress></DhcpEndIPAddress>
<DhcpLeaseTime></DhcpLeaseTime>
<PrimaryDns></PrimaryDns>
<SecondaryDns></SecondaryDns>
</request>
- reply:
<response>OK</response>
- Comments:
- DhcpStatus:
- 0 - DHCP server off
- 1 - DHCP server enabled
- DhcpLeaseTime: release time must be between 86400 and 604800 . The default is 86400 .
- DhcpStatus: