Global

Methods

(async) activeLoginPhrases(req, res)

To return a JSON response with a list of active login phrases. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) addMultiSigAddress(req, res) → {object}

To add a multi-signature address (requires multiple keys to authorize a transaction). Number of addresses/keys and keys object required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) addMultiSigAddressPost(req, res) → {object}

To add a multi-signature address (requires multiple keys to authorize a transaction) after data is processed. Number of addresses/keys and keys object required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) addNode(req, res) → {object}

To add a node. Node and command required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) addOutgoingPeer(req, res) → {object}

Function to be called by FluxNodes without the minimum Incoming connections.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) addPeer(req, res) → {object}

To add a peer by specifying the IP address. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) adjustConfigDefaultsFolder(method, newConfig) → {object}

To modify config for defult values for folders, PUT replaces the default config (omitted values are reset to the hard-coded defaults), PATCH replaces only the given child objects.
Parameters:
Name Type Description
method string Request method.
newConfig object new config.
Source:
Returns:
Message
Type
object

(async) adjustConfigDevices(method, newConfig, id) → {object}

To modify config for devices. PUT replaces the entire config, PATCH replaces only the given child objects and DELETE removes the device
Parameters:
Name Type Description
method string Request method.
newConfig string new config.
id string device ID.
Source:
Returns:
Message
Type
object

(async) adjustConfigFolders(method, newConfig, id) → {object}

To modify config for folders. PUT replaces the entire config, PATCH replaces only the given child objects and DELETE removes the folder
Parameters:
Name Type Description
method string Request method.
newConfig string new config to be replaced.
id string folder ID.
Source:
Returns:
Message
Type
object

(async) adjustConfigOptions(method, newConfig) → {object}

To modify options object, PUT replaces the entire object and PATCH replaces only the given child objects.
Parameters:
Name Type Description
method string Request.
newConfig object Response.
Source:
Returns:
Message
Type
object

(async) adjustCruxID(req, res)

To adjust the current CruxID that is being used with FluxOS. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) adjustExternalIP(ip) → {void}

To adjust an external IP.
Parameters:
Name Type Description
ip string IP address.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) adjustFirewall()

To adjust a firewall to allow ports for Flux.
Source:

(async) adjustKadenaAccount(req, res)

To update the current Kadena account (address/public key and chain ID) that is being used with FluxOS. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) allowPort(port) → {object}

To allow a port.
Parameters:
Name Type Description
port string Port.
Source:
Returns:
Command status.
Type
object

(async) allowPortApi(req, res) → {object}

To allow a port via API. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) appChanges(req, res)

To show filesystem changes for an app's Docker container. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) appDockerCreate(appSpecifications, appName, isComponent) → {object}

Creates an app container.
Parameters:
Name Type Description
appSpecifications object
appName string
isComponent bool
Source:
Returns:
Type
object

(async) appDockerImageRemove(idOrName) → {string}

Removes app's docker image.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
message
Type
string

(async) appDockerKill(idOrName) → {string}

Kills app's docker.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
message
Type
string

(async) appDockerPause(idOrName) → {string}

Pauses app's docker.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
message
Type
string

(async) appDockerRemove(idOrName) → {string}

Removes app's docker.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
message
Type
string

(async) appDockerRestart(idOrName) → {string}

Restarts app's docker.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
message
Type
string

(async) appDockerStart(idOrName) → {string}

Starts app's docker.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
message
Type
string

(async) appDockerStop(idOrName) → {string}

Stops app's docker.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
message
Type
string

(async) appDockerTop(idOrName) → {string}

Returns app's docker's active processes.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
message
Type
string

(async) appDockerUnpause(idOrName) → {string}

Unpauses app's docker.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
message
Type
string

(async) appExec(req, res)

To run a command inside an app's running Docker container. Only accessible by app owner.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) appHashHasMessage(hash) → {boolean}

To update the database that an app hash has a message.
Parameters:
Name Type Description
hash object Hash object containing app information.
Source:
Returns:
True.
Type
boolean

(async) appHashHasMessageNotFound(hash) → {boolean}

To update the database that an app hash has a message not found on network.
Parameters:
Name Type Description
hash object Hash object containing app information.
Source:
Returns:
True.
Type
boolean

(async) appInspect(req, res)

To inspect an app's Docker container and show low-level information about it. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) appKill(req, res) → {object}

To kill an app. Kills each component if the app is using Docker Compose. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) appLocation(appname)

To get app locations or a location of an app
Parameters:
Name Type Description
appname string Application Name.
Source:

(async) appLog(req, res)

To show an app's Docker container logs. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) appLogStream(req, res)

To show an app's Docker container log stream. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) appMonitor(req, res)

To show resource usage statistics for an app's Docker container. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) appMonitorStream(req, res)

To show resource usage statistics for an app's Docker container. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) appPause(req, res) → {object}

To pause an app. Pauses each component if the app is using Docker Compose. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

appPortsUnique(portsArray) → {object}

To convert an array of ports to a set object containing a list of unique ports.
Parameters:
Name Type Description
portsArray Array.<number> Array of ports.
Source:
Returns:
Set object.
Type
object

appPricePerMonth(dataForAppRegistration, height) → {number}

To return the monthly app hosting price.
Parameters:
Name Type Description
dataForAppRegistration string App registration date.
height number Block height.
Source:
Returns:
App price.
Type
number

(async) appRestart(req, res) → {object}

To restart an app. Restarts each component if the app is using Docker Compose. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) appsResources(req, res) → {object}

To show app resources locked (CPUs, RAM and HDD).
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) appStart(req, res) → {object}

To start an app. Starts each component if the app is using Docker Compose. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) appStats(req, res)

To show resource usage statistics for an app's Docker container. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) appStop(req, res) → {object}

To stop an app. Stops each component if the app is using Docker Compose. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) appTop(req, res) → {object}

To show an app's active Docker container processes. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Requst.
res object Response.
Source:
Returns:
Message.
Type
object

(async) appUninstallHard(appName, appId, appSpecifications, isComponent, res)

To hard uninstall an app including any components. Removes container/s, removes image/s, denies all app/component ports, unmounts volumes and removes cron job.
Parameters:
Name Type Description
appName string App name.
appId string App ID.
appSpecifications object App specifications.
isComponent boolean True if a Docker Compose component.
res object Response.
Source:

(async) appUninstallSoft(appName, appId, appSpecifications, isComponent, res)

To soft uninstall an app including any components. Removes container/s, removes image/s and denies all app/component ports.
Parameters:
Name Type Description
appName string App name.
appId string App ID.
appSpecifications object App specifications.
isComponent boolean True if a Docker Compose component.
res object Response.
Source:

(async) appUnpause(req, res) → {object}

To unpause an app. Unpauses each component if the app is using Docker Compose. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Restart.
Source:
Returns:
Message.
Type
object

(async) assignedPortsGlobalApps(appNames) → {Array.<object>}

To create a list of ports assigned to each global app.
Parameters:
Name Type Description
appNames Array.<string> App names.
Source:
Returns:
Array of app specs objects.
Type
Array.<object>

(async) assignedPortsInstalledApps() → {Array.<object>}

To create a list of ports assigned to each local app.
Source:
Returns:
Array of app specs objects.
Type
Array.<object>

(async) availableApps(req, res) → {object|Array.<object>}

To return available apps.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Returns a response or an array of app objects.
Type
object | Array.<object>

axiosGet(url, options) → {object}

To handle timeouts on axios connection.
Parameters:
Name Type Description
url string URL.
options object Options object.
Source:
Returns:
Response.
Type
object

(async) backupWallet(req, res) → {object}

To backup wallet. Backup destination/directory required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) benchmarkDebug(req, res) → {object}

To download Flux benchmark debug logs. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Debug.log file for Flux benchmark.
Type
object

(async) broadcastMessageFromUser(req, res)

To broadcast message from user. Handles messages to outgoing and incoming peers. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) broadcastMessageFromUserPost(req, res)

To broadcast message from user after data is processed. Handles messages to outgoing and incoming peers. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) broadcastMessageToIncoming(dataToBroadcast)

To broadcast message to incoming peers. Data is serialised and sent to incoming peers.
Parameters:
Name Type Description
dataToBroadcast object Data to broadcast.
Source:

(async) broadcastMessageToIncomingFromUser(req, res)

To broadcast message from user to incoming peers. Data is serialised and sent to incoming peers. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) broadcastMessageToIncomingFromUserPost(req, res)

To broadcast message from user to incoming peers after data is processed. Processed data is serialised and sent to incoming peers. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) broadcastMessageToOutgoing(dataToBroadcast)

To broadcast message to outgoing peers. Data is serialised and sent to outgoing peers.
Parameters:
Name Type Description
dataToBroadcast object Data to broadcast.
Source:

(async) broadcastMessageToOutgoingFromUser(req, res)

To broadcast message from user to outgoing peers. Data is serialised and sent to outgoing peers. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) broadcastMessageToOutgoingFromUserPost(req, res)

To broadcast message from user to outgoing peers after data is processed. Processed data is serialised and sent to outgoing peers. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) broadcastTemporaryAppMessage(message)

To broadcast temporary app message.
Parameters:
Name Type Description
message object Message.
Source:

(async) checkAndNotifyPeersOfRunningApps()

To check and notify peers of running apps. Checks if apps are installed, stopped or running.
Source:

(async) checkAndRemoveApplicationInstance() → {void}

To find and remove apps that are spawned more than maximum number of instances allowed locally.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) checkAndRequestApp(hash, txid, height, valueSat, i) → {void}

To check and request an app. Handles fluxappregister type and fluxappupdate type.
Parameters:
Name Type Default Description
hash object Hash object containing app information.
txid string Transaction ID.
height number Block height.
valueSat number Satoshi denomination (100 millionth of 1 Flux).
i number 0 Defaults to value of 0.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

checkAppGeolocationRequirements(appSpecs) → {boolean}

To check app requirements of geolocation restrictions for a node
Parameters:
Name Type Description
appSpecs object App specifications.
Source:
Returns:
True if all checks passed.
Type
boolean

(async) checkAppHWRequirements(appSpecs) → {boolean}

To check app requirements of HW for a node
Parameters:
Name Type Description
appSpecs object App specifications.
Source:
Returns:
True if all checks passed.
Type
boolean

(async) checkApplicationImagesComplience(appSpecs) → {boolean}

To check compliance of app images (including images for each component if a Docker Compose app). Checks Flux OS's GitHub repository for list of blocked Docker Hub repositories.
Parameters:
Name Type Description
appSpecs object App specifications.
Source:
Returns:
True if no errors are thrown.
Type
boolean

(async) checkApplicationRegistrationNameConflicts(appSpecFormatted) → {boolean}

To check if app name already registered. App names must be unique.
Parameters:
Name Type Description
appSpecFormatted object App specifications.
Source:
Returns:
True if no errors are thrown.
Type
boolean

(async) checkApplicationUpdateNameRepositoryConflicts(specifications, verificationTimestamp) → {boolean}

To check for any conflicts with the latest permenent app registration message and any app update messages.
Parameters:
Name Type Description
specifications object App specifications.
verificationTimestamp number Verifiaction time stamp.
Source:
Returns:
True if no errors are thrown.
Type
boolean

(async) checkAppMessageExistence(hash) → {object|boolean}

To check if an app message hash exists.
Parameters:
Name Type Description
hash string Message hash.
Source:
Returns:
Returns document object if it exists in the database. Otherwise returns false.
Type
object | boolean

(async) checkAppRequirements(appSpecs) → {boolean}

To check app requirements to include HDD space, CPU power, RAM and GEO for a node
Parameters:
Name Type Description
appSpecs object App specifications.
Source:
Returns:
True if all checks passed.
Type
boolean

(async) checkAppTemporaryMessageExistence(hash) → {object|boolean}

To check if an app temporary message hash exists.
Parameters:
Name Type Description
hash string Message hash.
Source:
Returns:
Returns document object if it exists in the database. Otherwise returns false.
Type
object | boolean

(async) checkBlockProcessingStopped(i, callback)

To check if block processing has stopped.
Parameters:
Name Type Description
i number Value.
callback callback Callback function.
Source:

checkComposeHWParameters(appSpecsComposed) → {boolean}

To check if a node's hardware is suitable for running the assigned Docker Compose app. Advises if too much resources being assigned to an app.
Parameters:
Name Type Description
appSpecsComposed object App specifications composed.
Source:
Returns:
True if no errors are thrown.
Type
boolean

(async) checkDeterministicNodesCollisions() → {void}

To check deterministic node collisions (i.e. if multiple FluxNode instances detected).
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) checkDockerAccessibility(req, res) → {object}

To check Docker accessibility. Only accessible by users.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) checkFluxAvailability(req, res) → {object}

To check Flux availability for specific IP address/port.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) checkFluxbenchVersionAllowed() → {boolean}

To check if Flux benchmark version is allowed.
Source:
Returns:
True if version is verified as allowed. Otherwise false.
Type
boolean

checkHWParameters(appSpecs) → {boolean}

To check if a node's hardware is suitable for running the assigned app.
Parameters:
Name Type Description
appSpecs object App specifications.
Source:
Returns:
True if no errors are thrown.
Type
boolean

(async) checkLoggedUser(req, res)

To check the privilege level a user (ZelID). The privilege level is either admin, flux team or user.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) checkMyFluxAvailability(retryNumber) → {boolean}

To check user's FluxNode availability.
Parameters:
Name Type Default Description
retryNumber number 0 Number of retries.
Source:
Returns:
True if all checks passed.
Type
boolean

checkRateLimit(ip, fillPerSecond, maxBurst) → {boolean}

To check rate limit.
Parameters:
Name Type Default Description
ip string IP address.
fillPerSecond number 10 Defaults to value of 10.
maxBurst number 15 Defaults to value of 15.
Source:
Returns:
True if a token is taken from the IP's token bucket. Otherwise false.
Type
boolean

(async) checkSynced() → {boolean}

Checks if a node's FluxOS database is synced with the node's daemon database.
Source:
Returns:
True if FluxOS databse height is within 1 of the daemon database height. False if not within 1 of the height or if there is an error.
Type
boolean

(async) checkWhitelistedRepository(repotag) → {boolean}

To check if an app's Git repository is whitelisted and able to be run on FluxOS.
Parameters:
Name Type Description
repotag string GitHub repository tag.
Source:
Returns:
True or an error is thrown.
Type
boolean

(async) clearBanned(req, res) → {object}

To clear banned IP addresses. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) closeConnection(ip) → {object}

To close an outgoing connection.
Parameters:
Name Type Description
ip string IP address.
Source:
Returns:
Message.
Type
object

(async) closeIncomingConnection(ip, expressWS, clientToClose) → {object}

To close an incoming connection.
Parameters:
Name Type Description
ip string IP address.
expressWS object Express web socket.
clientToClose object Web socket for client to close.
Source:
Returns:
Message.
Type
object

(async) confirmNodeTierHardware() → {boolean}

To check if the hardware specification requirements of the node tier are being met by the node (RAM and CPU threads).
Source:
Returns:
True or an error is thrown.
Type
boolean

connectedPeers(req, res)

To get IP addresses for all outgoing connected peers.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

connectedPeersInfo(req, res)

To get info (IP address, latency and lastPingTime) for all outgoing connected peers.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) continuousFluxAppHashesCheck()

To perform continuous checks for Flux app hashes that don't have a message.
Source:

(async) createAppVolume(appSpecifications, appName, isComponent, res) → {object}

To create an app volume. First checks for availability of disk space and chooses an available volume that meets the app specifications. Then creates the necessary file systems and mounts the volume. Finally, sets up cron job.
Parameters:
Name Type Description
appSpecifications object App specifications.
appName string App name.
isComponent boolean True if a Docker Compose component.
res object Response.
Source:
Returns:
Message.
Type
object

(async) createConfirmationTransaction(req, res) → {object}

To create confirmation transaction.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

createDataMessage(data) → {object}

Creates a message object.
Parameters:
Name Type Description
data object
Source:
Returns:
message
Type
object

createErrorMessage(message, nameopt, codeopt) → {object}

Creates a message indicating an error.
Parameters:
Name Type Attributes Description
message string
name string <optional>
code string <optional>
Source:
Returns:
error message
Type
object

(async) createFluxDockerNetwork() → {object}

Creates flux docker network if doesn't exist
Source:
Returns:
response
Type
object

(async) createFluxNetworkAPI(req, res) → {object}

To create Flux Docker network API. Only accessible by admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) createMultiSig(req, res) → {object}

To create a multi-signature scheme (to require multiple keys to authorize a transaction). Number of signatures and keys object required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) createMultiSigPost(req, res) → {object}

To create a multi-signature scheme (to require multiple keys to authorize a transaction) after data is processed. Number of signatures and keys object required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) createRawTransaction(req, res) → {object}

To create raw transaction. Transactions, addresses, lock time (defaults to value of 0) and expiry height (defaults to block count + 20) required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) createRawTransactionPost(req, res) → {object}

To create raw transaction after data is processed. Transactions, addresses, lock time (defaults to value of 0) and expiry height (defaults to block count + 20) required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

createSuccessMessage(message, nameopt, codeopt) → {object}

Creates a message object indicating success.
Parameters:
Name Type Attributes Description
message string
name string <optional>
code string <optional>
Source:
Returns:
success message
Type
object

createWarningMessage(message, nameopt, codeopt) → {object}

Creates a message indicating a warning.
Parameters:
Name Type Attributes Description
message string
name string <optional>
code string <optional>
Source:
Returns:
warning message
Type
object

(async) createZelNodeBroadcast(req, res) → {object}

To create node broadcast. Command and alias required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) createZelNodeKey(req, res) → {object}

To create node key. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

daemonBlockchainInfoService()

To call the flux daemon blockchain info function at set intervals.
Source:

(async) daemonDebug(req, res) → {object}

To download Flux daemon debug logs. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Debug.log file for Flux daemon.
Type
object

(async) debugCpuprof(req, res) → {object}

To capture a profile of what Syncthing is doing on the CPU
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) debugFile(req, res) → {object}

To Show diagnostics about a certain file in a shared folder. Takes the {folder} and {file} parameters.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) debugHeapprof(req, res) → {object}

To capture a profile of what Syncthing is doing with the heap memory.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) debugHttpmetrics(req, res) → {object}

Returns statistics about each served REST API endpoint, to diagnose how much time was spent generating the responses.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) debugPeerCompletion(req, res) → {object}

Summarizes the completion precentage for each remote device.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) debugSupport(req, res) → {object}

To Collect information about the running instance for troubleshooting purposes.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

decodeMessage(asm) → {string}

To decode a message from Unicode values to text characters.
Parameters:
Name Type Description
asm string UTF-16 value.
Source:
Returns:
Message.
Type
string

(async) decodeRawTransaction(req, res) → {object}

To decode raw transaction. Hex string required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) decodeRawTransactionPost(req, res) → {object}

To decode raw transaction after data is processed. Hex string required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) decodeScript(req, res) → {object}

To decode script. Hex required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) decodeScriptPost(req, res) → {object}

To decode script after data is processed. Hex required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) decodeZelNodeBroadcast(req, res) → {object}

To decode node broadcast. Optional hex string can be included as a parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

delay(ms) → {Promise}

To delay by a number of milliseconds.
Parameters:
Name Type Description
ms number Number of milliseconds.
Source:
Returns:
Promise object.
Type
Promise

(async) deleteLoginPhrase(phrase)

To delete login phrase.
Parameters:
Name Type Description
phrase string Login phrase.
Source:

(async) denyPort(port) → {object}

To deny a port.
Parameters:
Name Type Description
port string Port.
Source:
Returns:
Command status.
Type
object

(async) deploymentInformation(req, res)

To get price and specification information required for deployment.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) deterministicFluxList(filter) → {*|*}

To get deterministc Flux list from cache.
Parameters:
Name Type Description
filter string Filter. Can only be a publicKey.
Source:
Returns:
Value of any type or an empty array of any type.
Type
* | *

(async) disconnectNode(req, res) → {object}

To disconnect a node. Node required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) dockerContainerChanges(idOrName) → {string}

Returns changes on a container’s filesystem.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
Type
string

(async) dockerContainerExec(container, cmd, env, res, callback)

Runs a command inside a running container.
Parameters:
Name Type Description
container object Docker container object
cmd string Command to execute
env array Environment variables
res object response object
callback function
Source:

(async) dockerContainerInspect(idOrName) → {object}

Returns low-level information about a container.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
Type
object

(async) dockerContainerLogs(idOrName, lines) → {string}

Returns requested number of lines of logs from the container.
Parameters:
Name Type Description
idOrName string
lines number
Source:
Returns:
Type
string

(async) dockerContainerLogsStream(idOrName, res, callback)

Subscribes to logs stream.
Parameters:
Name Type Description
idOrName string
res object
callback function
Source:

(async) dockerContainerStats(idOrName)

Returns a sample of container’s resource usage statistics.
Parameters:
Name Type Description
idOrName string
Source:
Returns:
docker container statistics

(async) dockerContainerStatsStream(repoTag, res, callback)

Take stats from docker container and follow progress of the stream.
Parameters:
Name Type Description
repoTag string Docker Hub repo/image tag.
res object Response.
callback function Callback.
Source:

(async) dockerCreateNetwork(options:) → {object}

Creates a docker network object.
Parameters:
Name Type Description
options: object Name: string; CheckDuplicate?: boolean | undefined; Driver?: string | undefined; Internal?: boolean | undefined; Attachable?: boolean | undefined; Ingress?: boolean | undefined; IPAM?: IPAM | undefined; EnableIPv6?: boolean | undefined; Options?: { [option: string]: string } | undefined; Labels?: { [label: string]: string } | undefined; abortSignal?: AbortSignal;
Source:
Returns:
Network
Type
object

(async) dockerListContainers(allopt, limitopt, sizeopt, filteropt) → {array}

Returns a list of containers.
Parameters:
Name Type Attributes Description
all bool <optional>
defaults to false; By default only running containers are shown
limit number <optional>
Return this number of most recently created containers, including non-running ones.
size bool <optional>
Return the size of container as fields SizeRw and SizeRootFs.
filter string <optional>
Filters to process on the container list, encoded as JSON
Source:
Returns:
containers list
Type
array

(async) dockerListImages() → {array}

Returns a list of images on the server.
Source:
Returns:
images list
Type
array

(async) dockerNetworkInspect(netw) → {object}

Returns inspect network object.
Parameters:
Name Type Description
netw object Network object
Source:
Returns:
ispect network object
Type
object

dockerPullStream(repoTag, res, callback)

To pull a Docker Hub image and follow progress of the stream.
Parameters:
Name Type Description
repoTag string Docker Hub repo/image tag.
res object Response.
callback function Callback.
Source:

(async) dockerRemoveNetwork(netw) → {Buffer}

Removes docker network.
Parameters:
Name Type Description
netw object Network object
Source:
Returns:
Type
Buffer

(async) dumpPrivKey(req, res) → {object}

To dump private key. Address required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) emergencyPhrase(req, res)

To return a JSON response with the user's emergency login phrase.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) ensureApplicationImagesExistsForPlatform(appSpecFormatted) → {boolean}

To ensure that all app images are of a consistent architecture type. Architecture must be either ARM64 or AMD64.
Parameters:
Name Type Description
appSpecFormatted object App specifications.
Source:
Returns:
True if all apps have the same system architecture.
Type
boolean

(async) ensureApplicationPortsNotUsed(appSpecFormatted, globalCheckedApps) → {boolean}

To ensure application ports are not already in use by another appliaction.
Parameters:
Name Type Description
appSpecFormatted object App specifications.
globalCheckedApps Array.<string> Names of global checked apps.
Source:
Returns:
True if no errors are thrown.
Type
boolean

ensureAppUniquePorts(appSpecFormatted)

To ensure that the app ports are unique.
Parameters:
Name Type Description
appSpecFormatted object App specifications.
Source:
Returns:
True if Docker version 1. If Docker version 2 to 3, returns true if no errors are thrown.

ensureBoolean(parameter) → {boolean}

To convert a parameter to a boolean.
Parameters:
Name Type Description
parameter string | number | boolean True, false, 1 or 0 in either string, number or boolean form.
Source:
Returns:
True or false.
Type
boolean

ensureNumber(parameter) → {number}

To convert a parameter to a number.
Parameters:
Name Type Description
parameter * Parameter of any type.
Source:
Returns:
Parameter converted to number type.
Type
number

ensureObject(parameter) → {object}

To check if a parameter is an object and if not, return an empty object.
Parameters:
Name Type Description
parameter * Parameter of any type.
Source:
Returns:
Returns the original parameter if it is an object or returns an empty object.
Type
object

ensureString(parameter) → {string}

To convert a parameter to a string.
Parameters:
Name Type Description
parameter * Parameter of any type.
Source:
Returns:
Parameter converted to string type.
Type
string

errUnauthorizedMessage() → {object}

Returns unauthorized error message.
Source:
Returns:
unauthorized error message
Type
object

(async) estimateFee(req, res) → {object}

To estimate a transaction fee. Number of blocks required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) estimatePriority(req, res) → {object}

To estimate transaction priority. Number of blocks required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) executeAppGlobalCommand(appname, command, zelidauth, paramA)

To execute a command to all app instances.
Parameters:
Name Type Description
appname string Application name or App component name in Flux notation '_'.
command string What command to execute, api route to be done.
zelidauth object What zelidauth headers to send with request for authentication purposes.
paramA object | boolean | string first parameter that a command may need
Source:

(async) executeCall(rpc, params) → {object}

To execute a remote procedure call (RPC).
Parameters:
Name Type Description
rpc string Remote procedure call.
params Array.<string> RPC parameters.
Source:
Returns:
Message.
Type
object

(async) executeCall(rpc, params) → {object}

To execute a remote procedure call (RPC).
Parameters:
Name Type Description
rpc string Remote procedure call.
params Array.<string> RPC parameters.
Source:
Returns:
Message.
Type
object

(async) expireGlobalApplications()

To find and remove expired global applications. Finds applications that are lower than blocksLasting and deletes them from global database.
Source:

(async) fluxBackendFolder(req, res) → {object}

To show the directory on the node machine where FluxOS files are stored.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) fluxDaemonBlockchainInfo()

To show flux daemon blockchain sync status in logs.
Source:

(async) fluxDebugLog(req, res) → {void}

To download FluxOS debug log. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) fluxDiscovery()

To discover and connect to other randomly selected FluxNodes. Maintains connections with 1-2% of nodes on the Flux network. Ensures that FluxNode connections are not duplicated.
Source:

(async) fluxErrorLog(req, res) → {void}

To download FluxOS error log. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) fluxInfoLog(req, res) → {void}

To download FluxOS info log. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) fluxLog(res, filelog) → {object}

To download a specified FluxOS log file.
Parameters:
Name Type Description
res object Response.
filelog string Log file name (excluding `.log`).
Source:
Returns:
FluxOS .log file.
Type
object

(async) fluxShareCreateFolder(req, res)

To create a folder. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) fluxShareDatabaseFileDelete(file) → {boolean}

Delete a specific FluxShare file.
Parameters:
Name Type Description
file string Name of file to be deleted.
Source:
Returns:
Returns true unless an error is caught.
Type
boolean

(async) fluxShareDatabaseFileDeleteMultiple(pathstart) → {boolean}

Delete all FluxShare files that start with a specified path.
Parameters:
Name Type Description
pathstart string Path of files to be deleted.
Source:
Returns:
Returns true unless an error is caught.
Type
boolean

(async) fluxShareDatabaseShareFile(file) → {object}

To get a file from database or insert it into database if it doesn't already exist.
Parameters:
Name Type Description
file string File name.
Source:
Returns:
File detail (name and token).
Type
object

(async) fluxShareDownloadFile(req, res) → {void}

To download a specified file. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) fluxShareDownloadFolder(req, res, authorized) → {void}

To download a zip folder for a specified directory. Only accessible by admins.
Parameters:
Name Type Default Description
req object Request.
res object Response.
authorized boolean false False until verified as an admin.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) fluxShareFileExists(req, res)

To check if a file exists. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) fluxShareGetFolder(req, res)

To get a list of files with their details for all files within a shared folder. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) fluxShareGetSharedFiles(req, res)

To get shared files. Only accessible by admins.
Parameters:
Name Type Description
req object Requet.
res object Response.
Source:

(async) fluxShareRemoveFile(req, res)

To remove a specified shared file. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) fluxShareRemoveFolder(req, res)

To remove a specified shared folder. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) fluxShareRename(req, res)

To rename a file or folder. Oldpath is relative path to default fluxshare directory; newname is just a new name of folder/file. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) fluxShareSharedFiles() → {Array.<object>}

To search for shared files.
Source:
Returns:
Array of shared files.
Type
Array.<object>

(async) fluxShareShareFile(req, res)

To share a file. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) fluxShareStorageStats(req, res)

To show FluxShare storage stats (GB available, GB used and GB total). Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) fluxShareUnshareFile(req, res)

To unshare a file. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) fluxShareUpload(req, res)

To upload a specified folder to FluxShare. Checks that there is enough space available. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

fluxUptime(req, res)

To get node uptime in seconds
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) fluxUsage(req, res) → {object}

To show average Flux CPU usage.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) fluxWarnLog(req, res) → {void}

To download FluxOS warn log. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) fundRawTransaction(req, res) → {object}

To fund raw transaction. Hex string required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) fundRawTransactionPost(req, res) → {object}

To fund raw transaction after data is processed. Hex string required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getAddedNodeInfo(req, res) → {object}

To get node info. DNS and node required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getAddressBalance(req, res) → {object}

To get balance of address/es. Addresses required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getAddressBalance(req, res)

To get the Flux balance for a specific address.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getAddressDeltas(req, res) → {object}

To get address deltas. Addresses, start, end and chain info required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getAddressFusionCoinbase(req, res)

To get UTXOs for a specific Fusion/Coinbase address.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getAddressMempool(req, res) → {object}

To get mempool (memory pool) for multiple addresses. Addresses required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getAddressTransactions(req, res)

To get transactions for a specific address.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getAddressTxids(req, res) → {object}

To get transaction IDs for specified address/es. Addresses, start and end required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getAddressUtxos(req, res) → {object}

To get UTXOs for multiple addresses. Addresses and chain info required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getAddressUtxos(req, res)

To get all UTXOs for a specific address.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getAllAddresses(req, res)

To get all addresses.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getAllAddressesWithTransactions(req, res)

To get all addresses with transactions.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

getAllFiles(dirPath, arrayOfFiles) → {Array.<string>}

To add all files within a directory into an array of file paths/names.
Parameters:
Name Type Description
dirPath string Directory path.
arrayOfFiles Array.<string> Existing array of file paths/names or empty array.
Source:
Returns:
Updated array of file paths/names.
Type
Array.<string>

(async) getAllFluxTransactions(req, res)

To get all Flux transactions.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getAllFusionCoinbase(req, res)

To get all Fusion/Coinbase transactions.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getAllGlobalApplicationsNames() → {Array.<string>}

To get all global app names.
Source:
Returns:
Array of app names or an empty array if an error is caught.
Type
Array.<string>

(async) getAllGlobalApplicationsNamesWithLocation() → {Array.<string>}

To get all applications list with geolocation
Source:
Returns:
Array of app names or an empty array if an error is caught.
Type
Array.<string>

(async) getAllUtxos(req, res)

To get all UTXOs (unspent transaction outputs).
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

getAppDockerNameIdentifier(appName) → {string}

Generates an app docker name based on app name
Parameters:
Name Type Description
appName string
Source:
Returns:
app docker name id
Type
string

(async) getAppFolderSize(appName)

Returns folder size in byes of application component
Parameters:
Name Type Description
appName object monitored component name
Source:

(async) getAppHashes(req, res)

To get app hashes.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

getAppIdentifier(appName) → {string}

Generates an app identifier based on app name.
Parameters:
Name Type Description
appName string
Source:
Returns:
app identifier
Type
string

(async) getApplicationGlobalSpecifications(appName) → {object}

To get app specifications for a specific global app.
Parameters:
Name Type Description
appName string App name.
Source:
Returns:
Document with app info.
Type
object

(async) getApplicationLocalSpecifications(appName) → {object}

To get app specifications for a specific local app.
Parameters:
Name Type Description
appName string App name.
Source:
Returns:
Document with app info.
Type
object

(async) getApplicationOwner(appName) → {number}

To return the owner of a FluxOS application.
Parameters:
Name Type Description
appName string Name of app.
Source:
Returns:
Owner.
Type
number

(async) getApplicationOwnerAPI(req, res)

To get app owner for a specific app (global or local) via API.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getApplicationSpecificationAPI(req, res)

To get app specifications for a specific app (global or local) via API.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getApplicationSpecifications(appName) → {object}

To get app specifications for a specific app if global/local status is unkown. First searches global apps and if not found then searches local apps.
Parameters:
Name Type Description
appName string App name.
Source:
Returns:
Document with app info.
Type
object

(async) getAppPrice(req, res) → {object}

To get app price.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getAppsLocation(req, res)

To get a specific app's location.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getAppsLocations(req, res)

To get app locations.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getAppsPermanentMessages(req, res)

To get permanent hash messages for global apps.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getAppsTemporaryMessages(req, res)

To get temporary hash messages for global apps.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getBalance(req, res) → {object}

To get balance. Min conf (defaults to value of 1) and whether to include watch only (defaults to false) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBenchmarks(req, res) → {object}

To show status of benchmarks.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBenchmarks(req, res) → {object}

To get benchmarks.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBenchStatus(req, res) → {object}

To get benchmark status.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBestBlockHash(req, res) → {object}

To get best block hash.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBlock(req, res) → {object}

To get block. Hash height and verbosity required as parameters for RPC call. Verbosity defaults to an integer value of 2.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

getBlockCache(key) → {object}

Gets blockCache data. Created for testing purposes.
Parameters:
Name Type Description
key object
Source:
Returns:
cached data
Type
object

(async) getBlockchainInfo(req, res) → {object}

To get blockchain info.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBlockCount(req, res) → {object}

To get block count.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBlockDeltas(req, res) → {object}

To get block deltas. Hash required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBlockHash(req, res) → {object}

To get block hash. Index required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBlockHashes(req, res) → {object}

To get block hashes. High and low values and options object required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBlockHashesPost(req, res)

To get block hashes after data is processed. High and low values required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getBlockHeader(req, res) → {object}

To get block header. Hash and verbose (defaults to true) required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBlockSubsidy(req, res) → {object}

To get block subsidy. Height required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getBlockTemplate(req, res) → {object}

To get block template. JSON request object required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Block template.
Type
object

(async) getChainTips(req, res) → {object}

To get chain tips.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getClusterPendigDevices(req, res) → {object}

Lists remote devices which have tried to connect, but are not yet configured in the instance.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getClusterPendigFolders(req, res) → {object}

Lists folders which remote devices have offered to us, but are not yet shared from our instance to them. Takes the optional {device} parameter to only return folders offered by a specific remote device.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

getCollateralInfo(collateralOutpoint) → {object}

To return a transaction hash and index.
Parameters:
Name Type Description
collateralOutpoint Array.<string> List of collateral outpoints.
Properties:
Name Type Description
txhash string Transaction hash.
txindex number Transaction index.
Source:
Returns:
Collateral info object.
Type
object

(async) getConfig(req, res) → {object}

Returns the entire config.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getConfigDefaultsDevice(req, res) → {object}

Returns a template device configuration object with all default values, which only needs a unique ID to be applied
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getConfigDefaultsFolder(req, res) → {object}

Returns a template folder configuration object with all default values, which only needs a unique ID to be applied
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getConfigDefaultsIgnores(req, res) → {object}

returns an object listing ignore patterns to be used by default on folders, as an array of single-line strings
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getConfigDevices(req, res) → {object}

Returns the device for the given ID.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getConfigFile() → {string}

To get syncthing config xml file
Source:
Returns:
config gile (XML).
Type
string

(async) getConfigFolders(req, res) → {object}

Returns the folder for the given ID.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getConfigGui(req, res) → {object}

Returns the gui object
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getConfigLdap(req, res) → {object}

Returns the ldap object
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getConfigOptions(req, res) → {object}

Returns the options object
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getConfigRestartRequired(req, res) → {object}

Returns whether a restart of Syncthing is required for the current config to take effect.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

getConfigValue(parameter) → {string}

To get a value for a specified key from the configuration file.
Parameters:
Name Type Description
parameter string Config key.
Source:
Returns:
Config value.
Type
string

(async) getConnectionCount(req, res) → {object}

To get connection count.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getDbBrowse(req, res) → {object}

Returns the directory tree of the global model. takes one mandatory {folder} parameter and two optional parameters {levels} and {prefix}.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getDbCompletion(req, res) → {object}

Returns the completion percentage (0 to 100) and byte / item counts. Takes optional {device} and {folder} parameters.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getDbFile(req, res) → {object}

Returns most data available about a given file, including version and availability. Takes {folder} and {file} parameters.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getDbIgnores(req, res) → {object}

Returns the content of the .stignore as the ignore field. Takes one parameter, {folder}
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getDbLocalchanged(req, res) → {object}

Returns the list of files which were changed locally in a receive-only folder. Takes one mandatory parameter, {folder}
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getDbNeed(req, res) → {object}

Returns lists of files which are needed by this device in order for it to become in sync. Takes one mandatory parameter, {folder}
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getDbRemoteNeed(req, res) → {object}

Returns the list of files which are needed by that remote device in order for it to become in sync with the shared folder. Takes the mandatory parameters {folder} and {device}
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getDbStatus(req, res) → {object}

Returns information about the current status of a folder. Takes the mandatory parameter {folder}
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getDeprecationInfo(req, res) → {object}

To get deprecation info.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getDeviceID(req, res) → {object}

Returns device id, also checks that syncthing is installed and running and we have the api key.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getDifficulty(req, res) → {object}

To get block hash algorithm difficulty.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

getDockerContainer(id) → {object}

Creates a docker container object with a given ID.
Parameters:
Name Type Description
id string
Source:
Returns:
docker container object
Type
object

(async) getDockerContainerByIdOrName(idOrName) → {object}

Returns a docker container found by name or ID
Parameters:
Name Type Description
idOrName string
Source:
Returns:
dockerContainer
Type
object

(async) getDOSList(req, res) → {object}

To get DOS list.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

getDosMessage() → {string}

Getter for dosMessage. Main goal for this is testing availability.
Source:
Returns:
dosMessage
Type
string

(async) getDOSState(req, res) → {object}

To get DOS state.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

getDosStateValue() → {number}

Getter for dosState. Main goal for this is testing availability.
Source:
Returns:
dosState
Type
number

(async) getEvents(req, res) → {object}

To receive Syncthing events. takes {events}, {since}, {limit} and {timeout} parameters to filter the result.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getEventsDisk(req, res) → {object}

To receive LocalChangeDetected and RemoteChangeDetected event types. takes {since}, {limit} and {timeout} parameters to filter the result.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getFilteredFluxTxs(req, res)

To get Flux transactions filtered by either IP address, collateral hash or Flux address.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

getFluxCruxID(req, res) → {object}

To show the current CruxID that is being used with FluxOS.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getFluxInfo(req, res) → {object}

To get info (version, status etc.) for daemon, node, benchmark, FluxOS and apps.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getFluxIP(req, res) → {object}

To show FluxOS IP address.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

getFluxKadena(req, res) → {object}

To show the current user's Kadena address (public key) that is being used with FluxOS.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getFluxMessageSignature(message, privatekey) → {string}

To get Flux message signature.
Parameters:
Name Type Description
message object Message.
privatekey string Private key.
Source:
Returns:
Signature.
Type
string

(async) getFluxNodePrivateKey(privatekey) → {string}

To get FluxNode private key.
Parameters:
Name Type Description
privatekey string Private Key.
Source:
Returns:
Private key, if already input as parameter or otherwise from the daemon config.
Type
string

(async) getFluxNodePublicKey(privatekey) → {string}

To get FluxNode public key.
Parameters:
Name Type Description
privatekey string Private key.
Source:
Returns:
Public key.
Type
string

getFluxShareSize() → {number}

To get total size (GB) for all files within a directory.
Source:
Returns:
Total file size (GB).
Type
number

getFluxShareSpecificFolderSize(folder) → {number}

To get total size (Bytes) for a specific folder.
Parameters:
Name Type Description
folder string Directory path for folder.
Source:
Returns:
Folder size (Bytes).
Type
number

getFluxTimezone(req, res) → {object}

To get FluxOS time zone.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

getFluxVersion(req, res) → {object}

To show FluxOS version.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

getFluxZelID(req, res) → {object}

To show the current user's ZelID that is being used to access FluxOS.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getFolderErrors(req, res) → {object}

Returns the list of errors encountered during scanning or pulling. Takes one mandatory parameter {folder}
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getFolderVersions(req, res) → {object}

Returns the list of archived files that could be recovered. Takes one mandatory parameter {folder}
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getGatewayApi(req, res)

To show a message with gateway address. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getGlobalAppsSpecifications(req, res)

To get specifications for global apps.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getHealth(req, res) → {object}

To get Syhcthing health
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
System health, {"status": "OK"}.
Type
object

getIncomingConnections(req, res, expressWS)

To get IP addresses for incoming connections.
Parameters:
Name Type Description
req object Request.
res object Response.
expressWS object Express web socket.
Source:

getIncomingConnectionsInfo(req, res)

To get info for incoming connections.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getInfo(req, res) → {object}

To get info on benchmark version and RCP port.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getInfo(req, res) → {object}

To get info on daemon version and RPC port. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getIpApi(req, res)

To show a message with IP address. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getLocalSolPs(req, res) → {object}

To get local solutions (hash computations created) per second.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getMapApi(req, res)

To show a message with mappings. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) getMempoolInfo(req, res) → {object}

To get mempool (memory pool) info.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getMeta(req, res) → {object}

To get meta
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getMiningInfo(req, res) → {object}

To get mining info.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getMyFluxIPandPort() → {string}

To get Flux IP adress and port.
Source:
Returns:
IP address and port.
Type
string

(async) getNetTotals(req, res) → {object}

To get net totals.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getNetworkHashPs(req, res) → {object}

To get number of network hashes per second. Blocks (defaults to value of 120) and height (defaults to value of -1) required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getNetworkInfo(req, res) → {object}

To get network info.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getNetworkSolPs(req, res) → {object}

To get network solutions (hash computations created) per second. Blocks (defaults to value of 120) and height (defaults to value of -1) required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getNewAddress(req, res) → {object}

To get a new address. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getNewNodeTier() → {string}

To return the tier of a node.
Source:
Returns:
Name of the node tier.
Type
string

getNodeGeolocation()

Method responsible for getting stored node geolocation information
Source:

(async) getNodeSpecs()

To get node specifications (CPUs, RAM and SSD).
Source:

(async) getNodeTier(req, res)

To get the tier of the FluxNode (Cumulus, Nimbus or Stratus). Checks the node tier against the node collateral.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

getNumberOfPeers()

Return the number of peers this node is connected to
Source:

(async) getPeerInfo(req, res) → {object}

To get node peer info.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getPreviousAppSpecifications(specifications, message) → {object}

To get previous app specifications.
Parameters:
Name Type Description
specifications object App sepcifications.
message object Message.
Source:
Returns:
App specifications.
Type
object

(async) getPublicIp(req, res) → {object}

To show public IP address.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getRandomConnection() → {string}

To get a random connection.
Source:
Returns:
IP:Port or just IP if default.
Type
string

(async) getRawChangeAddress(req, res) → {object}

To get raw change address. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getRawMemPool(req, res) → {object}

To get raw mempool (memory pool) info. Verbose (defaults to true) required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getRawTransaction(req, res) → {object}

To get raw transaction. Transaction ID and verbose (defaults to value of 0) required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

getRawTxCacheCache(key) → {object}

Gets rawTxCache data. Created for testing purposes.
Parameters:
Name Type Description
key object
Source:
Returns:
cached data
Type
object

(async) getReceivedByAddress(req, res) → {object}

To get received by address. Address and min conf (defaults to value of 1) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getRunningAppIpList(ip) → {Array.<object>}

To get a list of running apps for a specific IP address.
Parameters:
Name Type Description
ip string IP address.
Source:
Returns:
Array of running apps.
Type
Array.<object>

(async) getRunningAppList(appName) → {Array.<object>}

To get a list of running instances of a specific app.
Parameters:
Name Type Description
appName string App name.
Source:
Returns:
Array of running apps.
Type
Array.<object>

(async) getScannedHeight(req, res)

To get scanned block height.
Parameters:
Name Type Description
req object Reqest.
res object Response.
Source:

(async) getSender(txid, vout) → {object}

To return the sender address of a transaction (from Flux database or Blockchain).
Parameters:
Name Type Description
txid string Transaction ID.
vout number Transaction output number (vector of outputs).
Source:
Returns:
Document.
Type
object

(async) getSenderForFluxTx(txid, vout) → {object}

To return the sender address of a transaction (from Flux cache or database).
Parameters:
Name Type Description
txid string Transaction ID.
vout number Transaction output number (vector of outputs).
Source:
Returns:
Document.
Type
object

(async) getSenderForFluxTxInsight(txid, vout) → {object}

To return sender for a transaction.
Parameters:
Name Type Description
txid string Transaction ID.
vout number Transaction output number (vector of outputs).
Source:
Returns:
Document.
Type
object

(async) getSenderTransactionFromDaemon(txid) → {object}

To return the sender's transaction info from the daemon service.
Parameters:
Name Type Description
txid string Transaction ID.
Source:
Returns:
Transaction obtained from transaction cache.
Type
object

(async) getSingleAddressBalance(req, res) → {object}

To get balance of a single address. Address required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getSingleAddressDeltas(req, res) → {object}

To get deltas for a single address. Address, start, end and chain info required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getSingleAddressMempool(req, res) → {object}

To get mempool (memory pool) for a single address. Address required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getSingleAddresssTxids(req, res) → {object}

To get transaction IDs for single specified address. Address, start and end required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getSingleAddressUtxos(req, res) → {object}

To get UTXOs for a single address. Address and chain info required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getSpaceAvailableForFluxShare() → {number}

To check the quantity of space (GB) available for FluxShare. This is the space available after space already reserved for the FluxNode.
Source:
Returns:
The quantity of space available (GB).
Type
number

(async) getSpentInfo(req, res) → {object}

To get spent info. Transaction ID and index required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getSpentInfoPost(req, res) → {object}

To get spent info after data is processed. Transaction ID and index required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

getStandardCache(key) → {object}

Gets standard cache data. Created for testing purposes.
Parameters:
Name Type Description
key object
Source:
Returns:
cached data
Type
object

(async) getStartList(req, res) → {object}

To get start list.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getStatus(req, res) → {object}

To get benchmark status.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

getStoredCollateral() → {number}

Returns storedCollateral - created for testing purposes
Source:
Returns:
storedTier
Type
number

getStoredFluxBenchAllowed() → {number}

Getter for storedFluxBenchAllowed. Main goal for this is testing availability.
Source:
Returns:
storedFluxBenchAllowed
Type
number

getStoredTier() → {string}

Returns storedTier - created for testing purposes
Source:
Returns:
storedTier
Type
string

(async) getStrictApplicationSpecifications(appName) → {object}

To get app specifications for a specific app (case sensitive) if global/local status is unkown. First searches global apps and if not found then searches local apps.
Parameters:
Name Type Description
appName string App name.
Source:
Returns:
Document with app info.
Type
object

(async) getSvcDeviceID(req, res) → {object}

Verifies and formats a device ID. Takes one parameter, {id}.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getSvcRandomString(req, res) → {object}

Returns a strong random generated string (alphanumeric) of the specified length. Takes the {length} parameter.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getSvcReport(req, res) → {object}

Returns the data sent in the anonymous usage report.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) getSyncthingApiKey() → {string}

To get syncthing Api key
Source:
Returns:
Api key.
Type
string

(async) getTransaction(req, res) → {object}

To get a transaction. Transaction ID and whether to include watch only (defaults to false) required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getTxOut(req, res) → {object}

To get transaction output. Transaction ID, number and whether to include mempool (defaults to true) required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getTxOutProof(req, res) → {object}

To get transaction output proof. Array of transaction IDs required as parameter for RPC call. Block hash can also be included as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getTxOutSetInfo(req, res) → {object}

To get transaction output set info.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getUnconfirmedBalance(req, res) → {object}

To get unconfirmed balance. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getVerboseBlock(heightOrHash, verbosity) → {object}

To get the details of a verbose block.
Parameters:
Name Type Default Description
heightOrHash number | string Block height or block hash.
verbosity number 2 Verbosity level.
Source:
Returns:
Block data from block cache.
Type
object

(async) getWalletInfo(req, res) → {object}

To get wallet info. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getZelNodeCount(req, res) → {object}

To get node count.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getZelNodeOutputs(req, res) → {object}

To get node outputs. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getZelNodeScores(req, res) → {object}

To get node scores. Optional number of blocks can be included as a parameter for RPC call. Otherwise defaults to 10 blocks.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getZelNodeStatus(req, res) → {object}

To get node status.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) getZelNodeWinners(req, res) → {object}

To get node winnners. Optional filter can be included as a parameter for RPC call. Optional number of blocks can be included as a parameter for RPC call. Otherwise defaults to 10 blocks.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) handleAppMessages(message, fromIP)

To handle temporary app messages.
Parameters:
Name Type Description
message object Message.
fromIP string Sender's IP address.
Source:

(async) handleAppRunningMessage(message, fromIP)

To handle running app messages.
Parameters:
Name Type Description
message object Message.
fromIP string Sender's IP address.
Source:

handleIncomingConnection(ws, req, expressWS) → {void}

To handle incoming connection. Several types of verification are performed.
Parameters:
Name Type Description
ws object Web socket.
req object Request.
expressWS object Express web socket.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) hardRedeploy(appSpecs, res)

To hard redeploy. Removes and reinstalls app locally.
Parameters:
Name Type Description
appSpecs object App specifications.
res object Response.
Source:

(async) hardUpdateFlux(req, res) → {object}

To hard update FluxOS version (executes the command `npm run hardupdateflux` on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) help(req, res) → {object}

To request help message.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) help(req, res) → {object}

To request help message. Command required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) importAddress(req, res) → {object}

To import address. Address, label and whether to rescan (defaults to true) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) importPrivKey(req, res) → {object}

To import private key. Private key, label and whether to rescan (defaults to true) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) importWallet(req, res) → {object}

To import wallet. File name required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) initiateAndHandleConnection(connection)

To initiate and handle a connection. Opens a web socket and handles various events during connection.
Parameters:
Name Type Description
connection string IP address (and port if applicable).
Source:

(async) initiateBlockProcessor(restoreDatabase, deepRestore, reindexOrRescanGlobalApps) → {void}

To start the block processor.
Parameters:
Name Type Description
restoreDatabase boolean True if database is to be restored.
deepRestore boolean True if a deep restore is required.
reindexOrRescanGlobalApps boolean True if apps collections are to be reindexed.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) installApplicationHard(appSpecifications, appName, isComponent, res) → {void}

To hard install an app. Pulls image/s, creates data volumes, creates components/app, assigns ports to components/app and starts all containers.
Parameters:
Name Type Description
appSpecifications object App specifications.
appName string App name.
isComponent boolean True if a Docker Compose component.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) installApplicationSoft(appSpecifications, appName, isComponent, res) → {void}

To soft install app. Pulls image/s, creates components/app, assigns ports to components/app and starts all containers. Does not create data volumes.
Parameters:
Name Type Description
appSpecifications object App specifications.
appName string App name.
isComponent boolean True if a Docker Compose component.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) installAppLocally(req, res)

To install any app locally Checks that the app is installable on the machine (i.e. the machine has a suitable space. Only accessible by admins and Flux team members. Possible to install any locally present app and currently present global app This has intentionally less check then automated global installation. Node op should know what is doing, great for testing.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) installedApps(req, res) → {object}

To get a list of installed apps. Where req can be equal to appname. Shall be identical to listAllApps but this is a database response.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) installFluxWatchTower()

To install Flux Watch Tower (executes the command `bash fluxwatchtower.sh` in the relevent directory on the node machine).
Source:

(async) installSyncthing()

To install Syncthing
Source:

isCommunicationEstablished(req, res)

To check if sufficient communication is established. Minimum number of outgoing and incoming peers must be met.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

isDaemonSynced(req, res) → {object}

To check if daemon is synced.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

isDecimalLimit(value, decimals)

If a number or a string value has maximum of decimals
Parameters:
Name Type Default Description
value string | number Number to check agains
decimals number 8 Maximum number of allowed decimals. Defaults to 8 for satoshis
Source:

(async) isFirewallActive() → {boolean}

To check if a firewall is active.
Source:
Returns:
True if a firewall is active. Otherwise false.
Type
boolean

(async) isFluxAvailable(ip, port) → {boolean}

To perform a basic check of current FluxOS version.
Parameters:
Name Type Description
ip string IP address.
port string Port. Defaults to config.server.apiport.
Source:
Returns:
False unless FluxOS version meets or exceeds the minimum allowed version.
Type
boolean

isInsightExplorer() → {boolean}

To check if Insight Explorer is activated in the daemon configuration file.
Source:
Returns:
True if the daemon is configured with Insight Explorer on.
Type
boolean

(async) isNodeStatusConfirmed() → {boolean}

Checks if a node's status is confirmed.
Source:
Returns:
True if node is confirmed. False if there is an error.
Type
boolean

isUPNP() → {boolean}

To quickly check if node has UPnP (Universal Plug and Play) support.
Source:
Returns:
True if port mappings can be set. Otherwise false.
Type
boolean

keepConnectionsAlive()

To keep connections alive by pinging all outgoing and incoming peers.
Source:

(async) keyPoolRefill(req, res) → {object}

To refill key pool. New size (defaults to value of 100) required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) listAddressGroupings(req, res) → {object}

To list address groupings. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) listAllApps(req, res) → {object}

To list all apps or app components Shall be identical to installedApps but this is the Docker response.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) listAppsImages(req, res) → {object}

To list Docker images for apps.
Parameters:
Name Type Description
req object Request.
res object Repsonse.
Source:
Returns:
Message.
Type
object

(async) listBanned(req, res) → {object}

To list banned IP addresses.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) listLockUnspent(req, res) → {object}

To list lock unspent. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) listReceivedByAddress(req, res) → {object}

To list received transactions by address. Min conf (defaults to value of 1), whether to include empty (defaults to false) and whether to include watch only (defaults to false) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) listRunningApps(req, res) → {object}

To list running apps.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) listSinceBlock(req, res) → {object}

To list since a specified block. Block hash, target confirmations (defaults to value of 1) and whether to include watch only (defaults to false) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) listTransactions(req, res) → {object}

To list transactions. Account, count (defaults to value of 10), from (defaults to value of 0) and whether to include watch only (defaults to false) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) listUnspent(req, res) → {object}

To list unspent. Min conf (defaults to value of 1), max conf (defaults to value of 9999999) and address required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) listZelNodeConf(req, res) → {object}

To list node configuration. Optional filter can be included as a parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) listZelNodes(req, res) → {object}

To list nodes. Optional filter can be included as a parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) lockUnspent(req, res) → {object}

To lock unspent. Whether unlocked and transactions required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) loggedSessions(req, res)

To return a JSON response with a list of logged sessions. Only accessible by the ZelID owner.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) loggedUsers(req, res)

To return a JSON response with a list of logged in users. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) loginPhrase(req, res) → {void}

To return a JSON response with the user's login phrase.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) logoutAllSessions(req, res)

To return a JSON response to show the user if they have logged out from all sessions successfully or not. Only accessible by the ZelID owner.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) logoutAllUsers(req, res)

To return a JSON response to show the admin user if they have logged out all users successfully or not. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) logoutCurrentSession(req, res)

To return a JSON response to show the user if they have logged out of the current session successfully or not. Only accessible by the ZelID owner.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) logoutSpecificSession(req, res)

To return a JSON response to show the user if they have logged out of a specific session successfully or not. Only accessible by the ZelID owner.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) mapPortApi(req, res)

To map a specified port and show a message if successfully mapped. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) mapUpnpPort(port, description) → {boolean}

To create mappings for UPnP (Universal Plug and Play) port.
Parameters:
Name Type Description
port number Port number.
description string Port description.
Source:
Returns:
True if port mappings can be created for both TCP (Transmission Control Protocol) and UDP (User Datagram Protocol) protocols. Otherwise false.
Type
boolean

(async) messageHash(message) → {string}

To hash a message using sha256 encryption.
Parameters:
Name Type Description
message string Message to be hashed.
Source:
Returns:
Hashed message.
Type
string

minVersionSatisfy(version, minimumVersion) → {boolean}

Check if semantic version is bigger or equal to minimum version
Parameters:
Name Type Description
version string Version to check
minimumVersion string minimum version that version must meet
Source:
Returns:
True if version is equal or higher to minimum version otherwise false.
Type
boolean

(async) nodeCollateral() → {number}

To return the quantity of collateral stored and determine what type of node it can be used for.
Source:
Returns:
The quantity of collateral.
Type
number

(async) nodeTier() → {string}

To return the tier of a node in old naming scheme
Source:
Returns:
Name of the node tier in old naming scheme
Type
string

(async) performRequest(method, urlpath, data) → {object}

To perform http request
Parameters:
Name Type Default Description
method string get Method.
urlpath string URL to be called.
data object Request data.
Source:
Returns:
Message.
Type
object

(async) ping(req, res) → {object}

To send a ping to peers. Only accessible by admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) postClusterPendigDevices(req, res) → {object}

To remove records about a pending remote device which tried to connect.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postClusterPendigFolders(req, res) → {object}

To remove records about a pending folder announced from a remote device.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postConfig(req, res) → {object}

Replaces the entire config.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postConfigDefaultsDevice(req, res) → {object}

To modify config for defult values for devices, PUT replaces the default config (omitted values are reset to the hard-coded defaults), PATCH replaces only the given child objects.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postConfigDefaultsFolder(req, res) → {object}

To modify config for defult values for folders, PUT replaces the default config (omitted values are reset to the hard-coded defaults), PATCH replaces only the given child objects.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postConfigDefaultsIgnores(req, res) → {object}

To replace the default ignore patterns from an object of the same format
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postConfigDevices(req, res) → {object}

To modify config for devices. PUT replaces the entire config, PATCH replaces only the given child objects and DELETE removes the devices
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postConfigFolders(req, res) → {object}

To modify config for folders. PUT replaces the entire config, PATCH replaces only the given child objects and DELETE removes the folder
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postConfigGui(req, res) → {object}

To modify gui object, PUT replaces the entire object and PATCH replaces only the given child objects.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postConfigLdap(req, res) → {object}

To modify ldap object, PUT replaces the entire object and PATCH replaces only the given child objects.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postConfigOptions(req, res) → {object}

To modify options object, PUT replaces the entire object and PATCH replaces only the given child objects.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postDbIgnores(req, res) → {object}

Updates the content of the .stignore echoing it back as a response. Takes one parameter {folder}
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postDbOverride(req, res) → {object}

Request override of a send only folder. Override means to make the local version latest, overriding changes made on other devices. This API call does nothing if the folder is not a send only folder. Takes the mandatory parameter {folder}
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postDbPrio(req, res) → {object}

Moves the file to the top of the download queue.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postDbRevert(req, res) → {object}

To request revert of a receive only folder. Reverting a folder means to undo all local changes. This API call does nothing if the folder is not a receive only folder. Takes the mandatory parameter {folder}.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postDbScan(req, res) → {object}

To request immediate scan. Takes the optional parameters {folder} (folder ID), {sub} (path relative to the folder root) and {next} (time in seconds)
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postFolderVersions(req, res) → {object}

To restore archived versions of a given set of files. Expects an object with attributes named after the relative file paths, with timestamps as values matching valid versionTime entries in the corresponding getFolderVersions() response object. Takes one mandatory parameter {folder}
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postSystemError(req, res) → {object}

Post with an error message in the body (plain text) to register a new error.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) postSystemUpgrade(req, res) → {object}

To perform an upgrade to the newest released version and restart.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) prioritiseTransaction(req, res) → {object}

To prioritise transaction. Transaction ID, priority delta and fee delta required as parameters for RPC call. Only accessible by users.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) processBlock(blockHeight, isInsightExplorer) → {void}

To process block data for entry to Insight database.
Parameters:
Name Type Description
blockHeight number Block height.
isInsightExplorer boolean True if node is insight explorer based.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) processBlockTransactions(txs, height) → {Array.<object>}

To process a block of transactions.
Parameters:
Name Type Description
txs Array.<object> Array of transaction content objects.
height number Blockchain height.
Source:
Returns:
Array of transaction detail objects.
Type
Array.<object>

(async) processInsight(blockDataVerbose, database)

To process verbose block data for entry to Insight database.
Parameters:
Name Type Description
blockDataVerbose object Verbose block data.
database string Database.
Source:

(async) processStandard(blockDataVerbose, database)

To process verbose block data for entry to database.
Parameters:
Name Type Description
blockDataVerbose object Verbose block data.
database string Database.
Source:

(async) processTransaction(txContent, height) → {object}

To process a transaction. This checks that a transaction is UTXO and if so, stores it to the database to include the sender.
Parameters:
Name Type Description
txContent object Transaction content.
height number Blockchain height.
Source:
Returns:
Transaction detail.
Type
object

(async) provideSign(req, res)

To return a JSON response with a new signature for the user. A series of checks are performed on the ZelID and signature.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) rebuildHome(req, res) → {object}

To rebuild FluxOS (executes the command `npm run homebuild` on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) reconstructAppMessagesHashCollection() → {string}

To reconstruct app messages hash collection. Checks if globalAppsMessages has the message or not.
Source:
Returns:
Reconstruct success message.
Type
string

(async) reconstructAppMessagesHashCollectionAPI(req, res)

To reconstruct app messages hash collection via API. Checks if globalAppsMessages has the message or not. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) redeployAPI(req, res) → {object}

To redeploy via API. Cannot be performed for individual components. Force defaults to false. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) registerAppGlobalyApi(req, res) → {void}

To register an app globally via API. Performs various checks before the app can be registered. Only accessible by users.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) registerAppLocally(appSpecs, componentSpecs, res) → {void}

To register an app locally. Performs pre-installation checks - database in place, Flux Docker network in place and if app already installed. Then registers app in database and performs hard install. If registration fails, the app is removed locally.
Parameters:
Name Type Description
appSpecs object App specifications.
componentSpecs object Component specifications.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

registrationInformation(req, res)

To get registration information (Flux apps).
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) reindexDaemon(req, res) → {object}

To reindex Flux daemon database (executes the command `bash reindexDaemon.sh` on the node machine). Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) reindexExplorer(req, res)

To reindex Flux explorer database. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) reindexGlobalAppsInformation() → {boolean}

To drop global apps information and iterate over all global apps messages and reconstruct the global apps information. Further creates database indexes.
Source:
Returns:
True or thorws an error.
Type
boolean

(async) reindexGlobalAppsInformationAPI(req, res)

To reindex global apps information via API. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) reindexGlobalAppsLocation() → {boolean}

To drop information about running apps and rebuild indexes.
Source:
Returns:
True or thorws an error.
Type
boolean

(async) reindexGlobalAppsLocationAPI(req, res)

To reindex global apps location via API. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) reinstallOldApplications() → {void}

To reinstall old apps. Tries soft and hard reinstalls of app (and any components).
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) relayZelNodeBroadcast(req, res) → {object}

To relay node broadcast. Optional hex string can be included as a parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) removeAppLocally(app, res, force, endResponse) → {void}

To remove an app locally including any components. First finds app specifications in database and then deletes the app from database.
Parameters:
Name Type Default Description
app string App name and app component (if applicable). A component name follows the app name after an underscore `_`.
res object Response.
force boolean false Defaults to false. Force determines if a check for app not found is skipped.
endResponse boolean true Defaults to true.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) removeAppLocallyApi(req, res)

To remove app locally via API call. Cannot be performed for individual components. Force defaults to false. Only accessible by app owner, admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) removeIncomingPeer(req, res, expressWS) → {object}

To remove an incoming peer by specifying the IP address. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
expressWS object Express web socket.
Source:
Returns:
Message.
Type
object

(async) removeMapPortApi(req, res)

To unmap a specified port and show a message if successfully unmapped. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) removeMapUpnpPort(port) → {boolean}

To remove TCP (Transmission Control Protocol) and UDP (User Datagram Protocol) port mappings from UPnP (Universal Plug and Play) port.
Parameters:
Name Type Description
port number Port number.
Source:
Returns:
True if port mappings have been removed for both TCP (Transmission Control Protocol) and UDP (User Datagram Protocol) protocols. Otherwise false.
Type
boolean

(async) removePeer(req, res) → {object}

To remove an outgoing peer by specifying the IP address. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) repositoryArchitectures(repotag) → {Array.<string>}

To get Docker image architectures.
Parameters:
Name Type Description
repotag string Docker Hub repository tag.
Source:
Returns:
List of Docker image architectures.
Type
Array.<string>

(async) requestAppMessage(hash)

To request app message.
Parameters:
Name Type Description
hash string Message hash.
Source:

(async) rescanBlockchain(req, res) → {object}

To rescan the blockchain. Start height (defaults to value of 0) required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) rescanExplorer(req, res)

To rescan Flux explorer database from a specific block height. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) rescanGlobalAppsInformation(height, removeLastInformation) → {boolean}

To iterate over all global apps messages and update global apps information database.
Parameters:
Name Type Default Description
height number 0 Defaults to value of 0.
removeLastInformation boolean false Defaults to false.
Source:
Returns:
True or thorws an error.
Type
boolean

(async) rescanGlobalAppsInformationAPI(req, res)

To rescan global apps information via API. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) respondWithAppMessage(message, ws) → {void}

To respond with app message.
Parameters:
Name Type Description
message object Message.
ws object Web socket.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) restartBenchmark(req, res) → {object}

To restart Flux benchmark (executes the command `bash restartBenchmark.sh` on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) restartBlockProcessing(req, res)

To restart block processing. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) restartDaemon(req, res) → {object}

To restart Flux daemon (executes the command `bash restartDaemon.sh` on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) restartNodeBenchmarks(req, res) → {object}

To restart node benchmarks. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) restoreAppsPortsSupport()

Restores applications firewall, UPNP rules
Source:

(async) restoreDatabaseToBlockheightState(height, rescanGlobalApps) → {boolean}

To restore database to specified block height.
Parameters:
Name Type Default Description
height number Block height.
rescanGlobalApps boolean false Value set to false on function call.
Source:
Returns:
Value set to true after database is restored.
Type
boolean

(async) restoreFluxPortsSupport()

Restores FluxOS firewall, UPNP rules
Source:

(async) restorePortsSupport()

Restores FluxOS and applications firewall, UPNP rules
Source:

(async) sendFrom(req, res) → {object}

To send transaction from address. Sender account, recipient address, amount, min conf (defaults to value of 1), comment and comment for recipient required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) sendFromPost(req, res) → {object}

To send transaction from address after data is processed. Sender account, recipient address, amount, min conf (defaults to value of 1), comment and comment for recipient required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) sendMany(req, res) → {object}

To send multiple transactions. Sender account, amounts, min conf (defaults to value of 1), comment and fee to substract from amount required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) sendManyPost(req, res) → {object}

To send multiple transactions after data is processed. Sender account, amounts, min conf (defaults to value of 1), comment and fee to substract from amount required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) sendMessageToWS(message, ws)

To sign and send message to web socket.
Parameters:
Name Type Description
message object Message.
ws object Web Socket.
Source:

(async) sendRawTransaction(req, res) → {object}

To send raw transaction. Hex string and whether to allow high fees (defaults to false) required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) sendRawTransactionPost(req, res) → {object}

To send raw transaction after data is processed. Hex string and whether to allow high fees (defaults to false) required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) sendToAddress(req, res) → {object}

To send transaction to address. Recipient address, amount, comment, comment for recipient and fee to substract from amount (defaults to false) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) sendToAddressPost(req, res) → {object}

To send transaction to address after data is processed. Recipient address, amount, comment, comment for recipient and fee to substract from amount (defaults to false) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) sendToAllIncomingConnections(data, wsList)

To send to all incoming connections.
Parameters:
Name Type Description
data object Data.
wsList Array.<object> Web socket list.
Source:

(async) sendToAllPeers(data, wsList)

To send to all peers.
Parameters:
Name Type Description
data object Data.
wsList Array.<object> Web socket list.
Source:

(async) serialiseAndSignFluxBroadcast(dataToBroadcast, privatekey) → {string}

To serialise and sign a Flux broadcast.
Parameters:
Name Type Description
dataToBroadcast object Data to broadcast. Contains version, timestamp, pubKey, signature and data.
privatekey string Private key.
Source:
Returns:
Data string (serialised data object).
Type
string

(async) setBan(req, res) → {object}

To set a ban on an IP address. IP, command, ban time and if absolute required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

setBlockCache(key, value)

Sets block cache data. Created for testing purposes.
Parameters:
Name Type Description
key object
value object
Source:

setDosMessage(message)

Setter for dosMessage. Main goal for this is testing availability.
Parameters:
Name Type Description
message string New message
Source:

setDosStateValue(sets)

Setter for dosState. Main goal for this is testing availability.
Parameters:
Name Type Description
sets number dosState
Source:

setMyFluxIp(value)

Setter for myFluxIp. Main goal for this is testing availability.
Parameters:
Name Type Description
value string new IP to be set
Source:

(async) setNodeGeolocation()

Method responsable for setting node geolocation information
Source:

setRawTxCache(key, value)

Sets rawTx cache data. Created for testing purposes.
Parameters:
Name Type Description
key object
value object
Source:

setStandardCache(key, value)

Sets standard cache data. Created for testing purposes.
Parameters:
Name Type Description
key object
value object
Source:

setStoredCollateral()

Set storedCollateral - created for testing purposes
Source:

setStoredFluxBenchAllowed(value)

Setter for storedFluxBenchAllowed. Main goal for this is testing availability.
Parameters:
Name Type Description
value number
Source:

setStoredTier()

Set nodeTier - created for testing purposes
Source:

(async) setTxFee(req, res) → {object}

To set transaction fee. Amount required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) setupUPNP(apiport) → {boolean}

To set up UPnP (Universal Plug and Play) support.
Parameters:
Name Type Description
apiport number Port number.
Source:
Returns:
True if port mappings can be set. Otherwise false.
Type
boolean

(async) signFluxTransaction(req, res) → {object}

To sign Flux transaction. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) signFluxTransactionPost(req, res)

To ensure that a request is an object and sign Flux transaction. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) signMessage(req, res) → {object}

To sign message. Address and message required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

signMessage(message, pk) → {string}

Signs the message with the private key.
Parameters:
Name Type Description
message object
pk string private key
Source:
Returns:
signature
Type
string

(async) signMessagePost(req, res) → {object}

To sign message after data is processed. Address and message required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) signRawTransaction(req, res) → {object}

To sign raw transaction. Hex string, previous transactions, private keys, signature hash type (defaults to ALL) and branch ID required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) signRawTransactionPost(req, res) → {object}

To sign raw transaction after data is processed. Hex string, previous transactions, private keys, signature hash type (defaults to all) and branch ID required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) softRedeploy(appSpecs, res) → {void}

To soft redeploy. Checks if any other installations/uninstallations are in progress and if not, removes and reinstalls app locally.
Parameters:
Name Type Description
appSpecs object App specifications.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) softRegisterAppLocally(appSpecs, componentSpecs, res) → {void}

To soft register an app locally (with data volume already in existence). Performs pre-installation checks - database in place, Flux Docker network in place and if app already installed. Then registers app in database and performs soft install. If registration fails, the app is removed locally.
Parameters:
Name Type Description
appSpecs object App specifications.
componentSpecs object Component specifications.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) softRemoveAppLocally(app, res)

To remove an app locally (including any components) without storage and cache deletion (keeps mounted volumes and cron job). First finds app specifications in database and then deletes the app from database. For app reload. Only for internal usage. We are throwing in functions using this.
Parameters:
Name Type Description
app string App name.
res object Response.
Source:

(async) softUpdateFlux(req, res) → {object}

To soft update FluxOS version (executes the command `npm run softupdate` on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) softUpdateFluxInstall(req, res) → {object}

To install the soft update of FluxOS (executes the command `npm run softupdateinstall` on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

specificationFormatter(appSpecification) → {object}

To format app specification object. Checks that all parameters exist and are correct.
Parameters:
Name Type Description
appSpecification object App specification.
Source:
Returns:
Returns formatted app specification to be stored in global database. Otherwise throws error.
Type
object

(async) spork(req, res) → {object}

To show spork. Optional value can be included as a parameter for RPC call. Optional name can be included as a parameter for RPC call. Otherwise defaults to show.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

startAppMonitoring(appName)

Starts app monitoring for a single app and saves monitoring data in-memory to the appsMonitored object.
Parameters:
Name Type Description
appName object monitored component name
Source:

(async) startAppMonitoringAPI(req, res) → {void}

API call to start app monitoring and save monitoring data in-memory to the appsMonitored object. Monitors all apps or a single app if its name is specified in the API request.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) startBenchmark(req, res) → {object}

To start Flux benchmark (executes the command `fluxbenchd -daemon` on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) startBenchmarkD(req, res) → {object}

To start benchmark daemon. Only accessible by admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) startDaemon(req, res) → {object}

To start Flux daemon (executes the command `fluxd` on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) startDeterministicZelNode(req, res) → {object}

To start deterministic node. Alias required as a parameter for RPC call if not already specified. Optional lock wallet configuration can be included as a parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) startFluxFunctions()

To start FluxOS. A series of checks are performed on port and UPnP (Universal Plug and Play) support and mapping. Database connections are established. The other relevant functions required to start FluxOS services are called.
Source:

(async) startMonitoringOfApps(appSpecsToMonitor)

Starts app monitoring for all apps.
Parameters:
Name Type Description
appSpecsToMonitor array Array of application specs to be monitored
Source:

(async) startSyncthing()

To Start Syncthing
Source:

(async) startZelNode(req, res) → {object}

To start node. Set and lock wallet configurations required as parameters for RPC call if not already specified. Optional alias can be included as a parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) statsDevice(req, res) → {object}

To get device statistics
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
General statistics about devices.
Type
object

(async) statsFolder(req, res) → {object}

To get folder statistics
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
General statistics about folders.
Type
object

(async) stop(req, res) → {object}

To stop node benchmarks. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) stop(req, res) → {object}

To stop node daemon. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) stopAllNonFluxRunningApps()

To stop all non Flux running apps. Executes continuously at regular intervals.
Source:

stopAppMonitoring(appName, deleteData)

Stops app monitoring for a single app.
Parameters:
Name Type Description
appName object App specifications.
deleteData boolean Delete monitored data
Source:

(async) stopAppMonitoringAPI(req, res) → {void}

API call to stop app monitoring. Applies to all apps or a single app if its name is specified in the API request. Maintains existing monitoring data or deletes existing monitoring data if specified in the API request.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) stopBenchmarkD(req, res) → {object}

To stop benchmark daemon. Only accessible by admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) stopBlockProcessing(req, res)

To stop block processing. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) stopMonitoringOfApps(appSpecsToMonitor)

Stops app monitoring for all apps.
Parameters:
Name Type Description
appSpecsToMonitor array Array of application specs to be stopped for monitor
Source:

(async) storeAppPermanentMessage(message)

To store a permanent message for an app.
Parameters:
Name Type Description
message object Message.
Source:
Returns:
True if no error is thrown.

(async) storeAppRunningMessage(message) → {boolean}

To store a message for a running app.
Parameters:
Name Type Description
message object Message.
Source:
Returns:
True if message is successfully stored and rebroadcasted. Returns false if message is already in cache, is already stored or is old. Throws an error if invalid.
Type
boolean

(async) storeAppTemporaryMessage(message, furtherVerification) → {boolean}

To store a temporary message for an app.
Parameters:
Name Type Default Description
message object Message.
furtherVerification boolean false Defaults to false.
Source:
Returns:
True if message is successfully stored and rebroadcasted. Returns false if message is already in cache or has already been broadcast. Otherwise an error is thrown.
Type
boolean

(async) submitBlock(req, res) → {object}

To submit a block. Hex data required as parameter for RPC call. JSON parameters object can also be provided as a parameter for RPC call. Only accessible by users.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) submitBlockPost(req, res) → {object}

To submit a block after data is processed. Hex data required as parameter for RPC call. JSON parameters object can also be provided as a parameter for RPC call. Only accessible by users.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) systemArchitecture() → {string}

To get system architecture type (ARM64 or AMD64).
Source:
Returns:
Architecture type (ARM64 or AMD64).
Type
string

(async) systemBrowse(req, res) → {object}

To get list of directories matching the path given by the optional parameter current
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
List of directories in json array format.
Type
object

(async) systemConnections(req, res) → {object}

To get the list of configured devices and some metadata associated with them. The list also contains the local device itself as not connected.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
List of configured devices and some metadata in json format.
Type
object

(async) systemDebug(req, res) → {object}

To get the set of debug facilities and which of them are currently enabled.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
List of debug facilities and which of them are currently enabled.
Type
object

(async) systemDiscovery(req, res) → {object}

To get the contents of the local discovery cache
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Contents of the local discovery cache
Type
object

(async) systemError(req, res) → {object}

Returns the list of recent errors. Post with an error message in the body (plain text) to register a new error.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemErrorClear(req, res) → {object}

Post with empty body to remove all recent errors.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemLog(req, res) → {object}

To get the list of recent log entries. The optional {since} parameter limits the results to message newer than the given timestamp in RFC 3339 format.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemLogTxt(req, res) → {object}

To get the list of recent log entries formatted as a text log instead of a JSON object. The optional {since} parameter limits the results to message newer than the given timestamp in RFC 3339 format.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemPaths(req, res) → {object}

To get the path locations used internally for storing configuration, database, and others.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemPause(req, res) → {object}

To pause the given device or all devices. Takes the optional parameter {device} (device ID). When omitted, pauses all devices.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemPing(req, res) → {object}

Returns a {"ping": "pong"} object.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemReset(req, res) → {object}

To erase the current index database and restart Syncthing. With no query parameters, the entire database is erased from disk. By specifying the {folder} parameter with a valid folder ID, only information for that folder will be erased.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemRestart(req, res) → {object}

To immediately restart Syncthing
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemResume(req, res) → {object}

To resume the given device or all devices. Takes the optional parameter {device} (device ID). When omitted, resumes all devices
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemShutdown(req, res) → {object}

To cause Syncthing to exit and not restart.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemStatus(req, res) → {object}

Returns information about current system status and resource usage.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemUpgrade(req, res) → {object}

To Check for a possible upgrade, returns an object describing the newest version and upgrade possibility.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) systemVersion(req, res) → {object}

Returns the current Syncthing version information.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message
Type
object

(async) tailBenchmarkDebug(req, res)

To get Flux benchmark tail debug logs (executes the command `tail -n 100 debug.log` in the relevent benchmark directory on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) tailDaemonDebug(req, res)

To get Flux daemon tail debug logs (executes the command `tail -n 100 debug.log` in the relevent daemon directory on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) tailFluxDebugLog(req, res)

To get FluxOS tail debug logs. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) tailFluxErrorLog(req, res)

To get FluxOS tail error logs. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) tailFluxInfoLog(req, res)

To get FluxOS tail info logs. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) tailFluxLog(req, res, logfile)

To get a specified FluxOS tail log file (executes the command `tail -n 100` for the specified .log file on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
logfile string Log file name (excluding `.log`).
Source:

(async) tailFluxWarnLog(req, res)

To get FluxOS tail warn logs. Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

totalAppHWRequirements(appSpecifications, myNodeTier) → {object}

To return total app hardware requirements (CPU, RAM and HDD).
Parameters:
Name Type Description
appSpecifications object App specifications.
myNodeTier string Node tier.
Source:
Returns:
Values for CPU, RAM and HDD.
Type
object

(async) trySpawningGlobalApplication() → {void}

To try spawning a global application. Performs various checks before the app is spawned. Checks that app is not already running on the FluxNode/IP address. Checks if app already has the required number of instances deployed. Checks that application image is not blacklisted. Checks that ports not already in use.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) updateAppGlobalyApi(req, res) → {void}

To update an app globally via API. Performs various checks before the app can be updated. Price handled in UI and available in API. Only accessible by users.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Return statement is only used here to interrupt the function and nothing is returned.
Type
void

(async) updateAppSpecifications(appSpecs)

To update app specifications.
Parameters:
Name Type Description
appSpecs object App specifications.
Source:

(async) updateAppSpecsForRescanReindex(appSpecs) → {boolean}

To update app specifications for rescan/reindex.
Parameters:
Name Type Description
appSpecs object App specifications.
Source:
Returns:
True.
Type
boolean

(async) updateBenchmark(req, res) → {object}

To update Flux benchmark version (executes the command `bash updateBenchmark.sh` on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) updateDaemon(req, res) → {object}

To update Flux daemon version (executes the command `bash updateDaemon.sh` on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) updateFlux(req, res) → {object}

To update FluxOS version (executes the command `npm run updateflux` on the node machine). Only accessible by admins and Flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) validateAddress(req, res) → {object}

To validate an address. Address required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) verifyAppHash(message) → {boolean}

To verify an app hash message.
Parameters:
Name Type Description
message object Message.
Source:
Returns:
True if no error is thrown.
Type
boolean

(async) verifyAppMessageSignature(type, version, appSpec, timestamp, signature) → {boolean}

To verify an app message signature.
Parameters:
Name Type Description
type string Type.
version number Version.
appSpec object App specifications.
timestamp number Time stamp.
signature string Signature.
Source:
Returns:
True if no error is thrown.
Type
boolean

(async) verifyAppMessageUpdateSignature(type, version, appSpec, timestamp, signature, appOwner) → {boolean}

To verify an app message signature update.
Parameters:
Name Type Description
type string Type.
version number Version.
appSpec object App specifications.
timestamp number Time stamp.
signature string Signature.
appOwner string App owner.
Source:
Returns:
True if no errors are thrown.
Type
boolean

(async) verifyAppRegistrationParameters(req, res) → {object}

To verify app registration parameters. Checks for correct format, specs and non-duplication of values/resources.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) verifyAppSpecifications(appSpecifications, height, checkDockerAndWhitelist)

To verify app specifications. Checks the attribute values of the appSpecifications object.
Parameters:
Name Type Default Description
appSpecifications object App specifications.
height number Block height.
checkDockerAndWhitelist boolean false Defaults to false.
Source:

(async) verifyAppUpdateParameters(req, res) → {object}

To verify app update parameters. Checks for correct format, specs and non-duplication of values/resources.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) verifyChain(req, res) → {object}

To verify chain. Check level and number of blocks required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) verifyFluxBroadcast(data, obtainedFluxNodesList, currentTimeStamp) → {boolean}

To verify Flux broadcast.
Parameters:
Name Type Description
data object Data containing public key, timestamp, signature and version.
obtainedFluxNodesList Array.<object> List of FluxNodes.
currentTimeStamp number Current timestamp.
Source:
Returns:
False unless message is successfully verified.
Type
boolean

(async) verifyLogin(req, res)

To return a JSON response to show the user if they have logged in successfully or not. In order to successfully log in, a series of checks are performed on the ZelID and signature.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) verifyMessage(req, res) → {object}

To verify a message. Address, signature and message required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

verifyMessage(message, address, signature, strMessageMagic, checkSegwitAlways) → {bool}

Verifies if the message was properly signed.
Parameters:
Name Type Description
message object
address string
signature string
strMessageMagic string
checkSegwitAlways string
Source:
Returns:
isValid
Type
bool

(async) verifyMessagePost(req, res) → {object}

To verify a message after data is processed. Address, signature and message required as parameters for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

verifyObjectKeysCorrectnessOfApp(appSpecification) → {boolean}

To verify correctness of attribute values within an app specification object. Checks if all object keys are assigned and no excess present
Parameters:
Name Type Description
appSpecification object App specifications.
Source:
Returns:
True if no errors are thrown.
Type
boolean

(async) verifyOriginalFluxBroadcast(data, obtainedFluxNodeList, currentTimeStamp) → {boolean}

To verify original Flux broadcast. Extends verifyFluxBroadcast by not allowing request older than 5 mins.
Parameters:
Name Type Description
data object Data.
obtainedFluxNodeList Array.<object> List of FluxNodes.
currentTimeStamp number Current timestamp.
Source:
Returns:
False unless message is successfully verified.
Type
boolean

(async) verifyPrivilege(privilege, req, appName) → {Promise.<boolean>}

Verifies a specific privilege based on request headers.
Parameters:
Name Type Description
privilege string 'admin, 'fluxteam', 'adminandfluxteam', 'appownerabove', 'appowner', 'user'
req object
appName string
Source:
Returns:
authorized
Type
Promise.<boolean>

(async) verifyRepository(repotag) → {boolean}

To verfiy a Docker Hub repository.
Parameters:
Name Type Description
repotag string Docker Hub repository tag.
Source:
Returns:
True if no errors are thrown.
Type
boolean

verifyRestrictionCorrectnessOfApp(appSpecification) → {boolean}

To verify correctness of attribute values within an app specification object. Checks for if restrictions of specs are valid.
Parameters:
Name Type Description
appSpecification object App specifications.
Source:
Returns:
True if no errors are thrown.
Type
boolean

(async) verifyTimestampInFluxBroadcast(data, currentTimeStamp) → {boolean}

To verify timestamp in Flux broadcast.
Parameters:
Name Type Description
data object Data.
currentTimeStamp number Current timestamp.
Source:
Returns:
False unless current timestamp is within 5 minutes of the data object's timestamp.
Type
boolean

(async) verifyTxOutProof(req, res) → {object}

To verify transaction output proof. Proof required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

verifyTypeCorrectnessOfApp(appSpecification) → {boolean}

To verify correctness of attribute values within an app specification object. Checks for types and that required attributes exist.
Parameters:
Name Type Description
appSpecification object App specifications.
Source:
Returns:
True if no errors are thrown.
Type
boolean

(async) verifyUPNPsupport(apiport) → {boolean}

To verify that a port has UPnP (Universal Plug and Play) support.
Parameters:
Name Type Description
apiport number Port number.
Source:
Returns:
True if port mappings can be set. Otherwise false.
Type
boolean

verifyZelID(address) → {bool}

Verifies ZelID, returns true if it's valid.
Parameters:
Name Type Description
address string
Source:
Returns:
isVaild
Type
bool

(async) viewDeterministicZelNodeList(req, res) → {object}

To view list of deterministic nodes. Optional filter can be included as a parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) whitelistedRepositories(req, res)

To create a JSON response showing a list of whitelisted Github repositories.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:

(async) wsRespondLoginPhrase(ws, req)

To check if a login phrase is currently active. The user's ZelID, login phrase, signature and privilege level are returned if the login phrase is active.
Parameters:
Name Type Description
ws object Web socket.
req object Request.
Source:

(async) wsRespondSignature(ws, req)

To check if a signature exists.
Parameters:
Name Type Description
ws object Web socket.
req object Request.
Source:

(async) zcBenchmark(req, res) → {object}

To perform benchmark. Benchmark type and sample count required as parameters for RPC call. Only accessible by admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zcRawJoinSplit(req, res) → {object}

To perform a raw join split. Raw transaction, inputs, outputs, old vpub and new vpub required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zcRawJoinSplitPost(req, res) → {object}

To perform a raw join split after data is processed. Raw transaction, inputs, outputs, old vpub and new vpub required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zcRawKeygen(req, res) → {object}

To generate a raw key. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zcRawReceive(req, res) → {object}

To receive raw transaction. Secret key and encrypted note required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zcRawReceivePost(req, res) → {object}

To receive raw transaction after data is processed. Secret key and encrypted note required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zcSampleJoinSplit(req, res) → {object}

To perform a sample join split. Only accessible by admins and flux team members.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zelNodeCurrentWinner(req, res) → {object}

To show current node winner.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zelNodeDebug(req, res) → {object}

To debug node.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zExportKey(req, res) → {object}

To export key. Address required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zExportViewingKey(req, res) → {object}

To export viewing key. Address required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zGetBalance(req, res) → {object}

To get account balance. Address and min conf (defaults to value of 1) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zGetMigrationStatus(req, res) → {object}

To get migration status. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zGetNewAddress(req, res) → {object}

To get new address. Type (defaults to sapling) required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zGetOperationResult(req, res) → {object}

To get operation result. Operation ID required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zGetOperationStatus(req, res) → {object}

To get operation status. Operation ID required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zGetTotalBalance(req, res) → {object}

To get total balance. Min conf (defaults to value of 1) and whether to include watch only (defaults to false) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zImportKey(req, res) → {object}

To import key. Key, rescan configuration (defaults to when key is new) and start height (defaults to value of 0) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zImportViewingKey(req, res) → {object}

To import viewing key. Viewing key, rescan configuration (defaults to when key is new) and start height (defaults to value of 0) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zImportWallet(req, res) → {object}

To import wallet. File name required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zListAddresses(req, res) → {object}

To list addresses. Whether to include watch only (defaults to false) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zListOperationIds(req, res) → {object}

To list Operation IDs. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zListReceivedByAddress(req, res) → {object}

To list received by address. Address and min conf (defaults to value of 1) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zListUnspent(req, res) → {object}

To list unspent. Min conf (defaults to value of 1), max conf (defaults to value of 9999999), whether to include watch only (defaults to false) and addresses required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zMergeToAddress(req, res) → {object}

To merge to address. Sender address, recipient address, fee (defaults to a value of 0.0001), transparent limit (defaults to a value of 50), shielded limit (defaults to a value of 20) and memo required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) znsync(req, res) → {object}

To get node sync status. Mode (defaults to status) required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zSendMany(req, res) → {object}

To send multiple transactions. Sender account, amounts, min conf (defaults to value of 1) and fee (defaults to a value of 0.0001) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zSendManyPost(req, res) → {object}

To send multiple transactions after data is processed. Sender account, amounts, min conf (defaults to value of 1) and fee (defaults to a value of 0.0001) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zSetMigration(req, res) → {object}

To set migration. Enabled configuration required as parameter for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zShieldCoinBase(req, res) → {object}

To shield coin base. Sender address, recipient address, fee (defaults to a value of 0.0001) and limit (defaults to a value of 50) required as parameters for RPC call. Only accessible by admins.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object

(async) zValidateAddress(req, res) → {object}

To validate a Z address. Z address required as parameter for RPC call.
Parameters:
Name Type Description
req object Request.
res object Response.
Source:
Returns:
Message.
Type
object