GatewayServer

GatewayServer

Facilitates interaction with a Gateway instance.

Constructor

new GatewayServer(sdk, serverUrl, opts)

Create a new Gateway instance.

Source:
Parameters:
Name Type Description
sdk ShelfNetwork

Parent SDK instance.

serverUrl string

Gateway URL.

opts Object
Name Type Attributes Description
allowHttp boolean <optional>

Allow connecting to http servers, default: false. This must be set to false in production deployments!

proxy Object <optional>

Proxy configuration. Look axios docs for more info

httpBasicAuth Object <optional>

HTTP basic auth credentials. Look axios docs for more info.

customHeaders Object <optional>

Custom headers for request.

Classes

GatewayServer

Methods

blacklistAccount(opts) → {JsonApiResponse}

Blacklist an account

Source:
Parameters:
Name Type Description
opts object
Name Type Description
id string

account to blacklist

state string

accepts "stopped", "paused"

Returns:
Type:
JsonApiResponse

getAccountsBlacklist() → {JsonApiResponse}

Returns all blacklisted accounts

Source:
Returns:
Type:
JsonApiResponse

unblacklistAccount(id) → {JsonApiResponse}

Remove an account from the unblacklist

Source:
Parameters:
Name Type Description
id string

account to unblacklist

Returns:
Type:
JsonApiResponse