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

#import <Foundation/Foundation.h>

#if !defined(GPB_GRPC_FORWARD_DECLARE_MESSAGE_PROTO) || !GPB_GRPC_FORWARD_DECLARE_MESSAGE_PROTO
#import "keyapis/subscription/v1/KeyapisSubscriptionSubscriptionV1.pbobjc.h"
#endif

#if !defined(GPB_GRPC_PROTOCOL_ONLY) || !GPB_GRPC_PROTOCOL_ONLY
#import <ProtoRPC/ProtoService.h>
#import <ProtoRPC/ProtoRPCLegacy.h>
#import <RxLibrary/GRXWriteable.h>
#import <RxLibrary/GRXWriter.h>
#endif

@class KEYAPISSUBSCRIPTIONV1GetSubscriptionCountRequest;
@class KEYAPISSUBSCRIPTIONV1GetSubscriptionCountResponse;
@class KEYAPISSUBSCRIPTIONV1GetSubscriptionListRequest;
@class KEYAPISSUBSCRIPTIONV1GetSubscriptionListResponse;
@class KEYAPISSUBSCRIPTIONV1GetSubscriptionRequest;
@class KEYAPISSUBSCRIPTIONV1GetSubscriptionResponse;

#if !defined(GPB_GRPC_FORWARD_DECLARE_MESSAGE_PROTO) || !GPB_GRPC_FORWARD_DECLARE_MESSAGE_PROTO
#if defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) && GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS
  #import <Protobuf/GPBTimestamp.pbobjc.h>
#else
  #import "GPBTimestamp.pbobjc.h"
#endif
  #import "google/api/Annotations.pbobjc.h"
  #import "google/api/FieldBehavior.pbobjc.h"
  #import "google/protobuf/Descriptor.pbobjc.h"
#if defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) && GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS
  #import <Protobuf/GPBWrappers.pbobjc.h>
#else
  #import "GPBWrappers.pbobjc.h"
#endif
  #import "keyapis/subscription/v1/KeyapisSubscriptionOfferV1.pbobjc.h"
#endif

@class GRPCUnaryProtoCall;
@class GRPCStreamingProtoCall;
@class GRPCCallOptions;
@protocol GRPCProtoResponseHandler;
@class GRPCProtoCall;


NS_ASSUME_NONNULL_BEGIN

@protocol KEYAPISSUBSCRIPTIONV1SubscriptionService2 <NSObject>

#pragma mark GetSubscription(GetSubscriptionRequest) returns (GetSubscriptionResponse)

/**
 * Метод получения подписки.
 * Метод доступен для: admin, mrf, master, ltp_first, service, application(subscription:read или subscription:edit)
 */
- (GRPCUnaryProtoCall *)getSubscriptionWithMessage:(KEYAPISSUBSCRIPTIONV1GetSubscriptionRequest *)message responseHandler:(id<GRPCProtoResponseHandler>)handler callOptions:(GRPCCallOptions *_Nullable)callOptions;

#pragma mark GetSubscriptionList(GetSubscriptionListRequest) returns (stream GetSubscriptionListResponse)

/**
 * Метод получения списка подписок.
 * Метод доступен для: admin, mrf, master, ltp_first, service, application(subscription:read или subscription:edit)
 */
- (GRPCUnaryProtoCall *)getSubscriptionListWithMessage:(KEYAPISSUBSCRIPTIONV1GetSubscriptionListRequest *)message responseHandler:(id<GRPCProtoResponseHandler>)handler callOptions:(GRPCCallOptions *_Nullable)callOptions;

#pragma mark GetSubscriptionCount(GetSubscriptionCountRequest) returns (GetSubscriptionCountResponse)

/**
 * Метод получения количества подписок.
 * Метод доступен для: admin, mrf, master, ltp_first, service, application(subscription:read или subscription:edit)
 */
- (GRPCUnaryProtoCall *)getSubscriptionCountWithMessage:(KEYAPISSUBSCRIPTIONV1GetSubscriptionCountRequest *)message responseHandler:(id<GRPCProtoResponseHandler>)handler callOptions:(GRPCCallOptions *_Nullable)callOptions;

@end

/**
 * The methods in this protocol belong to a set of old APIs that have been deprecated. They do not
 * recognize call options provided in the initializer. Using the v2 protocol is recommended.
 */
@protocol KEYAPISSUBSCRIPTIONV1SubscriptionService <NSObject>

#pragma mark GetSubscription(GetSubscriptionRequest) returns (GetSubscriptionResponse)

/**
 * Метод получения подписки.
 * Метод доступен для: admin, mrf, master, ltp_first, service, application(subscription:read или subscription:edit)
 *
 * This method belongs to a set of APIs that have been deprecated. Using the v2 API is recommended.
 */
- (void)getSubscriptionWithRequest:(KEYAPISSUBSCRIPTIONV1GetSubscriptionRequest *)request handler:(void(^)(KEYAPISSUBSCRIPTIONV1GetSubscriptionResponse *_Nullable response, NSError *_Nullable error))handler;

/**
 * Метод получения подписки.
 * Метод доступен для: admin, mrf, master, ltp_first, service, application(subscription:read или subscription:edit)
 *
 * This method belongs to a set of APIs that have been deprecated. Using the v2 API is recommended.
 */
- (GRPCProtoCall *)RPCToGetSubscriptionWithRequest:(KEYAPISSUBSCRIPTIONV1GetSubscriptionRequest *)request handler:(void(^)(KEYAPISSUBSCRIPTIONV1GetSubscriptionResponse *_Nullable response, NSError *_Nullable error))handler;


#pragma mark GetSubscriptionList(GetSubscriptionListRequest) returns (stream GetSubscriptionListResponse)

/**
 * Метод получения списка подписок.
 * Метод доступен для: admin, mrf, master, ltp_first, service, application(subscription:read или subscription:edit)
 *
 * This method belongs to a set of APIs that have been deprecated. Using the v2 API is recommended.
 */
- (void)getSubscriptionListWithRequest:(KEYAPISSUBSCRIPTIONV1GetSubscriptionListRequest *)request eventHandler:(void(^)(BOOL done, KEYAPISSUBSCRIPTIONV1GetSubscriptionListResponse *_Nullable response, NSError *_Nullable error))eventHandler;

/**
 * Метод получения списка подписок.
 * Метод доступен для: admin, mrf, master, ltp_first, service, application(subscription:read или subscription:edit)
 *
 * This method belongs to a set of APIs that have been deprecated. Using the v2 API is recommended.
 */
- (GRPCProtoCall *)RPCToGetSubscriptionListWithRequest:(KEYAPISSUBSCRIPTIONV1GetSubscriptionListRequest *)request eventHandler:(void(^)(BOOL done, KEYAPISSUBSCRIPTIONV1GetSubscriptionListResponse *_Nullable response, NSError *_Nullable error))eventHandler;


#pragma mark GetSubscriptionCount(GetSubscriptionCountRequest) returns (GetSubscriptionCountResponse)

/**
 * Метод получения количества подписок.
 * Метод доступен для: admin, mrf, master, ltp_first, service, application(subscription:read или subscription:edit)
 *
 * This method belongs to a set of APIs that have been deprecated. Using the v2 API is recommended.
 */
- (void)getSubscriptionCountWithRequest:(KEYAPISSUBSCRIPTIONV1GetSubscriptionCountRequest *)request handler:(void(^)(KEYAPISSUBSCRIPTIONV1GetSubscriptionCountResponse *_Nullable response, NSError *_Nullable error))handler;

/**
 * Метод получения количества подписок.
 * Метод доступен для: admin, mrf, master, ltp_first, service, application(subscription:read или subscription:edit)
 *
 * This method belongs to a set of APIs that have been deprecated. Using the v2 API is recommended.
 */
- (GRPCProtoCall *)RPCToGetSubscriptionCountWithRequest:(KEYAPISSUBSCRIPTIONV1GetSubscriptionCountRequest *)request handler:(void(^)(KEYAPISSUBSCRIPTIONV1GetSubscriptionCountResponse *_Nullable response, NSError *_Nullable error))handler;


@end


#if !defined(GPB_GRPC_PROTOCOL_ONLY) || !GPB_GRPC_PROTOCOL_ONLY
/**
 * Basic service implementation, over gRPC, that only does
 * marshalling and parsing.
 */
@interface KEYAPISSUBSCRIPTIONV1SubscriptionService : GRPCProtoService<KEYAPISSUBSCRIPTIONV1SubscriptionService2, KEYAPISSUBSCRIPTIONV1SubscriptionService>
- (instancetype)initWithHost:(NSString *)host callOptions:(GRPCCallOptions *_Nullable)callOptions NS_DESIGNATED_INITIALIZER;
+ (instancetype)serviceWithHost:(NSString *)host callOptions:(GRPCCallOptions *_Nullable)callOptions;
// The following methods belong to a set of old APIs that have been deprecated.
- (instancetype)initWithHost:(NSString *)host;
+ (instancetype)serviceWithHost:(NSString *)host;
@end
#endif

NS_ASSUME_NONNULL_END

