dot-vote-relayer
TypeScript icon, indicating that this package has built-in type declarations

2.2.1 • Public • Published

Dot-Vote-Relayer

Dot-Vote-Relayer relays signatures created on a Dot-Vote website. To use Dot-Vote-Relayer, import the relayer to your file using const { Relayer } = require("dot-vote-relayer");.

Create a config for your relayer which contains the following fields:

  • ethRpcUrl - String
  • mongoDbUrl - String
  • governorAddress - Address
  • tokenAddress - Address
  • governorVoteFunction - String
  • governorGetProposalFunction - String
  • governorGetReceiptFunction - String
  • relayerPk - String
  • notificationHook - String
  • relayAtBlocks - array of integers

There is also an optional notificationHook field which can be used to send telegram notifications.

The ABI for your governor and governance token must be placed in the root directory and be named governor.abi and token.abi.

Then start your relayer as follows:

const relayer = new Relayer(config);
relayer.start();

For an example integration, see dydx-relayer.

Readme

Keywords

none

Package Sidebar

Install

npm i dot-vote-relayer

Weekly Downloads

2

Version

2.2.1

License

MIT

Unpacked Size

41.4 kB

Total Files

37

Last publish

Collaborators

  • arr00