How to use @taquito/signer - 1 common examples

To help you get started, we’ve selected a few @taquito/signer examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ecadlabs / taquito / example / contract-schema.ts View on Github external
async function example() {
    const provider = 'https://alphanet-node.tzscan.io';
    const signer: any = new InMemorySigner('edsk3xkqabYfWWpcEKTWk75cRQv2bgHA3EHuuHSFH3ejqzKPx69Zh9');
    Tezos.setProvider({ rpc: provider, signer });
    try {
        const contract = await Tezos.contract.at('KT1SawqvsVdAbDzqc4KwPpaS1S1veuFgF9AN');
        console.log("Printing contract methods...");
        console.log(contract.methods);
        console.log("Showing initial storage...");
        console.log(await contract.storage())
        const op = await contract.methods.mint("tz1QZ6KY7d3BuZDT1d19dUxoQrtFPN2QJ3hn", 100).send({ fee: 30000, gasLimit: 200000 })
        console.log('Awaiting confirmation...');
        await op.confirmation();
        console.log(op.hash, op.includedInBlock);
        console.log("Showing final storage...");
        console.log(await contract.storage())
    } catch (ex) {
        console.log(ex)
    }

@taquito/signer

Provide signing functionality to be with taquito

Apache-2.0
Latest version published 5 days ago

Package Health Score

63 / 100
Full package analysis

Popular @taquito/signer functions