@shelby-protocol/sdk 0.0.9 → 0.2.0

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.
Files changed (99) hide show
  1. package/dist/browser/index.d.ts +17 -10
  2. package/dist/browser/index.mjs +89 -28
  3. package/dist/{chunk-XWAPNLU6.mjs → chunk-2WEX3K7C.mjs} +6 -4
  4. package/dist/chunk-4MG4XGY4.mjs +91 -0
  5. package/dist/{chunk-SEXQTDX6.mjs → chunk-4ZOFT75Q.mjs} +16 -2
  6. package/dist/{chunk-BTHSKDJR.mjs → chunk-7PN65RDX.mjs} +44 -10
  7. package/dist/chunk-AABBONAF.mjs +34 -0
  8. package/dist/{chunk-ZPW742E7.mjs → chunk-AUQDI5BS.mjs} +17 -2
  9. package/dist/{chunk-HFGEQP5N.mjs → chunk-CGYJLKBU.mjs} +4 -4
  10. package/dist/chunk-CQ6QPIZK.mjs +37 -0
  11. package/dist/{chunk-VRLIOKWG.mjs → chunk-D6GQHO6G.mjs} +5 -1
  12. package/dist/chunk-E5QCRTBU.mjs +493 -0
  13. package/dist/chunk-HPPMI7DC.mjs +56 -0
  14. package/dist/chunk-IE6LYVIA.mjs +26 -0
  15. package/dist/{chunk-67F5YZ25.mjs → chunk-JTXYKO3U.mjs} +10 -0
  16. package/dist/{chunk-WJKSPJSS.mjs → chunk-KJ24NKPH.mjs} +46 -0
  17. package/dist/{chunk-WBFEX7OM.mjs → chunk-MV6FNYAU.mjs} +31 -7
  18. package/dist/{chunk-PZF2VTGP.mjs → chunk-NHWWORCH.mjs} +3 -1
  19. package/dist/{chunk-NLPIHQ7K.mjs → chunk-OGKZ575S.mjs} +6 -19
  20. package/dist/{chunk-5I3MBJGN.mjs → chunk-PJVWGMVI.mjs} +164 -35
  21. package/dist/{chunk-7UVMDCCR.mjs → chunk-SRV4YWFH.mjs} +232 -47
  22. package/dist/chunk-W37FZSMA.mjs +83 -0
  23. package/dist/chunk-WTICJPDB.mjs +0 -0
  24. package/dist/chunk-Z4FZ7W6L.mjs +39 -0
  25. package/dist/{chunk-QFWQ7FIC.mjs → chunk-ZEDD2MPU.mjs} +1 -1
  26. package/dist/{clay-codes-pdZFxI_B.d.ts → clay-codes-DHP-bYcP.d.ts} +6 -2
  27. package/dist/core/blobs.d.ts +2 -0
  28. package/dist/core/chunk.d.ts +10 -1
  29. package/dist/core/chunk.mjs +2 -2
  30. package/dist/core/clients/ShelbyBlobClient.d.ts +165 -12
  31. package/dist/core/clients/ShelbyBlobClient.mjs +13 -11
  32. package/dist/core/clients/ShelbyClient.d.ts +21 -4
  33. package/dist/core/clients/ShelbyClient.mjs +17 -14
  34. package/dist/core/clients/ShelbyClientConfig.d.ts +7 -2
  35. package/dist/{node → core}/clients/ShelbyMetadataClient.d.ts +3 -3
  36. package/dist/core/clients/ShelbyMetadataClient.mjs +9 -0
  37. package/dist/core/clients/ShelbyMicropaymentChannelClient.d.ts +349 -0
  38. package/dist/core/clients/ShelbyMicropaymentChannelClient.mjs +16 -0
  39. package/dist/core/clients/ShelbyPlacementGroupClient.d.ts +73 -0
  40. package/dist/core/clients/ShelbyPlacementGroupClient.mjs +11 -0
  41. package/dist/core/clients/ShelbyRPCClient.d.ts +30 -4
  42. package/dist/core/clients/ShelbyRPCClient.mjs +8 -8
  43. package/dist/core/clients/index.d.ts +11 -5
  44. package/dist/core/clients/index.mjs +35 -15
  45. package/dist/core/clients/utils.d.ts +54 -0
  46. package/dist/core/clients/utils.mjs +1 -1
  47. package/dist/core/commitments.d.ts +6 -2
  48. package/dist/core/commitments.mjs +5 -3
  49. package/dist/core/constants.d.ts +18 -3
  50. package/dist/core/constants.mjs +5 -1
  51. package/dist/core/erasure/clay-codes.d.ts +1 -1
  52. package/dist/core/erasure/clay-codes.mjs +5 -5
  53. package/dist/core/erasure/constants.d.ts +15 -3
  54. package/dist/core/erasure/constants.mjs +3 -1
  55. package/dist/core/erasure/default.d.ts +5 -2
  56. package/dist/core/erasure/default.mjs +12 -6
  57. package/dist/core/erasure/index.d.ts +3 -3
  58. package/dist/core/erasure/index.mjs +15 -7
  59. package/dist/core/erasure/provider.d.ts +1 -1
  60. package/dist/core/erasure/reed-solomon.d.ts +1 -1
  61. package/dist/core/erasure/reed-solomon.mjs +1 -1
  62. package/dist/core/erasure/utils.d.ts +1 -1
  63. package/dist/core/errors.d.ts +58 -0
  64. package/dist/core/errors.mjs +15 -0
  65. package/dist/core/index.d.ts +17 -10
  66. package/dist/core/index.mjs +89 -28
  67. package/dist/core/layout.d.ts +5 -16
  68. package/dist/core/layout.mjs +3 -9
  69. package/dist/core/networks.d.ts +1 -1
  70. package/dist/core/networks.mjs +1 -1
  71. package/dist/core/operations/generated/sdk.d.ts +207 -17
  72. package/dist/core/operations/generated/sdk.mjs +7 -1
  73. package/dist/core/operations/index.d.ts +9 -3
  74. package/dist/core/operations/index.mjs +10 -4
  75. package/dist/core/rpc-responses.d.ts +69 -0
  76. package/dist/core/rpc-responses.mjs +15 -0
  77. package/dist/core/types/blobs.d.ts +8 -4
  78. package/dist/core/types/encodings.d.ts +1 -1
  79. package/dist/core/types/index.d.ts +4 -2
  80. package/dist/core/types/index.mjs +12 -2
  81. package/dist/core/types/payments.d.ts +94 -0
  82. package/dist/core/types/payments.mjs +9 -0
  83. package/dist/core/types/placement_groups.d.ts +30 -1
  84. package/dist/core/types/placement_groups.mjs +1 -0
  85. package/dist/core/types/storage_providers.d.ts +32 -2
  86. package/dist/node/clients/ShelbyNodeClient.d.ts +9 -6
  87. package/dist/node/clients/ShelbyNodeClient.mjs +18 -15
  88. package/dist/node/clients/index.d.ts +7 -6
  89. package/dist/node/clients/index.mjs +19 -17
  90. package/dist/node/index.d.ts +17 -11
  91. package/dist/node/index.mjs +91 -34
  92. package/package.json +3 -2
  93. package/dist/chunk-CPNZAQVY.mjs +0 -29
  94. package/dist/chunk-GY5DCVVL.mjs +0 -86
  95. package/dist/chunk-RBFWGDMY.mjs +0 -30
  96. package/dist/node/clients/ShelbyMetadataClient.mjs +0 -9
  97. /package/dist/{chunk-DJJD2AXO.mjs → chunk-AD2G3QYD.mjs} +0 -0
  98. /package/dist/{chunk-MWDW4ROU.mjs → chunk-EM67QTMR.mjs} +0 -0
  99. /package/dist/{chunk-RNXGC54D.mjs → chunk-QQ57OGQ2.mjs} +0 -0
@@ -1,37 +1,72 @@
1
- import { Aptos, AccountAddress, AccountAddressInput, Account, InputGenerateTransactionOptions, PendingTransactionResponse, InputGenerateTransactionPayloadData } from '@aptos-labs/ts-sdk';
1
+ import { InputGenerateTransactionOptions, Aptos, AccountAddress, InputTransactionPluginData, AccountAddressInput, Account, PendingTransactionResponse, InputGenerateTransactionPayloadData } from '@aptos-labs/ts-sdk';
2
2
  import { BlobName } from '../layout.js';
3
3
  import { BlobMetadata, BlobActivity, StorageProviderAck } from '../types/blobs.js';
4
+ import { E as ErasureCodingConfig } from '../../clay-codes-DHP-bYcP.js';
4
5
  import { ShelbyIndexerClient } from '../operations/index.js';
5
6
  import { Blobs_Order_By, Blobs_Bool_Exp, Blob_Activities_Bool_Exp, Blob_Activities_Order_By } from '../operations/generated/sdk.js';
6
7
  import { ShelbyClientConfig } from './ShelbyClientConfig.js';
7
8
  import 'zod';
8
- import '../../clay-codes-pdZFxI_B.js';
9
9
  import '@shelby-protocol/clay-codes';
10
10
  import 'graphql-request';
11
11
  import 'graphql';
12
12
  import '../networks.js';
13
13
 
14
+ /**
15
+ * Error thrown when USD sponsorship is configured without a transaction submitter.
16
+ * USD sponsorship requires a transaction submitter because the sponsored transaction
17
+ * is a multi-agent transaction that must be co-signed by the sponsor.
18
+ */
19
+ declare class MissingTransactionSubmitterError extends Error {
20
+ constructor();
21
+ }
22
+ interface BuildOptions {
23
+ options?: InputGenerateTransactionOptions;
24
+ withFeePayer?: boolean;
25
+ }
26
+ interface UsdSponsorOptions {
27
+ /**
28
+ * This should be provided by your gas station provider (e.g. Geomi) after you create
29
+ * a gas station.
30
+ */
31
+ feePayerAddress: AccountAddress;
32
+ }
14
33
  interface WriteBlobCommitmentsOptions {
15
- build?: {
16
- options?: InputGenerateTransactionOptions;
17
- };
34
+ build?: BuildOptions;
35
+ submit?: InputTransactionPluginData;
36
+ /**
37
+ * Whereas build.withFeePayer corresponds to regular APT fee sponsorship, this refers
38
+ * to the Shelby-specific fees in stables. If set, we will use the sponsored variants
39
+ * of the various entry functions, e.g. register_blob_with_sponsor rather than
40
+ * register_blob. Aptos right now requires that the payload includes the address of
41
+ * the second signer when it is initially built, so you must provide the fee payer
42
+ * address of your gas station.
43
+ *
44
+ * These payloads by definition must be signed by the sponsor as well, so you must
45
+ * also configure a `transactionSubmitter` in your Aptos client's pluginSettings
46
+ * (via `aptos.pluginSettings.TRANSACTION_SUBMITTER`) that sends the transaction to
47
+ * an intermediate service (like a gas station) that co-signs the transaction.
48
+ *
49
+ * If `usdSponsor` is provided without a transaction submitter configured, an error
50
+ * will be thrown.
51
+ */
52
+ usdSponsor?: UsdSponsorOptions;
18
53
  chunksetSizeBytes?: number;
19
54
  }
20
55
  interface AckTransactionOptions {
21
- build?: {
22
- options?: InputGenerateTransactionOptions;
23
- };
56
+ build?: BuildOptions;
24
57
  }
25
58
  declare class ShelbyBlobClient {
26
59
  readonly aptos: Aptos;
27
60
  readonly deployer: AccountAddress;
28
61
  readonly indexer: ShelbyIndexerClient;
62
+ readonly defaultOptions: WriteBlobCommitmentsOptions;
29
63
  /**
30
64
  * The ShelbyBlobClient is used to interact with the Shelby contract on the Aptos blockchain. This
31
65
  * includes functions for registering blob commitments and retrieving blob metadata.
32
66
  *
33
67
  * @param config - The client configuration object.
34
68
  * @param config.network - The Shelby network to use.
69
+ * @param defaultOptions - Optional default options for blob operations.
35
70
  *
36
71
  * @example
37
72
  * ```typescript
@@ -44,8 +79,37 @@ declare class ShelbyBlobClient {
44
79
  * },
45
80
  * });
46
81
  * ```
82
+ *
83
+ * @example
84
+ * ```typescript
85
+ * // With default options for USD sponsorship
86
+ * const blobClient = new ShelbyBlobClient(
87
+ * {
88
+ * network: Network.SHELBYNET,
89
+ * aptos: {
90
+ * pluginSettings: {
91
+ * TRANSACTION_SUBMITTER: myGasStationSubmitter,
92
+ * },
93
+ * },
94
+ * },
95
+ * {
96
+ * usdSponsor: { feePayerAddress: sponsorAddress },
97
+ * }
98
+ * );
99
+ * ```
100
+ */
101
+ constructor(config: ShelbyClientConfig, defaultOptions?: WriteBlobCommitmentsOptions);
102
+ /**
103
+ * Merges method-level options with default options, giving precedence to method-level values.
47
104
  */
48
- constructor(config: ShelbyClientConfig);
105
+ private mergeOptions;
106
+ /**
107
+ * Validates that if USD sponsorship is requested, a transaction submitter is
108
+ * configured as well. Checks both the client-level and method-level transaction
109
+ * submitter configurations. Throws MissingTransactionSubmitterError if usdSponsor is
110
+ * provided without a transaction submitter.
111
+ */
112
+ private validateUsdSponsorConfig;
49
113
  /**
50
114
  * Retrieves the blob metadata from the blockchain. If it does not exist,
51
115
  * returns `undefined`.
@@ -186,10 +250,70 @@ declare class ShelbyBlobClient {
186
250
  blobMerkleRoot: string;
187
251
  size: number;
188
252
  expirationMicros: number;
253
+ config?: ErasureCodingConfig;
189
254
  options?: WriteBlobCommitmentsOptions;
190
255
  }): Promise<{
191
256
  transaction: PendingTransactionResponse;
192
257
  }>;
258
+ /**
259
+ * Deletes a blob on the blockchain.
260
+ *
261
+ * @param params.account - The account that is signing and paying for the transaction.
262
+ * @param params.blobName - The name/path of the blob (e.g. "foo/bar.txt").
263
+ * @param params.options - Optional transaction building options.
264
+ *
265
+ * @returns An object containing the pending transaction.
266
+ *
267
+ * @example
268
+ * ```typescript
269
+ *
270
+ * const { transaction } = await client.deleteBlob({
271
+ * account: signer,
272
+ * blobName: "foo/bar.txt",
273
+ * });
274
+ * ```
275
+ */
276
+ deleteBlob(params: {
277
+ account: Account;
278
+ blobName: BlobName;
279
+ options?: InputGenerateTransactionOptions;
280
+ }): Promise<{
281
+ transaction: PendingTransactionResponse;
282
+ }>;
283
+ /**
284
+ * Deletes multiple blobs on the blockchain in a single atomic transaction.
285
+ *
286
+ * **Note:** This function requires the `delete_multiple_blobs` entry function
287
+ * which will be deployed to the smart contract on 2026-02-04. Using this
288
+ * function before that date will result in a transaction failure.
289
+ *
290
+ * This operation is atomic: if any blob deletion fails (e.g., blob not found),
291
+ * the entire transaction fails and no blobs are deleted.
292
+ *
293
+ * @param params.account - The account that is signing and paying for the transaction.
294
+ * @param params.blobNames - Array of blob name suffixes without the account address prefix
295
+ * (e.g. ["foo/bar.txt", "baz.txt"], NOT ["0x1/foo/bar.txt"]). The account address
296
+ * prefix is automatically derived from the signer.
297
+ * @param params.options - Optional transaction building options.
298
+ *
299
+ * @returns An object containing the pending transaction.
300
+ *
301
+ * @example
302
+ * ```typescript
303
+ *
304
+ * const { transaction } = await client.deleteMultipleBlobs({
305
+ * account: signer,
306
+ * blobNames: ["foo/bar.txt", "baz.txt"],
307
+ * });
308
+ * ```
309
+ */
310
+ deleteMultipleBlobs(params: {
311
+ account: Account;
312
+ blobNames: BlobName[];
313
+ options?: InputGenerateTransactionOptions;
314
+ }): Promise<{
315
+ transaction: PendingTransactionResponse;
316
+ }>;
193
317
  /**
194
318
  * Acks the blob chunksets on-chain. If each chunkset meets the necessary threshold, the entire blob will be marked as written.
195
319
  *
@@ -267,6 +391,7 @@ declare class ShelbyBlobClient {
267
391
  blobSize: number;
268
392
  blobMerkleRoot: string;
269
393
  }[];
394
+ config?: ErasureCodingConfig;
270
395
  options?: WriteBlobCommitmentsOptions;
271
396
  }): Promise<{
272
397
  transaction: PendingTransactionResponse;
@@ -295,6 +420,8 @@ declare class ShelbyBlobClient {
295
420
  blobMerkleRoot: string;
296
421
  expirationMicros: number;
297
422
  numChunksets: number;
423
+ useSponsoredUsdVariant?: boolean;
424
+ encoding: number;
298
425
  }): InputGenerateTransactionPayloadData;
299
426
  /**
300
427
  * Creates a transaction payload to register multiple blobs on the blockchain.
@@ -323,13 +450,15 @@ declare class ShelbyBlobClient {
323
450
  blobMerkleRoot: string;
324
451
  numChunksets: number;
325
452
  }[];
453
+ useSponsoredUsdVariant?: boolean;
454
+ encoding: number;
326
455
  }): InputGenerateTransactionPayloadData;
327
456
  /**
328
457
  * Creates a transaction payload to delete a blob on the blockchain.
329
458
  * This is a static helper method for constructing the Move function call payload.
330
459
  *
331
460
  * @param params.deployer - Optional deployer account address. Defaults to SHELBY_DEPLOYER.
332
- * @param params.blobNameSuffix - The blob name suffix (e.g. "bar.txt").
461
+ * @param params.blobName - The blob name (e.g. "bar.txt", without the account address prefix).
333
462
  *
334
463
  * @returns An Aptos transaction payload data object for the delete_blob Move function.
335
464
  *
@@ -337,7 +466,31 @@ declare class ShelbyBlobClient {
337
466
  */
338
467
  static createDeleteBlobPayload(params: {
339
468
  deployer?: AccountAddress;
340
- blobNameSuffix: string;
469
+ blobName: string;
470
+ }): InputGenerateTransactionPayloadData;
471
+ /**
472
+ * Creates a transaction payload to delete multiple blobs on the blockchain.
473
+ * This is a static helper method for constructing the Move function call payload.
474
+ *
475
+ * **Note:** This function requires the `delete_multiple_blobs` entry function
476
+ * which will be deployed to the smart contract on 2026-02-04. Using this
477
+ * function before that date will result in a transaction failure.
478
+ *
479
+ * This operation is atomic: if any blob deletion fails (e.g., blob not found),
480
+ * the entire transaction fails and no blobs are deleted.
481
+ *
482
+ * @param params.deployer - Optional deployer account address. Defaults to SHELBY_DEPLOYER.
483
+ * @param params.blobNames - Array of blob name suffixes without the account address prefix
484
+ * (e.g. ["foo/bar.txt", "baz.txt"], NOT ["0x1/foo/bar.txt"]). The account address
485
+ * prefix is automatically derived from the transaction sender.
486
+ *
487
+ * @returns An Aptos transaction payload data object for the delete_multiple_blobs Move function.
488
+ *
489
+ * @see https://github.com/shelby/shelby/blob/main/move/shelby_contract/sources/blob_metadata.move
490
+ */
491
+ static createDeleteMultipleBlobsPayload(params: {
492
+ deployer?: AccountAddress;
493
+ blobNames: string[];
341
494
  }): InputGenerateTransactionPayloadData;
342
495
  static createChunksetAcknowledgementsPayload(params: {
343
496
  blobOwner: AccountAddress;
@@ -348,4 +501,4 @@ declare class ShelbyBlobClient {
348
501
  }): InputGenerateTransactionPayloadData;
349
502
  }
350
503
 
351
- export { type AckTransactionOptions, ShelbyBlobClient, type WriteBlobCommitmentsOptions };
504
+ export { type AckTransactionOptions, type BuildOptions, MissingTransactionSubmitterError, ShelbyBlobClient, type UsdSponsorOptions, type WriteBlobCommitmentsOptions };
@@ -1,20 +1,22 @@
1
1
  import {
2
+ MissingTransactionSubmitterError,
2
3
  ShelbyBlobClient
3
- } from "../../chunk-7UVMDCCR.mjs";
4
+ } from "../../chunk-SRV4YWFH.mjs";
4
5
  import "../../chunk-XNEIWM4O.mjs";
5
- import "../../chunk-CPNZAQVY.mjs";
6
- import "../../chunk-NLPIHQ7K.mjs";
7
- import "../../chunk-PZF2VTGP.mjs";
8
- import "../../chunk-HFGEQP5N.mjs";
9
- import "../../chunk-WJKSPJSS.mjs";
10
- import "../../chunk-RBFWGDMY.mjs";
6
+ import "../../chunk-HPPMI7DC.mjs";
7
+ import "../../chunk-OGKZ575S.mjs";
8
+ import "../../chunk-NHWWORCH.mjs";
9
+ import "../../chunk-CGYJLKBU.mjs";
10
+ import "../../chunk-KJ24NKPH.mjs";
11
+ import "../../chunk-AABBONAF.mjs";
11
12
  import "../../chunk-OTBLZL2S.mjs";
12
- import "../../chunk-XWAPNLU6.mjs";
13
+ import "../../chunk-2WEX3K7C.mjs";
13
14
  import "../../chunk-4JZO2D7T.mjs";
14
- import "../../chunk-67F5YZ25.mjs";
15
- import "../../chunk-ZPW742E7.mjs";
16
- import "../../chunk-SEXQTDX6.mjs";
15
+ import "../../chunk-JTXYKO3U.mjs";
16
+ import "../../chunk-AUQDI5BS.mjs";
17
+ import "../../chunk-4ZOFT75Q.mjs";
17
18
  import "../../chunk-7P6ASYW6.mjs";
18
19
  export {
20
+ MissingTransactionSubmitterError,
19
21
  ShelbyBlobClient
20
22
  };
@@ -1,18 +1,21 @@
1
- import { WriteBlobCommitmentsOptions, ShelbyBlobClient } from './ShelbyBlobClient.js';
2
1
  import { Aptos, Account, AccountAddressInput } from '@aptos-labs/ts-sdk';
3
2
  import { ShelbyBlob } from '../blobs.js';
4
- import { a as ErasureCodingProvider } from '../../clay-codes-pdZFxI_B.js';
3
+ import { a as ErasureCodingProvider } from '../../clay-codes-DHP-bYcP.js';
5
4
  import { BlobName } from '../layout.js';
5
+ import { WriteBlobCommitmentsOptions, ShelbyBlobClient } from './ShelbyBlobClient.js';
6
6
  import { ShelbyClientConfig } from './ShelbyClientConfig.js';
7
+ import { ShelbyMetadataClient } from './ShelbyMetadataClient.js';
7
8
  import { ShelbyRPCClient } from './ShelbyRPCClient.js';
8
- import '../types/blobs.js';
9
- import '@shelby-protocol/clay-codes';
10
9
  import 'zod';
10
+ import '@shelby-protocol/clay-codes';
11
+ import '../types/blobs.js';
11
12
  import '../operations/index.js';
12
13
  import 'graphql-request';
13
14
  import '../operations/generated/sdk.js';
14
15
  import 'graphql';
15
16
  import '../networks.js';
17
+ import '../types/storage_providers.js';
18
+ import '../types/payments.js';
16
19
 
17
20
  type UploadOptions = WriteBlobCommitmentsOptions;
18
21
  declare class ShelbyClient {
@@ -21,6 +24,10 @@ declare class ShelbyClient {
21
24
  * and metadata for blobs.
22
25
  */
23
26
  readonly coordination: ShelbyBlobClient;
27
+ /**
28
+ * The metadata client is used for protocol-level metadata queries.
29
+ */
30
+ readonly metadata: ShelbyMetadataClient;
24
31
  /**
25
32
  * The RPC client is used to interact with the Shelby RPC node which can be responsible for storing,
26
33
  * confirming, and retrieving blobs from the storage layer.
@@ -83,6 +90,11 @@ declare class ShelbyClient {
83
90
  * This method handles the complete upload flow including commitment generation,
84
91
  * blockchain registration, and storage upload.
85
92
  *
93
+ * Note: This method accepts only `Uint8Array` and buffers the entire blob in memory.
94
+ * For streaming uploads of large files (e.g. >2 GiB), orchestrate the steps manually
95
+ * using `generateCommitments()`, `coordination.registerBlob()`, and `rpc.putBlob()`
96
+ * with a `ReadableStream`.
97
+ *
86
98
  * @param params.blobData - The raw data to upload as a Uint8Array.
87
99
  * @param params.signer - The account that signs and pays for the transaction.
88
100
  * @param params.blobName - The name/path of the blob (e.g. "folder/file.txt").
@@ -115,6 +127,11 @@ declare class ShelbyClient {
115
127
  * This method handles the complete upload flow including commitment generation,
116
128
  * blockchain registration, and storage upload.
117
129
  *
130
+ * Note: This method accepts only `Uint8Array` and buffers each blob in memory.
131
+ * For streaming uploads of large files, orchestrate the steps manually using
132
+ * `generateCommitments()`, `coordination.registerBlob()`, and `rpc.putBlob()`
133
+ * with a `ReadableStream`.
134
+ *
118
135
  * @param params.blobs - The blobs to upload.
119
136
  * @param params.blobs.blobData - The raw data to upload as a Uint8Array.
120
137
  * @param params.blobs.blobName - The name/path of the blob (e.g. "folder/file.txt").
@@ -1,23 +1,26 @@
1
1
  import {
2
2
  ShelbyClient
3
- } from "../../chunk-BTHSKDJR.mjs";
4
- import "../../chunk-7UVMDCCR.mjs";
3
+ } from "../../chunk-7PN65RDX.mjs";
4
+ import "../../chunk-SRV4YWFH.mjs";
5
5
  import "../../chunk-XNEIWM4O.mjs";
6
- import "../../chunk-CPNZAQVY.mjs";
7
- import "../../chunk-NLPIHQ7K.mjs";
8
- import "../../chunk-PZF2VTGP.mjs";
9
- import "../../chunk-5I3MBJGN.mjs";
10
- import "../../chunk-HFGEQP5N.mjs";
11
- import "../../chunk-WJKSPJSS.mjs";
12
- import "../../chunk-GY5DCVVL.mjs";
6
+ import "../../chunk-HPPMI7DC.mjs";
7
+ import "../../chunk-OGKZ575S.mjs";
8
+ import "../../chunk-NHWWORCH.mjs";
9
+ import "../../chunk-MV6FNYAU.mjs";
10
+ import "../../chunk-PJVWGMVI.mjs";
11
+ import "../../chunk-4MG4XGY4.mjs";
12
+ import "../../chunk-CGYJLKBU.mjs";
13
+ import "../../chunk-KJ24NKPH.mjs";
14
+ import "../../chunk-AABBONAF.mjs";
13
15
  import "../../chunk-I6NG5GNL.mjs";
14
- import "../../chunk-RBFWGDMY.mjs";
16
+ import "../../chunk-IE6LYVIA.mjs";
15
17
  import "../../chunk-OTBLZL2S.mjs";
16
- import "../../chunk-XWAPNLU6.mjs";
18
+ import "../../chunk-2WEX3K7C.mjs";
17
19
  import "../../chunk-4JZO2D7T.mjs";
18
- import "../../chunk-67F5YZ25.mjs";
19
- import "../../chunk-ZPW742E7.mjs";
20
- import "../../chunk-SEXQTDX6.mjs";
20
+ import "../../chunk-JTXYKO3U.mjs";
21
+ import "../../chunk-AUQDI5BS.mjs";
22
+ import "../../chunk-4ZOFT75Q.mjs";
23
+ import "../../chunk-Z4FZ7W6L.mjs";
21
24
  import "../../chunk-7P6ASYW6.mjs";
22
25
  export {
23
26
  ShelbyClient
@@ -42,8 +42,13 @@ interface ShelbyClientConfig {
42
42
  rpc?: ShelbyRPCConfig;
43
43
  /** An optional indexer configuration for GraphQL queries. If not provided, the default indexer will be used. */
44
44
  indexer?: ShelbyIndexerConfig;
45
- /** An optional faucet URL for funding accounts. If not provided, the default faucet will be used. */
46
- faucet?: string;
45
+ /** An optional faucet configuration. */
46
+ faucet?: {
47
+ /** An optional faucet URL for funding accounts. If not provided, the default faucet will be used. */
48
+ baseUrl?: string;
49
+ /** Auth token for the faucet endpoint. */
50
+ authToken?: string;
51
+ };
47
52
  }
48
53
 
49
54
  export type { ShelbyClientConfig, ShelbyIndexerConfig, ShelbyRPCConfig };
@@ -1,7 +1,7 @@
1
1
  import { Aptos, AccountAddress, AccountAddressInput } from '@aptos-labs/ts-sdk';
2
- import { ShelbyClientConfig } from '../../core/clients/ShelbyClientConfig.js';
3
- import { StorageProviderInfo } from '../../core/types/storage_providers.js';
4
- import '../../core/networks.js';
2
+ import { StorageProviderInfo } from '../types/storage_providers.js';
3
+ import { ShelbyClientConfig } from './ShelbyClientConfig.js';
4
+ import '../networks.js';
5
5
 
6
6
  declare class ShelbyMetadataClient {
7
7
  readonly aptos: Aptos;
@@ -0,0 +1,9 @@
1
+ import {
2
+ ShelbyMetadataClient
3
+ } from "../../chunk-MV6FNYAU.mjs";
4
+ import "../../chunk-AABBONAF.mjs";
5
+ import "../../chunk-4ZOFT75Q.mjs";
6
+ import "../../chunk-7P6ASYW6.mjs";
7
+ export {
8
+ ShelbyMetadataClient
9
+ };