Node HTTP Interface¶
Each node has an HTTP interface that allows:
- view current status,
- change parameters "on the fly" (without restarting the node)
- get the transport file of the current stream
HTTP interface works on the main port of the node (specified by parameter
By default the interface is available only from the localhost.
To allow remote access, you have to run the node with the option
Also you can set a security token for HTTP interface to prevent unauthorized access, using option
Access to HTTP interface is performed via GET request:
# get node status http://localhost:<port>/app/<token>/monitor # update node parameters http://localhost:<port>/app/<token>/update # get transport file http://localhost:<port>/app/<token>/get_transport_file?format=raw
If node was launched without option
<token> part of the URL is omitted:
Responses are in JSON format.
- version - node's version
- max_connections - maximum number of TCP-connections
- max_peers - maximum number of concurrently connected nodes
- download_speed - current speed of data download (byte/s)
- upload_speed - current speed of data upload (byte/s)
- connected_peers_count - number of connected nodes
- connected_peers - list of connected nodes (empty, if option --stats-report-peers is not set)
param2 are names of parameters that have to be updated,
value2 are new values for these parameters.
The list of available parameters:
- TODO: add the rest of params
# set max number of peers to 100 http://192.168.1.3:8640/app/update?max_peers=100
The response body contains raw transport file data.
This method is primarily used by support nodes to get transport file from the source node.