@algorandfoundation/algokit-utils 10.0.0-alpha.31 → 10.0.0-alpha.32
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/account-manager.d.ts +448 -0
- package/account-manager.js +623 -0
- package/account-manager.js.map +1 -0
- package/account-manager.mjs +620 -0
- package/account-manager.mjs.map +1 -0
- package/account.d.ts +156 -0
- package/account.js +10 -0
- package/account.js.map +1 -0
- package/account.mjs +9 -0
- package/account.mjs.map +1 -0
- package/algorand-client-transaction-creator.d.ts +1103 -0
- package/algorand-client-transaction-creator.js +735 -0
- package/algorand-client-transaction-creator.js.map +1 -0
- package/algorand-client-transaction-creator.mjs +734 -0
- package/algorand-client-transaction-creator.mjs.map +1 -0
- package/algorand-client-transaction-sender.d.ts +1317 -0
- package/algorand-client-transaction-sender.js +933 -0
- package/algorand-client-transaction-sender.js.map +1 -0
- package/algorand-client-transaction-sender.mjs +932 -0
- package/algorand-client-transaction-sender.mjs.map +1 -0
- package/algorand-client.d.ts +246 -0
- package/algorand-client.js +325 -0
- package/algorand-client.js.map +1 -0
- package/algorand-client.mjs +325 -0
- package/algorand-client.mjs.map +1 -0
- package/amount.d.ts +46 -3
- package/amount.js +92 -13
- package/amount.js.map +1 -1
- package/amount.mjs +80 -3
- package/amount.mjs.map +1 -1
- package/app-client.d.ts +2130 -0
- package/app-client.js +909 -0
- package/app-client.js.map +1 -0
- package/app-client.mjs +908 -0
- package/app-client.mjs.map +1 -0
- package/app-deployer.d.ts +166 -0
- package/app-deployer.js +353 -0
- package/app-deployer.js.map +1 -0
- package/app-deployer.mjs +353 -0
- package/app-deployer.mjs.map +1 -0
- package/app-factory.d.ts +965 -0
- package/app-factory.js +448 -0
- package/app-factory.js.map +1 -0
- package/app-factory.mjs +448 -0
- package/app-factory.mjs.map +1 -0
- package/app-manager.d.ts +323 -0
- package/app-manager.js +468 -0
- package/app-manager.js.map +1 -0
- package/app-manager.mjs +468 -0
- package/app-manager.mjs.map +1 -0
- package/app-spec.d.ts +203 -0
- package/app-spec.js +137 -0
- package/app-spec.js.map +1 -0
- package/app-spec.mjs +137 -0
- package/app-spec.mjs.map +1 -0
- package/app.d.ts +257 -0
- package/app.js +49 -0
- package/app.js.map +1 -0
- package/app.mjs +42 -0
- package/app.mjs.map +1 -0
- package/asset-manager.d.ts +212 -0
- package/asset-manager.js +166 -0
- package/asset-manager.js.map +1 -0
- package/asset-manager.mjs +166 -0
- package/asset-manager.mjs.map +1 -0
- package/async-event-emitter.d.ts +16 -0
- package/async-event-emitter.js +38 -0
- package/async-event-emitter.js.map +1 -0
- package/async-event-emitter.mjs +37 -0
- package/async-event-emitter.mjs.map +1 -0
- package/client-manager.d.ts +475 -0
- package/client-manager.js +616 -0
- package/client-manager.js.map +1 -0
- package/client-manager.mjs +616 -0
- package/client-manager.mjs.map +1 -0
- package/composer.d.ts +947 -0
- package/composer.js +1584 -0
- package/composer.js.map +1 -0
- package/composer.mjs +1583 -0
- package/composer.mjs.map +1 -0
- package/config.d.ts +1 -1
- package/config.js +2 -2
- package/config.js.map +1 -1
- package/config.mjs +1 -1
- package/config.mjs.map +1 -1
- package/debugging.d.ts +47 -0
- package/debugging.js +20 -0
- package/debugging.js.map +1 -0
- package/debugging.mjs +15 -0
- package/debugging.mjs.map +1 -0
- package/dispenser-client.d.ts +90 -0
- package/dispenser-client.js +127 -0
- package/dispenser-client.js.map +1 -0
- package/dispenser-client.mjs +127 -0
- package/dispenser-client.mjs.map +1 -0
- package/expand.d.ts +2 -0
- package/expand.js +0 -0
- package/expand.mjs +0 -0
- package/index.d.ts +6 -5
- package/index.js +4 -3
- package/index.mjs +5 -5
- package/indexer-client/indexer-lookup.d.ts +1 -1
- package/indexer-client/indexer-lookup.js.map +1 -1
- package/indexer-client/indexer-lookup.mjs.map +1 -1
- package/indexer.d.ts +40 -0
- package/indexer.js +38 -0
- package/indexer.js.map +1 -0
- package/indexer.mjs +35 -0
- package/indexer.mjs.map +1 -0
- package/instance-of.d.ts +8 -0
- package/kmd-account-manager.d.ts +74 -0
- package/kmd-account-manager.js +167 -0
- package/kmd-account-manager.js.map +1 -0
- package/kmd-account-manager.mjs +165 -0
- package/kmd-account-manager.mjs.map +1 -0
- package/lifecycle-events.d.ts +14 -0
- package/lifecycle-events.js +11 -0
- package/lifecycle-events.js.map +1 -0
- package/lifecycle-events.mjs +10 -0
- package/lifecycle-events.mjs.map +1 -0
- package/logging.d.ts +13 -0
- package/logging.js +47 -0
- package/logging.js.map +1 -0
- package/logging.mjs +42 -0
- package/logging.mjs.map +1 -0
- package/logic-error.d.ts +39 -0
- package/logic-error.js +54 -0
- package/logic-error.js.map +1 -0
- package/logic-error.mjs +53 -0
- package/logic-error.mjs.map +1 -0
- package/network-client.d.ts +43 -0
- package/network-client.js +14 -0
- package/network-client.js.map +1 -0
- package/network-client.mjs +13 -0
- package/network-client.mjs.map +1 -0
- package/package.json +11 -1
- package/testing/account.d.ts +2 -2
- package/testing/account.js +1 -1
- package/testing/account.js.map +1 -1
- package/testing/account.mjs +1 -1
- package/testing/account.mjs.map +1 -1
- package/testing/fixtures/algokit-log-capture-fixture.d.ts +1 -1
- package/testing/fixtures/algokit-log-capture-fixture.js.map +1 -1
- package/testing/fixtures/algokit-log-capture-fixture.mjs.map +1 -1
- package/testing/fixtures/algorand-fixture.d.ts +2 -2
- package/testing/fixtures/algorand-fixture.js +2 -2
- package/testing/fixtures/algorand-fixture.js.map +1 -1
- package/testing/fixtures/algorand-fixture.mjs +2 -2
- package/testing/fixtures/algorand-fixture.mjs.map +1 -1
- package/testing/index.d.ts +2 -1
- package/testing/test-logger.d.ts +1 -1
- package/testing/test-logger.js.map +1 -1
- package/testing/test-logger.mjs.map +1 -1
- package/testing/types.d.ts +156 -0
- package/transaction/index.d.ts +4 -0
- package/transaction/index.js +9 -0
- package/transaction/index.mjs +4 -0
- package/transaction/perform-transaction-composer-simulate.d.ts +1 -1
- package/transaction/perform-transaction-composer-simulate.js.map +1 -1
- package/transaction/perform-transaction-composer-simulate.mjs.map +1 -1
- package/transaction/transaction.d.ts +2 -2
- package/transaction/transaction.js.map +1 -1
- package/transaction/transaction.mjs.map +1 -1
- package/transaction/types.d.ts +133 -0
- package/transactions/app-call.d.ts +1 -1
- package/transactions/app-call.js +1 -1
- package/transactions/app-call.js.map +1 -1
- package/transactions/app-call.mjs +1 -1
- package/transactions/app-call.mjs.map +1 -1
- package/transactions/common.d.ts +1 -1
- package/transactions/common.js.map +1 -1
- package/transactions/common.mjs.map +1 -1
- package/transactions/method-call.d.ts +1 -1
- package/transactions/method-call.js +1 -1
- package/transactions/method-call.js.map +1 -1
- package/transactions/method-call.mjs +1 -1
- package/transactions/method-call.mjs.map +1 -1
- package/transactions/payment.d.ts +1 -1
- package/transactions/payment.js.map +1 -1
- package/transactions/payment.mjs.map +1 -1
- package/types/account-manager.d.ts +11 -442
- package/types/account-manager.js +5 -616
- package/types/account-manager.js.map +1 -1
- package/types/account-manager.mjs +5 -614
- package/types/account-manager.mjs.map +1 -1
- package/types/account.d.ts +8 -150
- package/types/account.js +3 -4
- package/types/account.js.map +1 -1
- package/types/account.mjs +4 -4
- package/types/account.mjs.map +1 -1
- package/types/algorand-client-transaction-creator.d.ts +5 -1098
- package/types/algorand-client-transaction-creator.js +3 -729
- package/types/algorand-client-transaction-creator.js.map +1 -1
- package/types/algorand-client-transaction-creator.mjs +4 -729
- package/types/algorand-client-transaction-creator.mjs.map +1 -1
- package/types/algorand-client-transaction-sender.d.ts +5 -1312
- package/types/algorand-client-transaction-sender.js +3 -927
- package/types/algorand-client-transaction-sender.js.map +1 -1
- package/types/algorand-client-transaction-sender.mjs +3 -926
- package/types/algorand-client-transaction-sender.mjs.map +1 -1
- package/types/algorand-client.d.ts +5 -241
- package/types/algorand-client.js +3 -319
- package/types/algorand-client.js.map +1 -1
- package/types/algorand-client.mjs +3 -319
- package/types/algorand-client.mjs.map +1 -1
- package/types/amount.d.ts +6 -45
- package/types/amount.js +3 -79
- package/types/amount.js.map +1 -1
- package/types/amount.mjs +4 -79
- package/types/amount.mjs.map +1 -1
- package/types/app-client.d.ts +75 -2125
- package/types/app-client.js +3 -903
- package/types/app-client.js.map +1 -1
- package/types/app-client.mjs +3 -902
- package/types/app-client.mjs.map +1 -1
- package/types/app-deployer.d.ts +21 -161
- package/types/app-deployer.js +3 -347
- package/types/app-deployer.js.map +1 -1
- package/types/app-deployer.mjs +3 -347
- package/types/app-deployer.mjs.map +1 -1
- package/types/app-factory.d.ts +21 -960
- package/types/app-factory.js +3 -442
- package/types/app-factory.js.map +1 -1
- package/types/app-factory.mjs +3 -442
- package/types/app-factory.mjs.map +1 -1
- package/types/app-manager.d.ts +15 -318
- package/types/app-manager.js +3 -462
- package/types/app-manager.js.map +1 -1
- package/types/app-manager.mjs +3 -462
- package/types/app-manager.mjs.map +1 -1
- package/types/app-spec.d.ts +39 -198
- package/types/app-spec.js +3 -131
- package/types/app-spec.js.map +1 -1
- package/types/app-spec.mjs +3 -131
- package/types/app-spec.mjs.map +1 -1
- package/types/app.d.ts +62 -247
- package/types/app.js +15 -37
- package/types/app.js.map +1 -1
- package/types/app.mjs +16 -37
- package/types/app.mjs.map +1 -1
- package/types/asset-manager.d.ts +9 -207
- package/types/asset-manager.js +3 -160
- package/types/asset-manager.js.map +1 -1
- package/types/asset-manager.mjs +3 -160
- package/types/asset-manager.mjs.map +1 -1
- package/types/async-event-emitter.d.ts +7 -11
- package/types/async-event-emitter.js +3 -32
- package/types/async-event-emitter.js.map +1 -1
- package/types/async-event-emitter.mjs +4 -32
- package/types/async-event-emitter.mjs.map +1 -1
- package/types/client-manager.d.ts +27 -470
- package/types/client-manager.js +3 -610
- package/types/client-manager.js.map +1 -1
- package/types/client-manager.mjs +3 -610
- package/types/client-manager.mjs.map +1 -1
- package/types/composer.d.ts +79 -943
- package/types/composer.js +3 -1578
- package/types/composer.js.map +1 -1
- package/types/composer.mjs +3 -1577
- package/types/composer.mjs.map +1 -1
- package/types/config.d.ts +7 -52
- package/types/config.js +3 -74
- package/types/config.js.map +1 -1
- package/types/config.mjs +3 -74
- package/types/config.mjs.map +1 -1
- package/types/debugging.d.ts +12 -37
- package/types/debugging.js +11 -10
- package/types/debugging.js.map +1 -1
- package/types/debugging.mjs +12 -10
- package/types/debugging.mjs.map +1 -1
- package/types/dispenser-client.d.ts +11 -85
- package/types/dispenser-client.js +3 -121
- package/types/dispenser-client.js.map +1 -1
- package/types/dispenser-client.mjs +3 -121
- package/types/dispenser-client.mjs.map +1 -1
- package/types/expand.d.ts +8 -2
- package/types/indexer.d.ts +16 -36
- package/types/indexer.js +7 -30
- package/types/indexer.js.map +1 -1
- package/types/indexer.mjs +8 -30
- package/types/indexer.mjs.map +1 -1
- package/types/instance-of.d.ts +4 -4
- package/types/kmd-account-manager.d.ts +5 -69
- package/types/kmd-account-manager.js +3 -161
- package/types/kmd-account-manager.js.map +1 -1
- package/types/kmd-account-manager.mjs +3 -159
- package/types/kmd-account-manager.mjs.map +1 -1
- package/types/lifecycle-events.d.ts +7 -9
- package/types/lifecycle-events.js +3 -5
- package/types/lifecycle-events.js.map +1 -1
- package/types/lifecycle-events.mjs +4 -5
- package/types/lifecycle-events.mjs.map +1 -1
- package/types/logging.d.ts +14 -9
- package/types/logging.js +11 -37
- package/types/logging.js.map +1 -1
- package/types/logging.mjs +12 -37
- package/types/logging.mjs.map +1 -1
- package/types/logic-error.d.ts +8 -35
- package/types/logic-error.js +3 -48
- package/types/logic-error.js.map +1 -1
- package/types/logic-error.mjs +4 -48
- package/types/logic-error.mjs.map +1 -1
- package/types/network-client.d.ts +10 -39
- package/types/network-client.js +3 -8
- package/types/network-client.js.map +1 -1
- package/types/network-client.mjs +4 -8
- package/types/network-client.mjs.map +1 -1
- package/types/testing.d.ts +13 -151
- package/types/transaction.d.ts +33 -128
- package/updatable-config.d.ts +57 -0
- package/updatable-config.js +80 -0
- package/updatable-config.js.map +1 -0
- package/updatable-config.mjs +80 -0
- package/updatable-config.mjs.map +1 -0
- package/util.js +1 -1
- package/util.js.map +1 -1
- package/util.mjs +1 -1
- package/util.mjs.map +1 -1
package/types/app-factory.d.ts
CHANGED
|
@@ -1,965 +1,26 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Expand } from "../packages/common/src/expand.js";
|
|
3
|
-
import { ABIValue } from "../packages/abi/src/abi-value.js";
|
|
4
|
-
import { Arc56Contract } from "../packages/abi/src/arc56-contract.js";
|
|
5
|
-
import { ABIMethod, ABIReturn } from "../packages/abi/src/abi-method.js";
|
|
6
|
-
import { OnApplicationComplete, ResourceReference } from "../packages/transact/src/transactions/app-call.js";
|
|
7
|
-
import { Transaction } from "../packages/transact/src/transactions/transaction.js";
|
|
8
|
-
import { AddressWithTransactionSigner, SendingAddress, TransactionSigner } from "../packages/transact/src/signer.js";
|
|
9
|
-
import { PendingTransactionResponse } from "../packages/algod_client/src/models/pending-transaction-response.js";
|
|
10
|
-
import { AlgoAmount } from "./amount.js";
|
|
11
|
-
import { BoxIdentifier, BoxReference } from "./app-manager.js";
|
|
12
|
-
import { AppMethodCallParams } from "../transactions/app-call.js";
|
|
13
|
-
import { AppMethodCall, AppMethodCallTransactionArgument } from "../transactions/method-call.js";
|
|
14
|
-
import { ConfirmedTransactionResult, SendParams } from "./transaction.js";
|
|
15
|
-
import { TransactionWithSigner } from "../transaction/transaction.js";
|
|
16
|
-
import { AppDeployMetadata, CompiledTeal, TealTemplateParams } from "./app.js";
|
|
17
|
-
import { AppDeployParams } from "./app-deployer.js";
|
|
18
|
-
import { AppSpec } from "./app-spec.js";
|
|
19
|
-
import { AppClient, AppClientBareCallParams, AppClientCompilationParams, AppClientCompilationResult, AppClientMethodCallParams, AppClientParams, AppSourceMaps, ResolveAppClientByCreatorAndName } from "./app-client.js";
|
|
20
|
-
import { AlgorandClient } from "./algorand-client.js";
|
|
1
|
+
import { AppFactory as AppFactory$1, AppFactoryAppClientParams as AppFactoryAppClientParams$1, AppFactoryCreateMethodCallParams as AppFactoryCreateMethodCallParams$1, AppFactoryCreateParams as AppFactoryCreateParams$1, AppFactoryDeployParams as AppFactoryDeployParams$1, AppFactoryParams as AppFactoryParams$1, AppFactoryResolveAppClientByCreatorAndNameParams as AppFactoryResolveAppClientByCreatorAndNameParams$1, CreateOnComplete as CreateOnComplete$1, CreateSchema as CreateSchema$1 } from "../app-factory.js";
|
|
21
2
|
|
|
22
3
|
//#region src/types/app-factory.d.ts
|
|
23
|
-
/**
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
version?: string;
|
|
44
|
-
/**
|
|
45
|
-
* Whether or not the contract should have deploy-time immutability control set, undefined = ignore.
|
|
46
|
-
* If specified here will get used in calls to `deploy` and `create` calls unless overridden in those calls.
|
|
47
|
-
*
|
|
48
|
-
* Useful if you want to vend multiple contracts from the same factory without specifying this value
|
|
49
|
-
* for each call.
|
|
50
|
-
*/
|
|
51
|
-
updatable?: boolean;
|
|
52
|
-
/**
|
|
53
|
-
* Whether or not the contract should have deploy-time permanence control set, undefined = ignore.
|
|
54
|
-
* If specified here will get used in calls to `deploy` and `create` calls unless overridden in those calls.
|
|
55
|
-
*
|
|
56
|
-
* Useful if you want to vend multiple contracts from the same factory without specifying this value
|
|
57
|
-
* for each call.
|
|
58
|
-
*/
|
|
59
|
-
deletable?: boolean;
|
|
60
|
-
/**
|
|
61
|
-
* Optional deploy-time TEAL template replacement parameters.
|
|
62
|
-
* If specified here will get used in calls to `deploy` and `create` calls unless overridden in those calls.
|
|
63
|
-
*
|
|
64
|
-
* Useful if you want to vend multiple contracts from the same factory without specifying this value
|
|
65
|
-
* for each call.
|
|
66
|
-
*/
|
|
67
|
-
deployTimeParams?: TealTemplateParams;
|
|
68
|
-
}
|
|
69
|
-
/** onComplete parameter for a create app call */
|
|
70
|
-
type CreateOnComplete = {
|
|
71
|
-
onComplete?: Exclude<OnApplicationComplete, OnApplicationComplete.ClearState>;
|
|
72
|
-
};
|
|
73
|
-
/** Specifies a schema used for creating an app */
|
|
74
|
-
type CreateSchema = {
|
|
75
|
-
/** The state schema for the app. This is immutable once the app is created. By default uses the ARC32/ARC-56 spec. */
|
|
76
|
-
schema?: {
|
|
77
|
-
/** The number of integers saved in global state. */
|
|
78
|
-
globalInts: number;
|
|
79
|
-
/** The number of byte slices saved in global state. */
|
|
80
|
-
globalByteSlices: number;
|
|
81
|
-
/** The number of integers saved in local state. */
|
|
82
|
-
localInts: number;
|
|
83
|
-
/** The number of byte slices saved in local state. */
|
|
84
|
-
localByteSlices: number;
|
|
85
|
-
};
|
|
86
|
-
/** Number of extra pages required for the programs.
|
|
87
|
-
* Defaults to the number needed for the programs in this call if not specified.
|
|
88
|
-
* This is immutable once the app is created. */
|
|
89
|
-
extraProgramPages?: number;
|
|
90
|
-
};
|
|
91
|
-
/** Params to specify a bare (raw) create call for an app */
|
|
92
|
-
type AppFactoryCreateParams = Expand<AppClientBareCallParams & AppClientCompilationParams & CreateOnComplete & CreateSchema>;
|
|
93
|
-
/** Params to specify a create method call for an app */
|
|
94
|
-
type AppFactoryCreateMethodCallParams = Expand<AppClientMethodCallParams & AppClientCompilationParams & CreateOnComplete & CreateSchema>;
|
|
95
|
-
/** Params to get an app client by ID from an app factory. */
|
|
96
|
-
type AppFactoryAppClientParams = Expand<Omit<AppClientParams, 'algorand' | 'appSpec'>>;
|
|
97
|
-
/** Params to get an app client by creator address and name from an app factory. */
|
|
98
|
-
type AppFactoryResolveAppClientByCreatorAndNameParams = Expand<Omit<ResolveAppClientByCreatorAndName, 'algorand' | 'appSpec'>>;
|
|
99
|
-
/** Parameters to define a deployment for an `AppFactory` */
|
|
100
|
-
type AppFactoryDeployParams = Expand<Omit<AppDeployParams, 'createParams' | 'updateParams' | 'deleteParams' | 'metadata'> & {
|
|
101
|
-
/** Create transaction parameters to use if a create needs to be issued as part of deployment */
|
|
102
|
-
createParams?: Expand<AppClientMethodCallParams & CreateOnComplete & CreateSchema> | Expand<AppClientBareCallParams & CreateOnComplete & CreateSchema>;
|
|
103
|
-
/** Update transaction parameters to use if a create needs to be issued as part of deployment */
|
|
104
|
-
updateParams?: AppClientMethodCallParams | AppClientBareCallParams;
|
|
105
|
-
/** Delete transaction parameters to use if a create needs to be issued as part of deployment */
|
|
106
|
-
deleteParams?: AppClientMethodCallParams | AppClientBareCallParams;
|
|
107
|
-
/**
|
|
108
|
-
* Whether or not the contract should have deploy-time immutability control set.
|
|
109
|
-
* `undefined` = use AppFactory constructor value if set or base it on the app spec.
|
|
110
|
-
*/
|
|
111
|
-
updatable?: boolean;
|
|
112
|
-
/**
|
|
113
|
-
* Whether or not the contract should have deploy-time permanence control set.
|
|
114
|
-
* `undefined` = use AppFactory constructor value if set or base it on the app spec.
|
|
115
|
-
*/
|
|
116
|
-
deletable?: boolean;
|
|
117
|
-
/** Override the app name for this deployment */
|
|
118
|
-
appName?: string;
|
|
119
|
-
}>;
|
|
120
|
-
/**
|
|
121
|
-
* ARC-56/ARC-32 app factory that, for a given app spec, allows you to create
|
|
122
|
-
* and deploy one or more app instances and to create one or more app clients
|
|
123
|
-
* to interact with those (or other) app instances.
|
|
124
|
-
*/
|
|
125
|
-
declare class AppFactory {
|
|
126
|
-
private _appSpec;
|
|
127
|
-
private _appName;
|
|
128
|
-
private _algorand;
|
|
129
|
-
private _version;
|
|
130
|
-
private _defaultSender?;
|
|
131
|
-
private _defaultSigner?;
|
|
132
|
-
private _deployTimeParams?;
|
|
133
|
-
private _updatable?;
|
|
134
|
-
private _deletable?;
|
|
135
|
-
private _approvalSourceMap;
|
|
136
|
-
private _clearSourceMap;
|
|
137
|
-
private _paramsMethods;
|
|
138
|
-
/**
|
|
139
|
-
* Create a new app factory.
|
|
140
|
-
* @param params The parameters to create the app factory
|
|
141
|
-
* @returns The `AppFactory` instance
|
|
142
|
-
* @example
|
|
143
|
-
* ```typescript
|
|
144
|
-
* const appFactory = new AppFactory({
|
|
145
|
-
* appSpec: appSpec,
|
|
146
|
-
* algorand: AlgorandClient.mainNet(),
|
|
147
|
-
* })
|
|
148
|
-
*/
|
|
149
|
-
constructor(params: AppFactoryParams);
|
|
150
|
-
/** The name of the app (from the ARC-32 / ARC-56 app spec or override). */
|
|
151
|
-
get appName(): string;
|
|
152
|
-
/** The ARC-56 app spec being used */
|
|
153
|
-
get appSpec(): Arc56Contract;
|
|
154
|
-
/** Return the algorand client this factory is using. */
|
|
155
|
-
get algorand(): AlgorandClient;
|
|
156
|
-
/** Get parameters to create transactions (create and deploy related calls) for the current app.
|
|
157
|
-
*
|
|
158
|
-
* A good mental model for this is that these parameters represent a deferred transaction creation.
|
|
159
|
-
* @example Create a transaction in the future using Algorand Client
|
|
160
|
-
* ```typescript
|
|
161
|
-
* const createAppParams = appFactory.params.create({method: 'create_method', args: [123, 'hello']})
|
|
162
|
-
* // ...
|
|
163
|
-
* await algorand.send.AppCreateMethodCall(createAppParams)
|
|
164
|
-
* ```
|
|
165
|
-
* @example Define a nested transaction as an ABI argument
|
|
166
|
-
* ```typescript
|
|
167
|
-
* const createAppParams = appFactory.params.create({method: 'create_method', args: [123, 'hello']})
|
|
168
|
-
* await appClient.send.call({method: 'my_method', args: [createAppParams]})
|
|
169
|
-
* ```
|
|
170
|
-
*/
|
|
171
|
-
get params(): {
|
|
172
|
-
/** Return params for a create ABI call, including deploy-time TEAL template replacements and compilation if provided */
|
|
173
|
-
create: (params: {
|
|
174
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
175
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
176
|
-
note?: string | Uint8Array | undefined;
|
|
177
|
-
lease?: string | Uint8Array | undefined;
|
|
178
|
-
staticFee?: AlgoAmount | undefined;
|
|
179
|
-
extraFee?: AlgoAmount | undefined;
|
|
180
|
-
maxFee?: AlgoAmount | undefined;
|
|
181
|
-
validityWindow?: number | bigint | undefined;
|
|
182
|
-
firstValidRound?: bigint | undefined;
|
|
183
|
-
lastValidRound?: bigint | undefined;
|
|
184
|
-
onComplete?: OnApplicationComplete.NoOp | OnApplicationComplete.OptIn | OnApplicationComplete.CloseOut | OnApplicationComplete.UpdateApplication | OnApplicationComplete.DeleteApplication | undefined;
|
|
185
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
186
|
-
appReferences?: bigint[] | undefined;
|
|
187
|
-
assetReferences?: bigint[] | undefined;
|
|
188
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
189
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
190
|
-
rejectVersion?: number | undefined;
|
|
191
|
-
sender?: ReadableAddress | undefined;
|
|
192
|
-
method: string;
|
|
193
|
-
args?: (ABIValue | AppMethodCallTransactionArgument | undefined)[] | undefined;
|
|
194
|
-
deployTimeParams?: TealTemplateParams | undefined;
|
|
195
|
-
updatable?: boolean | undefined;
|
|
196
|
-
deletable?: boolean | undefined;
|
|
197
|
-
schema?: {
|
|
198
|
-
/** The number of integers saved in global state. */
|
|
199
|
-
globalInts: number;
|
|
200
|
-
/** The number of byte slices saved in global state. */
|
|
201
|
-
globalByteSlices: number;
|
|
202
|
-
/** The number of integers saved in local state. */
|
|
203
|
-
localInts: number;
|
|
204
|
-
/** The number of byte slices saved in local state. */
|
|
205
|
-
localByteSlices: number;
|
|
206
|
-
} | undefined;
|
|
207
|
-
extraProgramPages?: number | undefined;
|
|
208
|
-
}) => Promise<{
|
|
209
|
-
deployTimeParams: TealTemplateParams | undefined;
|
|
210
|
-
schema: {
|
|
211
|
-
/** The number of integers saved in global state. */
|
|
212
|
-
globalInts: number;
|
|
213
|
-
/** The number of byte slices saved in global state. */
|
|
214
|
-
globalByteSlices: number;
|
|
215
|
-
/** The number of integers saved in local state. */
|
|
216
|
-
localInts: number;
|
|
217
|
-
/** The number of byte slices saved in local state. */
|
|
218
|
-
localByteSlices: number;
|
|
219
|
-
};
|
|
220
|
-
approvalProgram: Uint8Array;
|
|
221
|
-
clearStateProgram: Uint8Array;
|
|
222
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
223
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
224
|
-
note?: string | Uint8Array | undefined;
|
|
225
|
-
lease?: string | Uint8Array | undefined;
|
|
226
|
-
staticFee?: AlgoAmount | undefined;
|
|
227
|
-
extraFee?: AlgoAmount | undefined;
|
|
228
|
-
maxFee?: AlgoAmount | undefined;
|
|
229
|
-
validityWindow?: number | bigint | undefined;
|
|
230
|
-
firstValidRound?: bigint | undefined;
|
|
231
|
-
lastValidRound?: bigint | undefined;
|
|
232
|
-
onComplete?: OnApplicationComplete.NoOp | OnApplicationComplete.OptIn | OnApplicationComplete.CloseOut | OnApplicationComplete.UpdateApplication | OnApplicationComplete.DeleteApplication | undefined;
|
|
233
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
234
|
-
appReferences?: bigint[] | undefined;
|
|
235
|
-
assetReferences?: bigint[] | undefined;
|
|
236
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
237
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
238
|
-
rejectVersion?: number | undefined;
|
|
239
|
-
sender?: ReadableAddress | undefined;
|
|
240
|
-
method: string;
|
|
241
|
-
args?: (ABIValue | AppMethodCallTransactionArgument | undefined)[] | undefined;
|
|
242
|
-
updatable?: boolean | undefined;
|
|
243
|
-
deletable?: boolean | undefined;
|
|
244
|
-
extraProgramPages?: number | undefined;
|
|
245
|
-
} & {
|
|
246
|
-
sender: Address;
|
|
247
|
-
signer: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
248
|
-
method: ABIMethod;
|
|
249
|
-
args: (Transaction | Promise<Transaction> | ABIValue | TransactionWithSigner | AppMethodCall<{
|
|
250
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
251
|
-
sender: SendingAddress;
|
|
252
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
253
|
-
note?: string | Uint8Array | undefined;
|
|
254
|
-
lease?: string | Uint8Array | undefined;
|
|
255
|
-
staticFee?: AlgoAmount | undefined;
|
|
256
|
-
extraFee?: AlgoAmount | undefined;
|
|
257
|
-
maxFee?: AlgoAmount | undefined;
|
|
258
|
-
validityWindow?: number | bigint | undefined;
|
|
259
|
-
firstValidRound?: bigint | undefined;
|
|
260
|
-
lastValidRound?: bigint | undefined;
|
|
261
|
-
onComplete?: OnApplicationComplete.NoOp | OnApplicationComplete.OptIn | OnApplicationComplete.CloseOut | OnApplicationComplete.UpdateApplication | OnApplicationComplete.DeleteApplication | undefined;
|
|
262
|
-
args?: Uint8Array[] | undefined;
|
|
263
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
264
|
-
appReferences?: bigint[] | undefined;
|
|
265
|
-
assetReferences?: bigint[] | undefined;
|
|
266
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
267
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
268
|
-
rejectVersion?: number | undefined;
|
|
269
|
-
appId?: 0 | undefined;
|
|
270
|
-
approvalProgram: string | Uint8Array;
|
|
271
|
-
clearStateProgram: string | Uint8Array;
|
|
272
|
-
schema?: {
|
|
273
|
-
globalInts: number;
|
|
274
|
-
globalByteSlices: number;
|
|
275
|
-
localInts: number;
|
|
276
|
-
localByteSlices: number;
|
|
277
|
-
} | undefined;
|
|
278
|
-
extraProgramPages?: number | undefined;
|
|
279
|
-
}> | AppMethodCall<{
|
|
280
|
-
sender: SendingAddress;
|
|
281
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
282
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
283
|
-
note?: string | Uint8Array | undefined;
|
|
284
|
-
lease?: string | Uint8Array | undefined;
|
|
285
|
-
staticFee?: AlgoAmount | undefined;
|
|
286
|
-
extraFee?: AlgoAmount | undefined;
|
|
287
|
-
maxFee?: AlgoAmount | undefined;
|
|
288
|
-
validityWindow?: number | bigint | undefined;
|
|
289
|
-
firstValidRound?: bigint | undefined;
|
|
290
|
-
lastValidRound?: bigint | undefined;
|
|
291
|
-
appId: bigint;
|
|
292
|
-
onComplete?: OnApplicationComplete.UpdateApplication | undefined;
|
|
293
|
-
args?: Uint8Array[] | undefined;
|
|
294
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
295
|
-
appReferences?: bigint[] | undefined;
|
|
296
|
-
assetReferences?: bigint[] | undefined;
|
|
297
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
298
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
299
|
-
rejectVersion?: number | undefined;
|
|
300
|
-
approvalProgram: string | Uint8Array;
|
|
301
|
-
clearStateProgram: string | Uint8Array;
|
|
302
|
-
}> | AppMethodCall<AppMethodCallParams> | undefined)[] | undefined;
|
|
303
|
-
onComplete: OnApplicationComplete.NoOp | OnApplicationComplete.OptIn | OnApplicationComplete.CloseOut | OnApplicationComplete.UpdateApplication | OnApplicationComplete.DeleteApplication;
|
|
304
|
-
}>;
|
|
305
|
-
/** Return params for a deployment update ABI call */
|
|
306
|
-
deployUpdate: (params: {
|
|
307
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
308
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
309
|
-
note?: string | Uint8Array | undefined;
|
|
310
|
-
lease?: string | Uint8Array | undefined;
|
|
311
|
-
staticFee?: AlgoAmount | undefined;
|
|
312
|
-
extraFee?: AlgoAmount | undefined;
|
|
313
|
-
maxFee?: AlgoAmount | undefined;
|
|
314
|
-
validityWindow?: number | bigint | undefined;
|
|
315
|
-
firstValidRound?: bigint | undefined;
|
|
316
|
-
lastValidRound?: bigint | undefined;
|
|
317
|
-
onComplete?: OnApplicationComplete | undefined;
|
|
318
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
319
|
-
appReferences?: bigint[] | undefined;
|
|
320
|
-
assetReferences?: bigint[] | undefined;
|
|
321
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
322
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
323
|
-
rejectVersion?: number | undefined;
|
|
324
|
-
sender?: ReadableAddress | undefined;
|
|
325
|
-
method: string;
|
|
326
|
-
args?: (ABIValue | AppMethodCallTransactionArgument | undefined)[] | undefined;
|
|
327
|
-
}) => {
|
|
328
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
329
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
330
|
-
note?: string | Uint8Array | undefined;
|
|
331
|
-
lease?: string | Uint8Array | undefined;
|
|
332
|
-
staticFee?: AlgoAmount | undefined;
|
|
333
|
-
extraFee?: AlgoAmount | undefined;
|
|
334
|
-
maxFee?: AlgoAmount | undefined;
|
|
335
|
-
validityWindow?: number | bigint | undefined;
|
|
336
|
-
firstValidRound?: bigint | undefined;
|
|
337
|
-
lastValidRound?: bigint | undefined;
|
|
338
|
-
onComplete?: OnApplicationComplete | undefined;
|
|
339
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
340
|
-
appReferences?: bigint[] | undefined;
|
|
341
|
-
assetReferences?: bigint[] | undefined;
|
|
342
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
343
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
344
|
-
rejectVersion?: number | undefined;
|
|
345
|
-
sender?: ReadableAddress | undefined;
|
|
346
|
-
method: string;
|
|
347
|
-
args?: (ABIValue | AppMethodCallTransactionArgument | undefined)[] | undefined;
|
|
348
|
-
} & {
|
|
349
|
-
sender: Address;
|
|
350
|
-
signer: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
351
|
-
method: ABIMethod;
|
|
352
|
-
args: (Transaction | Promise<Transaction> | ABIValue | TransactionWithSigner | AppMethodCall<{
|
|
353
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
354
|
-
sender: SendingAddress;
|
|
355
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
356
|
-
note?: string | Uint8Array | undefined;
|
|
357
|
-
lease?: string | Uint8Array | undefined;
|
|
358
|
-
staticFee?: AlgoAmount | undefined;
|
|
359
|
-
extraFee?: AlgoAmount | undefined;
|
|
360
|
-
maxFee?: AlgoAmount | undefined;
|
|
361
|
-
validityWindow?: number | bigint | undefined;
|
|
362
|
-
firstValidRound?: bigint | undefined;
|
|
363
|
-
lastValidRound?: bigint | undefined;
|
|
364
|
-
onComplete?: OnApplicationComplete.NoOp | OnApplicationComplete.OptIn | OnApplicationComplete.CloseOut | OnApplicationComplete.UpdateApplication | OnApplicationComplete.DeleteApplication | undefined;
|
|
365
|
-
args?: Uint8Array[] | undefined;
|
|
366
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
367
|
-
appReferences?: bigint[] | undefined;
|
|
368
|
-
assetReferences?: bigint[] | undefined;
|
|
369
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
370
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
371
|
-
rejectVersion?: number | undefined;
|
|
372
|
-
appId?: 0 | undefined;
|
|
373
|
-
approvalProgram: string | Uint8Array;
|
|
374
|
-
clearStateProgram: string | Uint8Array;
|
|
375
|
-
schema?: {
|
|
376
|
-
globalInts: number;
|
|
377
|
-
globalByteSlices: number;
|
|
378
|
-
localInts: number;
|
|
379
|
-
localByteSlices: number;
|
|
380
|
-
} | undefined;
|
|
381
|
-
extraProgramPages?: number | undefined;
|
|
382
|
-
}> | AppMethodCall<{
|
|
383
|
-
sender: SendingAddress;
|
|
384
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
385
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
386
|
-
note?: string | Uint8Array | undefined;
|
|
387
|
-
lease?: string | Uint8Array | undefined;
|
|
388
|
-
staticFee?: AlgoAmount | undefined;
|
|
389
|
-
extraFee?: AlgoAmount | undefined;
|
|
390
|
-
maxFee?: AlgoAmount | undefined;
|
|
391
|
-
validityWindow?: number | bigint | undefined;
|
|
392
|
-
firstValidRound?: bigint | undefined;
|
|
393
|
-
lastValidRound?: bigint | undefined;
|
|
394
|
-
appId: bigint;
|
|
395
|
-
onComplete?: OnApplicationComplete.UpdateApplication | undefined;
|
|
396
|
-
args?: Uint8Array[] | undefined;
|
|
397
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
398
|
-
appReferences?: bigint[] | undefined;
|
|
399
|
-
assetReferences?: bigint[] | undefined;
|
|
400
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
401
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
402
|
-
rejectVersion?: number | undefined;
|
|
403
|
-
approvalProgram: string | Uint8Array;
|
|
404
|
-
clearStateProgram: string | Uint8Array;
|
|
405
|
-
}> | AppMethodCall<AppMethodCallParams> | undefined)[] | undefined;
|
|
406
|
-
onComplete: OnApplicationComplete.UpdateApplication;
|
|
407
|
-
};
|
|
408
|
-
/** Return params for a deployment delete ABI call */
|
|
409
|
-
deployDelete: (params: {
|
|
410
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
411
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
412
|
-
note?: string | Uint8Array | undefined;
|
|
413
|
-
lease?: string | Uint8Array | undefined;
|
|
414
|
-
staticFee?: AlgoAmount | undefined;
|
|
415
|
-
extraFee?: AlgoAmount | undefined;
|
|
416
|
-
maxFee?: AlgoAmount | undefined;
|
|
417
|
-
validityWindow?: number | bigint | undefined;
|
|
418
|
-
firstValidRound?: bigint | undefined;
|
|
419
|
-
lastValidRound?: bigint | undefined;
|
|
420
|
-
onComplete?: OnApplicationComplete | undefined;
|
|
421
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
422
|
-
appReferences?: bigint[] | undefined;
|
|
423
|
-
assetReferences?: bigint[] | undefined;
|
|
424
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
425
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
426
|
-
rejectVersion?: number | undefined;
|
|
427
|
-
sender?: ReadableAddress | undefined;
|
|
428
|
-
method: string;
|
|
429
|
-
args?: (ABIValue | AppMethodCallTransactionArgument | undefined)[] | undefined;
|
|
430
|
-
}) => {
|
|
431
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
432
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
433
|
-
note?: string | Uint8Array | undefined;
|
|
434
|
-
lease?: string | Uint8Array | undefined;
|
|
435
|
-
staticFee?: AlgoAmount | undefined;
|
|
436
|
-
extraFee?: AlgoAmount | undefined;
|
|
437
|
-
maxFee?: AlgoAmount | undefined;
|
|
438
|
-
validityWindow?: number | bigint | undefined;
|
|
439
|
-
firstValidRound?: bigint | undefined;
|
|
440
|
-
lastValidRound?: bigint | undefined;
|
|
441
|
-
onComplete?: OnApplicationComplete | undefined;
|
|
442
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
443
|
-
appReferences?: bigint[] | undefined;
|
|
444
|
-
assetReferences?: bigint[] | undefined;
|
|
445
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
446
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
447
|
-
rejectVersion?: number | undefined;
|
|
448
|
-
sender?: ReadableAddress | undefined;
|
|
449
|
-
method: string;
|
|
450
|
-
args?: (ABIValue | AppMethodCallTransactionArgument | undefined)[] | undefined;
|
|
451
|
-
} & {
|
|
452
|
-
sender: Address;
|
|
453
|
-
signer: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
454
|
-
method: ABIMethod;
|
|
455
|
-
args: (Transaction | Promise<Transaction> | ABIValue | TransactionWithSigner | AppMethodCall<{
|
|
456
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
457
|
-
sender: SendingAddress;
|
|
458
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
459
|
-
note?: string | Uint8Array | undefined;
|
|
460
|
-
lease?: string | Uint8Array | undefined;
|
|
461
|
-
staticFee?: AlgoAmount | undefined;
|
|
462
|
-
extraFee?: AlgoAmount | undefined;
|
|
463
|
-
maxFee?: AlgoAmount | undefined;
|
|
464
|
-
validityWindow?: number | bigint | undefined;
|
|
465
|
-
firstValidRound?: bigint | undefined;
|
|
466
|
-
lastValidRound?: bigint | undefined;
|
|
467
|
-
onComplete?: OnApplicationComplete.NoOp | OnApplicationComplete.OptIn | OnApplicationComplete.CloseOut | OnApplicationComplete.UpdateApplication | OnApplicationComplete.DeleteApplication | undefined;
|
|
468
|
-
args?: Uint8Array[] | undefined;
|
|
469
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
470
|
-
appReferences?: bigint[] | undefined;
|
|
471
|
-
assetReferences?: bigint[] | undefined;
|
|
472
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
473
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
474
|
-
rejectVersion?: number | undefined;
|
|
475
|
-
appId?: 0 | undefined;
|
|
476
|
-
approvalProgram: string | Uint8Array;
|
|
477
|
-
clearStateProgram: string | Uint8Array;
|
|
478
|
-
schema?: {
|
|
479
|
-
globalInts: number;
|
|
480
|
-
globalByteSlices: number;
|
|
481
|
-
localInts: number;
|
|
482
|
-
localByteSlices: number;
|
|
483
|
-
} | undefined;
|
|
484
|
-
extraProgramPages?: number | undefined;
|
|
485
|
-
}> | AppMethodCall<{
|
|
486
|
-
sender: SendingAddress;
|
|
487
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
488
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
489
|
-
note?: string | Uint8Array | undefined;
|
|
490
|
-
lease?: string | Uint8Array | undefined;
|
|
491
|
-
staticFee?: AlgoAmount | undefined;
|
|
492
|
-
extraFee?: AlgoAmount | undefined;
|
|
493
|
-
maxFee?: AlgoAmount | undefined;
|
|
494
|
-
validityWindow?: number | bigint | undefined;
|
|
495
|
-
firstValidRound?: bigint | undefined;
|
|
496
|
-
lastValidRound?: bigint | undefined;
|
|
497
|
-
appId: bigint;
|
|
498
|
-
onComplete?: OnApplicationComplete.UpdateApplication | undefined;
|
|
499
|
-
args?: Uint8Array[] | undefined;
|
|
500
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
501
|
-
appReferences?: bigint[] | undefined;
|
|
502
|
-
assetReferences?: bigint[] | undefined;
|
|
503
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
504
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
505
|
-
rejectVersion?: number | undefined;
|
|
506
|
-
approvalProgram: string | Uint8Array;
|
|
507
|
-
clearStateProgram: string | Uint8Array;
|
|
508
|
-
}> | AppMethodCall<AppMethodCallParams> | undefined)[] | undefined;
|
|
509
|
-
onComplete: OnApplicationComplete.DeleteApplication;
|
|
510
|
-
};
|
|
511
|
-
bare: {
|
|
512
|
-
/** Return params for a create bare call, including deploy-time TEAL template replacements and compilation if provided */
|
|
513
|
-
create: (params?: {
|
|
514
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
515
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
516
|
-
note?: string | Uint8Array | undefined;
|
|
517
|
-
lease?: string | Uint8Array | undefined;
|
|
518
|
-
staticFee?: AlgoAmount | undefined;
|
|
519
|
-
extraFee?: AlgoAmount | undefined;
|
|
520
|
-
maxFee?: AlgoAmount | undefined;
|
|
521
|
-
validityWindow?: number | bigint | undefined;
|
|
522
|
-
firstValidRound?: bigint | undefined;
|
|
523
|
-
lastValidRound?: bigint | undefined;
|
|
524
|
-
args?: Uint8Array[] | undefined;
|
|
525
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
526
|
-
appReferences?: bigint[] | undefined;
|
|
527
|
-
assetReferences?: bigint[] | undefined;
|
|
528
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
529
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
530
|
-
rejectVersion?: number | undefined;
|
|
531
|
-
sender?: ReadableAddress | undefined;
|
|
532
|
-
deployTimeParams?: TealTemplateParams | undefined;
|
|
533
|
-
updatable?: boolean | undefined;
|
|
534
|
-
deletable?: boolean | undefined;
|
|
535
|
-
onComplete?: OnApplicationComplete.NoOp | OnApplicationComplete.OptIn | OnApplicationComplete.CloseOut | OnApplicationComplete.UpdateApplication | OnApplicationComplete.DeleteApplication | undefined;
|
|
536
|
-
schema?: {
|
|
537
|
-
/** The number of integers saved in global state. */
|
|
538
|
-
globalInts: number;
|
|
539
|
-
/** The number of byte slices saved in global state. */
|
|
540
|
-
globalByteSlices: number;
|
|
541
|
-
/** The number of integers saved in local state. */
|
|
542
|
-
localInts: number;
|
|
543
|
-
/** The number of byte slices saved in local state. */
|
|
544
|
-
localByteSlices: number;
|
|
545
|
-
} | undefined;
|
|
546
|
-
extraProgramPages?: number | undefined;
|
|
547
|
-
} | undefined) => Promise<{
|
|
548
|
-
approvalProgram: Uint8Array;
|
|
549
|
-
clearStateProgram: Uint8Array;
|
|
550
|
-
compiledApproval?: CompiledTeal | undefined;
|
|
551
|
-
compiledClear?: CompiledTeal | undefined;
|
|
552
|
-
deployTimeParams: TealTemplateParams | undefined;
|
|
553
|
-
schema: {
|
|
554
|
-
/** The number of integers saved in global state. */
|
|
555
|
-
globalInts: number;
|
|
556
|
-
/** The number of byte slices saved in global state. */
|
|
557
|
-
globalByteSlices: number;
|
|
558
|
-
/** The number of integers saved in local state. */
|
|
559
|
-
localInts: number;
|
|
560
|
-
/** The number of byte slices saved in local state. */
|
|
561
|
-
localByteSlices: number;
|
|
562
|
-
};
|
|
563
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
564
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
565
|
-
note?: string | Uint8Array | undefined;
|
|
566
|
-
lease?: string | Uint8Array | undefined;
|
|
567
|
-
staticFee?: AlgoAmount | undefined;
|
|
568
|
-
extraFee?: AlgoAmount | undefined;
|
|
569
|
-
maxFee?: AlgoAmount | undefined;
|
|
570
|
-
validityWindow?: number | bigint | undefined;
|
|
571
|
-
firstValidRound?: bigint | undefined;
|
|
572
|
-
lastValidRound?: bigint | undefined;
|
|
573
|
-
args?: Uint8Array[] | undefined;
|
|
574
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
575
|
-
appReferences?: bigint[] | undefined;
|
|
576
|
-
assetReferences?: bigint[] | undefined;
|
|
577
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
578
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
579
|
-
rejectVersion?: number | undefined;
|
|
580
|
-
sender?: ReadableAddress | undefined;
|
|
581
|
-
updatable?: boolean | undefined;
|
|
582
|
-
deletable?: boolean | undefined;
|
|
583
|
-
onComplete?: OnApplicationComplete.NoOp | OnApplicationComplete.OptIn | OnApplicationComplete.CloseOut | OnApplicationComplete.UpdateApplication | OnApplicationComplete.DeleteApplication | undefined;
|
|
584
|
-
extraProgramPages?: number | undefined;
|
|
585
|
-
} & {
|
|
586
|
-
sender: Address;
|
|
587
|
-
signer: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
588
|
-
onComplete: OnApplicationComplete.NoOp | OnApplicationComplete.OptIn | OnApplicationComplete.CloseOut | OnApplicationComplete.UpdateApplication | OnApplicationComplete.DeleteApplication;
|
|
589
|
-
}>;
|
|
590
|
-
/** Return params for a deployment update bare call */
|
|
591
|
-
deployUpdate: (params?: {
|
|
592
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
593
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
594
|
-
note?: string | Uint8Array | undefined;
|
|
595
|
-
lease?: string | Uint8Array | undefined;
|
|
596
|
-
staticFee?: AlgoAmount | undefined;
|
|
597
|
-
extraFee?: AlgoAmount | undefined;
|
|
598
|
-
maxFee?: AlgoAmount | undefined;
|
|
599
|
-
validityWindow?: number | bigint | undefined;
|
|
600
|
-
firstValidRound?: bigint | undefined;
|
|
601
|
-
lastValidRound?: bigint | undefined;
|
|
602
|
-
args?: Uint8Array[] | undefined;
|
|
603
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
604
|
-
appReferences?: bigint[] | undefined;
|
|
605
|
-
assetReferences?: bigint[] | undefined;
|
|
606
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
607
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
608
|
-
rejectVersion?: number | undefined;
|
|
609
|
-
sender?: ReadableAddress | undefined;
|
|
610
|
-
} | undefined) => {
|
|
611
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
612
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
613
|
-
note?: string | Uint8Array | undefined;
|
|
614
|
-
lease?: string | Uint8Array | undefined;
|
|
615
|
-
staticFee?: AlgoAmount | undefined;
|
|
616
|
-
extraFee?: AlgoAmount | undefined;
|
|
617
|
-
maxFee?: AlgoAmount | undefined;
|
|
618
|
-
validityWindow?: number | bigint | undefined;
|
|
619
|
-
firstValidRound?: bigint | undefined;
|
|
620
|
-
lastValidRound?: bigint | undefined;
|
|
621
|
-
args?: Uint8Array[] | undefined;
|
|
622
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
623
|
-
appReferences?: bigint[] | undefined;
|
|
624
|
-
assetReferences?: bigint[] | undefined;
|
|
625
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
626
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
627
|
-
rejectVersion?: number | undefined;
|
|
628
|
-
sender?: ReadableAddress | undefined;
|
|
629
|
-
} & {
|
|
630
|
-
sender: Address;
|
|
631
|
-
signer: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
632
|
-
onComplete: OnApplicationComplete.UpdateApplication;
|
|
633
|
-
};
|
|
634
|
-
/** Return params for a deployment delete bare call */
|
|
635
|
-
deployDelete: (params?: {
|
|
636
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
637
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
638
|
-
note?: string | Uint8Array | undefined;
|
|
639
|
-
lease?: string | Uint8Array | undefined;
|
|
640
|
-
staticFee?: AlgoAmount | undefined;
|
|
641
|
-
extraFee?: AlgoAmount | undefined;
|
|
642
|
-
maxFee?: AlgoAmount | undefined;
|
|
643
|
-
validityWindow?: number | bigint | undefined;
|
|
644
|
-
firstValidRound?: bigint | undefined;
|
|
645
|
-
lastValidRound?: bigint | undefined;
|
|
646
|
-
args?: Uint8Array[] | undefined;
|
|
647
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
648
|
-
appReferences?: bigint[] | undefined;
|
|
649
|
-
assetReferences?: bigint[] | undefined;
|
|
650
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
651
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
652
|
-
rejectVersion?: number | undefined;
|
|
653
|
-
sender?: ReadableAddress | undefined;
|
|
654
|
-
} | undefined) => {
|
|
655
|
-
signer?: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
656
|
-
rekeyTo?: ReadableAddress | undefined;
|
|
657
|
-
note?: string | Uint8Array | undefined;
|
|
658
|
-
lease?: string | Uint8Array | undefined;
|
|
659
|
-
staticFee?: AlgoAmount | undefined;
|
|
660
|
-
extraFee?: AlgoAmount | undefined;
|
|
661
|
-
maxFee?: AlgoAmount | undefined;
|
|
662
|
-
validityWindow?: number | bigint | undefined;
|
|
663
|
-
firstValidRound?: bigint | undefined;
|
|
664
|
-
lastValidRound?: bigint | undefined;
|
|
665
|
-
args?: Uint8Array[] | undefined;
|
|
666
|
-
accountReferences?: ReadableAddress[] | undefined;
|
|
667
|
-
appReferences?: bigint[] | undefined;
|
|
668
|
-
assetReferences?: bigint[] | undefined;
|
|
669
|
-
boxReferences?: (BoxReference | BoxIdentifier)[] | undefined;
|
|
670
|
-
accessReferences?: ResourceReference[] | undefined;
|
|
671
|
-
rejectVersion?: number | undefined;
|
|
672
|
-
sender?: ReadableAddress | undefined;
|
|
673
|
-
} & {
|
|
674
|
-
sender: Address;
|
|
675
|
-
signer: AddressWithTransactionSigner | TransactionSigner | undefined;
|
|
676
|
-
onComplete: OnApplicationComplete.DeleteApplication;
|
|
677
|
-
};
|
|
678
|
-
};
|
|
679
|
-
};
|
|
680
|
-
/** Create transactions for the current app */
|
|
681
|
-
readonly createTransaction: {
|
|
682
|
-
/** Create bare (raw) transactions for the current app */
|
|
683
|
-
bare: {
|
|
684
|
-
/**
|
|
685
|
-
* Create a create app call transaction using a bare (raw) create call.
|
|
686
|
-
*
|
|
687
|
-
* Performs deploy-time TEAL template placeholder substitutions (if specified).
|
|
688
|
-
* @param params The parameters to create the create call transaction
|
|
689
|
-
* @returns The create call transaction
|
|
690
|
-
*/
|
|
691
|
-
create: (params?: AppFactoryCreateParams) => Promise<Transaction>;
|
|
692
|
-
};
|
|
693
|
-
/**
|
|
694
|
-
* Create a create app call transaction using an ABI create call.
|
|
695
|
-
*
|
|
696
|
-
* Performs deploy-time TEAL template placeholder substitutions (if specified).
|
|
697
|
-
* @param params The parameters to create the create call transaction
|
|
698
|
-
* @returns The create call transaction
|
|
699
|
-
*/
|
|
700
|
-
create: (params: AppFactoryCreateMethodCallParams) => Promise<{
|
|
701
|
-
transactions: Transaction[];
|
|
702
|
-
methodCalls: Map<number, ABIMethod>;
|
|
703
|
-
signers: Map<number, TransactionSigner>;
|
|
704
|
-
}>;
|
|
705
|
-
};
|
|
706
|
-
/** Send transactions to the current app */
|
|
707
|
-
readonly send: {
|
|
708
|
-
/** Send bare (raw) transactions for the current app */
|
|
709
|
-
bare: {
|
|
710
|
-
/**
|
|
711
|
-
* Creates an instance of the app using a bare (raw) create call and returns the result
|
|
712
|
-
* of the creation transaction and an app client to interact with that app instance.
|
|
713
|
-
*
|
|
714
|
-
* Performs deploy-time TEAL template placeholder substitutions (if specified).
|
|
715
|
-
* @param params The parameters to create the app
|
|
716
|
-
* @returns The app client and the result of the creation transaction
|
|
717
|
-
*/
|
|
718
|
-
create: (params?: AppFactoryCreateParams & SendParams) => Promise<{
|
|
719
|
-
appClient: AppClient;
|
|
720
|
-
result: {
|
|
721
|
-
compiledApproval?: CompiledTeal | undefined;
|
|
722
|
-
compiledClear?: CompiledTeal | undefined;
|
|
723
|
-
return: undefined;
|
|
724
|
-
groupId: string | undefined;
|
|
725
|
-
txIds: string[];
|
|
726
|
-
returns?: ABIReturn[] | undefined;
|
|
727
|
-
confirmations: PendingTransactionResponse[];
|
|
728
|
-
transactions: Transaction[];
|
|
729
|
-
confirmation: PendingTransactionResponse;
|
|
730
|
-
transaction: Transaction;
|
|
731
|
-
appId: bigint;
|
|
732
|
-
appAddress: Address;
|
|
733
|
-
};
|
|
734
|
-
}>;
|
|
735
|
-
};
|
|
736
|
-
/**
|
|
737
|
-
* Creates an instance of the app and returns the result of the creation
|
|
738
|
-
* transaction and an app client to interact with that app instance.
|
|
739
|
-
*
|
|
740
|
-
* Performs deploy-time TEAL template placeholder substitutions (if specified).
|
|
741
|
-
* @param params The parameters to create the app
|
|
742
|
-
* @returns The app client and the result of the creation transaction
|
|
743
|
-
*/
|
|
744
|
-
create: (params: AppFactoryCreateMethodCallParams & SendParams) => Promise<{
|
|
745
|
-
appClient: AppClient;
|
|
746
|
-
result: {
|
|
747
|
-
compiledApproval?: CompiledTeal | undefined;
|
|
748
|
-
compiledClear?: CompiledTeal | undefined;
|
|
749
|
-
return: ABIValue | undefined;
|
|
750
|
-
groupId: string | undefined;
|
|
751
|
-
txIds: string[];
|
|
752
|
-
returns?: ABIReturn[] | undefined;
|
|
753
|
-
confirmations: PendingTransactionResponse[];
|
|
754
|
-
transactions: Transaction[];
|
|
755
|
-
confirmation: PendingTransactionResponse;
|
|
756
|
-
transaction: Transaction;
|
|
757
|
-
appId: bigint;
|
|
758
|
-
appAddress: Address;
|
|
759
|
-
};
|
|
760
|
-
}>;
|
|
761
|
-
};
|
|
762
|
-
/**
|
|
763
|
-
* Idempotently deploy (create if not exists, update if changed) an app against the given name for the given creator account, including deploy-time TEAL template placeholder substitutions (if specified).
|
|
764
|
-
*
|
|
765
|
-
* **Note:** When using the return from this function be sure to check `operationPerformed` to get access to various return properties like `transaction`, `confirmation` and `deleteResult`.
|
|
766
|
-
*
|
|
767
|
-
* **Note:** if there is a breaking state schema change to an existing app (and `onSchemaBreak` is set to `'replace'`) the existing app will be deleted and re-created.
|
|
768
|
-
*
|
|
769
|
-
* **Note:** if there is an update (different TEAL code) to an existing app (and `onUpdate` is set to `'replace'`) the existing app will be deleted and re-created.
|
|
770
|
-
* @param params The arguments to control the app deployment
|
|
771
|
-
* @returns The app client and the result of the deployment
|
|
772
|
-
* @example
|
|
773
|
-
* ```ts
|
|
774
|
-
* const { appClient, result } = await factory.deploy({
|
|
775
|
-
* createParams: {
|
|
776
|
-
* sender: 'SENDER_ADDRESS',
|
|
777
|
-
* approvalProgram: 'APPROVAL PROGRAM',
|
|
778
|
-
* clearStateProgram: 'CLEAR PROGRAM',
|
|
779
|
-
* schema: {
|
|
780
|
-
* globalByteSlices: 0,
|
|
781
|
-
* globalInts: 0,
|
|
782
|
-
* localByteSlices: 0,
|
|
783
|
-
* localInts: 0
|
|
784
|
-
* }
|
|
785
|
-
* },
|
|
786
|
-
* updateParams: {
|
|
787
|
-
* sender: 'SENDER_ADDRESS'
|
|
788
|
-
* },
|
|
789
|
-
* deleteParams: {
|
|
790
|
-
* sender: 'SENDER_ADDRESS'
|
|
791
|
-
* },
|
|
792
|
-
* onSchemaBreak: 'append',
|
|
793
|
-
* onUpdate: 'append'
|
|
794
|
-
* })
|
|
795
|
-
* ```
|
|
796
|
-
*/
|
|
797
|
-
deploy(params: AppFactoryDeployParams): Promise<{
|
|
798
|
-
appClient: AppClient;
|
|
799
|
-
result: {
|
|
800
|
-
return: ABIValue | undefined;
|
|
801
|
-
deleteReturn: ABIValue | undefined;
|
|
802
|
-
compiledApproval?: CompiledTeal | undefined;
|
|
803
|
-
compiledClear?: CompiledTeal | undefined;
|
|
804
|
-
operationPerformed: "create";
|
|
805
|
-
version: string;
|
|
806
|
-
updatable?: boolean | undefined;
|
|
807
|
-
deletable?: boolean | undefined;
|
|
808
|
-
createdRound: bigint;
|
|
809
|
-
updatedRound: bigint;
|
|
810
|
-
createdMetadata: AppDeployMetadata;
|
|
811
|
-
deleted: boolean;
|
|
812
|
-
name: string;
|
|
813
|
-
groupId: string | undefined;
|
|
814
|
-
txIds: string[];
|
|
815
|
-
returns?: ABIReturn[] | undefined;
|
|
816
|
-
confirmations: PendingTransactionResponse[];
|
|
817
|
-
transactions: Transaction[];
|
|
818
|
-
confirmation: PendingTransactionResponse;
|
|
819
|
-
transaction: Transaction;
|
|
820
|
-
appId: bigint;
|
|
821
|
-
appAddress: Address;
|
|
822
|
-
} | {
|
|
823
|
-
return: ABIValue | undefined;
|
|
824
|
-
deleteReturn: ABIValue | undefined;
|
|
825
|
-
compiledApproval?: CompiledTeal | undefined;
|
|
826
|
-
compiledClear?: CompiledTeal | undefined;
|
|
827
|
-
operationPerformed: "update";
|
|
828
|
-
appId: bigint;
|
|
829
|
-
appAddress: Address;
|
|
830
|
-
createdRound: bigint;
|
|
831
|
-
updatedRound: bigint;
|
|
832
|
-
createdMetadata: AppDeployMetadata;
|
|
833
|
-
deleted: boolean;
|
|
834
|
-
name: string;
|
|
835
|
-
version: string;
|
|
836
|
-
deletable?: boolean | undefined;
|
|
837
|
-
updatable?: boolean | undefined;
|
|
838
|
-
groupId: string | undefined;
|
|
839
|
-
txIds: string[];
|
|
840
|
-
returns?: ABIReturn[] | undefined;
|
|
841
|
-
confirmations: PendingTransactionResponse[];
|
|
842
|
-
transactions: Transaction[];
|
|
843
|
-
confirmation: PendingTransactionResponse;
|
|
844
|
-
transaction: Transaction;
|
|
845
|
-
} | {
|
|
846
|
-
return: ABIValue | undefined;
|
|
847
|
-
deleteReturn: ABIValue | undefined;
|
|
848
|
-
compiledApproval?: CompiledTeal | undefined;
|
|
849
|
-
compiledClear?: CompiledTeal | undefined;
|
|
850
|
-
operationPerformed: "replace";
|
|
851
|
-
version: string;
|
|
852
|
-
updatable?: boolean | undefined;
|
|
853
|
-
deletable?: boolean | undefined;
|
|
854
|
-
createdRound: bigint;
|
|
855
|
-
updatedRound: bigint;
|
|
856
|
-
createdMetadata: AppDeployMetadata;
|
|
857
|
-
deleted: boolean;
|
|
858
|
-
name: string;
|
|
859
|
-
groupId: string | undefined;
|
|
860
|
-
txIds: string[];
|
|
861
|
-
returns?: ABIReturn[] | undefined;
|
|
862
|
-
confirmations: PendingTransactionResponse[];
|
|
863
|
-
transactions: Transaction[];
|
|
864
|
-
confirmation: PendingTransactionResponse;
|
|
865
|
-
transaction: Transaction;
|
|
866
|
-
appId: bigint;
|
|
867
|
-
appAddress: Address;
|
|
868
|
-
deleteResult: ConfirmedTransactionResult;
|
|
869
|
-
} | {
|
|
870
|
-
return: ABIValue | undefined;
|
|
871
|
-
deleteReturn: ABIValue | undefined;
|
|
872
|
-
compiledApproval?: CompiledTeal | undefined;
|
|
873
|
-
compiledClear?: CompiledTeal | undefined;
|
|
874
|
-
operationPerformed: "nothing";
|
|
875
|
-
appId: bigint;
|
|
876
|
-
appAddress: Address;
|
|
877
|
-
createdRound: bigint;
|
|
878
|
-
updatedRound: bigint;
|
|
879
|
-
createdMetadata: AppDeployMetadata;
|
|
880
|
-
deleted: boolean;
|
|
881
|
-
name: string;
|
|
882
|
-
version: string;
|
|
883
|
-
deletable?: boolean | undefined;
|
|
884
|
-
updatable?: boolean | undefined;
|
|
885
|
-
};
|
|
886
|
-
}>;
|
|
887
|
-
/**
|
|
888
|
-
* Returns a new `AppClient` client for an app instance of the given ID.
|
|
889
|
-
*
|
|
890
|
-
* Automatically populates appName, defaultSender and source maps from the factory
|
|
891
|
-
* if not specified in the params.
|
|
892
|
-
* @param params The parameters to create the app client
|
|
893
|
-
* @returns The `AppClient` instance
|
|
894
|
-
* @example
|
|
895
|
-
* ```typescript
|
|
896
|
-
* const appClient = factory.getAppClientById({ appId: 12345n })
|
|
897
|
-
* ```
|
|
898
|
-
*/
|
|
899
|
-
getAppClientById(params: AppFactoryAppClientParams): AppClient;
|
|
900
|
-
/**
|
|
901
|
-
* Returns a new `AppClient` client, resolving the app by creator address and name
|
|
902
|
-
* using AlgoKit app deployment semantics (i.e. looking for the app creation transaction note).
|
|
903
|
-
*
|
|
904
|
-
* Automatically populates appName, defaultSender and source maps from the factory
|
|
905
|
-
* if not specified in the params.
|
|
906
|
-
* @param params The parameters to create the app client
|
|
907
|
-
* @returns The `AppClient` instance
|
|
908
|
-
* @example
|
|
909
|
-
* ```typescript
|
|
910
|
-
* const appClient = factory.getAppClientByCreatorAndName({ creatorAddress: 'CREATOR_ADDRESS', appName: 'my_app' })
|
|
911
|
-
* ```
|
|
912
|
-
*/
|
|
913
|
-
getAppClientByCreatorAndName(params: AppFactoryResolveAppClientByCreatorAndNameParams): Promise<AppClient>;
|
|
914
|
-
/**
|
|
915
|
-
* Takes an error that may include a logic error from a call to the current app and re-exposes the
|
|
916
|
-
* error to include source code information via the source map and ARC-56 spec.
|
|
917
|
-
* @param e The error to parse
|
|
918
|
-
* @param isClearStateProgram Whether or not the code was running the clear state program (defaults to approval program)
|
|
919
|
-
* @returns The new error, or if there was no logic error or source map then the wrapped error with source details
|
|
920
|
-
*/
|
|
921
|
-
exposeLogicError(e: Error, isClearStateProgram?: boolean): Error;
|
|
922
|
-
/**
|
|
923
|
-
* Export the current source maps for the app.
|
|
924
|
-
* @returns The source maps
|
|
925
|
-
*/
|
|
926
|
-
exportSourceMaps(): AppSourceMaps;
|
|
927
|
-
/**
|
|
928
|
-
* Import source maps for the app.
|
|
929
|
-
* @param sourceMaps The source maps to import
|
|
930
|
-
*/
|
|
931
|
-
importSourceMaps(sourceMaps: AppSourceMaps): void;
|
|
932
|
-
private getDeployTimeControl;
|
|
933
|
-
private getParamsMethods;
|
|
934
|
-
/** Make the given call and catch any errors, augmenting with debugging information before re-throwing. */
|
|
935
|
-
private handleCallErrors;
|
|
936
|
-
/**
|
|
937
|
-
* Compiles the approval and clear state programs (if TEAL templates provided),
|
|
938
|
-
* performing any provided deploy-time parameter replacement and stores
|
|
939
|
-
* the source maps.
|
|
940
|
-
*
|
|
941
|
-
* If no TEAL templates provided it will use any byte code provided in the app spec.
|
|
942
|
-
*
|
|
943
|
-
* Will store any generated source maps for later use in debugging.
|
|
944
|
-
* @param compilation Optional compilation parameters to use for the compilation
|
|
945
|
-
* @returns The compilation result
|
|
946
|
-
* @example
|
|
947
|
-
* ```typescript
|
|
948
|
-
* const result = await factory.compile()
|
|
949
|
-
* ```
|
|
950
|
-
*/
|
|
951
|
-
compile(compilation?: AppClientCompilationParams): Promise<AppClientCompilationResult>;
|
|
952
|
-
private getBareParams;
|
|
953
|
-
private getABIParams;
|
|
954
|
-
private getCreateABIArgsWithDefaultValues;
|
|
955
|
-
/** Returns the sender for a call, using the `defaultSender`
|
|
956
|
-
* if none provided and throws an error if neither provided */
|
|
957
|
-
private getSender;
|
|
958
|
-
/** Returns the signer for a call, using the provided signer or the `defaultSigner`
|
|
959
|
-
* if no signer was provided and the sender resolves to the default sender, the call will use default signer
|
|
960
|
-
* or `undefined` otherwise (so the signer is resolved from `AlgorandClient`) */
|
|
961
|
-
private getSigner;
|
|
962
|
-
}
|
|
4
|
+
/** @deprecated Import from `@algorandfoundation/algokit-utils/app-factory` instead */
|
|
5
|
+
type AppFactoryParams = AppFactoryParams$1;
|
|
6
|
+
/** @deprecated Import from `@algorandfoundation/algokit-utils/app-factory` instead */
|
|
7
|
+
type CreateOnComplete = CreateOnComplete$1;
|
|
8
|
+
/** @deprecated Import from `@algorandfoundation/algokit-utils/app-factory` instead */
|
|
9
|
+
type CreateSchema = CreateSchema$1;
|
|
10
|
+
/** @deprecated Import from `@algorandfoundation/algokit-utils/app-factory` instead */
|
|
11
|
+
type AppFactoryCreateParams = AppFactoryCreateParams$1;
|
|
12
|
+
/** @deprecated Import from `@algorandfoundation/algokit-utils/app-factory` instead */
|
|
13
|
+
type AppFactoryCreateMethodCallParams = AppFactoryCreateMethodCallParams$1;
|
|
14
|
+
/** @deprecated Import from `@algorandfoundation/algokit-utils/app-factory` instead */
|
|
15
|
+
type AppFactoryAppClientParams = AppFactoryAppClientParams$1;
|
|
16
|
+
/** @deprecated Import from `@algorandfoundation/algokit-utils/app-factory` instead */
|
|
17
|
+
type AppFactoryResolveAppClientByCreatorAndNameParams = AppFactoryResolveAppClientByCreatorAndNameParams$1;
|
|
18
|
+
/** @deprecated Import from `@algorandfoundation/algokit-utils/app-factory` instead */
|
|
19
|
+
type AppFactoryDeployParams = AppFactoryDeployParams$1;
|
|
20
|
+
/** @deprecated Import from `@algorandfoundation/algokit-utils/app-factory` instead */
|
|
21
|
+
declare const AppFactory: typeof AppFactory$1;
|
|
22
|
+
/** @deprecated Import from `@algorandfoundation/algokit-utils/app-factory` instead */
|
|
23
|
+
type AppFactory = AppFactory$1;
|
|
963
24
|
//#endregion
|
|
964
25
|
export { AppFactory, AppFactoryAppClientParams, AppFactoryCreateMethodCallParams, AppFactoryCreateParams, AppFactoryDeployParams, AppFactoryParams, AppFactoryResolveAppClientByCreatorAndNameParams, CreateOnComplete, CreateSchema };
|
|
965
26
|
//# sourceMappingURL=app-factory.d.ts.map
|