Honeycomb class provides a client for interacting with Solana programs (Particulary Honycomb Protocol programs).

Hierarchy

  • Honeycomb

Constructors

  • Constructs a new instance of the Honeycomb client.

    Parameters

    • connectionOrRpc: string | Connection

      The connection to the Solana blockchain or RPC URL.

    • Optional args: {
          confirmOptions?: ConfirmOptions;
          env?: string;
      }

      Additional configuration options for Honeycomb.

      • Optional confirmOptions?: ConfirmOptions
      • Optional env?: string

    Returns Honeycomb

Properties

_emitter: EventEmitter

An EventEmitter to handle custom events in Honeycomb.

_projects: {
    [key: string]: HoneycombProject;
}

Type declaration

connection: Connection

A connection to a Solana JSON RPC endpoint.

env: string

The environment setting for Honeycomb, defaulting to "main".

programId: PublicKey

The program ID of the Honeycomb hive cotrol program.

Accessors

  • get cluster(): "mainnet-beta" | "devnet" | "testnet" | "custom"
  • Get the cluster name based on the RPC endpoint.

    Returns "mainnet-beta" | "devnet" | "testnet" | "custom"

  • get confirmOptions(): ConfirmOptions
  • Get the options for sending ad confirming transactions on the Solana blockchain.

    Returns ConfirmOptions

  • set confirmOptions(confirmOptions): void
  • Set the options for sending ad confirming transactions on the Solana blockchain.

    Parameters

    • confirmOptions: ConfirmOptions

    Returns void

  • get processedConnection(): Connection
  • Get a connection object with processed connnection.

    Returns Connection

  • get rpcEndpoint(): string
  • Get the RPC endpoint of the current connection.

    Returns string

Methods

  • Returns HttpModule

  • Unsubscribe from a custom event in Honeycomb.

    Parameters

    • event: "install"

      The name of the custom event to unsubscribe from.

    • listener: ((...args) => void)

      The event listener function to be removed.

        • (...args): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns Honeycomb

    The Honeycomb client instance.

  • Subscribe to a custom event in Honeycomb.

    Parameters

    • event: "install"

      The name of the custom event to subscribe to.

    • listener: ((...args) => void)

      The event listener function.

        • (...args): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns Honeycomb

    The Honeycomb client instance.

  • Parameters

    • Optional key: string | PublicKey

    Returns HoneycombProject

  • Fetch the public information for the specified environment.

    Parameters

    • Optional env: string

      The environment for which to fetch public information.

    • Optional reFetch: boolean

      If true, re-fetches the public information even if it's already cached.

    Returns Promise<Map<String, string>>

    A Promise containing the public information as a map of labels and their corresponding values.

  • Returns RpcClient

  • Use a module in the Honeycomb client.

    Parameters

    • module: Module

      The module to install and use.

    Returns Honeycomb

    The Honeycomb client instance.

Generated using TypeDoc