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

from yandex.cloud.access import access_pb2 as yandex_dot_cloud_dot_access_dot_access__pb2
from yandex.cloud.operation import operation_pb2 as yandex_dot_cloud_dot_operation_dot_operation__pb2
from yandex.cloud.serverless.apigateway.v1 import apigateway_pb2 as yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__pb2
from yandex.cloud.serverless.apigateway.v1 import apigateway_service_pb2 as yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2


class ApiGatewayServiceStub(object):
    """A set of methods for managing API gateways.
    """

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

        Args:
            channel: A grpc.Channel.
        """
        self.Get = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/Get',
                request_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.GetApiGatewayRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__pb2.ApiGateway.FromString,
                )
        self.List = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/List',
                request_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListApiGatewayRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListApiGatewayResponse.FromString,
                )
        self.Create = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/Create',
                request_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.CreateApiGatewayRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
                )
        self.Update = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/Update',
                request_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.UpdateApiGatewayRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
                )
        self.Delete = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/Delete',
                request_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.DeleteApiGatewayRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
                )
        self.AddDomain = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/AddDomain',
                request_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.AddDomainRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
                )
        self.RemoveDomain = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/RemoveDomain',
                request_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.RemoveDomainRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
                )
        self.GetOpenapiSpec = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/GetOpenapiSpec',
                request_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.GetOpenapiSpecRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.GetOpenapiSpecResponse.FromString,
                )
        self.ListOperations = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/ListOperations',
                request_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListOperationsRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListOperationsResponse.FromString,
                )
        self.ListAccessBindings = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/ListAccessBindings',
                request_serializer=yandex_dot_cloud_dot_access_dot_access__pb2.ListAccessBindingsRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_access_dot_access__pb2.ListAccessBindingsResponse.FromString,
                )
        self.SetAccessBindings = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/SetAccessBindings',
                request_serializer=yandex_dot_cloud_dot_access_dot_access__pb2.SetAccessBindingsRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
                )
        self.UpdateAccessBindings = channel.unary_unary(
                '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/UpdateAccessBindings',
                request_serializer=yandex_dot_cloud_dot_access_dot_access__pb2.UpdateAccessBindingsRequest.SerializeToString,
                response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
                )


class ApiGatewayServiceServicer(object):
    """A set of methods for managing API gateways.
    """

    def Get(self, request, context):
        """Returns the specified API gateway. Note that only API gateway basic attributes are returned.
        To get associated openapi specification, make a [GetOpenapiSpec](#GetOpenapiSpec) request.

        To get the list of all available API gateways, make a [List] request.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def List(self, request, context):
        """Retrieves the list of API gateways in the specified folder.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def Create(self, request, context):
        """Creates an API gateway in the specified folder.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def Update(self, request, context):
        """Updates the specified API gateway.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def Delete(self, request, context):
        """Deletes the specified API gateway.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def AddDomain(self, request, context):
        """Attaches domain to the specified API gateway.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def RemoveDomain(self, request, context):
        """Detaches domain from the specified API gateway.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def GetOpenapiSpec(self, request, context):
        """Returns the OpenAPI specification of specified API gateway.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def ListOperations(self, request, context):
        """Lists operations for the specified API gateway.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def ListAccessBindings(self, request, context):
        """Lists existing access bindings for the specified API gateway.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def SetAccessBindings(self, request, context):
        """Sets access bindings for the specified API gateway.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def UpdateAccessBindings(self, request, context):
        """Updates access bindings for the specified API gateway.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')


def add_ApiGatewayServiceServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'Get': grpc.unary_unary_rpc_method_handler(
                    servicer.Get,
                    request_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.GetApiGatewayRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__pb2.ApiGateway.SerializeToString,
            ),
            'List': grpc.unary_unary_rpc_method_handler(
                    servicer.List,
                    request_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListApiGatewayRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListApiGatewayResponse.SerializeToString,
            ),
            'Create': grpc.unary_unary_rpc_method_handler(
                    servicer.Create,
                    request_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.CreateApiGatewayRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
            ),
            'Update': grpc.unary_unary_rpc_method_handler(
                    servicer.Update,
                    request_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.UpdateApiGatewayRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
            ),
            'Delete': grpc.unary_unary_rpc_method_handler(
                    servicer.Delete,
                    request_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.DeleteApiGatewayRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
            ),
            'AddDomain': grpc.unary_unary_rpc_method_handler(
                    servicer.AddDomain,
                    request_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.AddDomainRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
            ),
            'RemoveDomain': grpc.unary_unary_rpc_method_handler(
                    servicer.RemoveDomain,
                    request_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.RemoveDomainRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
            ),
            'GetOpenapiSpec': grpc.unary_unary_rpc_method_handler(
                    servicer.GetOpenapiSpec,
                    request_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.GetOpenapiSpecRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.GetOpenapiSpecResponse.SerializeToString,
            ),
            'ListOperations': grpc.unary_unary_rpc_method_handler(
                    servicer.ListOperations,
                    request_deserializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListOperationsRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListOperationsResponse.SerializeToString,
            ),
            'ListAccessBindings': grpc.unary_unary_rpc_method_handler(
                    servicer.ListAccessBindings,
                    request_deserializer=yandex_dot_cloud_dot_access_dot_access__pb2.ListAccessBindingsRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_access_dot_access__pb2.ListAccessBindingsResponse.SerializeToString,
            ),
            'SetAccessBindings': grpc.unary_unary_rpc_method_handler(
                    servicer.SetAccessBindings,
                    request_deserializer=yandex_dot_cloud_dot_access_dot_access__pb2.SetAccessBindingsRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
            ),
            'UpdateAccessBindings': grpc.unary_unary_rpc_method_handler(
                    servicer.UpdateAccessBindings,
                    request_deserializer=yandex_dot_cloud_dot_access_dot_access__pb2.UpdateAccessBindingsRequest.FromString,
                    response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'yandex.cloud.serverless.apigateway.v1.ApiGatewayService', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


 # This class is part of an EXPERIMENTAL API.
class ApiGatewayService(object):
    """A set of methods for managing API gateways.
    """

    @staticmethod
    def Get(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/Get',
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.GetApiGatewayRequest.SerializeToString,
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__pb2.ApiGateway.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def List(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/List',
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListApiGatewayRequest.SerializeToString,
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListApiGatewayResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def Create(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/Create',
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.CreateApiGatewayRequest.SerializeToString,
            yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def Update(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/Update',
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.UpdateApiGatewayRequest.SerializeToString,
            yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def Delete(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/Delete',
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.DeleteApiGatewayRequest.SerializeToString,
            yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def AddDomain(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/AddDomain',
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.AddDomainRequest.SerializeToString,
            yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def RemoveDomain(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/RemoveDomain',
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.RemoveDomainRequest.SerializeToString,
            yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def GetOpenapiSpec(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/GetOpenapiSpec',
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.GetOpenapiSpecRequest.SerializeToString,
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.GetOpenapiSpecResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def ListOperations(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/ListOperations',
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListOperationsRequest.SerializeToString,
            yandex_dot_cloud_dot_serverless_dot_apigateway_dot_v1_dot_apigateway__service__pb2.ListOperationsResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def ListAccessBindings(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/ListAccessBindings',
            yandex_dot_cloud_dot_access_dot_access__pb2.ListAccessBindingsRequest.SerializeToString,
            yandex_dot_cloud_dot_access_dot_access__pb2.ListAccessBindingsResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def SetAccessBindings(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/SetAccessBindings',
            yandex_dot_cloud_dot_access_dot_access__pb2.SetAccessBindingsRequest.SerializeToString,
            yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def UpdateAccessBindings(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, '/yandex.cloud.serverless.apigateway.v1.ApiGatewayService/UpdateAccessBindings',
            yandex_dot_cloud_dot_access_dot_access__pb2.UpdateAccessBindingsRequest.SerializeToString,
            yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
