Node: {
    methods: {
        getStatus: {
            I: typeof GetStatusRequest;
            O: typeof Status;
            kind: Unary;
            name: "GetStatus";
        };
        negotiateDataChannel: {
            I: typeof DataChannelNegotiation;
            O: typeof DataChannelNegotiation;
            kind: BiDiStreaming;
            name: "NegotiateDataChannel";
        };
        receiveSignalChannel: {
            I: typeof WebRTCSignal;
            O: typeof WebRTCSignal;
            kind: BiDiStreaming;
            name: "ReceiveSignalChannel";
        };
    };
    typeName: "v1.Node";
} = ...

Node is the service exposed on every node in the mesh to communicate network information amongst themselves and facilitate inbound/outbound connections.

Type declaration

  • Readonly methods: {
        getStatus: {
            I: typeof GetStatusRequest;
            O: typeof Status;
            kind: Unary;
            name: "GetStatus";
        };
        negotiateDataChannel: {
            I: typeof DataChannelNegotiation;
            O: typeof DataChannelNegotiation;
            kind: BiDiStreaming;
            name: "NegotiateDataChannel";
        };
        receiveSignalChannel: {
            I: typeof WebRTCSignal;
            O: typeof WebRTCSignal;
            kind: BiDiStreaming;
            name: "ReceiveSignalChannel";
        };
    }
    • Readonly getStatus: {
          I: typeof GetStatusRequest;
          O: typeof Status;
          kind: Unary;
          name: "GetStatus";
      }

      GetStatus gets the status of a node in the cluster. If the node is not able to return the status of the ID requested, it should return an error.

      Generated

      from rpc v1.Node.GetStatus

    • Readonly negotiateDataChannel: {
          I: typeof DataChannelNegotiation;
          O: typeof DataChannelNegotiation;
          kind: BiDiStreaming;
          name: "NegotiateDataChannel";
      }

      NegotiateDataChannel is used to negotiate a WebRTC connection between a webmesh client and a node in the cluster. The handling server will send the target node the source address, the destination for traffic, and STUN/TURN servers to use for the negotiation. The node responds with an offer to be forwarded to the client. When the handler receives an answer from the client, it forwards it to the node. Once the node receives the answer, the stream can optionally be used to exchange ICE candidates.

      Generated

      from rpc v1.Node.NegotiateDataChannel

    • Readonly receiveSignalChannel: {
          I: typeof WebRTCSignal;
          O: typeof WebRTCSignal;
          kind: BiDiStreaming;
          name: "ReceiveSignalChannel";
      }

      ReceiveSignalChannel is used to receive a request to start a WebRTC connection between a remote node and this node. The node should wait for the client to send an offer, and then respond with an answer. Once the node receives the answer, the stream can optionally be used to exchange ICE candidates.

      Generated

      from rpc v1.Node.ReceiveSignalChannel

      • Readonly I: typeof WebRTCSignal
      • Readonly O: typeof WebRTCSignal
      • Readonly kind: BiDiStreaming
      • Readonly name: "ReceiveSignalChannel"
  • Readonly typeName: "v1.Node"

Generated

from service v1.Node

Generated using TypeDoc