Options
All
  • Public
  • Public/Protected
  • All
Menu

@cityofzion/wallet-connect-sdk-core

Index

Type aliases

ContractInvocation

ContractInvocation: { abortOnFail?: boolean; args: Argument[]; operation: string; scriptHash: string }

A simple interface that defines the invocation options

Type declaration

  • Optional abortOnFail?: boolean

    When requesting multiple invocations, you can set abortOnFail to true on some invocations so the VM will abort the rest of the calls if this invocation returns false

  • args: Argument[]

    The parameters to be sent to the method

  • operation: string

    The SmartContract's method name

  • scriptHash: string

    The SmartContract ScriptHash

ContractInvocationMulti

ContractInvocationMulti: { invocations: ContractInvocation[]; signers: Signer[] }

A simple interface that defines the MultiInvoke options

Type declaration

SignedMessage

SignedMessage: { data: string; messageHex: string; publicKey: string; salt: string }

A simple interface that defines the Signed Message format

Type declaration

  • data: string

    encrypted message

  • messageHex: string

    message hex

  • publicKey: string

    signer's public key

  • salt: string

    salt used to encrypt

Signer

Signer: { allowedContracts?: string[]; allowedGroups?: string[]; scopes: WitnessScope }

A simple interface that defines the signing options, which privileges the user needs to give for the SmartContract. Usually the default signer is enough: { scopes: WitnessScope.CalledByEntry } But you may need additional authorization, for instance, allow the SmartContract to invoke another specific contract:

{
scopes: WitnessScope.CustomContracts,
allowedContracts: ['0xf970f4ccecd765b63732b821775dc38c25d74f23']
}

Type declaration

  • Optional allowedContracts?: string[]

    When the scopes is WitnessScope.CustomContracts, you need to specify which contracts are allowed

  • Optional allowedGroups?: string[]

    When the scopes is WitnessScope.CustomGroups, you need to specify which groups are allowed

  • scopes: WitnessScope

    The level of permission the invocation needs

WCMethodType

WCMethodType: typeof SUPPORTED_WC_METHODS[number]

A list of types supported by wallets

Generated using TypeDoc