Function getContractUpdateEnergyCost

  • Get contract update energy cost Estimated by calculateEnergyCost, where transactionSpecificCost received from invokeContract used energy

    Throws

    'no response' if either the block does not exist, or then node fails to parse any of the inputs If the response tag is failure, then error contains a response message

    Returns

    estimated amount of energy for the last finalized block according to the node, this means that the actual energy cost might be different depending on the implementation of the smart contract and the interaction with the instance, since this was estimated

    Parameters

    • grpcClient: ConcordiumGRPCClient

      The client to be used for the query

    • contractAddress: ContractAddress

      The address of the contract to query

    • invoker: AccountAddress

      Representation of an account address

    • parameter: Parameter

      Input for contract function

    • method: ReceiveName

      Represents a receive-function in a smart contract module

    • signatureCount: bigint

      Number of expected signatures

    • Optional blockHash: BlockHash

      Optional block hash allowing for dry-running the contract update at the end of a specific block.

    Returns Promise<Energy.Type>

Generated using TypeDoc