External Events

An ExternalEvent is a log that is sent to the cloud from a client application such as the Files.com CLI.

List External Events

SDK Function

ExternalEvent.list()

Return Object

ListIterator<ExternalEvent>

Authorization Requirement

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

Additional Arguments

Example Request

import com.files.ListIterator;
import com.files.exceptions.*;
import com.files.exceptions.ApiErrorException.*;
import com.files.models.ExternalEvent;

try {
  HashMap<String, Object> parameters = new HashMap<>();
  ListIterator<ExternalEvent> externalEvents = ExternalEvent.list(parameters);
  for (ExternalEvent externalEvent : externalEvents.listAutoPaging()) {
    // Operate on externalEvent
  }
} 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());
}

Show External Event

SDK Function

ExternalEvent.find()

Return Object

ExternalEvent

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
External Event ID.

Example Request

import com.files.exceptions.*;
import com.files.exceptions.ApiErrorException.*;
import com.files.models.ExternalEvent;

try {
  HashMap<String, Object> parameters = new HashMap<>();
  ExternalEvent externalEvent = ExternalEvent.find(id, parameters);
  // Operate on externalEvent
} 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());
}

Create External Event

SDK Function

ExternalEvent.create()

Return Object

ExternalEvent

Authorization Requirement

Available to all authenticated keys or sessions.

Function Arguments

ArgumentDescription
status
string
Required
Status of event.
Possible values: success, failure, partial_failure, in_progress, skipped
body
string
Required
Event body

Example Request

import com.files.exceptions.*;
import com.files.exceptions.ApiErrorException.*;
import com.files.models.ExternalEvent;

try {
  HashMap<String, Object> parameters = new HashMap<>();
  parameters.put("status", "example");
  parameters.put("body", "example");
  
  ExternalEvent externalEvent = ExternalEvent.create(parameters);
  // Operate on externalEvent
} 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 ExternalEvent Object

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

AttributeDescription
id
int64
Event ID
event_type
string
Type of event being recorded.
Possible values: ldap_sync, remote_server_sync, lockout, ldap_login, saml_login, client_log, pending_work, siem_http_destination
status
string
Status of event.
Possible values: success, failure, partial_failure, in_progress, skipped
body
string
Event body
created_at
date-time
External event create date/time
body_url
string
Link to log file.