@sparkvault/sdk-js 9.2.0 → 9.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +95 -20
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +95 -20
- package/dist/index.mjs.map +1 -1
- package/dist/sparkvault.js +1 -1
- package/dist/sparkvault.js.map +1 -1
- package/dist/vaults/upload/api.d.ts +12 -0
- package/package.json +1 -1
|
@@ -52,6 +52,18 @@ export declare class UploadApi extends SparkVaultApi {
|
|
|
52
52
|
* finalization via {@link verifyUploadFinalized} before reporting success.
|
|
53
53
|
*/
|
|
54
54
|
uploadFileToForge(file: File | Blob, forgeUrl: string, onProgress?: (bytesUploaded: number, bytesTotal: number) => void): Promise<string>;
|
|
55
|
+
/**
|
|
56
|
+
* Confirm the server finalized a fully received upload.
|
|
57
|
+
*
|
|
58
|
+
* The server persists the session's final offset BEFORE it finalizes, so an
|
|
59
|
+
* offset read from a resume HEAD can equal the file size while finalization
|
|
60
|
+
* failed or is still running — treating that offset as success would report
|
|
61
|
+
* a stored file whose ingot was never published. The zero-length PATCH at
|
|
62
|
+
* the final offset is the server's finalization re-drive: it answers 2xx
|
|
63
|
+
* only once finalization has actually completed, the same receipt a
|
|
64
|
+
* successful final chunk carries.
|
|
65
|
+
*/
|
|
66
|
+
private confirmServerFinalized;
|
|
55
67
|
/**
|
|
56
68
|
* Read the offset a failed chunk should resume from.
|
|
57
69
|
*
|