Remote Server Configuration Files

A RemoteServerConfigurationFile is a configuration file (required for some Remote Server integrations, such as the Files.com Agent).

Download configuration file (required for some Remote Server integrations, such as the Files.com Agent)

SDK Function

RemoteServer.findConfigurationFile()

Return Object

RemoteServerConfigurationFile

Authorization Requirement

Requires either a Site-Wide API key or User API key or session from a User with Site Admin permissions.

Function Arguments

ArgumentDescription
id
int64
Required
Remote Server ID.

Example Request

import com.files.exceptions.*;
import com.files.exceptions.ApiErrorException.*;
import com.files.models.RemoteServer;
import com.files.models.RemoteServerConfigurationFile;

try {
  HashMap<String, Object> parameters = new HashMap<>();
  RemoteServerConfigurationFile remoteServerConfigurationFile = RemoteServer.findConfigurationFile(id, parameters);
  // Operate on remoteServerConfigurationFile
} catch (NotAuthenticatedException e) {
  System.out.println("Authentication Error Occurred (" + e.getClass().getName() + "): " + e.getMessage());
} catch (SdkException e) {
  System.out.println("Unknown Error Occurred (" + e.getClass().getName() + "): " + e.getMessage());
}

Post local changes, check in, and download configuration file (used by some Remote Server integrations, such as the Files.com Agent)

SDK Function

remoteServer.configurationFile();

Return Object

RemoteServerConfigurationFile

Authorization Requirement

No authentication required; you may call this endpoint without a key or session.

Attribute Setters

SetterDescription
setApiToken
string
Files Agent API Token
setPermissionSet
string
The permission set for the agent ['read_write', 'read_only', 'write_only']
setRoot
string
The root directory for the agent
setHostname
string
setPort
int64
Incoming port for files agent connections
setStatus
string
either running or shutdown
setConfigVersion
string
agent config version
setPrivateKey
string
The private key for the agent
setPublicKey
string
public key
setServerHostKey
string
setSubdomain
string
Files.com subdomain site name

Example Request

import com.files.exceptions.*;
import com.files.exceptions.ApiErrorException.*;
import com.files.models.RemoteServer;
import com.files.models.RemoteServerConfigurationFile;

try {
  HashMap<String, Object> attributes = new HashMap<>();
  RemoteServer remoteServer = new RemoteServer(attributes);
  HashMap<String, Object> parameters = new HashMap<>();
  parameters.put("api_token", "example");
  remoteServer.configurationFile(parameters);
} catch (NotAuthenticatedException e) {
  System.out.println("Authentication Error Occurred (" + e.getClass().getName() + "): " + e.getMessage());
} catch (SdkException e) {
  System.out.println("Unknown Error Occurred (" + e.getClass().getName() + "): " + e.getMessage());
}

The RemoteServerConfigurationFile Object

Some of the functions above return a RemoteServerConfigurationFile object. The attributes of this object are listed below.

AttributeDescription
id
int64
The remote server ID of the agent
permission_set
string
The permission set for the agent ['read_write', 'read_only', 'write_only']
private_key
string
The private key for the agent
subdomain
string
Files.com subdomain site name
root
string
The root directory for the agent
node_name
string
Optional customer-facing name for this Agent installation
follow_links
boolean
Follow symlinks when traversing directories
prefer_protocol
string
Preferred network protocol ['udp', 'tcp'] (default udp)
dns
string
DNS lookup method ['auto','doh','system'] (default auto)
proxy_all_outbound
boolean
Proxy all outbound traffic through files.com proxy server
endpoint_override
string
Custom site endpoint URL
log_file
string
Log file name and location
log_level
string
Log level for the agent logs ['debug', 'info', 'warn', 'error', 'fatal'] (default info)
log_rotate_num
int64
Log route for agent logs. (default 5)
log_rotate_size
int64
Log route size in MB for agent logs. (default 20)
override_max_concurrent_jobs
int64
Maximum number of concurrent jobs (default 500)
graceful_shutdown_timeout
int64
Graceful shutdown timeout in seconds (default 15)
transfer_rate_limit
string
File transfer (upload/download) rate limit
<limit>-<period>, with the given periods:
* 'S': second
* 'M': minute
* 'H': hour
* 'D': day
Examples:
* 5 requests/second: '5-S'
* 10 requests/minute: '10-M'
* 1000 requests/hour: '1000-H'
* 2000 requests/day: '2000-D'
auto_update_policy
string
Auto update policy ['manual_trigger', 'critical_only', 'always', 'never'] (default always)
api_token
string
Files Agent API Token
port
int64
Incoming port for files agent connections
hostname
string
public_key
string
public key
status
string
either running or shutdown
server_host_key
string
config_version
string
agent config version