Document Upload: Create
Parameters
.file(…)fileThe binary data of the file to upload. Only
png, jpg, jpeg, or pdf files are supported. The file must not exceed 4MB..kind(…)multipleThe type of uploaded document. Value should always be EVIDENCE_DOCUMENT.
Examples
- Java
DocumentUploadRequest uploadRequest = new DocumentUploadRequest(
DocumentUpload.Kind.EVIDENCE_DOCUMENT,
new File("local_file.pdf")
);
Result<documentupload> result = gateway.documentUpload().create(uploadRequest);
if (result.isSuccess()) {
// document successfully uploaded
DocumentUpload document = result.getTarget();
} else {
System.out.println(result.getErrors());
}