@nilfoundation/niljs
Classes
Class | Description |
---|---|
BlockNotFoundError | The error class for 'block not found' errors. This error is thrown when the requested block is not found. |
ExternalMessageEnvelope | The envelope for an external message (a message sent by a user, a dApp, etc.) |
Faucet | Faucet is a special contract that is used to top up other contracts in the =nil; devnet. |
HttpTransport | HttpTransport represents the HTTP transport for connecting to the network. |
ITransport | The transport interface. |
InternalMessageEnvelope | The envelope for an internal message (a message sent by a smart contract to another smart contract). |
InvalidShardIdError | The error class for invalid shard ID. This error is thrown when the provided shard ID is invalid. |
LocalECDSAKeySigner | LocalKeySigner is a class that allows for signing data with the private key. It uses the secp256k1 curve implementation by the @noble/curves/secp256k1 library. |
MetaMaskSigner | MetaMaskSigner is a class that allows for signing data using MetaMask. This signer can only be used inside a browser. |
MetaMaskTransport | MetaMask transport represents the MetaMask transport for connecting to the network. MetaMask transport can be used in browser only. MetaMaskTransport |
PublicClient | PublicClient is a class that allows for interacting with the network via the JSON-RPC API. It provides an abstraction of the connection to =nil;. PublicClient enables using API requests that do not require signing data (or otherwise using one's private key). |
WalletV1 | WalletV1 is a class used for performing operations on the cluster that require authentication. |
Interfaces
Interface | Description |
---|---|
IMessage | The interface for the message object. This object is used to represent a message in the client code. It may differ from the actual message object used inside the network. |
ISigner | The interface for the Signer class |
Type Aliases
Type alias | Description |
---|---|
Block | The block type. |
BlockTag | The block tag type. |
CallParams | Represents the message call params. |
DeployParams | Represents the params for deploying a smart contract. |
ExternalMessage | The external message type. |
Hex | The hex type. |
IClientBaseConfig | The client configuration that is shared between public and private clients. |
IDeployData | - |
IHttpTransportConfig | The interface representing the configuration of the HTTP transport. |
ILocalKeySignerConfig | The interface for the configuration object of LocalKeySigner. |
ILog | The log interface. |
IPrivateKey | IPrivateKey represents a private key in hexadecimal format. |
IPublicClientConfig | The type representing the config for the public client. |
IReceipt | The receipt interface. |
ISendMessageOptions | The options for sending a message. |
ISignature | The interface for the signature. It contains the r, s, and yParity values. |
ISignedMessage | The signed message interface. |
IWalletClientConfig | The type representing the config for the basic wallet. |
RequestParams | Represents the params for making a request to the wallet. |
SendMessageParams | Represents the params for sending a message. |
SendSyncMessageParams | Represents the params for sending a message synchronously. |
WalletV1Config | Represents the wallet configuration. |
Variables
Variable | Description |
---|---|
MINTER_ABI | The ABI of the minter contract. |
MINTER_ADDRESS | The address of the minter contract. |
SszMessageSchema | The SSZ schema for a message object. |
SszSignedMessageSchema | SSZ schema for a signed message object. Includes auth data in addition to all other message fields. |