# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
"""Client and server classes corresponding to protobuf-defined services."""

import grpc

from nodus.v1.mcp.v1 import (
    connection_pb2 as nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2,
)
from nodus.v1.nodes.v1 import (
    execution_pb2 as nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2,
)
from nodus.v1.service.v1 import (
    service_pb2 as nodus_dot_v1_dot_service_dot_v1_dot_service__pb2,
)


class NodusServiceStub(object):
    """Missing associated documentation comment in .proto file."""

    def __init__(self, channel):
        """Constructor.

        Args:
            channel: A grpc.Channel.
        """
        self.ExecuteNode = channel.unary_unary(
            "/nodus.v1.service.v1.NodusService/ExecuteNode",
            request_serializer=nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeRequest.SerializeToString,
            response_deserializer=nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeResponse.FromString,
            _registered_method=True,
        )
        self.ExecuteNodeStream = channel.unary_stream(
            "/nodus.v1.service.v1.NodusService/ExecuteNodeStream",
            request_serializer=nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeStreamRequest.SerializeToString,
            response_deserializer=nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeStreamResponse.FromString,
            _registered_method=True,
        )
        self.RegisterMCPServer = channel.unary_unary(
            "/nodus.v1.service.v1.NodusService/RegisterMCPServer",
            request_serializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.RegisterMCPServerRequest.SerializeToString,
            response_deserializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.RegisterMCPServerResponse.FromString,
            _registered_method=True,
        )
        self.ListMCPServers = channel.unary_unary(
            "/nodus.v1.service.v1.NodusService/ListMCPServers",
            request_serializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.ListMCPServersRequest.SerializeToString,
            response_deserializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.ListMCPServersResponse.FromString,
            _registered_method=True,
        )
        self.QueryMCPTools = channel.unary_unary(
            "/nodus.v1.service.v1.NodusService/QueryMCPTools",
            request_serializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.QueryMCPToolsRequest.SerializeToString,
            response_deserializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.QueryMCPToolsResponse.FromString,
            _registered_method=True,
        )
        self.CheckHealth = channel.unary_unary(
            "/nodus.v1.service.v1.NodusService/CheckHealth",
            request_serializer=nodus_dot_v1_dot_service_dot_v1_dot_service__pb2.CheckHealthRequest.SerializeToString,
            response_deserializer=nodus_dot_v1_dot_service_dot_v1_dot_service__pb2.CheckHealthResponse.FromString,
            _registered_method=True,
        )


class NodusServiceServicer(object):
    """Missing associated documentation comment in .proto file."""

    def ExecuteNode(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def ExecuteNodeStream(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def RegisterMCPServer(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def ListMCPServers(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def QueryMCPTools(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def CheckHealth(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")


def add_NodusServiceServicer_to_server(servicer, server):
    rpc_method_handlers = {
        "ExecuteNode": grpc.unary_unary_rpc_method_handler(
            servicer.ExecuteNode,
            request_deserializer=nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeRequest.FromString,
            response_serializer=nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeResponse.SerializeToString,
        ),
        "ExecuteNodeStream": grpc.unary_stream_rpc_method_handler(
            servicer.ExecuteNodeStream,
            request_deserializer=nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeStreamRequest.FromString,
            response_serializer=nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeStreamResponse.SerializeToString,
        ),
        "RegisterMCPServer": grpc.unary_unary_rpc_method_handler(
            servicer.RegisterMCPServer,
            request_deserializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.RegisterMCPServerRequest.FromString,
            response_serializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.RegisterMCPServerResponse.SerializeToString,
        ),
        "ListMCPServers": grpc.unary_unary_rpc_method_handler(
            servicer.ListMCPServers,
            request_deserializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.ListMCPServersRequest.FromString,
            response_serializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.ListMCPServersResponse.SerializeToString,
        ),
        "QueryMCPTools": grpc.unary_unary_rpc_method_handler(
            servicer.QueryMCPTools,
            request_deserializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.QueryMCPToolsRequest.FromString,
            response_serializer=nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.QueryMCPToolsResponse.SerializeToString,
        ),
        "CheckHealth": grpc.unary_unary_rpc_method_handler(
            servicer.CheckHealth,
            request_deserializer=nodus_dot_v1_dot_service_dot_v1_dot_service__pb2.CheckHealthRequest.FromString,
            response_serializer=nodus_dot_v1_dot_service_dot_v1_dot_service__pb2.CheckHealthResponse.SerializeToString,
        ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
        "nodus.v1.service.v1.NodusService", rpc_method_handlers
    )
    server.add_generic_rpc_handlers((generic_handler,))
    server.add_registered_method_handlers(
        "nodus.v1.service.v1.NodusService", rpc_method_handlers
    )


# This class is part of an EXPERIMENTAL API.
class NodusService(object):
    """Missing associated documentation comment in .proto file."""

    @staticmethod
    def ExecuteNode(
        request,
        target,
        options=(),
        channel_credentials=None,
        call_credentials=None,
        insecure=False,
        compression=None,
        wait_for_ready=None,
        timeout=None,
        metadata=None,
    ):
        return grpc.experimental.unary_unary(
            request,
            target,
            "/nodus.v1.service.v1.NodusService/ExecuteNode",
            nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeRequest.SerializeToString,
            nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )

    @staticmethod
    def ExecuteNodeStream(
        request,
        target,
        options=(),
        channel_credentials=None,
        call_credentials=None,
        insecure=False,
        compression=None,
        wait_for_ready=None,
        timeout=None,
        metadata=None,
    ):
        return grpc.experimental.unary_stream(
            request,
            target,
            "/nodus.v1.service.v1.NodusService/ExecuteNodeStream",
            nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeStreamRequest.SerializeToString,
            nodus_dot_v1_dot_nodes_dot_v1_dot_execution__pb2.ExecuteNodeStreamResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )

    @staticmethod
    def RegisterMCPServer(
        request,
        target,
        options=(),
        channel_credentials=None,
        call_credentials=None,
        insecure=False,
        compression=None,
        wait_for_ready=None,
        timeout=None,
        metadata=None,
    ):
        return grpc.experimental.unary_unary(
            request,
            target,
            "/nodus.v1.service.v1.NodusService/RegisterMCPServer",
            nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.RegisterMCPServerRequest.SerializeToString,
            nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.RegisterMCPServerResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )

    @staticmethod
    def ListMCPServers(
        request,
        target,
        options=(),
        channel_credentials=None,
        call_credentials=None,
        insecure=False,
        compression=None,
        wait_for_ready=None,
        timeout=None,
        metadata=None,
    ):
        return grpc.experimental.unary_unary(
            request,
            target,
            "/nodus.v1.service.v1.NodusService/ListMCPServers",
            nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.ListMCPServersRequest.SerializeToString,
            nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.ListMCPServersResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )

    @staticmethod
    def QueryMCPTools(
        request,
        target,
        options=(),
        channel_credentials=None,
        call_credentials=None,
        insecure=False,
        compression=None,
        wait_for_ready=None,
        timeout=None,
        metadata=None,
    ):
        return grpc.experimental.unary_unary(
            request,
            target,
            "/nodus.v1.service.v1.NodusService/QueryMCPTools",
            nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.QueryMCPToolsRequest.SerializeToString,
            nodus_dot_v1_dot_mcp_dot_v1_dot_connection__pb2.QueryMCPToolsResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )

    @staticmethod
    def CheckHealth(
        request,
        target,
        options=(),
        channel_credentials=None,
        call_credentials=None,
        insecure=False,
        compression=None,
        wait_for_ready=None,
        timeout=None,
        metadata=None,
    ):
        return grpc.experimental.unary_unary(
            request,
            target,
            "/nodus.v1.service.v1.NodusService/CheckHealth",
            nodus_dot_v1_dot_service_dot_v1_dot_service__pb2.CheckHealthRequest.SerializeToString,
            nodus_dot_v1_dot_service_dot_v1_dot_service__pb2.CheckHealthResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )
