# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
import grpc

from speechly.analytics.v1 import analytics_api_pb2 as speechly_dot_analytics_dot_v1_dot_analytics__api__pb2


class AnalyticsAPIStub(object):
  """Speechly Analytics API contains methods to get accumulated access data
  for given apps and/or projects.
  """

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

    Args:
      channel: A grpc.Channel.
    """
    self.UtteranceStatistics = channel.unary_unary(
        '/speechly.analytics.v1.AnalyticsAPI/UtteranceStatistics',
        request_serializer=speechly_dot_analytics_dot_v1_dot_analytics__api__pb2.UtteranceStatisticsRequest.SerializeToString,
        response_deserializer=speechly_dot_analytics_dot_v1_dot_analytics__api__pb2.UtteranceStatisticsResponse.FromString,
        )


class AnalyticsAPIServicer(object):
  """Speechly Analytics API contains methods to get accumulated access data
  for given apps and/or projects.
  """

  def UtteranceStatistics(self, request, context):
    """Get a summary of utterances for a given time period.
    """
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')


def add_AnalyticsAPIServicer_to_server(servicer, server):
  rpc_method_handlers = {
      'UtteranceStatistics': grpc.unary_unary_rpc_method_handler(
          servicer.UtteranceStatistics,
          request_deserializer=speechly_dot_analytics_dot_v1_dot_analytics__api__pb2.UtteranceStatisticsRequest.FromString,
          response_serializer=speechly_dot_analytics_dot_v1_dot_analytics__api__pb2.UtteranceStatisticsResponse.SerializeToString,
      ),
  }
  generic_handler = grpc.method_handlers_generic_handler(
      'speechly.analytics.v1.AnalyticsAPI', rpc_method_handlers)
  server.add_generic_rpc_handlers((generic_handler,))
