@hardpointlabs/sdk
    Preparing search index...

    Class Sdk

    The single touchpoint to the Hardpoint SDK.

    Use Sdk.init to create or retrieve the singleton instance.

    Index

    Methods

    • Establish a tunnel to a service on your Hardpoint network.

      Locates the service and sets up an encrypted connection.

      Parameters

      Returns Promise<StreamLike>

      An encrypted tunnel to the desired service. For the most part you can treat this like a regular socket and pass it to any client library that takes a stream.

      See the docs for concrete examples with specific client libraries.

    • Establish a tunnel to a service on your Hardpoint network.

      Locates the service and sets up an encrypted connection. In contrast to Sdk.connect, this also creates a local UNIX socket listening for traffic from client libraries and pipes data between the tunnel and the UNIX socket.

      This is useful for client libraries that cannot directly accept a duplex.Stream-like object.

      Parameters

      Returns Promise<UnixSocketLike>

      A handle to the encrypted tunnel and UNIX socket ready to accept traffic. See UnixSocketLike for more information.

      See the docs for concrete examples with specific client libraries.

    • Initialize or retrieve the singleton SDK instance.

      This should only be done once on application startup. See SdkOptions for configuration options.

      Parameters

      Returns Sdk

      The singleton SDK instance