// Code generated by gRPC proto compiler.  DO NOT EDIT!
// source: keyapis/omnichat/v1/keyapis_omnichat_v1.proto

#if !defined(GPB_GRPC_PROTOCOL_ONLY) || !GPB_GRPC_PROTOCOL_ONLY
#import "keyapis/omnichat/v1/KeyapisOmnichatV1.pbrpc.h"
#import "keyapis/omnichat/v1/KeyapisOmnichatV1.pbobjc.h"
#import <ProtoRPC/ProtoRPCLegacy.h>
#import <RxLibrary/GRXWriter+Immediate.h>

#import "google/api/Annotations.pbobjc.h"
#import "google/api/FieldBehavior.pbobjc.h"

@implementation KEYAPISOMNICHATV1OmnichatService

#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wobjc-designated-initializers"

// Designated initializer
- (instancetype)initWithHost:(NSString *)host callOptions:(GRPCCallOptions *_Nullable)callOptions {
  return [super initWithHost:host
                 packageName:@"keyapis.omnichat.v1"
                 serviceName:@"OmnichatService"
                 callOptions:callOptions];
}

- (instancetype)initWithHost:(NSString *)host {
  return [super initWithHost:host
                 packageName:@"keyapis.omnichat.v1"
                 serviceName:@"OmnichatService"];
}

#pragma clang diagnostic pop

// Override superclass initializer to disallow different package and service names.
- (instancetype)initWithHost:(NSString *)host
                 packageName:(NSString *)packageName
                 serviceName:(NSString *)serviceName {
  return [self initWithHost:host];
}

- (instancetype)initWithHost:(NSString *)host
                 packageName:(NSString *)packageName
                 serviceName:(NSString *)serviceName
                 callOptions:(GRPCCallOptions *)callOptions {
  return [self initWithHost:host callOptions:callOptions];
}

#pragma mark - Class Methods

+ (instancetype)serviceWithHost:(NSString *)host {
  return [[self alloc] initWithHost:host];
}

+ (instancetype)serviceWithHost:(NSString *)host callOptions:(GRPCCallOptions *_Nullable)callOptions {
  return [[self alloc] initWithHost:host callOptions:callOptions];
}

#pragma mark - Method Implementations

#pragma mark GetAuth(GetAuthRequest) returns (GetAuthResponse)

/**
 * Метод получения хешированной инормации о пользователе.
 * Метод доступен для: master, employee
 *
 * This method belongs to a set of APIs that have been deprecated. Using the v2 API is recommended.
 */
- (void)getAuthWithRequest:(KEYAPISOMNICHATV1GetAuthRequest *)request handler:(void(^)(KEYAPISOMNICHATV1GetAuthResponse *_Nullable response, NSError *_Nullable error))handler{
  [[self RPCToGetAuthWithRequest:request handler:handler] start];
}
// Returns a not-yet-started RPC object.
/**
 * Метод получения хешированной инормации о пользователе.
 * Метод доступен для: master, employee
 *
 * This method belongs to a set of APIs that have been deprecated. Using the v2 API is recommended.
 */
- (GRPCProtoCall *)RPCToGetAuthWithRequest:(KEYAPISOMNICHATV1GetAuthRequest *)request handler:(void(^)(KEYAPISOMNICHATV1GetAuthResponse *_Nullable response, NSError *_Nullable error))handler{
  return [self RPCToMethod:@"GetAuth"
            requestsWriter:[GRXWriter writerWithValue:request]
             responseClass:[KEYAPISOMNICHATV1GetAuthResponse class]
        responsesWriteable:[GRXWriteable writeableWithSingleHandler:handler]];
}
/**
 * Метод получения хешированной инормации о пользователе.
 * Метод доступен для: master, employee
 */
- (GRPCUnaryProtoCall *)getAuthWithMessage:(KEYAPISOMNICHATV1GetAuthRequest *)message responseHandler:(id<GRPCProtoResponseHandler>)handler callOptions:(GRPCCallOptions *_Nullable)callOptions {
  return [self RPCToMethod:@"GetAuth"
                   message:message
           responseHandler:handler
               callOptions:callOptions
             responseClass:[KEYAPISOMNICHATV1GetAuthResponse class]];
}

@end
#endif
