Variable methodsConst

methods: {
    _getPollInterval: any;
    aensBid: any;
    aensClaim: any;
    aensPreclaim: any;
    aensQuery: any;
    aensRevoke: any;
    aensTransfer: any;
    aensUpdate: any;
    awaitHeight: any;
    buildAuthTxHash: any;
    buildAuthTxHashByGaMetaTx: any;
    createGeneralizedAccount: any;
    extendOracleTtl: any;
    getAccount: any;
    getBalance: any;
    getContract: any;
    getContractByteCode: any;
    getCurrentGeneration: any;
    getGeneration: any;
    getHeight: any;
    getKeyBlock: any;
    getMicroBlockHeader: any;
    getMicroBlockTransactions: any;
    getName: any;
    getOracleObject: any;
    getQueryObject: any;
    payForTransaction: any;
    poll: any;
    pollForQueries: any;
    pollForQueryResponse: any;
    postQueryToOracle: any;
    registerOracle: any;
    resolveName: any;
    respondToQuery: any;
    sendTransaction: any;
    spend: any;
    transferFunds: any;
    txDryRun: any;
    waitForTxConfirm: any;
    createDelegationSignature: ((contractAddress, ids, options) => Promise<Uint8Array>);
} = ...

Type declaration

  • createDelegationSignature: ((contractAddress, ids, options) => Promise<Uint8Array>)
      • (contractAddress, ids, options): Promise<Uint8Array>
      • Helper to generate a signature to delegate

        • pre-claim/claim/transfer/revoke of a name to a contract.
        • register/extend/respond of an Oracle to a contract.

        Parameters

        • contractAddress: `ct_${string}`

          Address of contract to delegate access

        • ids: (`${string}.chain` | `kh_${string}` | `mh_${string}` | `bf_${string}` | `bx_${string}` | `bs_${string}` | `ch_${string}` | `ct_${string}` | `cb_${string}` | `ck_${string}` | `cv_${string}` | `tx_${string}` | `th_${string}` | `ok_${string}` | `ov_${string}` | `oq_${string}` | `or_${string}` | `ak_${string}` | `sg_${string}` | `cm_${string}` | `pp_${string}` | `nm_${string}` | `st_${string}` | `pi_${string}` | `ss_${string}` | `cs_${string}` | `ba_${string}`)[]

          The list of id's to prepend

        • options: {
              omitAddress?: boolean;
              onAccount: AccountBase;
              onNode: Node;
          }

          Options

          • Optional omitAddress?: boolean

            Prepend delegation signature with an account address

          • onAccount: AccountBase

            Account to use

          • onNode: Node

            Node to use

        Returns Promise<Uint8Array>

        Signature

        Deprecated

        use methods sign*DelegationToContract of Account instance instead

        Example

        const aeSdk = new AeSdk({ ... })
        const contractAddress = 'ct_asd2ks...'
        const aensName = 'example.chain'
        const onAccount = new MemoryAccount(...) // Sign with a specific account
        // Preclaim signature
        const preclaimSig = await aeSdk.createDelegationSignature(contractAddress, [], { onAccount })
        // Claim, transfer and revoke signature
        const aensDelegationSig = await aeSdk
        .createDelegationSignature(contractAddress, [aensName], { onAccount })

        const oracleQueryId = 'oq_...'
        const onAccount = new MemoryAccount(...) // Sign with a specific account
        // Oracle register and extend signature
        const oracleDelegationSig = await aeSdk
        .createDelegationSignature(contractAddress, [], { onAccount })
        // Oracle respond signature
        const respondSig = await aeSdk
        .createDelegationSignature(contractAddress, [oracleQueryId], { onAccount, omitAddress: true })

Generated using TypeDoc