Package se.idkollen.client.endpoints
Class DocumentEndpoint
java.lang.Object
se.idkollen.client.endpoints.DocumentEndpoint
Endpoint for document upload and download operations.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondeleteAsync(String id) Delete a previously uploaded document.CompletableFuture<byte[]>downloadAsync(String id) Download a previously uploaded or signed document.uploadAsync(byte[] bytes, String filename) Upload a document with the default MIME typeapplication/pdf.uploadAsync(byte[] bytes, String filename, String mimeType) Upload a document for use in signing sessions.
-
Constructor Details
-
DocumentEndpoint
-
-
Method Details
-
uploadAsync
public CompletableFuture<DocumentUploadResponse> uploadAsync(byte[] bytes, String filename, String mimeType) Upload a document for use in signing sessions.- Parameters:
bytes- Raw file bytes.filename- File name sent in the multipart form.mimeType- MIME type of the file.- Returns:
- Upload response containing the document UUID and hash.
-
uploadAsync
Upload a document with the default MIME typeapplication/pdf. -
downloadAsync
Download a previously uploaded or signed document.- Returns:
- Raw file bytes.
-
deleteAsync
Delete a previously uploaded document.
-