Pending Work Events

A PendingWorkEvent is a log record for pending file work failures, such as GPG Encryption and GPG Decryption.

List Pending Work Events

SDK Function

PendingWorkEvent.list()

Return Object

ListIterator<PendingWorkEvent>

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.PendingWorkEvent;

try {
  HashMap<String, Object> parameters = new HashMap<>();
  ListIterator<PendingWorkEvent> pendingWorkEvents = PendingWorkEvent.list(parameters);
  for (PendingWorkEvent pendingWorkEvent : pendingWorkEvents.listAutoPaging()) {
    // Operate on pendingWorkEvent
  }
} 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 Pending Work Event

SDK Function

PendingWorkEvent.find()

Return Object

PendingWorkEvent

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
Pending Work Event ID.

Example Request

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

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

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

AttributeDescription
id
int64
Event ID
event_type
string
Type of pending work event being recorded.
status
string
Status of event.
Possible values: success, failure, partial_failure, in_progress, skipped
body
string
Event body.
event_errors
array(string)
Event errors.
created_at
date-time
Event create date/time.
body_url
string
Link to log file.
folder_behavior_id
int64
Folder Behavior ID.