// Copyright 2020 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.

syntax = "proto3";

package google.ads.googleads.v5.errors;

import "google/api/annotations.proto";

option csharp_namespace = "Google.Ads.GoogleAds.V5.Errors";
option go_package = "google.golang.org/genproto/googleapis/ads/googleads/v5/errors;errors";
option java_multiple_files = true;
option java_outer_classname = "ConversionUploadErrorProto";
option java_package = "com.google.ads.googleads.v5.errors";
option objc_class_prefix = "GAA";
option php_namespace = "Google\\Ads\\GoogleAds\\V5\\Errors";
option ruby_package = "Google::Ads::GoogleAds::V5::Errors";

// Proto file describing conversion upload errors.

// Container for enum describing possible conversion upload errors.
message ConversionUploadErrorEnum {
  // Enum describing possible conversion upload errors.
  enum ConversionUploadError {
    // Enum unspecified.
    UNSPECIFIED = 0;

    // The received error code is not known in this version.
    UNKNOWN = 1;

    // The request contained more than 2000 conversions.
    TOO_MANY_CONVERSIONS_IN_REQUEST = 2;

    // The specified gclid could not be decoded.
    UNPARSEABLE_GCLID = 3;

    // The specified conversion_date_time is before the event time
    // associated with the given gclid.
    CONVERSION_PRECEDES_GCLID = 4;

    // The click associated with the given gclid is either too old to be
    // imported or occurred outside of the click through lookback window for the
    // specified conversion action.
    EXPIRED_GCLID = 5;

    // The click associated with the given gclid occurred too recently. Please
    // try uploading again after 6 hours have passed since the click occurred.
    TOO_RECENT_GCLID = 6;

    // The click associated with the given gclid could not be found in the
    // system. This can happen if Google Click IDs are collected for non Google
    // Ads clicks.
    GCLID_NOT_FOUND = 7;

    // The click associated with the given gclid is owned by a customer
    // account that the uploading customer does not manage.
    UNAUTHORIZED_CUSTOMER = 8;

    // No upload eligible conversion action that matches the provided
    // information can be found for the customer.
    INVALID_CONVERSION_ACTION = 9;

    // The specified conversion action was created too recently.
    // Please try the upload again after 4-6 hours have passed since the
    // conversion action was created.
    TOO_RECENT_CONVERSION_ACTION = 10;

    // The click associated with the given gclid does not contain conversion
    // tracking information.
    CONVERSION_TRACKING_NOT_ENABLED_AT_IMPRESSION_TIME = 11;

    // The specified conversion action does not use an external attribution
    // model, but external_attribution_data was set.
    EXTERNAL_ATTRIBUTION_DATA_SET_FOR_NON_EXTERNALLY_ATTRIBUTED_CONVERSION_ACTION = 12;

    // The specified conversion action uses an external attribution model, but
    // external_attribution_data or one of its contained fields was not set.
    // Both external_attribution_credit and external_attribution_model must be
    // set for externally attributed conversion actions.
    EXTERNAL_ATTRIBUTION_DATA_NOT_SET_FOR_EXTERNALLY_ATTRIBUTED_CONVERSION_ACTION = 13;

    // Order IDs are not supported for conversion actions which use an external
    // attribution model.
    ORDER_ID_NOT_PERMITTED_FOR_EXTERNALLY_ATTRIBUTED_CONVERSION_ACTION = 14;

    // A conversion with the same order id and conversion action combination
    // already exists in our system.
    ORDER_ID_ALREADY_IN_USE = 15;

    // The request contained two or more conversions with the same order id and
    // conversion action combination.
    DUPLICATE_ORDER_ID = 16;

    // The call occurred too recently. Please try uploading again after 6 hours
    // have passed since the call occurred.
    TOO_RECENT_CALL = 17;

    // The click that initiated the call is too old for this conversion to be
    // imported.
    EXPIRED_CALL = 18;

    // The call or the click leading to the call was not found.
    CALL_NOT_FOUND = 19;

    // The specified conversion_date_time is before the call_start_date_time.
    CONVERSION_PRECEDES_CALL = 20;

    // The click associated with the call does not contain conversion tracking
    // information.
    CONVERSION_TRACKING_NOT_ENABLED_AT_CALL_TIME = 21;

    // The caller’s phone number cannot be parsed. It should be formatted either
    // as E.164 "+16502531234", International "+64 3-331 6005" or US national
    // number "6502531234".
    UNPARSEABLE_CALLERS_PHONE_NUMBER = 22;
  }


}
