# Types.SplitDocumentPayload

Input type describing a file to split and where the resulting parts land.

> Kind: Apex type · Updated: 2026-07-01

Custom Apex type representing one input entry for Client.splitDocument(). Each payload identifies the source file, the drive and storage library it lives in, and the Resource destination where the split parts are written, with optional AI instructions and a context identifier for traceability.

## Fields

### Fields
| Parameter | Type | Required | Description |
|---|---|---|---|
| fileId | String | required | The unique Resource Id of the file in the external storage that will be processed. |
| driveId | String | required | The Id of the connected drive where the file is located (required for Google Drive and SharePoint). |
| library | String | required | The external storage type, e.g., sharepoint, google, azure, onedrive, dropbox, box, or cloudfiles (AWS S3). |
| destination | <a href="#/apex-type-resource">Resource</a> | required | The target external location where the splitted file will be stored (includes library, driveId, and folder/location Id). |
| instructions | String | optional | Optional AI guidance for processing the document, improving accuracy for non-standard formats. |
| context | String | optional | Optional identifier to track the source or purpose of the action, enabling event traceability. |

## Constructors

```apex
global SplitDocumentPayload(
  String fileId,
  String driveId,
  String library,
  Resource destination,
  String context
)
```

```apex
global SplitDocumentPayload(
  String fileId,
  String driveId,
  String library,
  Resource destination,
  String instructions,
  String context
)
```
