@provablehq/sdk 0.9.16-rc → 0.9.16

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 (65) hide show
  1. package/dist/mainnet/account.d.ts +18 -3
  2. package/dist/mainnet/browser.d.ts +20 -8
  3. package/dist/mainnet/browser.js +997 -266
  4. package/dist/mainnet/browser.js.map +1 -1
  5. package/dist/{testnet/keys/provider → mainnet}/function-key-provider.d.ts +15 -23
  6. package/dist/mainnet/models/cryptoBoxPubkey.d.ts +4 -0
  7. package/dist/mainnet/models/encryptedProvingRequest.d.ts +4 -0
  8. package/dist/mainnet/models/provingResponse.d.ts +48 -2
  9. package/dist/mainnet/models/record-scanner/encryptedRecordsResult.d.ts +7 -0
  10. package/dist/mainnet/models/record-scanner/encryptedRegistrationRequest.d.ts +8 -0
  11. package/dist/mainnet/models/record-scanner/error.d.ts +47 -0
  12. package/dist/mainnet/models/record-scanner/ownedFilter.d.ts +0 -2
  13. package/dist/mainnet/models/record-scanner/ownedRecordsResult.d.ts +13 -0
  14. package/dist/mainnet/models/record-scanner/registrationResponse.d.ts +0 -2
  15. package/dist/mainnet/models/record-scanner/registrationResult.d.ts +9 -0
  16. package/dist/mainnet/models/record-scanner/serialNumbersResult.d.ts +15 -0
  17. package/dist/mainnet/models/record-scanner/statusResult.d.ts +13 -0
  18. package/dist/mainnet/models/record-scanner/tagsResult.d.ts +12 -0
  19. package/dist/mainnet/network-client.d.ts +81 -35
  20. package/dist/mainnet/node.d.ts +0 -1
  21. package/dist/mainnet/node.js +2 -129
  22. package/dist/mainnet/node.js.map +1 -1
  23. package/dist/mainnet/{keys/provider/offline-key-provider.d.ts → offline-key-provider.d.ts} +3 -6
  24. package/dist/mainnet/program-manager.d.ts +53 -48
  25. package/dist/mainnet/record-provider.d.ts +7 -7
  26. package/dist/mainnet/record-scanner.d.ts +231 -31
  27. package/dist/mainnet/security.d.ts +38 -0
  28. package/dist/mainnet/utils.d.ts +1 -0
  29. package/dist/testnet/account.d.ts +18 -3
  30. package/dist/testnet/browser.d.ts +20 -8
  31. package/dist/testnet/browser.js +997 -266
  32. package/dist/testnet/browser.js.map +1 -1
  33. package/dist/{mainnet/keys/provider → testnet}/function-key-provider.d.ts +15 -23
  34. package/dist/testnet/models/cryptoBoxPubkey.d.ts +4 -0
  35. package/dist/testnet/models/encryptedProvingRequest.d.ts +4 -0
  36. package/dist/testnet/models/provingResponse.d.ts +48 -2
  37. package/dist/testnet/models/record-scanner/encryptedRecordsResult.d.ts +7 -0
  38. package/dist/testnet/models/record-scanner/encryptedRegistrationRequest.d.ts +8 -0
  39. package/dist/testnet/models/record-scanner/error.d.ts +47 -0
  40. package/dist/testnet/models/record-scanner/ownedFilter.d.ts +0 -2
  41. package/dist/testnet/models/record-scanner/ownedRecordsResult.d.ts +13 -0
  42. package/dist/testnet/models/record-scanner/registrationResponse.d.ts +0 -2
  43. package/dist/testnet/models/record-scanner/registrationResult.d.ts +9 -0
  44. package/dist/testnet/models/record-scanner/serialNumbersResult.d.ts +15 -0
  45. package/dist/testnet/models/record-scanner/statusResult.d.ts +13 -0
  46. package/dist/testnet/models/record-scanner/tagsResult.d.ts +12 -0
  47. package/dist/testnet/network-client.d.ts +81 -35
  48. package/dist/testnet/node.d.ts +0 -1
  49. package/dist/testnet/node.js +2 -129
  50. package/dist/testnet/node.js.map +1 -1
  51. package/dist/testnet/{keys/provider/offline-key-provider.d.ts → offline-key-provider.d.ts} +3 -6
  52. package/dist/testnet/program-manager.d.ts +53 -48
  53. package/dist/testnet/record-provider.d.ts +7 -7
  54. package/dist/testnet/record-scanner.d.ts +231 -31
  55. package/dist/testnet/security.d.ts +38 -0
  56. package/dist/testnet/utils.d.ts +1 -0
  57. package/package.json +3 -2
  58. package/dist/mainnet/keys/keystore/file.d.ts +0 -23
  59. package/dist/mainnet/keys/keystore/keystore.d.ts +0 -81
  60. package/dist/mainnet/keys/keystore/memory.d.ts +0 -8
  61. package/dist/mainnet/models/keyPair.d.ts +0 -4
  62. package/dist/testnet/keys/keystore/file.d.ts +0 -23
  63. package/dist/testnet/keys/keystore/keystore.d.ts +0 -81
  64. package/dist/testnet/keys/keystore/memory.d.ts +0 -8
  65. package/dist/testnet/models/keyPair.d.ts +0 -4
@@ -3,19 +3,18 @@ import { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports } from "./n
3
3
  import { ImportedPrograms, ImportedVerifyingKeys } from "./models/imports.js";
4
4
  import { RecordProvider } from "./record-provider.js";
5
5
  import { RecordSearchParams } from "./models/record-provider/recordSearchParams.js";
6
- import { FunctionKeyProvider, KeySearchParams } from "./keys/provider/function-key-provider";
7
- import { FunctionKeyPair } from "./models/keyPair";
6
+ import { FunctionKeyPair, FunctionKeyProvider, KeySearchParams } from "./function-key-provider.js";
8
7
  import { Authorization, ExecutionResponse, OfflineQuery, RecordPlaintext, PrivateKey, Program, ProvingKey, ProvingRequest, VerifyingKey, Transaction } from "./wasm.js";
9
8
  /**
10
9
  * Represents the options for deploying and upgrading a transaction in the Aleo network.
11
10
  * This interface is used to specify the parameters required for building and submitting an deployment transaction.
12
11
  *
13
12
  * @property {string} program - The program source code to be deployed.
14
- * @property {number} priorityFee - The optional priority fee to be paid for the transaction.
13
+ * @property {number} priorityFee - The priority fee to be paid for the transaction.
15
14
  * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.
16
- * @property {RecordSearchParams | undefined} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.
17
- * @property {string | RecordPlaintext | undefined} [feeRecord] - Optional fee record to use for the transaction.
18
- * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.
15
+ * @property {RecordSearchParams} [recordSearchParams] - Parameters for searching for a record to pay the execution transaction fee.
16
+ * @property {string | RecordPlaintext} [feeRecord] - Fee record to use for the transaction.
17
+ * @property {PrivateKey} [privateKey] - Private key to use for the transaction.
19
18
  */
20
19
  interface DeployOptions {
21
20
  program: string;
@@ -31,18 +30,19 @@ interface DeployOptions {
31
30
  *
32
31
  * @property {string} programName - The name of the program containing the function to be executed.
33
32
  * @property {string} functionName - The name of the function to execute within the program.
34
- * @property {number} priorityFee - The optional priority fee to be paid for the transaction.
33
+ * @property {number} priorityFee - The priority fee to be paid for the transaction.
35
34
  * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.
36
35
  * @property {string[]} inputs - The inputs to the function being executed.
37
- * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.
38
- * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.
39
- * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.
40
- * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.
41
- * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.
42
- * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.
43
- * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.
44
- * @property {string | Program} [program] - Optional program source code to use for the transaction.
45
- * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.
36
+ * @property {RecordSearchParams} [recordSearchParams] - Parameters for searching for a record to pay the execution transaction fee.
37
+ * @property {KeySearchParams} [keySearchParams] - Parameters for finding the matching proving & verifying keys for the function.
38
+ * @property {string | RecordPlaintext} [feeRecord] - Fee record to use for the transaction.
39
+ * @property {ProvingKey} [provingKey] - Proving key to use for the transaction.
40
+ * @property {VerifyingKey} [verifyingKey] - Verifying key to use for the transaction.
41
+ * @property {PrivateKey} [privateKey] - Private key to use for the transaction.
42
+ * @property {OfflineQuery} [offlineQuery] - Offline query if creating transactions in an offline environment.
43
+ * @property {string | Program} [program] - Program source code to use for the transaction.
44
+ * @property {ProgramImports} [imports] - Programs that the program being executed imports.
45
+ * @property {number} [edition] - Edition of the program to execute the function in.
46
46
  */
47
47
  interface ExecuteOptions {
48
48
  programName: string;
@@ -125,7 +125,8 @@ interface ExecuteAuthorizationOptions {
125
125
  *
126
126
  * @property {string} programName - The name of the program containing the function to be executed.
127
127
  * @property {string} functionName - The name of the function to execute within the program.
128
- * @property {number} baseFee - The base fee to be paid for the transaction.
128
+ * @property {number} [baseFee] - The base fee to be paid for the transaction.
129
+ * @deprecated Base fee is now estimated automatically; this option is ignored and will be removed in a future version.
129
130
  * @property {number} priorityFee - The optional priority fee to be paid for the transaction.
130
131
  * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.
131
132
  * @property {string[]} inputs - The inputs to the function being executed.
@@ -136,6 +137,9 @@ interface ExecuteAuthorizationOptions {
136
137
  * @property {string} uri - The URI send the ProvingRequest to.
137
138
  * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.
138
139
  * @property {boolean} broadcast - Whether to broadcast the Transaction generated by the remove prover to the Aleo network.
140
+ * @property {boolean} unchecked - Whether to execute the transaction without checking the validity of the authorization (faster but may fail).
141
+ * @property {number} [edition] - Edition of the program to execute the function in.
142
+ * @property {boolean} [useFeeMaster] - Whether to use the FeeMaster account to execute the transaction.
139
143
  */
140
144
  interface ProvingRequestOptions {
141
145
  programName: string;
@@ -152,6 +156,7 @@ interface ProvingRequestOptions {
152
156
  broadcast?: boolean;
153
157
  unchecked?: boolean;
154
158
  edition?: number;
159
+ useFeeMaster?: boolean;
155
160
  }
156
161
  /**
157
162
  * Fee estimate options.
@@ -226,7 +231,7 @@ declare class ProgramManager {
226
231
  * import { ProgramManager } from "@provablehq/sdk/mainnet.js";
227
232
  *
228
233
  * // Create a ProgramManager
229
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1");
234
+ * const programManager = new ProgramManager("https://api.provable.com/v2");
230
235
  *
231
236
  * // Set the value of the `Accept-Language` header to `en-US`
232
237
  * programManager.setHeader('Accept-Language', 'en-US');
@@ -245,7 +250,7 @@ declare class ProgramManager {
245
250
  * keyProvider.useCache(true);
246
251
  *
247
252
  * // Create a ProgramManager
248
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider);
253
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider);
249
254
  *
250
255
  * // Set the inclusion keys.
251
256
  * programManager.setInclusionProver();
@@ -260,7 +265,7 @@ declare class ProgramManager {
260
265
  * import { ProgramManager } from "@provablehq/sdk/mainnet.js";
261
266
  *
262
267
  * // Create a ProgramManager
263
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1");
268
+ * const programManager = new ProgramManager("https://api.provable.com/v2");
264
269
  *
265
270
  * // Remove the default `X-Aleo-SDK-Version` header
266
271
  * programManager.removeHeader('X-Aleo-SDK-Version');
@@ -288,7 +293,7 @@ declare class ProgramManager {
288
293
  *
289
294
  * // Initialize a program manager with the key provider to automatically fetch keys for deployments
290
295
  * const program = "program hello_hello.aleo;\n\nfunction hello:\n input r0 as u32.public;\n input r1 as u32.private;\n add r0 r1 into r2;\n output r2 as u32.private;\n";
291
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
296
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
292
297
  * programManager.setAccount(Account);
293
298
  *
294
299
  * // Define a fee in credits
@@ -321,7 +326,7 @@ declare class ProgramManager {
321
326
  *
322
327
  * // Initialize a program manager with the key provider to automatically fetch keys for deployments
323
328
  * const program = "program hello_hello.aleo;\n\nfunction hello:\n input r0 as u32.public;\n input r1 as u32.private;\n add r0 r1 into r2;\n output r2 as u32.private;\n";
324
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
329
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
325
330
  * programManager.setAccount(Account);
326
331
  *
327
332
  * // Define a fee in credits
@@ -360,7 +365,7 @@ declare class ProgramManager {
360
365
  *
361
366
  * // Initialize a program manager with the key provider to automatically fetch keys for deployments
362
367
  * const program = "program hello_hello.aleo;\n\nfunction hello:\n input r0 as u32.public;\n input r1 as u32.private;\n add r0 r1 into r2;\n output r2 as u32.private;\n";
363
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
368
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
364
369
  *
365
370
  * // Define a fee in credits
366
371
  * const priorityFee = 0.0;
@@ -391,7 +396,7 @@ declare class ProgramManager {
391
396
  * keyProvider.useCache(true);
392
397
  *
393
398
  * // Initialize a program manager with the key provider to automatically fetch keys for executions
394
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
399
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
395
400
  *
396
401
  * // Build and execute the transaction
397
402
  * const tx = await programManager.buildExecutionTransaction({
@@ -431,7 +436,7 @@ declare class ProgramManager {
431
436
  * keyProvider.useCache(true);
432
437
  *
433
438
  * // Initialize a program manager with the key provider to automatically fetch keys for executions.
434
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider);
439
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider);
435
440
  *
436
441
  * // Build the `Authorization`.
437
442
  * const privateKey = new PrivateKey(); // Change this to a private key that has an aleo credit balance.
@@ -500,7 +505,7 @@ declare class ProgramManager {
500
505
  * keyProvider.useCache(true);
501
506
  *
502
507
  * // Initialize a ProgramManager with the key and record providers.
503
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
508
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
504
509
  *
505
510
  * // Build the `Authorization`.
506
511
  * const authorization = await programManager.buildAuthorization({
@@ -529,7 +534,7 @@ declare class ProgramManager {
529
534
  * keyProvider.useCache(true);
530
535
  *
531
536
  * // Initialize a ProgramManager with the key and record providers.
532
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
537
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
533
538
  *
534
539
  * // Build the unchecked `Authorization`.
535
540
  * const authorization = await programManager.buildAuthorizationUnchecked({
@@ -558,7 +563,7 @@ declare class ProgramManager {
558
563
  * keyProvider.useCache(true);
559
564
  *
560
565
  * // Initialize a ProgramManager with the key and record providers.
561
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
566
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
562
567
  *
563
568
  * // Build the proving request.
564
569
  * const provingRequest = await programManager.provingRequest({
@@ -590,7 +595,7 @@ declare class ProgramManager {
590
595
  * keyProvider.useCache(true);
591
596
  *
592
597
  * // Initialize a ProgramManager with the key and record providers.
593
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
598
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
594
599
  *
595
600
  * // Build a credits.aleo/fee_public `Authorization`.
596
601
  * const feePublicAuthorization = await programManager.buildFeeAuthorization({
@@ -623,7 +628,7 @@ declare class ProgramManager {
623
628
  * keyProvider.useCache(true);
624
629
  *
625
630
  * // Initialize a program manager with the key provider to automatically fetch keys for executions
626
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
631
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
627
632
  *
628
633
  * // Build and execute the transaction
629
634
  * const tx_id = await programManager.execute({
@@ -698,7 +703,7 @@ declare class ProgramManager {
698
703
  * keyProvider.useCache(true);
699
704
  *
700
705
  * // Initialize a program manager with the key provider to automatically fetch keys for executions
701
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
706
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
702
707
  * const record_1 = "{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}"
703
708
  * const record_2 = "{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 1540945439182663264862696551825005342995406165131907382295858612069623286213group.public}"
704
709
  * const tx_id = await programManager.join(record_1, record_2, 0.05, false);
@@ -729,7 +734,7 @@ declare class ProgramManager {
729
734
  * keyProvider.useCache(true);
730
735
  *
731
736
  * // Initialize a program manager with the key provider to automatically fetch keys for executions
732
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
737
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
733
738
  * const record = "{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}"
734
739
  * const tx_id = await programManager.split(25000000, record);
735
740
  *
@@ -776,7 +781,7 @@ declare class ProgramManager {
776
781
  * keyProvider.useCache(true);
777
782
  *
778
783
  * // Initialize a program manager with the key provider to automatically fetch keys for executions
779
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
784
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
780
785
  * const tx = await programManager.buildTransferTransaction(1, "aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px", "public", 0.2, false);
781
786
  * await programManager.networkClient.submitTransaction(tx.toString());
782
787
  *
@@ -807,7 +812,7 @@ declare class ProgramManager {
807
812
  * keyProvider.useCache(true);
808
813
  *
809
814
  * // Initialize a program manager with the key provider to automatically fetch keys for executions
810
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
815
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
811
816
  * const tx = await programManager.buildTransferPublicTransaction(1, "aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px", 0.2);
812
817
  * await programManager.networkClient.submitTransaction(tx.toString());
813
818
  *
@@ -838,7 +843,7 @@ declare class ProgramManager {
838
843
  * keyProvider.useCache(true);
839
844
  *
840
845
  * // Initialize a program manager with the key provider to automatically fetch keys for executions
841
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
846
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
842
847
  * const tx = await programManager.buildTransferPublicAsSignerTransaction(1, "aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px", 0.2);
843
848
  * await programManager.networkClient.submitTransaction(tx.toString());
844
849
  *
@@ -874,7 +879,7 @@ declare class ProgramManager {
874
879
  * keyProvider.useCache(true);
875
880
  *
876
881
  * // Initialize a program manager with the key provider to automatically fetch keys for executions
877
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
882
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
878
883
  * const tx_id = await programManager.transfer(1, "aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px", "public", 0.2, false);
879
884
  *
880
885
  * // Verify the transaction was successful
@@ -902,7 +907,7 @@ declare class ProgramManager {
902
907
  * keyProvider.useCache(true);
903
908
  *
904
909
  * // Create a new ProgramManager with the key that will be used to bond credits
905
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, undefined);
910
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, undefined);
906
911
  * programManager.setAccount(new Account("YourPrivateKey"));
907
912
  *
908
913
  * // Create the bonding transaction object for later submission
@@ -936,7 +941,7 @@ declare class ProgramManager {
936
941
  * keyProvider.useCache(true);
937
942
  *
938
943
  * // Create a new ProgramManager with the key that will be used to bond credits
939
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, undefined);
944
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, undefined);
940
945
  *
941
946
  * // Create the bonding transaction
942
947
  * tx_id = await programManager.bondPublic("aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j", "aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px", "aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9", 2000000);
@@ -967,7 +972,7 @@ declare class ProgramManager {
967
972
  * keyProvider.useCache(true);
968
973
  *
969
974
  * // Create a new ProgramManager with the key that will be used to bond credits
970
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, undefined);
975
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, undefined);
971
976
  * programManager.setAccount(new Account("YourPrivateKey"));
972
977
  *
973
978
  * // Create the bond validator transaction object for later use.
@@ -1002,7 +1007,7 @@ declare class ProgramManager {
1002
1007
  * keyProvider.useCache(true);
1003
1008
  *
1004
1009
  * // Create a new ProgramManager with the key that will be used to bond credits
1005
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, undefined);
1010
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, undefined);
1006
1011
  * programManager.setAccount(new Account("YourPrivateKey"));
1007
1012
  *
1008
1013
  * // Create the bonding transaction
@@ -1032,7 +1037,7 @@ declare class ProgramManager {
1032
1037
  * keyProvider.useCache(true);
1033
1038
  *
1034
1039
  * // Create a new ProgramManager with the key that will be used to unbond credits.
1035
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, undefined);
1040
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, undefined);
1036
1041
  * const tx = await programManager.buildUnbondPublicTransaction("aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j", 2000000);
1037
1042
  *
1038
1043
  * // The transaction can be submitted later to the network using the network client.
@@ -1067,7 +1072,7 @@ declare class ProgramManager {
1067
1072
  * keyProvider.useCache(true);
1068
1073
  *
1069
1074
  * // Create a new ProgramManager with the key that will be used to bond credits
1070
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, undefined);
1075
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, undefined);
1071
1076
  * programManager.setAccount(new Account("YourPrivateKey"));
1072
1077
  *
1073
1078
  * // Create the unbond_public transaction and send it to the network
@@ -1096,7 +1101,7 @@ declare class ProgramManager {
1096
1101
  * keyProvider.useCache(true);
1097
1102
  *
1098
1103
  * // Create a new ProgramManager with the key that will be used to claim unbonded credits.
1099
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, undefined);
1104
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, undefined);
1100
1105
  *
1101
1106
  * // Create the claim_unbond_public transaction object for later use.
1102
1107
  * const tx = await programManager.buildClaimUnbondPublicTransaction("aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j");
@@ -1128,7 +1133,7 @@ declare class ProgramManager {
1128
1133
  * keyProvider.useCache(true);
1129
1134
  *
1130
1135
  * // Create a new ProgramManager with the key that will be used to bond credits
1131
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, undefined);
1136
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, undefined);
1132
1137
  * programManager.setAccount(new Account("YourPrivateKey"));
1133
1138
  *
1134
1139
  * // Create the claim_unbond_public transaction
@@ -1165,7 +1170,7 @@ declare class ProgramManager {
1165
1170
  * keyProvider.useCache(true);
1166
1171
  *
1167
1172
  * // Create a new ProgramManager with the key that will be used to bond credits
1168
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, undefined);
1173
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, undefined);
1169
1174
  *
1170
1175
  * // Create the set_validator_state transaction
1171
1176
  * const tx = await programManager.buildSetValidatorStateTransaction(true);
@@ -1204,7 +1209,7 @@ declare class ProgramManager {
1204
1209
  * keyProvider.useCache(true);
1205
1210
  *
1206
1211
  * // Create a new ProgramManager with the key that will be used to bond credits
1207
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, undefined);
1212
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, undefined);
1208
1213
  *
1209
1214
  * // Create the set_validator_state transaction
1210
1215
  * const tx_id = await programManager.setValidatorState(true);
@@ -1285,7 +1290,7 @@ declare class ProgramManager {
1285
1290
  * keyProvider.useCache(true);
1286
1291
  *
1287
1292
  * // Initialize a program manager with the key provider to automatically fetch keys for executions.
1288
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider);
1293
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider);
1289
1294
  *
1290
1295
  * // Build the `Authorization`.
1291
1296
  * const privateKey = new PrivateKey(); // Change this to a private key that has an aleo credit balance.
@@ -1334,7 +1339,7 @@ declare class ProgramManager {
1334
1339
  * import { AleoKeyProvider, PrivateKey, initThreadPool, ProgramManager } from "@provablehq/sdk";
1335
1340
  *
1336
1341
  * // Initialize a program manager with the key provider to automatically fetch keys for executions.
1337
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider);
1342
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider);
1338
1343
  *
1339
1344
  * // Get the base fee in microcredits.
1340
1345
  * const baseFeeMicrocredits = await programManager.estimateExecutionFee({programName: "credits.aleo"});
@@ -54,7 +54,7 @@ interface RecordProvider {
54
54
  *
55
55
  * // When the program manager is initialized with the record provider it will be used to find automatically find
56
56
  * // fee records and amount records for value transfers so that they do not need to be specified manually
57
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
57
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
58
58
  * programManager.transfer(1, "aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at", "public", 0.5);
59
59
  */
60
60
  findCreditsRecord(microcredits: number, searchParameters: RecordSearchParams): Promise<OwnedRecord>;
@@ -77,7 +77,7 @@ interface RecordProvider {
77
77
  *
78
78
  * // When the program manager is initialized with the record provider it will be used to find automatically find
79
79
  * // fee records and amount records for value transfers so that they do not need to be specified manually
80
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
80
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
81
81
  * programManager.transfer(1, "aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at", "public", 0.5);
82
82
  */
83
83
  findCreditsRecords(microcreditAmounts: number[], searchParameters: RecordSearchParams): Promise<OwnedRecord[]>;
@@ -191,7 +191,7 @@ declare class NetworkRecordProvider implements RecordProvider {
191
191
  *
192
192
  * @example
193
193
  * // Create a new NetworkRecordProvider
194
- * const networkClient = new AleoNetworkClient("https://api.explorer.provable.com/v1");
194
+ * const networkClient = new AleoNetworkClient("https://api.provable.com/v2");
195
195
  * const keyProvider = new AleoKeyProvider();
196
196
  * const recordProvider = new NetworkRecordProvider(account, networkClient);
197
197
  *
@@ -204,7 +204,7 @@ declare class NetworkRecordProvider implements RecordProvider {
204
204
  *
205
205
  * // When the program manager is initialized with the record provider it will be used to find automatically find
206
206
  * // fee records and amount records for value transfers so that they do not need to be specified manually
207
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
207
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
208
208
  * programManager.transfer(1, "aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at", "public", 0.5);
209
209
  *
210
210
  * */
@@ -218,7 +218,7 @@ declare class NetworkRecordProvider implements RecordProvider {
218
218
  *
219
219
  * @example
220
220
  * // Create a new NetworkRecordProvider
221
- * const networkClient = new AleoNetworkClient("https://api.explorer.provable.com/v1");
221
+ * const networkClient = new AleoNetworkClient("https://api.provable.com/v2");
222
222
  * const keyProvider = new AleoKeyProvider();
223
223
  * const recordProvider = new NetworkRecordProvider(account, networkClient);
224
224
  *
@@ -231,7 +231,7 @@ declare class NetworkRecordProvider implements RecordProvider {
231
231
  *
232
232
  * // When the program manager is initialized with the record provider it will be used to find automatically find
233
233
  * // fee records and amount records for value transfers so that they do not need to be specified manually
234
- * const programManager = new ProgramManager("https://api.explorer.provable.com/v1", keyProvider, recordProvider);
234
+ * const programManager = new ProgramManager("https://api.provable.com/v2", keyProvider, recordProvider);
235
235
  * programManager.transfer(1, "aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at", "public", 0.5);
236
236
  */
237
237
  findCreditsRecord(microcredits: number, searchParameters: RecordSearchParams): Promise<OwnedRecord>;
@@ -256,7 +256,7 @@ declare class NetworkRecordProvider implements RecordProvider {
256
256
  * const params = new BlockHeightSearch(89995, 99995);
257
257
  *
258
258
  * // Create a new NetworkRecordProvider
259
- * const networkClient = new AleoNetworkClient("https://api.explorer.provable.com/v1");
259
+ * const networkClient = new AleoNetworkClient("https://api.provable.com/v2");
260
260
  * const keyProvider = new AleoKeyProvider();
261
261
  * const recordProvider = new NetworkRecordProvider(account, networkClient);
262
262
  *