Skip to content

AbiMethodConfig

Algorand TypeScript


Algorand TypeScript / arc4 / AbiMethodConfig

AbiMethodConfig<TContract> = object

Defined in: arc4/index.ts:103

Configuration options for an abi method

TContract extends Contract

the type of the contract this method is a part of

optional allowActions: OnCompleteActionStr | OnCompleteActionStr[]

Defined in: arc4/index.ts:108

Which on complete action(s) are allowed when invoking this method.

'NoOp';

optional defaultArguments: Record<string, DefaultArgument<TContract>>

Defined in: arc4/index.ts:147

Specify default arguments that can be populated by clients calling this method.

A map of parameter names to the default argument source


optional name: string

Defined in: arc4/index.ts:122

Override the name used to generate the abi method selector


optional onCreate: CreateOptions

Defined in: arc4/index.ts:113

Whether this method should be callable when creating the application.

'disallow';

optional readonly: boolean

Defined in: arc4/index.ts:118

Does the method only perform read operations (no mutation of chain state)

false;

optional resourceEncoding: ResourceEncodingOptions

Defined in: arc4/index.ts:131

The resource encoding to use for this method. The default is ‘value’

index: Application, Asset, and Account arguments are included in the transaction’s relevant array. The argument value is the uint8 index of the resource in the that array. value: Application, Asset and Account arguments are passed by their uint64 id (Application and Asset) or bytes[32] address (Account).

The resource must still be ‘available’ to this transaction but can take advantage of resource sharing within the transaction group.


optional validateEncoding: ValidateEncodingOptions

Defined in: arc4/index.ts:140

Controls validation behaviour for this method.

If “args”, then ABI arguments are validated automatically to ensure they are encoded correctly. If “unsafe-disabled”, then no automatic validation occurs. Arguments can instead be validated using the validateEncoding(…) function. The default behaviour of this option can be controlled with the —validate-abi-args CLI flag.