2026-02-10 14:14:00 -08:00
2023-01-15 13:52:19 -05:00
2026-02-10 14:14:00 -08:00
2023-01-15 13:52:19 -05:00
2023-01-15 13:52:19 -05:00
2023-01-15 13:52:19 -05:00
2023-01-15 13:52:19 -05:00
2023-01-15 13:52:19 -05:00
2023-01-15 16:07:25 -05:00
2023-11-10 09:29:53 -08:00
2026-02-10 14:14:00 -08:00
2023-02-28 16:50:46 -05:00
2023-01-15 13:52:19 -05:00
2023-11-10 09:29:43 -08:00

@wharfkit/transact-plugin-cosigner

Automatically cosign transactions to assume resource costs using a noop action.

Installation

yarn install @wharfkit/transact-plugin-cosigner

Usage

Include this transactPlugin in your Wharf Session Kit instance and specify the relevant information.

const session = new Session(
    {
        chain: {
            id: '73e4385a2708e6d7048834fbc1079f2fabb17b3c125b146af438971e90716c4d',
            url: 'https://jungle4.greymass.com',
        },
        permissionLevel: 'wharfkit1111@test',
        walletPlugin: wallet,
    },
    {
        transactPlugins: [
            new TransactPluginCosigner({
                actor: 'wharfkitnoop',
                permission: 'cosign',
                privateKey: '5JfFWg1CWsNTeXTWMyfChXXbyD31TCTknSVGwXDSpT6bPxKYLMM',
            }),
        ],
    }
)

Any transaction initiated with this session will automatically prepend a greymassnoop:noop action and sign it using the permissions specified for the TransactPluginCosigner.

Developing

You need Make, node.js and yarn installed.

Clone the repository and run make to checkout all dependencies and build the project. See the Makefile for other useful targets. Before submitting a pull request make sure to run make lint.


Made with & ❤️ by Greymass, if you find this useful please consider supporting us.

S
Description
TransactPlugin for the Wharf Session Kit. Cosign all transactions with a given private key to cover resource costs.
Readme BSD-3-Clause 155 KiB
Languages
TypeScript 53.3%
JavaScript 30%
Makefile 16.7%