@algorandfoundation/algokit-utils 9.2.0-beta.9 → 9.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.
- package/package.json +1 -1
- package/types/algorand-client-transaction-creator.d.ts +10 -0
- package/types/algorand-client-transaction-creator.js +8 -0
- package/types/algorand-client-transaction-creator.js.map +1 -1
- package/types/algorand-client-transaction-creator.mjs +8 -0
- package/types/algorand-client-transaction-creator.mjs.map +1 -1
- package/types/algorand-client-transaction-sender.d.ts +92 -0
- package/types/algorand-client-transaction-sender.js +8 -0
- package/types/algorand-client-transaction-sender.js.map +1 -1
- package/types/algorand-client-transaction-sender.mjs +8 -0
- package/types/algorand-client-transaction-sender.mjs.map +1 -1
- package/types/app-client.d.ts +37 -0
- package/types/app-factory.d.ts +18 -0
- package/types/app-manager.d.ts +11 -9
- package/types/app-manager.js +1 -0
- package/types/app-manager.js.map +1 -1
- package/types/app-manager.mjs +1 -0
- package/types/app-manager.mjs.map +1 -1
- package/types/composer.d.ts +10 -0
- package/types/composer.js +12 -1
- package/types/composer.js.map +1 -1
- package/types/composer.mjs +12 -1
- package/types/composer.mjs.map +1 -1
package/types/composer.d.ts
CHANGED
|
@@ -322,6 +322,8 @@ export type CommonAppCallParams = CommonTransactionParams & {
|
|
|
322
322
|
boxReferences?: (BoxReference | BoxIdentifier)[];
|
|
323
323
|
/** Access references unifies `accountReferences`, `appReferences`, `assetReferences`, and `boxReferences` under a single list. If non-empty, these other reference lists must be empty. If access is empty, those other reference lists may be non-empty. */
|
|
324
324
|
accessReferences?: ResourceReference[];
|
|
325
|
+
/** If set, the transaction will be rejected when the app's version is greater than or equal to this value. This can be used to prevent calling an app after it has been updated. Set to 0 or leave undefined to skip the version check. */
|
|
326
|
+
rejectVersion?: number;
|
|
325
327
|
};
|
|
326
328
|
/** Parameters to define an app create transaction */
|
|
327
329
|
export type AppCreateParams = Expand<Omit<CommonAppCallParams, 'appId'> & {
|
|
@@ -793,6 +795,7 @@ export declare class TransactionComposer {
|
|
|
793
795
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
794
796
|
* // already specified, but here for completeness
|
|
795
797
|
* maxFee: (3000).microAlgo(),
|
|
798
|
+
* rejectVersion: 1,
|
|
796
799
|
* // Signer only needed if you want to provide one,
|
|
797
800
|
* // generally you'd register it with AlgorandClient
|
|
798
801
|
* // against the sender and not need to pass it in
|
|
@@ -836,6 +839,7 @@ export declare class TransactionComposer {
|
|
|
836
839
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
837
840
|
* // already specified, but here for completeness
|
|
838
841
|
* maxFee: (3000).microAlgo(),
|
|
842
|
+
* rejectVersion: 1,
|
|
839
843
|
*})
|
|
840
844
|
* ```
|
|
841
845
|
*/
|
|
@@ -871,6 +875,7 @@ export declare class TransactionComposer {
|
|
|
871
875
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
872
876
|
* // already specified, but here for completeness
|
|
873
877
|
* maxFee: (3000).microAlgo(),
|
|
878
|
+
* rejectVersion: 1,
|
|
874
879
|
*})
|
|
875
880
|
* ```
|
|
876
881
|
*/
|
|
@@ -908,6 +913,7 @@ export declare class TransactionComposer {
|
|
|
908
913
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
909
914
|
* // already specified, but here for completeness
|
|
910
915
|
* maxFee: (3000).microAlgo(),
|
|
916
|
+
* rejectVersion: 1,
|
|
911
917
|
*})
|
|
912
918
|
* ```
|
|
913
919
|
*/
|
|
@@ -964,6 +970,7 @@ export declare class TransactionComposer {
|
|
|
964
970
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
965
971
|
* // already specified, but here for completeness
|
|
966
972
|
* maxFee: (3000).microAlgo(),
|
|
973
|
+
* rejectVersion: 1,
|
|
967
974
|
*})
|
|
968
975
|
* ```
|
|
969
976
|
*/
|
|
@@ -1013,6 +1020,7 @@ export declare class TransactionComposer {
|
|
|
1013
1020
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
1014
1021
|
* // already specified, but here for completeness
|
|
1015
1022
|
* maxFee: (3000).microAlgo(),
|
|
1023
|
+
* rejectVersion: 1,
|
|
1016
1024
|
*})
|
|
1017
1025
|
* ```
|
|
1018
1026
|
*/
|
|
@@ -1060,6 +1068,7 @@ export declare class TransactionComposer {
|
|
|
1060
1068
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
1061
1069
|
* // already specified, but here for completeness
|
|
1062
1070
|
* maxFee: (3000).microAlgo(),
|
|
1071
|
+
* rejectVersion: 1,
|
|
1063
1072
|
*})
|
|
1064
1073
|
* ```
|
|
1065
1074
|
*/
|
|
@@ -1107,6 +1116,7 @@ export declare class TransactionComposer {
|
|
|
1107
1116
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
1108
1117
|
* // already specified, but here for completeness
|
|
1109
1118
|
* maxFee: (3000).microAlgo(),
|
|
1119
|
+
* rejectVersion: 1,
|
|
1110
1120
|
*})
|
|
1111
1121
|
* ```
|
|
1112
1122
|
*/
|
package/types/composer.js
CHANGED
|
@@ -412,6 +412,7 @@ class TransactionComposer {
|
|
|
412
412
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
413
413
|
* // already specified, but here for completeness
|
|
414
414
|
* maxFee: (3000).microAlgo(),
|
|
415
|
+
* rejectVersion: 1,
|
|
415
416
|
* // Signer only needed if you want to provide one,
|
|
416
417
|
* // generally you'd register it with AlgorandClient
|
|
417
418
|
* // against the sender and not need to pass it in
|
|
@@ -458,6 +459,7 @@ class TransactionComposer {
|
|
|
458
459
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
459
460
|
* // already specified, but here for completeness
|
|
460
461
|
* maxFee: (3000).microAlgo(),
|
|
462
|
+
* rejectVersion: 1,
|
|
461
463
|
*})
|
|
462
464
|
* ```
|
|
463
465
|
*/
|
|
@@ -496,6 +498,7 @@ class TransactionComposer {
|
|
|
496
498
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
497
499
|
* // already specified, but here for completeness
|
|
498
500
|
* maxFee: (3000).microAlgo(),
|
|
501
|
+
* rejectVersion: 1,
|
|
499
502
|
*})
|
|
500
503
|
* ```
|
|
501
504
|
*/
|
|
@@ -536,6 +539,7 @@ class TransactionComposer {
|
|
|
536
539
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
537
540
|
* // already specified, but here for completeness
|
|
538
541
|
* maxFee: (3000).microAlgo(),
|
|
542
|
+
* rejectVersion: 1,
|
|
539
543
|
*})
|
|
540
544
|
* ```
|
|
541
545
|
*/
|
|
@@ -595,6 +599,7 @@ class TransactionComposer {
|
|
|
595
599
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
596
600
|
* // already specified, but here for completeness
|
|
597
601
|
* maxFee: (3000).microAlgo(),
|
|
602
|
+
* rejectVersion: 1,
|
|
598
603
|
*})
|
|
599
604
|
* ```
|
|
600
605
|
*/
|
|
@@ -647,6 +652,7 @@ class TransactionComposer {
|
|
|
647
652
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
648
653
|
* // already specified, but here for completeness
|
|
649
654
|
* maxFee: (3000).microAlgo(),
|
|
655
|
+
* rejectVersion: 1,
|
|
650
656
|
*})
|
|
651
657
|
* ```
|
|
652
658
|
*/
|
|
@@ -697,6 +703,7 @@ class TransactionComposer {
|
|
|
697
703
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
698
704
|
* // already specified, but here for completeness
|
|
699
705
|
* maxFee: (3000).microAlgo(),
|
|
706
|
+
* rejectVersion: 1,
|
|
700
707
|
*})
|
|
701
708
|
* ```
|
|
702
709
|
*/
|
|
@@ -747,6 +754,7 @@ class TransactionComposer {
|
|
|
747
754
|
* // Max fee doesn't make sense with extraFee AND staticFee
|
|
748
755
|
* // already specified, but here for completeness
|
|
749
756
|
* maxFee: (3000).microAlgo(),
|
|
757
|
+
* rejectVersion: 1,
|
|
750
758
|
*})
|
|
751
759
|
* ```
|
|
752
760
|
*/
|
|
@@ -1051,6 +1059,7 @@ class TransactionComposer {
|
|
|
1051
1059
|
return arg;
|
|
1052
1060
|
})
|
|
1053
1061
|
.reverse(),
|
|
1062
|
+
rejectVersion: params.rejectVersion,
|
|
1054
1063
|
// note, lease, and rekeyTo are set in the common build step
|
|
1055
1064
|
note: undefined,
|
|
1056
1065
|
lease: undefined,
|
|
@@ -1163,6 +1172,7 @@ class TransactionComposer {
|
|
|
1163
1172
|
access: params.accessReferences?.map(getResourceReference),
|
|
1164
1173
|
approvalProgram,
|
|
1165
1174
|
clearProgram: clearStateProgram,
|
|
1175
|
+
rejectVersion: params.rejectVersion,
|
|
1166
1176
|
};
|
|
1167
1177
|
if (appId === 0n) {
|
|
1168
1178
|
if (sdkParams.approvalProgram === undefined || sdkParams.clearProgram === undefined) {
|
|
@@ -1332,7 +1342,8 @@ class TransactionComposer {
|
|
|
1332
1342
|
});
|
|
1333
1343
|
this.atc['methodCalls'] = methodCalls;
|
|
1334
1344
|
}
|
|
1335
|
-
|
|
1345
|
+
const transactions = this.atc.buildGroup();
|
|
1346
|
+
return { atc: this.atc, transactions, methodCalls: this.atc['methodCalls'] };
|
|
1336
1347
|
}
|
|
1337
1348
|
/**
|
|
1338
1349
|
* Rebuild the group, discarding any previously built transactions.
|