lib/google_api/display_video/v1/model/double_verify.ex

# Copyright 2019 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.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.DisplayVideo.V1.Model.DoubleVerify do
  @moduledoc """
  Details of DoubleVerify settings.

  ## Attributes

  *   `appStarRating` (*type:* `GoogleApi.DisplayVideo.V1.Model.DoubleVerifyAppStarRating.t`, *default:* `nil`) - Avoid bidding on apps with the star ratings.
  *   `avoidedAgeRatings` (*type:* `list(String.t)`, *default:* `nil`) - Avoid bidding on apps with the age rating.
  *   `brandSafetyCategories` (*type:* `GoogleApi.DisplayVideo.V1.Model.DoubleVerifyBrandSafetyCategories.t`, *default:* `nil`) - DV Brand Safety Controls.
  *   `customSegmentId` (*type:* `String.t`, *default:* `nil`) - The custom segment ID provided by DoubleVerify. The ID must start with "51" and consist of eight digits. Custom segment ID cannot be specified along with any of the following fields: * brand_safety_categories * avoided_age_ratings * app_star_rating * fraud_invalid_traffic
  *   `displayViewability` (*type:* `GoogleApi.DisplayVideo.V1.Model.DoubleVerifyDisplayViewability.t`, *default:* `nil`) - Display viewability settings (applicable to display line items only).
  *   `fraudInvalidTraffic` (*type:* `GoogleApi.DisplayVideo.V1.Model.DoubleVerifyFraudInvalidTraffic.t`, *default:* `nil`) - Avoid Sites and Apps with historical Fraud & IVT Rates.
  *   `videoViewability` (*type:* `GoogleApi.DisplayVideo.V1.Model.DoubleVerifyVideoViewability.t`, *default:* `nil`) - Video viewability settings (applicable to video line items only).
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :appStarRating => GoogleApi.DisplayVideo.V1.Model.DoubleVerifyAppStarRating.t() | nil,
          :avoidedAgeRatings => list(String.t()) | nil,
          :brandSafetyCategories =>
            GoogleApi.DisplayVideo.V1.Model.DoubleVerifyBrandSafetyCategories.t() | nil,
          :customSegmentId => String.t() | nil,
          :displayViewability =>
            GoogleApi.DisplayVideo.V1.Model.DoubleVerifyDisplayViewability.t() | nil,
          :fraudInvalidTraffic =>
            GoogleApi.DisplayVideo.V1.Model.DoubleVerifyFraudInvalidTraffic.t() | nil,
          :videoViewability =>
            GoogleApi.DisplayVideo.V1.Model.DoubleVerifyVideoViewability.t() | nil
        }

  field(:appStarRating, as: GoogleApi.DisplayVideo.V1.Model.DoubleVerifyAppStarRating)
  field(:avoidedAgeRatings, type: :list)

  field(:brandSafetyCategories,
    as: GoogleApi.DisplayVideo.V1.Model.DoubleVerifyBrandSafetyCategories
  )

  field(:customSegmentId)
  field(:displayViewability, as: GoogleApi.DisplayVideo.V1.Model.DoubleVerifyDisplayViewability)
  field(:fraudInvalidTraffic, as: GoogleApi.DisplayVideo.V1.Model.DoubleVerifyFraudInvalidTraffic)
  field(:videoViewability, as: GoogleApi.DisplayVideo.V1.Model.DoubleVerifyVideoViewability)
end

defimpl Poison.Decoder, for: GoogleApi.DisplayVideo.V1.Model.DoubleVerify do
  def decode(value, options) do
    GoogleApi.DisplayVideo.V1.Model.DoubleVerify.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.DisplayVideo.V1.Model.DoubleVerify do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end