// <auto-generated>
//     Generated by the protocol buffer compiler.  DO NOT EDIT!
//     source: google/ads/googleads/v10/services/google_ads_service.proto
// </auto-generated>
// Original file comments:
// Copyright 2022 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
#pragma warning disable 0414, 1591
#region Designer generated code

using grpc = global::Grpc.Core;

namespace Google.Ads.GoogleAds.V10.Services {
  /// <summary>
  /// Service to fetch data and metrics across resources.
  /// </summary>
  public static partial class GoogleAdsService
  {
    static readonly string __ServiceName = "google.ads.googleads.v10.services.GoogleAdsService";

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static void __Helper_SerializeMessage(global::Google.Protobuf.IMessage message, grpc::SerializationContext context)
    {
      #if !GRPC_DISABLE_PROTOBUF_BUFFER_SERIALIZATION
      if (message is global::Google.Protobuf.IBufferMessage)
      {
        context.SetPayloadLength(message.CalculateSize());
        global::Google.Protobuf.MessageExtensions.WriteTo(message, context.GetBufferWriter());
        context.Complete();
        return;
      }
      #endif
      context.Complete(global::Google.Protobuf.MessageExtensions.ToByteArray(message));
    }

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static class __Helper_MessageCache<T>
    {
      public static readonly bool IsBufferMessage = global::System.Reflection.IntrospectionExtensions.GetTypeInfo(typeof(global::Google.Protobuf.IBufferMessage)).IsAssignableFrom(typeof(T));
    }

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static T __Helper_DeserializeMessage<T>(grpc::DeserializationContext context, global::Google.Protobuf.MessageParser<T> parser) where T : global::Google.Protobuf.IMessage<T>
    {
      #if !GRPC_DISABLE_PROTOBUF_BUFFER_SERIALIZATION
      if (__Helper_MessageCache<T>.IsBufferMessage)
      {
        return parser.ParseFrom(context.PayloadAsReadOnlySequence());
      }
      #endif
      return parser.ParseFrom(context.PayloadAsNewBuffer());
    }

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsRequest> __Marshaller_google_ads_googleads_v10_services_SearchGoogleAdsRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsResponse> __Marshaller_google_ads_googleads_v10_services_SearchGoogleAdsResponse = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsResponse.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamRequest> __Marshaller_google_ads_googleads_v10_services_SearchGoogleAdsStreamRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamResponse> __Marshaller_google_ads_googleads_v10_services_SearchGoogleAdsStreamResponse = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamResponse.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsRequest> __Marshaller_google_ads_googleads_v10_services_MutateGoogleAdsRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsResponse> __Marshaller_google_ads_googleads_v10_services_MutateGoogleAdsResponse = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsResponse.Parser));

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsRequest, global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsResponse> __Method_Search = new grpc::Method<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsRequest, global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsResponse>(
        grpc::MethodType.Unary,
        __ServiceName,
        "Search",
        __Marshaller_google_ads_googleads_v10_services_SearchGoogleAdsRequest,
        __Marshaller_google_ads_googleads_v10_services_SearchGoogleAdsResponse);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamRequest, global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamResponse> __Method_SearchStream = new grpc::Method<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamRequest, global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamResponse>(
        grpc::MethodType.ServerStreaming,
        __ServiceName,
        "SearchStream",
        __Marshaller_google_ads_googleads_v10_services_SearchGoogleAdsStreamRequest,
        __Marshaller_google_ads_googleads_v10_services_SearchGoogleAdsStreamResponse);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsRequest, global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsResponse> __Method_Mutate = new grpc::Method<global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsRequest, global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsResponse>(
        grpc::MethodType.Unary,
        __ServiceName,
        "Mutate",
        __Marshaller_google_ads_googleads_v10_services_MutateGoogleAdsRequest,
        __Marshaller_google_ads_googleads_v10_services_MutateGoogleAdsResponse);

    /// <summary>Service descriptor</summary>
    public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor
    {
      get { return global::Google.Ads.GoogleAds.V10.Services.GoogleAdsServiceReflection.Descriptor.Services[0]; }
    }

    /// <summary>Base class for server-side implementations of GoogleAdsService</summary>
    [grpc::BindServiceMethod(typeof(GoogleAdsService), "BindService")]
    public abstract partial class GoogleAdsServiceBase
    {
      /// <summary>
      /// Returns all rows that match the search query.
      ///
      /// List of thrown errors:
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [ChangeEventError]()
      ///   [ChangeStatusError]()
      ///   [ClickViewError]()
      ///   [HeaderError]()
      ///   [InternalError]()
      ///   [QueryError]()
      ///   [QuotaError]()
      ///   [RequestError]()
      /// </summary>
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsResponse> Search(global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      /// <summary>
      /// Returns all rows that match the search stream query.
      ///
      /// List of thrown errors:
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [ChangeEventError]()
      ///   [ChangeStatusError]()
      ///   [ClickViewError]()
      ///   [HeaderError]()
      ///   [InternalError]()
      ///   [QueryError]()
      ///   [QuotaError]()
      ///   [RequestError]()
      /// </summary>
      /// <param name="request">The request received from the client.</param>
      /// <param name="responseStream">Used for sending responses back to the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>A task indicating completion of the handler.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task SearchStream(global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamRequest request, grpc::IServerStreamWriter<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamResponse> responseStream, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      /// <summary>
      /// Creates, updates, or removes resources. This method supports atomic
      /// transactions with multiple types of resources. For example, you can
      /// atomically create a campaign and a campaign budget, or perform up to
      /// thousands of mutates atomically.
      ///
      /// This method is essentially a wrapper around a series of mutate methods. The
      /// only features it offers over calling those methods directly are:
      ///
      /// - Atomic transactions
      /// - Temp resource names (described below)
      /// - Somewhat reduced latency over making a series of mutate calls
      ///
      /// Note: Only resources that support atomic transactions are included, so this
      /// method can't replace all calls to individual services.
      ///
      /// ## Atomic Transaction Benefits
      ///
      /// Atomicity makes error handling much easier. If you're making a series of
      /// changes and one fails, it can leave your account in an inconsistent state.
      /// With atomicity, you either reach the desired state directly, or the request
      /// fails and you can retry.
      ///
      /// ## Temp Resource Names
      ///
      /// Temp resource names are a special type of resource name used to create a
      /// resource and reference that resource in the same request. For example, if a
      /// campaign budget is created with `resource_name` equal to
      /// `customers/123/campaignBudgets/-1`, that resource name can be reused in
      /// the `Campaign.budget` field in the same request. That way, the two
      /// resources are created and linked atomically.
      ///
      /// To create a temp resource name, put a negative number in the part of the
      /// name that the server would normally allocate.
      ///
      /// Note:
      ///
      /// - Resources must be created with a temp name before the name can be reused.
      ///   For example, the previous CampaignBudget+Campaign example would fail if
      ///   the mutate order was reversed.
      /// - Temp names are not remembered across requests.
      /// - There's no limit to the number of temp names in a request.
      /// - Each temp name must use a unique negative number, even if the resource
      ///   types differ.
      ///
      /// ## Latency
      ///
      /// It's important to group mutates by resource type or the request may time
      /// out and fail. Latency is roughly equal to a series of calls to individual
      /// mutate methods, where each change in resource type is a new call. For
      /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while
      /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls.
      ///
      /// List of thrown errors:
      ///   [AdCustomizerError]()
      ///   [AdError]()
      ///   [AdGroupAdError]()
      ///   [AdGroupCriterionError]()
      ///   [AdGroupError]()
      ///   [AssetError]()
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [BiddingError]()
      ///   [CampaignBudgetError]()
      ///   [CampaignCriterionError]()
      ///   [CampaignError]()
      ///   [CampaignExperimentError]()
      ///   [CampaignSharedSetError]()
      ///   [CollectionSizeError]()
      ///   [ContextError]()
      ///   [ConversionActionError]()
      ///   [CriterionError]()
      ///   [CustomerFeedError]()
      ///   [DatabaseError]()
      ///   [DateError]()
      ///   [DateRangeError]()
      ///   [DistinctError]()
      ///   [ExtensionFeedItemError]()
      ///   [ExtensionSettingError]()
      ///   [FeedAttributeReferenceError]()
      ///   [FeedError]()
      ///   [FeedItemError]()
      ///   [FeedItemSetError]()
      ///   [FieldError]()
      ///   [FieldMaskError]()
      ///   [FunctionParsingError]()
      ///   [HeaderError]()
      ///   [ImageError]()
      ///   [InternalError]()
      ///   [KeywordPlanAdGroupKeywordError]()
      ///   [KeywordPlanCampaignError]()
      ///   [KeywordPlanError]()
      ///   [LabelError]()
      ///   [ListOperationError]()
      ///   [MediaUploadError]()
      ///   [MutateError]()
      ///   [NewResourceCreationError]()
      ///   [NullError]()
      ///   [OperationAccessDeniedError]()
      ///   [PolicyFindingError]()
      ///   [PolicyViolationError]()
      ///   [QuotaError]()
      ///   [RangeError]()
      ///   [RequestError]()
      ///   [ResourceCountLimitExceededError]()
      ///   [SettingError]()
      ///   [SharedSetError]()
      ///   [SizeLimitError]()
      ///   [StringFormatError]()
      ///   [StringLengthError]()
      ///   [UrlFieldError]()
      ///   [UserListError]()
      ///   [YoutubeVideoRegistrationError]()
      /// </summary>
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsResponse> Mutate(global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

    }

    /// <summary>Client for GoogleAdsService</summary>
    public partial class GoogleAdsServiceClient : grpc::ClientBase<GoogleAdsServiceClient>
    {
      /// <summary>Creates a new client for GoogleAdsService</summary>
      /// <param name="channel">The channel to use to make remote calls.</param>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public GoogleAdsServiceClient(grpc::ChannelBase channel) : base(channel)
      {
      }
      /// <summary>Creates a new client for GoogleAdsService that uses a custom <c>CallInvoker</c>.</summary>
      /// <param name="callInvoker">The callInvoker to use to make remote calls.</param>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public GoogleAdsServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker)
      {
      }
      /// <summary>Protected parameterless constructor to allow creation of test doubles.</summary>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      protected GoogleAdsServiceClient() : base()
      {
      }
      /// <summary>Protected constructor to allow creation of configured clients.</summary>
      /// <param name="configuration">The client configuration.</param>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      protected GoogleAdsServiceClient(ClientBaseConfiguration configuration) : base(configuration)
      {
      }

      /// <summary>
      /// Returns all rows that match the search query.
      ///
      /// List of thrown errors:
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [ChangeEventError]()
      ///   [ChangeStatusError]()
      ///   [ClickViewError]()
      ///   [HeaderError]()
      ///   [InternalError]()
      ///   [QueryError]()
      ///   [QuotaError]()
      ///   [RequestError]()
      /// </summary>
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsResponse Search(global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return Search(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      /// <summary>
      /// Returns all rows that match the search query.
      ///
      /// List of thrown errors:
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [ChangeEventError]()
      ///   [ChangeStatusError]()
      ///   [ClickViewError]()
      ///   [HeaderError]()
      ///   [InternalError]()
      ///   [QueryError]()
      ///   [QuotaError]()
      ///   [RequestError]()
      /// </summary>
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsResponse Search(global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_Search, null, options, request);
      }
      /// <summary>
      /// Returns all rows that match the search query.
      ///
      /// List of thrown errors:
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [ChangeEventError]()
      ///   [ChangeStatusError]()
      ///   [ClickViewError]()
      ///   [HeaderError]()
      ///   [InternalError]()
      ///   [QueryError]()
      ///   [QuotaError]()
      ///   [RequestError]()
      /// </summary>
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsResponse> SearchAsync(global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return SearchAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      /// <summary>
      /// Returns all rows that match the search query.
      ///
      /// List of thrown errors:
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [ChangeEventError]()
      ///   [ChangeStatusError]()
      ///   [ClickViewError]()
      ///   [HeaderError]()
      ///   [InternalError]()
      ///   [QueryError]()
      ///   [QuotaError]()
      ///   [RequestError]()
      /// </summary>
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsResponse> SearchAsync(global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_Search, null, options, request);
      }
      /// <summary>
      /// Returns all rows that match the search stream query.
      ///
      /// List of thrown errors:
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [ChangeEventError]()
      ///   [ChangeStatusError]()
      ///   [ClickViewError]()
      ///   [HeaderError]()
      ///   [InternalError]()
      ///   [QueryError]()
      ///   [QuotaError]()
      ///   [RequestError]()
      /// </summary>
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncServerStreamingCall<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamResponse> SearchStream(global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return SearchStream(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      /// <summary>
      /// Returns all rows that match the search stream query.
      ///
      /// List of thrown errors:
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [ChangeEventError]()
      ///   [ChangeStatusError]()
      ///   [ClickViewError]()
      ///   [HeaderError]()
      ///   [InternalError]()
      ///   [QueryError]()
      ///   [QuotaError]()
      ///   [RequestError]()
      /// </summary>
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncServerStreamingCall<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamResponse> SearchStream(global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncServerStreamingCall(__Method_SearchStream, null, options, request);
      }
      /// <summary>
      /// Creates, updates, or removes resources. This method supports atomic
      /// transactions with multiple types of resources. For example, you can
      /// atomically create a campaign and a campaign budget, or perform up to
      /// thousands of mutates atomically.
      ///
      /// This method is essentially a wrapper around a series of mutate methods. The
      /// only features it offers over calling those methods directly are:
      ///
      /// - Atomic transactions
      /// - Temp resource names (described below)
      /// - Somewhat reduced latency over making a series of mutate calls
      ///
      /// Note: Only resources that support atomic transactions are included, so this
      /// method can't replace all calls to individual services.
      ///
      /// ## Atomic Transaction Benefits
      ///
      /// Atomicity makes error handling much easier. If you're making a series of
      /// changes and one fails, it can leave your account in an inconsistent state.
      /// With atomicity, you either reach the desired state directly, or the request
      /// fails and you can retry.
      ///
      /// ## Temp Resource Names
      ///
      /// Temp resource names are a special type of resource name used to create a
      /// resource and reference that resource in the same request. For example, if a
      /// campaign budget is created with `resource_name` equal to
      /// `customers/123/campaignBudgets/-1`, that resource name can be reused in
      /// the `Campaign.budget` field in the same request. That way, the two
      /// resources are created and linked atomically.
      ///
      /// To create a temp resource name, put a negative number in the part of the
      /// name that the server would normally allocate.
      ///
      /// Note:
      ///
      /// - Resources must be created with a temp name before the name can be reused.
      ///   For example, the previous CampaignBudget+Campaign example would fail if
      ///   the mutate order was reversed.
      /// - Temp names are not remembered across requests.
      /// - There's no limit to the number of temp names in a request.
      /// - Each temp name must use a unique negative number, even if the resource
      ///   types differ.
      ///
      /// ## Latency
      ///
      /// It's important to group mutates by resource type or the request may time
      /// out and fail. Latency is roughly equal to a series of calls to individual
      /// mutate methods, where each change in resource type is a new call. For
      /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while
      /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls.
      ///
      /// List of thrown errors:
      ///   [AdCustomizerError]()
      ///   [AdError]()
      ///   [AdGroupAdError]()
      ///   [AdGroupCriterionError]()
      ///   [AdGroupError]()
      ///   [AssetError]()
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [BiddingError]()
      ///   [CampaignBudgetError]()
      ///   [CampaignCriterionError]()
      ///   [CampaignError]()
      ///   [CampaignExperimentError]()
      ///   [CampaignSharedSetError]()
      ///   [CollectionSizeError]()
      ///   [ContextError]()
      ///   [ConversionActionError]()
      ///   [CriterionError]()
      ///   [CustomerFeedError]()
      ///   [DatabaseError]()
      ///   [DateError]()
      ///   [DateRangeError]()
      ///   [DistinctError]()
      ///   [ExtensionFeedItemError]()
      ///   [ExtensionSettingError]()
      ///   [FeedAttributeReferenceError]()
      ///   [FeedError]()
      ///   [FeedItemError]()
      ///   [FeedItemSetError]()
      ///   [FieldError]()
      ///   [FieldMaskError]()
      ///   [FunctionParsingError]()
      ///   [HeaderError]()
      ///   [ImageError]()
      ///   [InternalError]()
      ///   [KeywordPlanAdGroupKeywordError]()
      ///   [KeywordPlanCampaignError]()
      ///   [KeywordPlanError]()
      ///   [LabelError]()
      ///   [ListOperationError]()
      ///   [MediaUploadError]()
      ///   [MutateError]()
      ///   [NewResourceCreationError]()
      ///   [NullError]()
      ///   [OperationAccessDeniedError]()
      ///   [PolicyFindingError]()
      ///   [PolicyViolationError]()
      ///   [QuotaError]()
      ///   [RangeError]()
      ///   [RequestError]()
      ///   [ResourceCountLimitExceededError]()
      ///   [SettingError]()
      ///   [SharedSetError]()
      ///   [SizeLimitError]()
      ///   [StringFormatError]()
      ///   [StringLengthError]()
      ///   [UrlFieldError]()
      ///   [UserListError]()
      ///   [YoutubeVideoRegistrationError]()
      /// </summary>
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsResponse Mutate(global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return Mutate(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      /// <summary>
      /// Creates, updates, or removes resources. This method supports atomic
      /// transactions with multiple types of resources. For example, you can
      /// atomically create a campaign and a campaign budget, or perform up to
      /// thousands of mutates atomically.
      ///
      /// This method is essentially a wrapper around a series of mutate methods. The
      /// only features it offers over calling those methods directly are:
      ///
      /// - Atomic transactions
      /// - Temp resource names (described below)
      /// - Somewhat reduced latency over making a series of mutate calls
      ///
      /// Note: Only resources that support atomic transactions are included, so this
      /// method can't replace all calls to individual services.
      ///
      /// ## Atomic Transaction Benefits
      ///
      /// Atomicity makes error handling much easier. If you're making a series of
      /// changes and one fails, it can leave your account in an inconsistent state.
      /// With atomicity, you either reach the desired state directly, or the request
      /// fails and you can retry.
      ///
      /// ## Temp Resource Names
      ///
      /// Temp resource names are a special type of resource name used to create a
      /// resource and reference that resource in the same request. For example, if a
      /// campaign budget is created with `resource_name` equal to
      /// `customers/123/campaignBudgets/-1`, that resource name can be reused in
      /// the `Campaign.budget` field in the same request. That way, the two
      /// resources are created and linked atomically.
      ///
      /// To create a temp resource name, put a negative number in the part of the
      /// name that the server would normally allocate.
      ///
      /// Note:
      ///
      /// - Resources must be created with a temp name before the name can be reused.
      ///   For example, the previous CampaignBudget+Campaign example would fail if
      ///   the mutate order was reversed.
      /// - Temp names are not remembered across requests.
      /// - There's no limit to the number of temp names in a request.
      /// - Each temp name must use a unique negative number, even if the resource
      ///   types differ.
      ///
      /// ## Latency
      ///
      /// It's important to group mutates by resource type or the request may time
      /// out and fail. Latency is roughly equal to a series of calls to individual
      /// mutate methods, where each change in resource type is a new call. For
      /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while
      /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls.
      ///
      /// List of thrown errors:
      ///   [AdCustomizerError]()
      ///   [AdError]()
      ///   [AdGroupAdError]()
      ///   [AdGroupCriterionError]()
      ///   [AdGroupError]()
      ///   [AssetError]()
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [BiddingError]()
      ///   [CampaignBudgetError]()
      ///   [CampaignCriterionError]()
      ///   [CampaignError]()
      ///   [CampaignExperimentError]()
      ///   [CampaignSharedSetError]()
      ///   [CollectionSizeError]()
      ///   [ContextError]()
      ///   [ConversionActionError]()
      ///   [CriterionError]()
      ///   [CustomerFeedError]()
      ///   [DatabaseError]()
      ///   [DateError]()
      ///   [DateRangeError]()
      ///   [DistinctError]()
      ///   [ExtensionFeedItemError]()
      ///   [ExtensionSettingError]()
      ///   [FeedAttributeReferenceError]()
      ///   [FeedError]()
      ///   [FeedItemError]()
      ///   [FeedItemSetError]()
      ///   [FieldError]()
      ///   [FieldMaskError]()
      ///   [FunctionParsingError]()
      ///   [HeaderError]()
      ///   [ImageError]()
      ///   [InternalError]()
      ///   [KeywordPlanAdGroupKeywordError]()
      ///   [KeywordPlanCampaignError]()
      ///   [KeywordPlanError]()
      ///   [LabelError]()
      ///   [ListOperationError]()
      ///   [MediaUploadError]()
      ///   [MutateError]()
      ///   [NewResourceCreationError]()
      ///   [NullError]()
      ///   [OperationAccessDeniedError]()
      ///   [PolicyFindingError]()
      ///   [PolicyViolationError]()
      ///   [QuotaError]()
      ///   [RangeError]()
      ///   [RequestError]()
      ///   [ResourceCountLimitExceededError]()
      ///   [SettingError]()
      ///   [SharedSetError]()
      ///   [SizeLimitError]()
      ///   [StringFormatError]()
      ///   [StringLengthError]()
      ///   [UrlFieldError]()
      ///   [UserListError]()
      ///   [YoutubeVideoRegistrationError]()
      /// </summary>
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsResponse Mutate(global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_Mutate, null, options, request);
      }
      /// <summary>
      /// Creates, updates, or removes resources. This method supports atomic
      /// transactions with multiple types of resources. For example, you can
      /// atomically create a campaign and a campaign budget, or perform up to
      /// thousands of mutates atomically.
      ///
      /// This method is essentially a wrapper around a series of mutate methods. The
      /// only features it offers over calling those methods directly are:
      ///
      /// - Atomic transactions
      /// - Temp resource names (described below)
      /// - Somewhat reduced latency over making a series of mutate calls
      ///
      /// Note: Only resources that support atomic transactions are included, so this
      /// method can't replace all calls to individual services.
      ///
      /// ## Atomic Transaction Benefits
      ///
      /// Atomicity makes error handling much easier. If you're making a series of
      /// changes and one fails, it can leave your account in an inconsistent state.
      /// With atomicity, you either reach the desired state directly, or the request
      /// fails and you can retry.
      ///
      /// ## Temp Resource Names
      ///
      /// Temp resource names are a special type of resource name used to create a
      /// resource and reference that resource in the same request. For example, if a
      /// campaign budget is created with `resource_name` equal to
      /// `customers/123/campaignBudgets/-1`, that resource name can be reused in
      /// the `Campaign.budget` field in the same request. That way, the two
      /// resources are created and linked atomically.
      ///
      /// To create a temp resource name, put a negative number in the part of the
      /// name that the server would normally allocate.
      ///
      /// Note:
      ///
      /// - Resources must be created with a temp name before the name can be reused.
      ///   For example, the previous CampaignBudget+Campaign example would fail if
      ///   the mutate order was reversed.
      /// - Temp names are not remembered across requests.
      /// - There's no limit to the number of temp names in a request.
      /// - Each temp name must use a unique negative number, even if the resource
      ///   types differ.
      ///
      /// ## Latency
      ///
      /// It's important to group mutates by resource type or the request may time
      /// out and fail. Latency is roughly equal to a series of calls to individual
      /// mutate methods, where each change in resource type is a new call. For
      /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while
      /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls.
      ///
      /// List of thrown errors:
      ///   [AdCustomizerError]()
      ///   [AdError]()
      ///   [AdGroupAdError]()
      ///   [AdGroupCriterionError]()
      ///   [AdGroupError]()
      ///   [AssetError]()
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [BiddingError]()
      ///   [CampaignBudgetError]()
      ///   [CampaignCriterionError]()
      ///   [CampaignError]()
      ///   [CampaignExperimentError]()
      ///   [CampaignSharedSetError]()
      ///   [CollectionSizeError]()
      ///   [ContextError]()
      ///   [ConversionActionError]()
      ///   [CriterionError]()
      ///   [CustomerFeedError]()
      ///   [DatabaseError]()
      ///   [DateError]()
      ///   [DateRangeError]()
      ///   [DistinctError]()
      ///   [ExtensionFeedItemError]()
      ///   [ExtensionSettingError]()
      ///   [FeedAttributeReferenceError]()
      ///   [FeedError]()
      ///   [FeedItemError]()
      ///   [FeedItemSetError]()
      ///   [FieldError]()
      ///   [FieldMaskError]()
      ///   [FunctionParsingError]()
      ///   [HeaderError]()
      ///   [ImageError]()
      ///   [InternalError]()
      ///   [KeywordPlanAdGroupKeywordError]()
      ///   [KeywordPlanCampaignError]()
      ///   [KeywordPlanError]()
      ///   [LabelError]()
      ///   [ListOperationError]()
      ///   [MediaUploadError]()
      ///   [MutateError]()
      ///   [NewResourceCreationError]()
      ///   [NullError]()
      ///   [OperationAccessDeniedError]()
      ///   [PolicyFindingError]()
      ///   [PolicyViolationError]()
      ///   [QuotaError]()
      ///   [RangeError]()
      ///   [RequestError]()
      ///   [ResourceCountLimitExceededError]()
      ///   [SettingError]()
      ///   [SharedSetError]()
      ///   [SizeLimitError]()
      ///   [StringFormatError]()
      ///   [StringLengthError]()
      ///   [UrlFieldError]()
      ///   [UserListError]()
      ///   [YoutubeVideoRegistrationError]()
      /// </summary>
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsResponse> MutateAsync(global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return MutateAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      /// <summary>
      /// Creates, updates, or removes resources. This method supports atomic
      /// transactions with multiple types of resources. For example, you can
      /// atomically create a campaign and a campaign budget, or perform up to
      /// thousands of mutates atomically.
      ///
      /// This method is essentially a wrapper around a series of mutate methods. The
      /// only features it offers over calling those methods directly are:
      ///
      /// - Atomic transactions
      /// - Temp resource names (described below)
      /// - Somewhat reduced latency over making a series of mutate calls
      ///
      /// Note: Only resources that support atomic transactions are included, so this
      /// method can't replace all calls to individual services.
      ///
      /// ## Atomic Transaction Benefits
      ///
      /// Atomicity makes error handling much easier. If you're making a series of
      /// changes and one fails, it can leave your account in an inconsistent state.
      /// With atomicity, you either reach the desired state directly, or the request
      /// fails and you can retry.
      ///
      /// ## Temp Resource Names
      ///
      /// Temp resource names are a special type of resource name used to create a
      /// resource and reference that resource in the same request. For example, if a
      /// campaign budget is created with `resource_name` equal to
      /// `customers/123/campaignBudgets/-1`, that resource name can be reused in
      /// the `Campaign.budget` field in the same request. That way, the two
      /// resources are created and linked atomically.
      ///
      /// To create a temp resource name, put a negative number in the part of the
      /// name that the server would normally allocate.
      ///
      /// Note:
      ///
      /// - Resources must be created with a temp name before the name can be reused.
      ///   For example, the previous CampaignBudget+Campaign example would fail if
      ///   the mutate order was reversed.
      /// - Temp names are not remembered across requests.
      /// - There's no limit to the number of temp names in a request.
      /// - Each temp name must use a unique negative number, even if the resource
      ///   types differ.
      ///
      /// ## Latency
      ///
      /// It's important to group mutates by resource type or the request may time
      /// out and fail. Latency is roughly equal to a series of calls to individual
      /// mutate methods, where each change in resource type is a new call. For
      /// example, mutating 10 campaigns then 10 ad groups is like 2 calls, while
      /// mutating 1 campaign, 1 ad group, 1 campaign, 1 ad group is like 4 calls.
      ///
      /// List of thrown errors:
      ///   [AdCustomizerError]()
      ///   [AdError]()
      ///   [AdGroupAdError]()
      ///   [AdGroupCriterionError]()
      ///   [AdGroupError]()
      ///   [AssetError]()
      ///   [AuthenticationError]()
      ///   [AuthorizationError]()
      ///   [BiddingError]()
      ///   [CampaignBudgetError]()
      ///   [CampaignCriterionError]()
      ///   [CampaignError]()
      ///   [CampaignExperimentError]()
      ///   [CampaignSharedSetError]()
      ///   [CollectionSizeError]()
      ///   [ContextError]()
      ///   [ConversionActionError]()
      ///   [CriterionError]()
      ///   [CustomerFeedError]()
      ///   [DatabaseError]()
      ///   [DateError]()
      ///   [DateRangeError]()
      ///   [DistinctError]()
      ///   [ExtensionFeedItemError]()
      ///   [ExtensionSettingError]()
      ///   [FeedAttributeReferenceError]()
      ///   [FeedError]()
      ///   [FeedItemError]()
      ///   [FeedItemSetError]()
      ///   [FieldError]()
      ///   [FieldMaskError]()
      ///   [FunctionParsingError]()
      ///   [HeaderError]()
      ///   [ImageError]()
      ///   [InternalError]()
      ///   [KeywordPlanAdGroupKeywordError]()
      ///   [KeywordPlanCampaignError]()
      ///   [KeywordPlanError]()
      ///   [LabelError]()
      ///   [ListOperationError]()
      ///   [MediaUploadError]()
      ///   [MutateError]()
      ///   [NewResourceCreationError]()
      ///   [NullError]()
      ///   [OperationAccessDeniedError]()
      ///   [PolicyFindingError]()
      ///   [PolicyViolationError]()
      ///   [QuotaError]()
      ///   [RangeError]()
      ///   [RequestError]()
      ///   [ResourceCountLimitExceededError]()
      ///   [SettingError]()
      ///   [SharedSetError]()
      ///   [SizeLimitError]()
      ///   [StringFormatError]()
      ///   [StringLengthError]()
      ///   [UrlFieldError]()
      ///   [UserListError]()
      ///   [YoutubeVideoRegistrationError]()
      /// </summary>
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsResponse> MutateAsync(global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_Mutate, null, options, request);
      }
      /// <summary>Creates a new instance of client from given <c>ClientBaseConfiguration</c>.</summary>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      protected override GoogleAdsServiceClient NewInstance(ClientBaseConfiguration configuration)
      {
        return new GoogleAdsServiceClient(configuration);
      }
    }

    /// <summary>Creates service definition that can be registered with a server</summary>
    /// <param name="serviceImpl">An object implementing the server-side handling logic.</param>
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    public static grpc::ServerServiceDefinition BindService(GoogleAdsServiceBase serviceImpl)
    {
      return grpc::ServerServiceDefinition.CreateBuilder()
          .AddMethod(__Method_Search, serviceImpl.Search)
          .AddMethod(__Method_SearchStream, serviceImpl.SearchStream)
          .AddMethod(__Method_Mutate, serviceImpl.Mutate).Build();
    }

    /// <summary>Register service method with a service binder with or without implementation. Useful when customizing the  service binding logic.
    /// Note: this method is part of an experimental API that can change or be removed without any prior notice.</summary>
    /// <param name="serviceBinder">Service methods will be bound by calling <c>AddMethod</c> on this object.</param>
    /// <param name="serviceImpl">An object implementing the server-side handling logic.</param>
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    public static void BindService(grpc::ServiceBinderBase serviceBinder, GoogleAdsServiceBase serviceImpl)
    {
      serviceBinder.AddMethod(__Method_Search, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsRequest, global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsResponse>(serviceImpl.Search));
      serviceBinder.AddMethod(__Method_SearchStream, serviceImpl == null ? null : new grpc::ServerStreamingServerMethod<global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamRequest, global::Google.Ads.GoogleAds.V10.Services.SearchGoogleAdsStreamResponse>(serviceImpl.SearchStream));
      serviceBinder.AddMethod(__Method_Mutate, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsRequest, global::Google.Ads.GoogleAds.V10.Services.MutateGoogleAdsResponse>(serviceImpl.Mutate));
    }

  }
}
#endregion
