Class TestnetWorker

The main interface to near-workspaces. Create a new worker instance with init, then run code on it.

Hierarchy

Constructors

Properties

config: Config

Accessors

Methods

  • Initialize a new worker.

    In local sandbox mode, this will:

    • Create a new local blockchain
    • Load the root account for that blockchain, available as root:

    In testnet mode, the same functionality is achieved via different means: creating a new account as the root. Since all actions must occur on one blockchain instead of N.

    Parameters

    • config: Partial<Config>

      a configuration object

    Returns Promise<TestnetWorker>

    an instance of the Worker class

Generated using TypeDoc