blob: b928978607e7e705aaa24459eea5f2bed03f08be [file] [log] [blame]
<html><body>
<style>
body, h1, h2, h3, div, span, p, pre, a {
margin: 0;
padding: 0;
border: 0;
font-weight: inherit;
font-style: inherit;
font-size: 100%;
font-family: inherit;
vertical-align: baseline;
}
body {
font-size: 13px;
padding: 1em;
}
h1 {
font-size: 26px;
margin-bottom: 1em;
}
h2 {
font-size: 24px;
margin-bottom: 1em;
}
h3 {
font-size: 20px;
margin-bottom: 1em;
margin-top: 1em;
}
pre, code {
line-height: 1.5;
font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
}
pre {
margin-top: 0.5em;
}
h1, h2, h3, p {
font-family: Arial, sans serif;
}
h1, h2, h3 {
border-bottom: solid #CCC 1px;
}
.toc_element {
margin-top: 0.5em;
}
.firstline {
margin-left: 2 em;
}
.method {
margin-top: 1em;
border: solid 1px #CCC;
padding: 1em;
background: #EEE;
}
.details {
font-weight: bold;
font-size: 14px;
}
</style>
<h1><a href="displayvideo_v1.html">Display & Video 360 API</a> . <a href="displayvideo_v1.advertisers.html">advertisers</a> . <a href="displayvideo_v1.advertisers.insertionOrders.html">insertionOrders</a></h1>
<h2>Instance Methods</h2>
<p class="toc_element">
<code><a href="#create">create(advertiserId, body=None, x__xgafv=None)</a></code></p>
<p class="firstline">Creates a new insertion order.</p>
<p class="toc_element">
<code><a href="#delete">delete(advertiserId, insertionOrderId, x__xgafv=None)</a></code></p>
<p class="firstline">Deletes an insertion order.</p>
<p class="toc_element">
<code><a href="#get">get(advertiserId, insertionOrderId, x__xgafv=None)</a></code></p>
<p class="firstline">Gets an insertion order.</p>
<p class="toc_element">
<code><a href="#list">list(advertiserId, filter=None, pageToken=None, orderBy=None, pageSize=None, x__xgafv=None)</a></code></p>
<p class="firstline">Lists insertion orders in an advertiser.</p>
<p class="toc_element">
<code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
<p class="firstline">Retrieves the next page of results.</p>
<p class="toc_element">
<code><a href="#patch">patch(advertiserId, insertionOrderId, body=None, updateMask=None, x__xgafv=None)</a></code></p>
<p class="firstline">Updates an existing insertion order.</p>
<h3>Method Details</h3>
<div class="method">
<code class="details" id="create">create(advertiserId, body=None, x__xgafv=None)</code>
<pre>Creates a new insertion order.
Returns the newly created insertion order if successful.
Args:
advertiserId: string, Output only. The unique ID of the advertiser the insertion order belongs to. (required)
body: object, The request body.
The object takes the form of:
{ # A single insertion order.
&quot;bidStrategy&quot;: { # Settings that control the bid strategy. # Optional. The bidding strategy of the insertion order. By default,
# fixed_bid is set.
# Bid strategy determines the bid price.
&quot;fixedBid&quot;: { # A strategy that uses a fixed bidding price. # A strategy that uses a fixed bid price.
&quot;bidAmountMicros&quot;: &quot;A String&quot;, # The fixed bid amount, in micros of the advertiser&#x27;s currency.
# For insertion order entity,
# bid_amount_micros should be set as 0.
# For line item entity,
# bid_amount_micros must be greater
# than or equal to billable unit of the given currency and smaller than or
# equal to the upper limit 1000000000.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;maximizeSpendAutoBid&quot;: { # A strategy that automatically adjusts the bid to optimize a specified # A strategy that automatically adjusts the bid to optimize to your
# performance goal while spending the full budget.
#
# At insertion order level, the
# markup_type of line items
# cannot be set to `PARTNER_REVENUE_MODEL_MARKUP_TYPE_CPM`. In addition,
# when
# performance_goal_type
# is one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_AV_VIEWED` ,
#
# the line_item_type
# of the insertion order line items must be either:
#
# * `LINE_ITEM_TYPE_DISPLAY_DEFAULT`
# * `LINE_ITEM_TYPE_VIDEO_DEFAULT` ,
#
# and when
# performance_goal_type
# is either:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CIVA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_IVO_TEN`
#
# the line_item_type
# of the insertion order line items must be `LINE_ITEM_TYPE_VIDEO_DEFAULT`.
# performance goal while spending the full budget.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# tries to minimize while spending the full budget.
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM` is not supported for
# this strategy.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;performanceGoalAutoBid&quot;: { # A strategy that automatically adjusts the bid to meet or beat a specified # A strategy that automatically adjusts the bid to meet or beat a specified
# performance goal. It is to be used only for a line item entity.
# performance goal.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# will try to meet or beat.
#
# For line item level usage, the value must be one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency. Not applicable when
# performance_goal_type
# is set to `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
#
# For example, 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # Required. The performance goal the bidding strategy will attempt to
# meet or beat, in micros of the advertiser&#x27;s currency.
# Must be greater than or equal to a billable unit of the given currency and
# smaller or equal to upper bounds. Each
# performance_goal_type
# has its upper bound:
#
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`,
# upper bound is 10000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`,
# upper bound is 1000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, upper bound is
# 1000.00 USD.
#
# Example: If set to
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, the bid price will
# be based on the probability that each available impression will be
# viewable. For example, if viewable CPM target is $2 and an impression is
# 40% likely to be viewable, the bid price will be $0.80 CPM (40% of $2).
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
},
&quot;frequencyCap&quot;: { # Settings that control the number of times a user may be shown with the same # Required. The frequency capping setting of the insertion order.
# ad during a given time period.
&quot;unlimited&quot;: True or False, # Whether unlimited frequency capping is applied. When this field is set to
# `true`, the remaining frequency cap fields are not applicable.
&quot;maxImpressions&quot;: 42, # The maximum number of times a user may be shown with the same ad
# during this period. Must be greater than 0.
#
# Applicable when unlimited is `false`.
&quot;timeUnit&quot;: &quot;A String&quot;, # The time unit in which the frequency cap will be applied.
#
# Applicable when unlimited is `false`.
&quot;timeUnitCount&quot;: 42, # The number of time_unit the frequency cap will
# last.
#
# Applicable when unlimited is `false`.
# The following restrictions apply based on the value of
# time_unit:
#
# * `TIME_UNIT_LIFETIME` - this field is output only and will
# default to 1
# * `TIME_UNIT_MONTHS` - must be between 1 and 2
# * `TIME_UNIT_WEEKS` - must be between 1 and 4
# * `TIME_UNIT_DAYS` - must be between 1 and 6
# * `TIME_UNIT_HOURS` - must be between 1 and 23
# * `TIME_UNIT_MINUTES` - must be between 1 and 59
},
&quot;displayName&quot;: &quot;A String&quot;, # Required. The display name of the insertion order.
#
# Must be UTF-8 encoded with a maximum size of 240 bytes.
&quot;partnerCosts&quot;: [ # The partner costs associated with the insertion order.
#
# If absent or empty in
# CreateInsertionOrder
# method, the newly created insertion order will inherit partner costs from
# the partner settings.
{ # Settings that control a partner cost.
#
# A partner cost is any type of expense involved in running a campaign, other
# than the costs of purchasing impressions (which is called the media cost)
# and using third-party audience segment data (data fee). Some examples of
# partner costs include the fees for using DV360, a third-party ad server,
# or a third-party ad serving verification service.
&quot;feeAmount&quot;: &quot;A String&quot;, # The CPM fee amount in micros of advertiser&#x27;s currency.
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_CPM_FEE`. Must be greater than or equal to 0.
#
# For example, for 1.5 standard unit of the advertiser&#x27;s currency, set
# this field to 1500000.
&quot;costType&quot;: &quot;A String&quot;, # Required. The type of the partner cost.
&quot;feeType&quot;: &quot;A String&quot;, # Required. The fee type for this partner cost.
&quot;feePercentageMillis&quot;: &quot;A String&quot;, # The media fee percentage in millis (1/1000 of a percent).
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_MEDIA_FEE`. Must be greater than or equal to 0.
#
# For example: 100 represents 0.1%.
&quot;invoiceType&quot;: &quot;A String&quot;, # The invoice type for this partner cost.
#
# * Required when cost_type is one of:
# - `PARTNER_COST_TYPE_ADLOOX`
# - `PARTNER_COST_TYPE_DOUBLE_VERIFY`
# - `PARTNER_COST_TYPE_INTEGRAL_AD_SCIENCE`.
# * Output only for other types.
},
],
&quot;updateTime&quot;: &quot;A String&quot;, # Output only. The timestamp when the insertion order was last updated.
# Assigned by the system.
&quot;advertiserId&quot;: &quot;A String&quot;, # Output only. The unique ID of the advertiser the insertion order belongs to.
&quot;budget&quot;: { # Settings that control how insertion order budget is allocated. # Required. The budget allocation settings of the insertion order.
&quot;budgetSegments&quot;: [ # Required. The list of budget segments. Use a budget segment to specify
# a specific budget for a given period of time an insertion order is running.
{ # Settings that control the budget of a single budget segment.
&quot;budgetAmountMicros&quot;: &quot;A String&quot;, # Required. The budget amount the insertion order will spend for the given
# date_range.
# The amount is in micros. Must be greater than 0. For example, 500000000
# represents 500 standard units of the currency.
&quot;dateRange&quot;: { # A date range. # Required. The start and end date settings of the budget segment. They are resolved
# relative to the parent advertiser&#x27;s time zone.
#
# * When creating a new budget segment, both `start_date` and `end_date`
# must be in the future.
# * An existing budget segment with a `start_date` in the past has a mutable
# `end_date` but an immutable `start_date`.
# * `end_date` must be the `start_date` or later, both before the year 2037.
&quot;endDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The upper bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
&quot;startDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The lower bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
},
&quot;description&quot;: &quot;A String&quot;, # The budget segment description. It can be used to enter Purchase Order
# information for each budget segment and have that information printed on
# the invoices.
#
# Must be UTF-8 encoded with a length of no more than 80 characters.
&quot;campaignBudgetId&quot;: &quot;A String&quot;, # The ID of the campaign budget linked to this insertion order budget
# segment.
},
],
&quot;automationType&quot;: &quot;A String&quot;, # The type of automation used to manage bid and budget for
# the insertion order.
#
# If this field is unspecified in creation, the value defaults to
# `INSERTION_ORDER_AUTOMATION_TYPE_NONE`.
&quot;budgetUnit&quot;: &quot;A String&quot;, # Required. Immutable. The budget unit specifies whether the budget is currency based or
# impression based.
},
&quot;entityStatus&quot;: &quot;A String&quot;, # Required. Controls whether or not the insertion order can spend its budget
# and bid on inventory.
#
# * For
# CreateInsertionOrder method,
# only `ENTITY_STATUS_DRAFT` is allowed. To activate an insertion order, use
# UpdateInsertionOrder method
# and update the status to `ENTITY_STATUS_ACTIVE` after creation.
# * An insertion order cannot be changed back to `ENTITY_STATUS_DRAFT` status
# from any other status.
# * An insertion order cannot be set to `ENTITY_STATUS_ACTIVE` if its parent
# campaign is not active.
&quot;pacing&quot;: { # Settings that control the rate at which a budget is spent. # Required. The budget spending speed setting of the insertion order.
&quot;pacingPeriod&quot;: &quot;A String&quot;, # Required. The time period in which the pacing budget will be spent.
#
# When automatic budget allocation is enabled at the insertion order via
# auto_budget_allocation, this
# field is output only and defaults to `PACING_PERIOD_FLIGHT`.
&quot;pacingType&quot;: &quot;A String&quot;, # Required. The type of pacing that defines how the budget amount will be
# spent across the pacing_period.
&quot;dailyMaxImpressions&quot;: &quot;A String&quot;, # Maximum number of impressions to serve every day.
#
# Applicable when the budget is impression based. Must be greater than 0.
&quot;dailyMaxMicros&quot;: &quot;A String&quot;, # Maximum currency amount to spend every day in micros of
# advertiser&#x27;s currency.
#
# Applicable when the budget is currency based. Must be greater than 0.
# For example, for 1.5 standard unit of the currency, set this field to
# 1500000.
#
# The value assigned will be rounded to whole billable units for the
# relevant currency by the following rules: any positive value less than a
# single billable unit will be rounded up to one billable unit and any
# value larger than a single billable unit will be rounded down to the
# nearest billable value. For example, if the currency&#x27;s billable unit is
# 0.01, and this field is set to 10257770, it will round down to 10250000,
# a value of 10.25. If set to 505, it will round up to 10000, a value of
# 0.01.
},
&quot;performanceGoal&quot;: { # Settings that control the performance goal of a campaign or insertion order. # Required. Performance goal of the insertion order.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # The goal amount, in micros of the advertiser&#x27;s currency.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CPM`
# * `PERFORMANCE_GOAL_TYPE_CPC`
# * `PERFORMANCE_GOAL_TYPE_CPA`
# * `PERFORMANCE_GOAL_TYPE_CPIAVC`
#
# For example 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalPercentageMicros&quot;: &quot;A String&quot;, # The decimal representation of the goal percentage in micros.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CTR`
# * `PERFORMANCE_GOAL_TYPE_VIEWABILITY`
#
# For example, 70000 represents 7% (decimal 0.07).
&quot;performanceGoalString&quot;: &quot;A String&quot;, # A key performance indicator (KPI) string, which can be empty.
# Must be UTF-8 encoded with a length of no more than 100 characters.
#
# Applicable when
# performance_goal_type is set to
# `PERFORMANCE_GOAL_TYPE_OTHER`.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal.
},
&quot;insertionOrderId&quot;: &quot;A String&quot;, # Output only. The unique ID of the insertion order. Assigned by the system.
&quot;campaignId&quot;: &quot;A String&quot;, # Required. Immutable. The unique ID of the campaign that the insertion order belongs to.
&quot;name&quot;: &quot;A String&quot;, # Output only. The resource name of the insertion order.
&quot;integrationDetails&quot;: { # Integration details of an entry. # Additional integration details of the insertion order.
&quot;details&quot;: &quot;A String&quot;, # Additional details of the entry in string format.
#
# Must be UTF-8 encoded with a length of no more than 1000 characters.
&quot;integrationCode&quot;: &quot;A String&quot;, # An external identifier to be associated with the entry.
# The integration code will show up together with the entry in many
# places in the system, for example, reporting.
#
# Must be UTF-8 encoded with a length of no more than 500 characters.
},
}
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A single insertion order.
&quot;bidStrategy&quot;: { # Settings that control the bid strategy. # Optional. The bidding strategy of the insertion order. By default,
# fixed_bid is set.
# Bid strategy determines the bid price.
&quot;fixedBid&quot;: { # A strategy that uses a fixed bidding price. # A strategy that uses a fixed bid price.
&quot;bidAmountMicros&quot;: &quot;A String&quot;, # The fixed bid amount, in micros of the advertiser&#x27;s currency.
# For insertion order entity,
# bid_amount_micros should be set as 0.
# For line item entity,
# bid_amount_micros must be greater
# than or equal to billable unit of the given currency and smaller than or
# equal to the upper limit 1000000000.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;maximizeSpendAutoBid&quot;: { # A strategy that automatically adjusts the bid to optimize a specified # A strategy that automatically adjusts the bid to optimize to your
# performance goal while spending the full budget.
#
# At insertion order level, the
# markup_type of line items
# cannot be set to `PARTNER_REVENUE_MODEL_MARKUP_TYPE_CPM`. In addition,
# when
# performance_goal_type
# is one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_AV_VIEWED` ,
#
# the line_item_type
# of the insertion order line items must be either:
#
# * `LINE_ITEM_TYPE_DISPLAY_DEFAULT`
# * `LINE_ITEM_TYPE_VIDEO_DEFAULT` ,
#
# and when
# performance_goal_type
# is either:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CIVA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_IVO_TEN`
#
# the line_item_type
# of the insertion order line items must be `LINE_ITEM_TYPE_VIDEO_DEFAULT`.
# performance goal while spending the full budget.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# tries to minimize while spending the full budget.
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM` is not supported for
# this strategy.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;performanceGoalAutoBid&quot;: { # A strategy that automatically adjusts the bid to meet or beat a specified # A strategy that automatically adjusts the bid to meet or beat a specified
# performance goal. It is to be used only for a line item entity.
# performance goal.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# will try to meet or beat.
#
# For line item level usage, the value must be one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency. Not applicable when
# performance_goal_type
# is set to `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
#
# For example, 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # Required. The performance goal the bidding strategy will attempt to
# meet or beat, in micros of the advertiser&#x27;s currency.
# Must be greater than or equal to a billable unit of the given currency and
# smaller or equal to upper bounds. Each
# performance_goal_type
# has its upper bound:
#
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`,
# upper bound is 10000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`,
# upper bound is 1000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, upper bound is
# 1000.00 USD.
#
# Example: If set to
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, the bid price will
# be based on the probability that each available impression will be
# viewable. For example, if viewable CPM target is $2 and an impression is
# 40% likely to be viewable, the bid price will be $0.80 CPM (40% of $2).
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
},
&quot;frequencyCap&quot;: { # Settings that control the number of times a user may be shown with the same # Required. The frequency capping setting of the insertion order.
# ad during a given time period.
&quot;unlimited&quot;: True or False, # Whether unlimited frequency capping is applied. When this field is set to
# `true`, the remaining frequency cap fields are not applicable.
&quot;maxImpressions&quot;: 42, # The maximum number of times a user may be shown with the same ad
# during this period. Must be greater than 0.
#
# Applicable when unlimited is `false`.
&quot;timeUnit&quot;: &quot;A String&quot;, # The time unit in which the frequency cap will be applied.
#
# Applicable when unlimited is `false`.
&quot;timeUnitCount&quot;: 42, # The number of time_unit the frequency cap will
# last.
#
# Applicable when unlimited is `false`.
# The following restrictions apply based on the value of
# time_unit:
#
# * `TIME_UNIT_LIFETIME` - this field is output only and will
# default to 1
# * `TIME_UNIT_MONTHS` - must be between 1 and 2
# * `TIME_UNIT_WEEKS` - must be between 1 and 4
# * `TIME_UNIT_DAYS` - must be between 1 and 6
# * `TIME_UNIT_HOURS` - must be between 1 and 23
# * `TIME_UNIT_MINUTES` - must be between 1 and 59
},
&quot;displayName&quot;: &quot;A String&quot;, # Required. The display name of the insertion order.
#
# Must be UTF-8 encoded with a maximum size of 240 bytes.
&quot;partnerCosts&quot;: [ # The partner costs associated with the insertion order.
#
# If absent or empty in
# CreateInsertionOrder
# method, the newly created insertion order will inherit partner costs from
# the partner settings.
{ # Settings that control a partner cost.
#
# A partner cost is any type of expense involved in running a campaign, other
# than the costs of purchasing impressions (which is called the media cost)
# and using third-party audience segment data (data fee). Some examples of
# partner costs include the fees for using DV360, a third-party ad server,
# or a third-party ad serving verification service.
&quot;feeAmount&quot;: &quot;A String&quot;, # The CPM fee amount in micros of advertiser&#x27;s currency.
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_CPM_FEE`. Must be greater than or equal to 0.
#
# For example, for 1.5 standard unit of the advertiser&#x27;s currency, set
# this field to 1500000.
&quot;costType&quot;: &quot;A String&quot;, # Required. The type of the partner cost.
&quot;feeType&quot;: &quot;A String&quot;, # Required. The fee type for this partner cost.
&quot;feePercentageMillis&quot;: &quot;A String&quot;, # The media fee percentage in millis (1/1000 of a percent).
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_MEDIA_FEE`. Must be greater than or equal to 0.
#
# For example: 100 represents 0.1%.
&quot;invoiceType&quot;: &quot;A String&quot;, # The invoice type for this partner cost.
#
# * Required when cost_type is one of:
# - `PARTNER_COST_TYPE_ADLOOX`
# - `PARTNER_COST_TYPE_DOUBLE_VERIFY`
# - `PARTNER_COST_TYPE_INTEGRAL_AD_SCIENCE`.
# * Output only for other types.
},
],
&quot;updateTime&quot;: &quot;A String&quot;, # Output only. The timestamp when the insertion order was last updated.
# Assigned by the system.
&quot;advertiserId&quot;: &quot;A String&quot;, # Output only. The unique ID of the advertiser the insertion order belongs to.
&quot;budget&quot;: { # Settings that control how insertion order budget is allocated. # Required. The budget allocation settings of the insertion order.
&quot;budgetSegments&quot;: [ # Required. The list of budget segments. Use a budget segment to specify
# a specific budget for a given period of time an insertion order is running.
{ # Settings that control the budget of a single budget segment.
&quot;budgetAmountMicros&quot;: &quot;A String&quot;, # Required. The budget amount the insertion order will spend for the given
# date_range.
# The amount is in micros. Must be greater than 0. For example, 500000000
# represents 500 standard units of the currency.
&quot;dateRange&quot;: { # A date range. # Required. The start and end date settings of the budget segment. They are resolved
# relative to the parent advertiser&#x27;s time zone.
#
# * When creating a new budget segment, both `start_date` and `end_date`
# must be in the future.
# * An existing budget segment with a `start_date` in the past has a mutable
# `end_date` but an immutable `start_date`.
# * `end_date` must be the `start_date` or later, both before the year 2037.
&quot;endDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The upper bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
&quot;startDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The lower bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
},
&quot;description&quot;: &quot;A String&quot;, # The budget segment description. It can be used to enter Purchase Order
# information for each budget segment and have that information printed on
# the invoices.
#
# Must be UTF-8 encoded with a length of no more than 80 characters.
&quot;campaignBudgetId&quot;: &quot;A String&quot;, # The ID of the campaign budget linked to this insertion order budget
# segment.
},
],
&quot;automationType&quot;: &quot;A String&quot;, # The type of automation used to manage bid and budget for
# the insertion order.
#
# If this field is unspecified in creation, the value defaults to
# `INSERTION_ORDER_AUTOMATION_TYPE_NONE`.
&quot;budgetUnit&quot;: &quot;A String&quot;, # Required. Immutable. The budget unit specifies whether the budget is currency based or
# impression based.
},
&quot;entityStatus&quot;: &quot;A String&quot;, # Required. Controls whether or not the insertion order can spend its budget
# and bid on inventory.
#
# * For
# CreateInsertionOrder method,
# only `ENTITY_STATUS_DRAFT` is allowed. To activate an insertion order, use
# UpdateInsertionOrder method
# and update the status to `ENTITY_STATUS_ACTIVE` after creation.
# * An insertion order cannot be changed back to `ENTITY_STATUS_DRAFT` status
# from any other status.
# * An insertion order cannot be set to `ENTITY_STATUS_ACTIVE` if its parent
# campaign is not active.
&quot;pacing&quot;: { # Settings that control the rate at which a budget is spent. # Required. The budget spending speed setting of the insertion order.
&quot;pacingPeriod&quot;: &quot;A String&quot;, # Required. The time period in which the pacing budget will be spent.
#
# When automatic budget allocation is enabled at the insertion order via
# auto_budget_allocation, this
# field is output only and defaults to `PACING_PERIOD_FLIGHT`.
&quot;pacingType&quot;: &quot;A String&quot;, # Required. The type of pacing that defines how the budget amount will be
# spent across the pacing_period.
&quot;dailyMaxImpressions&quot;: &quot;A String&quot;, # Maximum number of impressions to serve every day.
#
# Applicable when the budget is impression based. Must be greater than 0.
&quot;dailyMaxMicros&quot;: &quot;A String&quot;, # Maximum currency amount to spend every day in micros of
# advertiser&#x27;s currency.
#
# Applicable when the budget is currency based. Must be greater than 0.
# For example, for 1.5 standard unit of the currency, set this field to
# 1500000.
#
# The value assigned will be rounded to whole billable units for the
# relevant currency by the following rules: any positive value less than a
# single billable unit will be rounded up to one billable unit and any
# value larger than a single billable unit will be rounded down to the
# nearest billable value. For example, if the currency&#x27;s billable unit is
# 0.01, and this field is set to 10257770, it will round down to 10250000,
# a value of 10.25. If set to 505, it will round up to 10000, a value of
# 0.01.
},
&quot;performanceGoal&quot;: { # Settings that control the performance goal of a campaign or insertion order. # Required. Performance goal of the insertion order.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # The goal amount, in micros of the advertiser&#x27;s currency.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CPM`
# * `PERFORMANCE_GOAL_TYPE_CPC`
# * `PERFORMANCE_GOAL_TYPE_CPA`
# * `PERFORMANCE_GOAL_TYPE_CPIAVC`
#
# For example 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalPercentageMicros&quot;: &quot;A String&quot;, # The decimal representation of the goal percentage in micros.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CTR`
# * `PERFORMANCE_GOAL_TYPE_VIEWABILITY`
#
# For example, 70000 represents 7% (decimal 0.07).
&quot;performanceGoalString&quot;: &quot;A String&quot;, # A key performance indicator (KPI) string, which can be empty.
# Must be UTF-8 encoded with a length of no more than 100 characters.
#
# Applicable when
# performance_goal_type is set to
# `PERFORMANCE_GOAL_TYPE_OTHER`.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal.
},
&quot;insertionOrderId&quot;: &quot;A String&quot;, # Output only. The unique ID of the insertion order. Assigned by the system.
&quot;campaignId&quot;: &quot;A String&quot;, # Required. Immutable. The unique ID of the campaign that the insertion order belongs to.
&quot;name&quot;: &quot;A String&quot;, # Output only. The resource name of the insertion order.
&quot;integrationDetails&quot;: { # Integration details of an entry. # Additional integration details of the insertion order.
&quot;details&quot;: &quot;A String&quot;, # Additional details of the entry in string format.
#
# Must be UTF-8 encoded with a length of no more than 1000 characters.
&quot;integrationCode&quot;: &quot;A String&quot;, # An external identifier to be associated with the entry.
# The integration code will show up together with the entry in many
# places in the system, for example, reporting.
#
# Must be UTF-8 encoded with a length of no more than 500 characters.
},
}</pre>
</div>
<div class="method">
<code class="details" id="delete">delete(advertiserId, insertionOrderId, x__xgafv=None)</code>
<pre>Deletes an insertion order.
Returns error code `NOT_FOUND` if the insertion order does not exist.
The insertion order should be archived first, i.e. set
entity_status to `ENTITY_STATUS_ARCHIVED`,
to be able to delete it.
Args:
advertiserId: string, The ID of the advertiser this insertion order belongs to. (required)
insertionOrderId: string, The ID of the insertion order we need to delete. (required)
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A generic empty message that you can re-use to avoid defining duplicated
# empty messages in your APIs. A typical example is to use it as the request
# or the response type of an API method. For instance:
#
# service Foo {
# rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
# }
#
# The JSON representation for `Empty` is empty JSON object `{}`.
}</pre>
</div>
<div class="method">
<code class="details" id="get">get(advertiserId, insertionOrderId, x__xgafv=None)</code>
<pre>Gets an insertion order.
Returns error code `NOT_FOUND` if the insertion order does not exist.
Args:
advertiserId: string, Required. The ID of the advertiser this insertion order belongs to. (required)
insertionOrderId: string, Required. The ID of the insertion order to fetch. (required)
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A single insertion order.
&quot;bidStrategy&quot;: { # Settings that control the bid strategy. # Optional. The bidding strategy of the insertion order. By default,
# fixed_bid is set.
# Bid strategy determines the bid price.
&quot;fixedBid&quot;: { # A strategy that uses a fixed bidding price. # A strategy that uses a fixed bid price.
&quot;bidAmountMicros&quot;: &quot;A String&quot;, # The fixed bid amount, in micros of the advertiser&#x27;s currency.
# For insertion order entity,
# bid_amount_micros should be set as 0.
# For line item entity,
# bid_amount_micros must be greater
# than or equal to billable unit of the given currency and smaller than or
# equal to the upper limit 1000000000.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;maximizeSpendAutoBid&quot;: { # A strategy that automatically adjusts the bid to optimize a specified # A strategy that automatically adjusts the bid to optimize to your
# performance goal while spending the full budget.
#
# At insertion order level, the
# markup_type of line items
# cannot be set to `PARTNER_REVENUE_MODEL_MARKUP_TYPE_CPM`. In addition,
# when
# performance_goal_type
# is one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_AV_VIEWED` ,
#
# the line_item_type
# of the insertion order line items must be either:
#
# * `LINE_ITEM_TYPE_DISPLAY_DEFAULT`
# * `LINE_ITEM_TYPE_VIDEO_DEFAULT` ,
#
# and when
# performance_goal_type
# is either:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CIVA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_IVO_TEN`
#
# the line_item_type
# of the insertion order line items must be `LINE_ITEM_TYPE_VIDEO_DEFAULT`.
# performance goal while spending the full budget.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# tries to minimize while spending the full budget.
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM` is not supported for
# this strategy.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;performanceGoalAutoBid&quot;: { # A strategy that automatically adjusts the bid to meet or beat a specified # A strategy that automatically adjusts the bid to meet or beat a specified
# performance goal. It is to be used only for a line item entity.
# performance goal.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# will try to meet or beat.
#
# For line item level usage, the value must be one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency. Not applicable when
# performance_goal_type
# is set to `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
#
# For example, 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # Required. The performance goal the bidding strategy will attempt to
# meet or beat, in micros of the advertiser&#x27;s currency.
# Must be greater than or equal to a billable unit of the given currency and
# smaller or equal to upper bounds. Each
# performance_goal_type
# has its upper bound:
#
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`,
# upper bound is 10000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`,
# upper bound is 1000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, upper bound is
# 1000.00 USD.
#
# Example: If set to
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, the bid price will
# be based on the probability that each available impression will be
# viewable. For example, if viewable CPM target is $2 and an impression is
# 40% likely to be viewable, the bid price will be $0.80 CPM (40% of $2).
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
},
&quot;frequencyCap&quot;: { # Settings that control the number of times a user may be shown with the same # Required. The frequency capping setting of the insertion order.
# ad during a given time period.
&quot;unlimited&quot;: True or False, # Whether unlimited frequency capping is applied. When this field is set to
# `true`, the remaining frequency cap fields are not applicable.
&quot;maxImpressions&quot;: 42, # The maximum number of times a user may be shown with the same ad
# during this period. Must be greater than 0.
#
# Applicable when unlimited is `false`.
&quot;timeUnit&quot;: &quot;A String&quot;, # The time unit in which the frequency cap will be applied.
#
# Applicable when unlimited is `false`.
&quot;timeUnitCount&quot;: 42, # The number of time_unit the frequency cap will
# last.
#
# Applicable when unlimited is `false`.
# The following restrictions apply based on the value of
# time_unit:
#
# * `TIME_UNIT_LIFETIME` - this field is output only and will
# default to 1
# * `TIME_UNIT_MONTHS` - must be between 1 and 2
# * `TIME_UNIT_WEEKS` - must be between 1 and 4
# * `TIME_UNIT_DAYS` - must be between 1 and 6
# * `TIME_UNIT_HOURS` - must be between 1 and 23
# * `TIME_UNIT_MINUTES` - must be between 1 and 59
},
&quot;displayName&quot;: &quot;A String&quot;, # Required. The display name of the insertion order.
#
# Must be UTF-8 encoded with a maximum size of 240 bytes.
&quot;partnerCosts&quot;: [ # The partner costs associated with the insertion order.
#
# If absent or empty in
# CreateInsertionOrder
# method, the newly created insertion order will inherit partner costs from
# the partner settings.
{ # Settings that control a partner cost.
#
# A partner cost is any type of expense involved in running a campaign, other
# than the costs of purchasing impressions (which is called the media cost)
# and using third-party audience segment data (data fee). Some examples of
# partner costs include the fees for using DV360, a third-party ad server,
# or a third-party ad serving verification service.
&quot;feeAmount&quot;: &quot;A String&quot;, # The CPM fee amount in micros of advertiser&#x27;s currency.
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_CPM_FEE`. Must be greater than or equal to 0.
#
# For example, for 1.5 standard unit of the advertiser&#x27;s currency, set
# this field to 1500000.
&quot;costType&quot;: &quot;A String&quot;, # Required. The type of the partner cost.
&quot;feeType&quot;: &quot;A String&quot;, # Required. The fee type for this partner cost.
&quot;feePercentageMillis&quot;: &quot;A String&quot;, # The media fee percentage in millis (1/1000 of a percent).
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_MEDIA_FEE`. Must be greater than or equal to 0.
#
# For example: 100 represents 0.1%.
&quot;invoiceType&quot;: &quot;A String&quot;, # The invoice type for this partner cost.
#
# * Required when cost_type is one of:
# - `PARTNER_COST_TYPE_ADLOOX`
# - `PARTNER_COST_TYPE_DOUBLE_VERIFY`
# - `PARTNER_COST_TYPE_INTEGRAL_AD_SCIENCE`.
# * Output only for other types.
},
],
&quot;updateTime&quot;: &quot;A String&quot;, # Output only. The timestamp when the insertion order was last updated.
# Assigned by the system.
&quot;advertiserId&quot;: &quot;A String&quot;, # Output only. The unique ID of the advertiser the insertion order belongs to.
&quot;budget&quot;: { # Settings that control how insertion order budget is allocated. # Required. The budget allocation settings of the insertion order.
&quot;budgetSegments&quot;: [ # Required. The list of budget segments. Use a budget segment to specify
# a specific budget for a given period of time an insertion order is running.
{ # Settings that control the budget of a single budget segment.
&quot;budgetAmountMicros&quot;: &quot;A String&quot;, # Required. The budget amount the insertion order will spend for the given
# date_range.
# The amount is in micros. Must be greater than 0. For example, 500000000
# represents 500 standard units of the currency.
&quot;dateRange&quot;: { # A date range. # Required. The start and end date settings of the budget segment. They are resolved
# relative to the parent advertiser&#x27;s time zone.
#
# * When creating a new budget segment, both `start_date` and `end_date`
# must be in the future.
# * An existing budget segment with a `start_date` in the past has a mutable
# `end_date` but an immutable `start_date`.
# * `end_date` must be the `start_date` or later, both before the year 2037.
&quot;endDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The upper bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
&quot;startDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The lower bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
},
&quot;description&quot;: &quot;A String&quot;, # The budget segment description. It can be used to enter Purchase Order
# information for each budget segment and have that information printed on
# the invoices.
#
# Must be UTF-8 encoded with a length of no more than 80 characters.
&quot;campaignBudgetId&quot;: &quot;A String&quot;, # The ID of the campaign budget linked to this insertion order budget
# segment.
},
],
&quot;automationType&quot;: &quot;A String&quot;, # The type of automation used to manage bid and budget for
# the insertion order.
#
# If this field is unspecified in creation, the value defaults to
# `INSERTION_ORDER_AUTOMATION_TYPE_NONE`.
&quot;budgetUnit&quot;: &quot;A String&quot;, # Required. Immutable. The budget unit specifies whether the budget is currency based or
# impression based.
},
&quot;entityStatus&quot;: &quot;A String&quot;, # Required. Controls whether or not the insertion order can spend its budget
# and bid on inventory.
#
# * For
# CreateInsertionOrder method,
# only `ENTITY_STATUS_DRAFT` is allowed. To activate an insertion order, use
# UpdateInsertionOrder method
# and update the status to `ENTITY_STATUS_ACTIVE` after creation.
# * An insertion order cannot be changed back to `ENTITY_STATUS_DRAFT` status
# from any other status.
# * An insertion order cannot be set to `ENTITY_STATUS_ACTIVE` if its parent
# campaign is not active.
&quot;pacing&quot;: { # Settings that control the rate at which a budget is spent. # Required. The budget spending speed setting of the insertion order.
&quot;pacingPeriod&quot;: &quot;A String&quot;, # Required. The time period in which the pacing budget will be spent.
#
# When automatic budget allocation is enabled at the insertion order via
# auto_budget_allocation, this
# field is output only and defaults to `PACING_PERIOD_FLIGHT`.
&quot;pacingType&quot;: &quot;A String&quot;, # Required. The type of pacing that defines how the budget amount will be
# spent across the pacing_period.
&quot;dailyMaxImpressions&quot;: &quot;A String&quot;, # Maximum number of impressions to serve every day.
#
# Applicable when the budget is impression based. Must be greater than 0.
&quot;dailyMaxMicros&quot;: &quot;A String&quot;, # Maximum currency amount to spend every day in micros of
# advertiser&#x27;s currency.
#
# Applicable when the budget is currency based. Must be greater than 0.
# For example, for 1.5 standard unit of the currency, set this field to
# 1500000.
#
# The value assigned will be rounded to whole billable units for the
# relevant currency by the following rules: any positive value less than a
# single billable unit will be rounded up to one billable unit and any
# value larger than a single billable unit will be rounded down to the
# nearest billable value. For example, if the currency&#x27;s billable unit is
# 0.01, and this field is set to 10257770, it will round down to 10250000,
# a value of 10.25. If set to 505, it will round up to 10000, a value of
# 0.01.
},
&quot;performanceGoal&quot;: { # Settings that control the performance goal of a campaign or insertion order. # Required. Performance goal of the insertion order.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # The goal amount, in micros of the advertiser&#x27;s currency.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CPM`
# * `PERFORMANCE_GOAL_TYPE_CPC`
# * `PERFORMANCE_GOAL_TYPE_CPA`
# * `PERFORMANCE_GOAL_TYPE_CPIAVC`
#
# For example 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalPercentageMicros&quot;: &quot;A String&quot;, # The decimal representation of the goal percentage in micros.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CTR`
# * `PERFORMANCE_GOAL_TYPE_VIEWABILITY`
#
# For example, 70000 represents 7% (decimal 0.07).
&quot;performanceGoalString&quot;: &quot;A String&quot;, # A key performance indicator (KPI) string, which can be empty.
# Must be UTF-8 encoded with a length of no more than 100 characters.
#
# Applicable when
# performance_goal_type is set to
# `PERFORMANCE_GOAL_TYPE_OTHER`.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal.
},
&quot;insertionOrderId&quot;: &quot;A String&quot;, # Output only. The unique ID of the insertion order. Assigned by the system.
&quot;campaignId&quot;: &quot;A String&quot;, # Required. Immutable. The unique ID of the campaign that the insertion order belongs to.
&quot;name&quot;: &quot;A String&quot;, # Output only. The resource name of the insertion order.
&quot;integrationDetails&quot;: { # Integration details of an entry. # Additional integration details of the insertion order.
&quot;details&quot;: &quot;A String&quot;, # Additional details of the entry in string format.
#
# Must be UTF-8 encoded with a length of no more than 1000 characters.
&quot;integrationCode&quot;: &quot;A String&quot;, # An external identifier to be associated with the entry.
# The integration code will show up together with the entry in many
# places in the system, for example, reporting.
#
# Must be UTF-8 encoded with a length of no more than 500 characters.
},
}</pre>
</div>
<div class="method">
<code class="details" id="list">list(advertiserId, filter=None, pageToken=None, orderBy=None, pageSize=None, x__xgafv=None)</code>
<pre>Lists insertion orders in an advertiser.
The order is defined by the order_by
parameter.
If a filter by
entity_status is not specified, insertion
orders with `ENTITY_STATUS_ARCHIVED` will not be included in the results.
Args:
advertiserId: string, Required. The ID of the advertiser to list insertion orders for. (required)
filter: string, Allows filtering by insertion order properties.
Supported syntax:
* Filter expressions are made up of one or more restrictions.
* Restrictions can be combined by `AND` or `OR` logical operators. A
sequence of restrictions implicitly uses `AND`.
* A restriction has the form of `{field} {operator} {value}`.
* The operator must be `EQUALS (=)`.
* Supported fields:
- `campaignId`
- `entityStatus`
Examples:
* All insertion orders under a campaign: `campaignId=&quot;1234&quot;`
* All `ENTITY_STATUS_ACTIVE` or `ENTITY_STATUS_PAUSED` insertion orders
under an advertiser:
`(entityStatus=&quot;ENTITY_STATUS_ACTIVE&quot; OR
entityStatus=&quot;ENTITY_STATUS_PAUSED&quot;)`
The length of this field should be no more than 500 characters.
pageToken: string, A token identifying a page of results the server should return.
Typically, this is the value of
next_page_token returned
from the previous call to `ListInsertionOrders` method. If not specified,
the first page of results will be returned.
orderBy: string, Field by which to sort the list.
Acceptable values are:
* &quot;displayName&quot; (default)
* &quot;entityStatus&quot;
The default sorting order is ascending. To specify descending order for
a field, a suffix &quot;desc&quot; should be added to the field name. Example:
`displayName desc`.
pageSize: integer, Requested page size. Must be between `1` and `100`. If unspecified will
default to `100`. Returns error code `INVALID_ARGUMENT` if an invalid value
is specified.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{
&quot;insertionOrders&quot;: [ # The list of insertion orders.
#
# This list will be absent if empty.
{ # A single insertion order.
&quot;bidStrategy&quot;: { # Settings that control the bid strategy. # Optional. The bidding strategy of the insertion order. By default,
# fixed_bid is set.
# Bid strategy determines the bid price.
&quot;fixedBid&quot;: { # A strategy that uses a fixed bidding price. # A strategy that uses a fixed bid price.
&quot;bidAmountMicros&quot;: &quot;A String&quot;, # The fixed bid amount, in micros of the advertiser&#x27;s currency.
# For insertion order entity,
# bid_amount_micros should be set as 0.
# For line item entity,
# bid_amount_micros must be greater
# than or equal to billable unit of the given currency and smaller than or
# equal to the upper limit 1000000000.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;maximizeSpendAutoBid&quot;: { # A strategy that automatically adjusts the bid to optimize a specified # A strategy that automatically adjusts the bid to optimize to your
# performance goal while spending the full budget.
#
# At insertion order level, the
# markup_type of line items
# cannot be set to `PARTNER_REVENUE_MODEL_MARKUP_TYPE_CPM`. In addition,
# when
# performance_goal_type
# is one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_AV_VIEWED` ,
#
# the line_item_type
# of the insertion order line items must be either:
#
# * `LINE_ITEM_TYPE_DISPLAY_DEFAULT`
# * `LINE_ITEM_TYPE_VIDEO_DEFAULT` ,
#
# and when
# performance_goal_type
# is either:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CIVA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_IVO_TEN`
#
# the line_item_type
# of the insertion order line items must be `LINE_ITEM_TYPE_VIDEO_DEFAULT`.
# performance goal while spending the full budget.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# tries to minimize while spending the full budget.
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM` is not supported for
# this strategy.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;performanceGoalAutoBid&quot;: { # A strategy that automatically adjusts the bid to meet or beat a specified # A strategy that automatically adjusts the bid to meet or beat a specified
# performance goal. It is to be used only for a line item entity.
# performance goal.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# will try to meet or beat.
#
# For line item level usage, the value must be one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency. Not applicable when
# performance_goal_type
# is set to `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
#
# For example, 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # Required. The performance goal the bidding strategy will attempt to
# meet or beat, in micros of the advertiser&#x27;s currency.
# Must be greater than or equal to a billable unit of the given currency and
# smaller or equal to upper bounds. Each
# performance_goal_type
# has its upper bound:
#
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`,
# upper bound is 10000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`,
# upper bound is 1000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, upper bound is
# 1000.00 USD.
#
# Example: If set to
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, the bid price will
# be based on the probability that each available impression will be
# viewable. For example, if viewable CPM target is $2 and an impression is
# 40% likely to be viewable, the bid price will be $0.80 CPM (40% of $2).
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
},
&quot;frequencyCap&quot;: { # Settings that control the number of times a user may be shown with the same # Required. The frequency capping setting of the insertion order.
# ad during a given time period.
&quot;unlimited&quot;: True or False, # Whether unlimited frequency capping is applied. When this field is set to
# `true`, the remaining frequency cap fields are not applicable.
&quot;maxImpressions&quot;: 42, # The maximum number of times a user may be shown with the same ad
# during this period. Must be greater than 0.
#
# Applicable when unlimited is `false`.
&quot;timeUnit&quot;: &quot;A String&quot;, # The time unit in which the frequency cap will be applied.
#
# Applicable when unlimited is `false`.
&quot;timeUnitCount&quot;: 42, # The number of time_unit the frequency cap will
# last.
#
# Applicable when unlimited is `false`.
# The following restrictions apply based on the value of
# time_unit:
#
# * `TIME_UNIT_LIFETIME` - this field is output only and will
# default to 1
# * `TIME_UNIT_MONTHS` - must be between 1 and 2
# * `TIME_UNIT_WEEKS` - must be between 1 and 4
# * `TIME_UNIT_DAYS` - must be between 1 and 6
# * `TIME_UNIT_HOURS` - must be between 1 and 23
# * `TIME_UNIT_MINUTES` - must be between 1 and 59
},
&quot;displayName&quot;: &quot;A String&quot;, # Required. The display name of the insertion order.
#
# Must be UTF-8 encoded with a maximum size of 240 bytes.
&quot;partnerCosts&quot;: [ # The partner costs associated with the insertion order.
#
# If absent or empty in
# CreateInsertionOrder
# method, the newly created insertion order will inherit partner costs from
# the partner settings.
{ # Settings that control a partner cost.
#
# A partner cost is any type of expense involved in running a campaign, other
# than the costs of purchasing impressions (which is called the media cost)
# and using third-party audience segment data (data fee). Some examples of
# partner costs include the fees for using DV360, a third-party ad server,
# or a third-party ad serving verification service.
&quot;feeAmount&quot;: &quot;A String&quot;, # The CPM fee amount in micros of advertiser&#x27;s currency.
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_CPM_FEE`. Must be greater than or equal to 0.
#
# For example, for 1.5 standard unit of the advertiser&#x27;s currency, set
# this field to 1500000.
&quot;costType&quot;: &quot;A String&quot;, # Required. The type of the partner cost.
&quot;feeType&quot;: &quot;A String&quot;, # Required. The fee type for this partner cost.
&quot;feePercentageMillis&quot;: &quot;A String&quot;, # The media fee percentage in millis (1/1000 of a percent).
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_MEDIA_FEE`. Must be greater than or equal to 0.
#
# For example: 100 represents 0.1%.
&quot;invoiceType&quot;: &quot;A String&quot;, # The invoice type for this partner cost.
#
# * Required when cost_type is one of:
# - `PARTNER_COST_TYPE_ADLOOX`
# - `PARTNER_COST_TYPE_DOUBLE_VERIFY`
# - `PARTNER_COST_TYPE_INTEGRAL_AD_SCIENCE`.
# * Output only for other types.
},
],
&quot;updateTime&quot;: &quot;A String&quot;, # Output only. The timestamp when the insertion order was last updated.
# Assigned by the system.
&quot;advertiserId&quot;: &quot;A String&quot;, # Output only. The unique ID of the advertiser the insertion order belongs to.
&quot;budget&quot;: { # Settings that control how insertion order budget is allocated. # Required. The budget allocation settings of the insertion order.
&quot;budgetSegments&quot;: [ # Required. The list of budget segments. Use a budget segment to specify
# a specific budget for a given period of time an insertion order is running.
{ # Settings that control the budget of a single budget segment.
&quot;budgetAmountMicros&quot;: &quot;A String&quot;, # Required. The budget amount the insertion order will spend for the given
# date_range.
# The amount is in micros. Must be greater than 0. For example, 500000000
# represents 500 standard units of the currency.
&quot;dateRange&quot;: { # A date range. # Required. The start and end date settings of the budget segment. They are resolved
# relative to the parent advertiser&#x27;s time zone.
#
# * When creating a new budget segment, both `start_date` and `end_date`
# must be in the future.
# * An existing budget segment with a `start_date` in the past has a mutable
# `end_date` but an immutable `start_date`.
# * `end_date` must be the `start_date` or later, both before the year 2037.
&quot;endDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The upper bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
&quot;startDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The lower bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
},
&quot;description&quot;: &quot;A String&quot;, # The budget segment description. It can be used to enter Purchase Order
# information for each budget segment and have that information printed on
# the invoices.
#
# Must be UTF-8 encoded with a length of no more than 80 characters.
&quot;campaignBudgetId&quot;: &quot;A String&quot;, # The ID of the campaign budget linked to this insertion order budget
# segment.
},
],
&quot;automationType&quot;: &quot;A String&quot;, # The type of automation used to manage bid and budget for
# the insertion order.
#
# If this field is unspecified in creation, the value defaults to
# `INSERTION_ORDER_AUTOMATION_TYPE_NONE`.
&quot;budgetUnit&quot;: &quot;A String&quot;, # Required. Immutable. The budget unit specifies whether the budget is currency based or
# impression based.
},
&quot;entityStatus&quot;: &quot;A String&quot;, # Required. Controls whether or not the insertion order can spend its budget
# and bid on inventory.
#
# * For
# CreateInsertionOrder method,
# only `ENTITY_STATUS_DRAFT` is allowed. To activate an insertion order, use
# UpdateInsertionOrder method
# and update the status to `ENTITY_STATUS_ACTIVE` after creation.
# * An insertion order cannot be changed back to `ENTITY_STATUS_DRAFT` status
# from any other status.
# * An insertion order cannot be set to `ENTITY_STATUS_ACTIVE` if its parent
# campaign is not active.
&quot;pacing&quot;: { # Settings that control the rate at which a budget is spent. # Required. The budget spending speed setting of the insertion order.
&quot;pacingPeriod&quot;: &quot;A String&quot;, # Required. The time period in which the pacing budget will be spent.
#
# When automatic budget allocation is enabled at the insertion order via
# auto_budget_allocation, this
# field is output only and defaults to `PACING_PERIOD_FLIGHT`.
&quot;pacingType&quot;: &quot;A String&quot;, # Required. The type of pacing that defines how the budget amount will be
# spent across the pacing_period.
&quot;dailyMaxImpressions&quot;: &quot;A String&quot;, # Maximum number of impressions to serve every day.
#
# Applicable when the budget is impression based. Must be greater than 0.
&quot;dailyMaxMicros&quot;: &quot;A String&quot;, # Maximum currency amount to spend every day in micros of
# advertiser&#x27;s currency.
#
# Applicable when the budget is currency based. Must be greater than 0.
# For example, for 1.5 standard unit of the currency, set this field to
# 1500000.
#
# The value assigned will be rounded to whole billable units for the
# relevant currency by the following rules: any positive value less than a
# single billable unit will be rounded up to one billable unit and any
# value larger than a single billable unit will be rounded down to the
# nearest billable value. For example, if the currency&#x27;s billable unit is
# 0.01, and this field is set to 10257770, it will round down to 10250000,
# a value of 10.25. If set to 505, it will round up to 10000, a value of
# 0.01.
},
&quot;performanceGoal&quot;: { # Settings that control the performance goal of a campaign or insertion order. # Required. Performance goal of the insertion order.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # The goal amount, in micros of the advertiser&#x27;s currency.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CPM`
# * `PERFORMANCE_GOAL_TYPE_CPC`
# * `PERFORMANCE_GOAL_TYPE_CPA`
# * `PERFORMANCE_GOAL_TYPE_CPIAVC`
#
# For example 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalPercentageMicros&quot;: &quot;A String&quot;, # The decimal representation of the goal percentage in micros.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CTR`
# * `PERFORMANCE_GOAL_TYPE_VIEWABILITY`
#
# For example, 70000 represents 7% (decimal 0.07).
&quot;performanceGoalString&quot;: &quot;A String&quot;, # A key performance indicator (KPI) string, which can be empty.
# Must be UTF-8 encoded with a length of no more than 100 characters.
#
# Applicable when
# performance_goal_type is set to
# `PERFORMANCE_GOAL_TYPE_OTHER`.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal.
},
&quot;insertionOrderId&quot;: &quot;A String&quot;, # Output only. The unique ID of the insertion order. Assigned by the system.
&quot;campaignId&quot;: &quot;A String&quot;, # Required. Immutable. The unique ID of the campaign that the insertion order belongs to.
&quot;name&quot;: &quot;A String&quot;, # Output only. The resource name of the insertion order.
&quot;integrationDetails&quot;: { # Integration details of an entry. # Additional integration details of the insertion order.
&quot;details&quot;: &quot;A String&quot;, # Additional details of the entry in string format.
#
# Must be UTF-8 encoded with a length of no more than 1000 characters.
&quot;integrationCode&quot;: &quot;A String&quot;, # An external identifier to be associated with the entry.
# The integration code will show up together with the entry in many
# places in the system, for example, reporting.
#
# Must be UTF-8 encoded with a length of no more than 500 characters.
},
},
],
&quot;nextPageToken&quot;: &quot;A String&quot;, # A token to retrieve the next page of results.
# Pass this value in the page_token
# field in the subsequent call to `ListInsertionOrders` method to retrieve
# the next page of results.
}</pre>
</div>
<div class="method">
<code class="details" id="list_next">list_next(previous_request, previous_response)</code>
<pre>Retrieves the next page of results.
Args:
previous_request: The request for the previous page. (required)
previous_response: The response from the request for the previous page. (required)
Returns:
A request object that you can call &#x27;execute()&#x27; on to request the next
page. Returns None if there are no more items in the collection.
</pre>
</div>
<div class="method">
<code class="details" id="patch">patch(advertiserId, insertionOrderId, body=None, updateMask=None, x__xgafv=None)</code>
<pre>Updates an existing insertion order.
Returns the updated insertion order if successful.
Args:
advertiserId: string, Output only. The unique ID of the advertiser the insertion order belongs to. (required)
insertionOrderId: string, Output only. The unique ID of the insertion order. Assigned by the system. (required)
body: object, The request body.
The object takes the form of:
{ # A single insertion order.
&quot;bidStrategy&quot;: { # Settings that control the bid strategy. # Optional. The bidding strategy of the insertion order. By default,
# fixed_bid is set.
# Bid strategy determines the bid price.
&quot;fixedBid&quot;: { # A strategy that uses a fixed bidding price. # A strategy that uses a fixed bid price.
&quot;bidAmountMicros&quot;: &quot;A String&quot;, # The fixed bid amount, in micros of the advertiser&#x27;s currency.
# For insertion order entity,
# bid_amount_micros should be set as 0.
# For line item entity,
# bid_amount_micros must be greater
# than or equal to billable unit of the given currency and smaller than or
# equal to the upper limit 1000000000.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;maximizeSpendAutoBid&quot;: { # A strategy that automatically adjusts the bid to optimize a specified # A strategy that automatically adjusts the bid to optimize to your
# performance goal while spending the full budget.
#
# At insertion order level, the
# markup_type of line items
# cannot be set to `PARTNER_REVENUE_MODEL_MARKUP_TYPE_CPM`. In addition,
# when
# performance_goal_type
# is one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_AV_VIEWED` ,
#
# the line_item_type
# of the insertion order line items must be either:
#
# * `LINE_ITEM_TYPE_DISPLAY_DEFAULT`
# * `LINE_ITEM_TYPE_VIDEO_DEFAULT` ,
#
# and when
# performance_goal_type
# is either:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CIVA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_IVO_TEN`
#
# the line_item_type
# of the insertion order line items must be `LINE_ITEM_TYPE_VIDEO_DEFAULT`.
# performance goal while spending the full budget.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# tries to minimize while spending the full budget.
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM` is not supported for
# this strategy.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;performanceGoalAutoBid&quot;: { # A strategy that automatically adjusts the bid to meet or beat a specified # A strategy that automatically adjusts the bid to meet or beat a specified
# performance goal. It is to be used only for a line item entity.
# performance goal.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# will try to meet or beat.
#
# For line item level usage, the value must be one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency. Not applicable when
# performance_goal_type
# is set to `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
#
# For example, 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # Required. The performance goal the bidding strategy will attempt to
# meet or beat, in micros of the advertiser&#x27;s currency.
# Must be greater than or equal to a billable unit of the given currency and
# smaller or equal to upper bounds. Each
# performance_goal_type
# has its upper bound:
#
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`,
# upper bound is 10000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`,
# upper bound is 1000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, upper bound is
# 1000.00 USD.
#
# Example: If set to
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, the bid price will
# be based on the probability that each available impression will be
# viewable. For example, if viewable CPM target is $2 and an impression is
# 40% likely to be viewable, the bid price will be $0.80 CPM (40% of $2).
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
},
&quot;frequencyCap&quot;: { # Settings that control the number of times a user may be shown with the same # Required. The frequency capping setting of the insertion order.
# ad during a given time period.
&quot;unlimited&quot;: True or False, # Whether unlimited frequency capping is applied. When this field is set to
# `true`, the remaining frequency cap fields are not applicable.
&quot;maxImpressions&quot;: 42, # The maximum number of times a user may be shown with the same ad
# during this period. Must be greater than 0.
#
# Applicable when unlimited is `false`.
&quot;timeUnit&quot;: &quot;A String&quot;, # The time unit in which the frequency cap will be applied.
#
# Applicable when unlimited is `false`.
&quot;timeUnitCount&quot;: 42, # The number of time_unit the frequency cap will
# last.
#
# Applicable when unlimited is `false`.
# The following restrictions apply based on the value of
# time_unit:
#
# * `TIME_UNIT_LIFETIME` - this field is output only and will
# default to 1
# * `TIME_UNIT_MONTHS` - must be between 1 and 2
# * `TIME_UNIT_WEEKS` - must be between 1 and 4
# * `TIME_UNIT_DAYS` - must be between 1 and 6
# * `TIME_UNIT_HOURS` - must be between 1 and 23
# * `TIME_UNIT_MINUTES` - must be between 1 and 59
},
&quot;displayName&quot;: &quot;A String&quot;, # Required. The display name of the insertion order.
#
# Must be UTF-8 encoded with a maximum size of 240 bytes.
&quot;partnerCosts&quot;: [ # The partner costs associated with the insertion order.
#
# If absent or empty in
# CreateInsertionOrder
# method, the newly created insertion order will inherit partner costs from
# the partner settings.
{ # Settings that control a partner cost.
#
# A partner cost is any type of expense involved in running a campaign, other
# than the costs of purchasing impressions (which is called the media cost)
# and using third-party audience segment data (data fee). Some examples of
# partner costs include the fees for using DV360, a third-party ad server,
# or a third-party ad serving verification service.
&quot;feeAmount&quot;: &quot;A String&quot;, # The CPM fee amount in micros of advertiser&#x27;s currency.
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_CPM_FEE`. Must be greater than or equal to 0.
#
# For example, for 1.5 standard unit of the advertiser&#x27;s currency, set
# this field to 1500000.
&quot;costType&quot;: &quot;A String&quot;, # Required. The type of the partner cost.
&quot;feeType&quot;: &quot;A String&quot;, # Required. The fee type for this partner cost.
&quot;feePercentageMillis&quot;: &quot;A String&quot;, # The media fee percentage in millis (1/1000 of a percent).
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_MEDIA_FEE`. Must be greater than or equal to 0.
#
# For example: 100 represents 0.1%.
&quot;invoiceType&quot;: &quot;A String&quot;, # The invoice type for this partner cost.
#
# * Required when cost_type is one of:
# - `PARTNER_COST_TYPE_ADLOOX`
# - `PARTNER_COST_TYPE_DOUBLE_VERIFY`
# - `PARTNER_COST_TYPE_INTEGRAL_AD_SCIENCE`.
# * Output only for other types.
},
],
&quot;updateTime&quot;: &quot;A String&quot;, # Output only. The timestamp when the insertion order was last updated.
# Assigned by the system.
&quot;advertiserId&quot;: &quot;A String&quot;, # Output only. The unique ID of the advertiser the insertion order belongs to.
&quot;budget&quot;: { # Settings that control how insertion order budget is allocated. # Required. The budget allocation settings of the insertion order.
&quot;budgetSegments&quot;: [ # Required. The list of budget segments. Use a budget segment to specify
# a specific budget for a given period of time an insertion order is running.
{ # Settings that control the budget of a single budget segment.
&quot;budgetAmountMicros&quot;: &quot;A String&quot;, # Required. The budget amount the insertion order will spend for the given
# date_range.
# The amount is in micros. Must be greater than 0. For example, 500000000
# represents 500 standard units of the currency.
&quot;dateRange&quot;: { # A date range. # Required. The start and end date settings of the budget segment. They are resolved
# relative to the parent advertiser&#x27;s time zone.
#
# * When creating a new budget segment, both `start_date` and `end_date`
# must be in the future.
# * An existing budget segment with a `start_date` in the past has a mutable
# `end_date` but an immutable `start_date`.
# * `end_date` must be the `start_date` or later, both before the year 2037.
&quot;endDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The upper bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
&quot;startDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The lower bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
},
&quot;description&quot;: &quot;A String&quot;, # The budget segment description. It can be used to enter Purchase Order
# information for each budget segment and have that information printed on
# the invoices.
#
# Must be UTF-8 encoded with a length of no more than 80 characters.
&quot;campaignBudgetId&quot;: &quot;A String&quot;, # The ID of the campaign budget linked to this insertion order budget
# segment.
},
],
&quot;automationType&quot;: &quot;A String&quot;, # The type of automation used to manage bid and budget for
# the insertion order.
#
# If this field is unspecified in creation, the value defaults to
# `INSERTION_ORDER_AUTOMATION_TYPE_NONE`.
&quot;budgetUnit&quot;: &quot;A String&quot;, # Required. Immutable. The budget unit specifies whether the budget is currency based or
# impression based.
},
&quot;entityStatus&quot;: &quot;A String&quot;, # Required. Controls whether or not the insertion order can spend its budget
# and bid on inventory.
#
# * For
# CreateInsertionOrder method,
# only `ENTITY_STATUS_DRAFT` is allowed. To activate an insertion order, use
# UpdateInsertionOrder method
# and update the status to `ENTITY_STATUS_ACTIVE` after creation.
# * An insertion order cannot be changed back to `ENTITY_STATUS_DRAFT` status
# from any other status.
# * An insertion order cannot be set to `ENTITY_STATUS_ACTIVE` if its parent
# campaign is not active.
&quot;pacing&quot;: { # Settings that control the rate at which a budget is spent. # Required. The budget spending speed setting of the insertion order.
&quot;pacingPeriod&quot;: &quot;A String&quot;, # Required. The time period in which the pacing budget will be spent.
#
# When automatic budget allocation is enabled at the insertion order via
# auto_budget_allocation, this
# field is output only and defaults to `PACING_PERIOD_FLIGHT`.
&quot;pacingType&quot;: &quot;A String&quot;, # Required. The type of pacing that defines how the budget amount will be
# spent across the pacing_period.
&quot;dailyMaxImpressions&quot;: &quot;A String&quot;, # Maximum number of impressions to serve every day.
#
# Applicable when the budget is impression based. Must be greater than 0.
&quot;dailyMaxMicros&quot;: &quot;A String&quot;, # Maximum currency amount to spend every day in micros of
# advertiser&#x27;s currency.
#
# Applicable when the budget is currency based. Must be greater than 0.
# For example, for 1.5 standard unit of the currency, set this field to
# 1500000.
#
# The value assigned will be rounded to whole billable units for the
# relevant currency by the following rules: any positive value less than a
# single billable unit will be rounded up to one billable unit and any
# value larger than a single billable unit will be rounded down to the
# nearest billable value. For example, if the currency&#x27;s billable unit is
# 0.01, and this field is set to 10257770, it will round down to 10250000,
# a value of 10.25. If set to 505, it will round up to 10000, a value of
# 0.01.
},
&quot;performanceGoal&quot;: { # Settings that control the performance goal of a campaign or insertion order. # Required. Performance goal of the insertion order.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # The goal amount, in micros of the advertiser&#x27;s currency.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CPM`
# * `PERFORMANCE_GOAL_TYPE_CPC`
# * `PERFORMANCE_GOAL_TYPE_CPA`
# * `PERFORMANCE_GOAL_TYPE_CPIAVC`
#
# For example 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalPercentageMicros&quot;: &quot;A String&quot;, # The decimal representation of the goal percentage in micros.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CTR`
# * `PERFORMANCE_GOAL_TYPE_VIEWABILITY`
#
# For example, 70000 represents 7% (decimal 0.07).
&quot;performanceGoalString&quot;: &quot;A String&quot;, # A key performance indicator (KPI) string, which can be empty.
# Must be UTF-8 encoded with a length of no more than 100 characters.
#
# Applicable when
# performance_goal_type is set to
# `PERFORMANCE_GOAL_TYPE_OTHER`.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal.
},
&quot;insertionOrderId&quot;: &quot;A String&quot;, # Output only. The unique ID of the insertion order. Assigned by the system.
&quot;campaignId&quot;: &quot;A String&quot;, # Required. Immutable. The unique ID of the campaign that the insertion order belongs to.
&quot;name&quot;: &quot;A String&quot;, # Output only. The resource name of the insertion order.
&quot;integrationDetails&quot;: { # Integration details of an entry. # Additional integration details of the insertion order.
&quot;details&quot;: &quot;A String&quot;, # Additional details of the entry in string format.
#
# Must be UTF-8 encoded with a length of no more than 1000 characters.
&quot;integrationCode&quot;: &quot;A String&quot;, # An external identifier to be associated with the entry.
# The integration code will show up together with the entry in many
# places in the system, for example, reporting.
#
# Must be UTF-8 encoded with a length of no more than 500 characters.
},
}
updateMask: string, Required. The mask to control which fields to update.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A single insertion order.
&quot;bidStrategy&quot;: { # Settings that control the bid strategy. # Optional. The bidding strategy of the insertion order. By default,
# fixed_bid is set.
# Bid strategy determines the bid price.
&quot;fixedBid&quot;: { # A strategy that uses a fixed bidding price. # A strategy that uses a fixed bid price.
&quot;bidAmountMicros&quot;: &quot;A String&quot;, # The fixed bid amount, in micros of the advertiser&#x27;s currency.
# For insertion order entity,
# bid_amount_micros should be set as 0.
# For line item entity,
# bid_amount_micros must be greater
# than or equal to billable unit of the given currency and smaller than or
# equal to the upper limit 1000000000.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;maximizeSpendAutoBid&quot;: { # A strategy that automatically adjusts the bid to optimize a specified # A strategy that automatically adjusts the bid to optimize to your
# performance goal while spending the full budget.
#
# At insertion order level, the
# markup_type of line items
# cannot be set to `PARTNER_REVENUE_MODEL_MARKUP_TYPE_CPM`. In addition,
# when
# performance_goal_type
# is one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_AV_VIEWED` ,
#
# the line_item_type
# of the insertion order line items must be either:
#
# * `LINE_ITEM_TYPE_DISPLAY_DEFAULT`
# * `LINE_ITEM_TYPE_VIDEO_DEFAULT` ,
#
# and when
# performance_goal_type
# is either:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CIVA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_IVO_TEN`
#
# the line_item_type
# of the insertion order line items must be `LINE_ITEM_TYPE_VIDEO_DEFAULT`.
# performance goal while spending the full budget.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# tries to minimize while spending the full budget.
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM` is not supported for
# this strategy.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency.
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
&quot;performanceGoalAutoBid&quot;: { # A strategy that automatically adjusts the bid to meet or beat a specified # A strategy that automatically adjusts the bid to meet or beat a specified
# performance goal. It is to be used only for a line item entity.
# performance goal.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal that the bidding strategy
# will try to meet or beat.
#
# For line item level usage, the value must be one of:
#
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`
# * `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
&quot;maxAverageCpmBidAmountMicros&quot;: &quot;A String&quot;, # The maximum average CPM that may be bid, in micros of the advertiser&#x27;s
# currency. Must be greater than or equal to a billable unit of the given
# currency. Not applicable when
# performance_goal_type
# is set to `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`.
#
# For example, 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # Required. The performance goal the bidding strategy will attempt to
# meet or beat, in micros of the advertiser&#x27;s currency.
# Must be greater than or equal to a billable unit of the given currency and
# smaller or equal to upper bounds. Each
# performance_goal_type
# has its upper bound:
#
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPA`,
# upper bound is 10000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_CPC`,
# upper bound is 1000.00 USD.
# * when
# performance_goal_type
# is `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, upper bound is
# 1000.00 USD.
#
# Example: If set to
# `BIDDING_STRATEGY_PERFORMANCE_GOAL_TYPE_VIEWABLE_CPM`, the bid price will
# be based on the probability that each available impression will be
# viewable. For example, if viewable CPM target is $2 and an impression is
# 40% likely to be viewable, the bid price will be $0.80 CPM (40% of $2).
#
# For example, 1500000 represents 1.5 standard units of the currency.
},
},
&quot;frequencyCap&quot;: { # Settings that control the number of times a user may be shown with the same # Required. The frequency capping setting of the insertion order.
# ad during a given time period.
&quot;unlimited&quot;: True or False, # Whether unlimited frequency capping is applied. When this field is set to
# `true`, the remaining frequency cap fields are not applicable.
&quot;maxImpressions&quot;: 42, # The maximum number of times a user may be shown with the same ad
# during this period. Must be greater than 0.
#
# Applicable when unlimited is `false`.
&quot;timeUnit&quot;: &quot;A String&quot;, # The time unit in which the frequency cap will be applied.
#
# Applicable when unlimited is `false`.
&quot;timeUnitCount&quot;: 42, # The number of time_unit the frequency cap will
# last.
#
# Applicable when unlimited is `false`.
# The following restrictions apply based on the value of
# time_unit:
#
# * `TIME_UNIT_LIFETIME` - this field is output only and will
# default to 1
# * `TIME_UNIT_MONTHS` - must be between 1 and 2
# * `TIME_UNIT_WEEKS` - must be between 1 and 4
# * `TIME_UNIT_DAYS` - must be between 1 and 6
# * `TIME_UNIT_HOURS` - must be between 1 and 23
# * `TIME_UNIT_MINUTES` - must be between 1 and 59
},
&quot;displayName&quot;: &quot;A String&quot;, # Required. The display name of the insertion order.
#
# Must be UTF-8 encoded with a maximum size of 240 bytes.
&quot;partnerCosts&quot;: [ # The partner costs associated with the insertion order.
#
# If absent or empty in
# CreateInsertionOrder
# method, the newly created insertion order will inherit partner costs from
# the partner settings.
{ # Settings that control a partner cost.
#
# A partner cost is any type of expense involved in running a campaign, other
# than the costs of purchasing impressions (which is called the media cost)
# and using third-party audience segment data (data fee). Some examples of
# partner costs include the fees for using DV360, a third-party ad server,
# or a third-party ad serving verification service.
&quot;feeAmount&quot;: &quot;A String&quot;, # The CPM fee amount in micros of advertiser&#x27;s currency.
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_CPM_FEE`. Must be greater than or equal to 0.
#
# For example, for 1.5 standard unit of the advertiser&#x27;s currency, set
# this field to 1500000.
&quot;costType&quot;: &quot;A String&quot;, # Required. The type of the partner cost.
&quot;feeType&quot;: &quot;A String&quot;, # Required. The fee type for this partner cost.
&quot;feePercentageMillis&quot;: &quot;A String&quot;, # The media fee percentage in millis (1/1000 of a percent).
#
# Applicable when the fee_type is
# `PARTNER_FEE_TYPE_MEDIA_FEE`. Must be greater than or equal to 0.
#
# For example: 100 represents 0.1%.
&quot;invoiceType&quot;: &quot;A String&quot;, # The invoice type for this partner cost.
#
# * Required when cost_type is one of:
# - `PARTNER_COST_TYPE_ADLOOX`
# - `PARTNER_COST_TYPE_DOUBLE_VERIFY`
# - `PARTNER_COST_TYPE_INTEGRAL_AD_SCIENCE`.
# * Output only for other types.
},
],
&quot;updateTime&quot;: &quot;A String&quot;, # Output only. The timestamp when the insertion order was last updated.
# Assigned by the system.
&quot;advertiserId&quot;: &quot;A String&quot;, # Output only. The unique ID of the advertiser the insertion order belongs to.
&quot;budget&quot;: { # Settings that control how insertion order budget is allocated. # Required. The budget allocation settings of the insertion order.
&quot;budgetSegments&quot;: [ # Required. The list of budget segments. Use a budget segment to specify
# a specific budget for a given period of time an insertion order is running.
{ # Settings that control the budget of a single budget segment.
&quot;budgetAmountMicros&quot;: &quot;A String&quot;, # Required. The budget amount the insertion order will spend for the given
# date_range.
# The amount is in micros. Must be greater than 0. For example, 500000000
# represents 500 standard units of the currency.
&quot;dateRange&quot;: { # A date range. # Required. The start and end date settings of the budget segment. They are resolved
# relative to the parent advertiser&#x27;s time zone.
#
# * When creating a new budget segment, both `start_date` and `end_date`
# must be in the future.
# * An existing budget segment with a `start_date` in the past has a mutable
# `end_date` but an immutable `start_date`.
# * `end_date` must be the `start_date` or later, both before the year 2037.
&quot;endDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The upper bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
&quot;startDate&quot;: { # Represents a whole or partial calendar date, e.g. a birthday. The time of day # The lower bound of the date range, inclusive. Must specify a positive value
# for `year`, `month`, and `day`.
# and time zone are either specified elsewhere or are not significant. The date
# is relative to the Proleptic Gregorian Calendar. This can represent:
#
# * A full date, with non-zero year, month and day values
# * A month and day value, with a zero year, e.g. an anniversary
# * A year on its own, with zero month and day values
# * A year and month value, with a zero day, e.g. a credit card expiration date
#
# Related types are google.type.TimeOfDay and `google.protobuf.Timestamp`.
&quot;year&quot;: 42, # Year of date. Must be from 1 to 9999, or 0 if specifying a date without
# a year.
&quot;day&quot;: 42, # Day of month. Must be from 1 to 31 and valid for the year and month, or 0
# if specifying a year by itself or a year and month where the day is not
# significant.
&quot;month&quot;: 42, # Month of year. Must be from 1 to 12, or 0 if specifying a year without a
# month and day.
},
},
&quot;description&quot;: &quot;A String&quot;, # The budget segment description. It can be used to enter Purchase Order
# information for each budget segment and have that information printed on
# the invoices.
#
# Must be UTF-8 encoded with a length of no more than 80 characters.
&quot;campaignBudgetId&quot;: &quot;A String&quot;, # The ID of the campaign budget linked to this insertion order budget
# segment.
},
],
&quot;automationType&quot;: &quot;A String&quot;, # The type of automation used to manage bid and budget for
# the insertion order.
#
# If this field is unspecified in creation, the value defaults to
# `INSERTION_ORDER_AUTOMATION_TYPE_NONE`.
&quot;budgetUnit&quot;: &quot;A String&quot;, # Required. Immutable. The budget unit specifies whether the budget is currency based or
# impression based.
},
&quot;entityStatus&quot;: &quot;A String&quot;, # Required. Controls whether or not the insertion order can spend its budget
# and bid on inventory.
#
# * For
# CreateInsertionOrder method,
# only `ENTITY_STATUS_DRAFT` is allowed. To activate an insertion order, use
# UpdateInsertionOrder method
# and update the status to `ENTITY_STATUS_ACTIVE` after creation.
# * An insertion order cannot be changed back to `ENTITY_STATUS_DRAFT` status
# from any other status.
# * An insertion order cannot be set to `ENTITY_STATUS_ACTIVE` if its parent
# campaign is not active.
&quot;pacing&quot;: { # Settings that control the rate at which a budget is spent. # Required. The budget spending speed setting of the insertion order.
&quot;pacingPeriod&quot;: &quot;A String&quot;, # Required. The time period in which the pacing budget will be spent.
#
# When automatic budget allocation is enabled at the insertion order via
# auto_budget_allocation, this
# field is output only and defaults to `PACING_PERIOD_FLIGHT`.
&quot;pacingType&quot;: &quot;A String&quot;, # Required. The type of pacing that defines how the budget amount will be
# spent across the pacing_period.
&quot;dailyMaxImpressions&quot;: &quot;A String&quot;, # Maximum number of impressions to serve every day.
#
# Applicable when the budget is impression based. Must be greater than 0.
&quot;dailyMaxMicros&quot;: &quot;A String&quot;, # Maximum currency amount to spend every day in micros of
# advertiser&#x27;s currency.
#
# Applicable when the budget is currency based. Must be greater than 0.
# For example, for 1.5 standard unit of the currency, set this field to
# 1500000.
#
# The value assigned will be rounded to whole billable units for the
# relevant currency by the following rules: any positive value less than a
# single billable unit will be rounded up to one billable unit and any
# value larger than a single billable unit will be rounded down to the
# nearest billable value. For example, if the currency&#x27;s billable unit is
# 0.01, and this field is set to 10257770, it will round down to 10250000,
# a value of 10.25. If set to 505, it will round up to 10000, a value of
# 0.01.
},
&quot;performanceGoal&quot;: { # Settings that control the performance goal of a campaign or insertion order. # Required. Performance goal of the insertion order.
&quot;performanceGoalAmountMicros&quot;: &quot;A String&quot;, # The goal amount, in micros of the advertiser&#x27;s currency.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CPM`
# * `PERFORMANCE_GOAL_TYPE_CPC`
# * `PERFORMANCE_GOAL_TYPE_CPA`
# * `PERFORMANCE_GOAL_TYPE_CPIAVC`
#
# For example 1500000 represents 1.5 standard units of the currency.
&quot;performanceGoalPercentageMicros&quot;: &quot;A String&quot;, # The decimal representation of the goal percentage in micros.
#
# Applicable when
# performance_goal_type is one of:
#
# * `PERFORMANCE_GOAL_TYPE_CTR`
# * `PERFORMANCE_GOAL_TYPE_VIEWABILITY`
#
# For example, 70000 represents 7% (decimal 0.07).
&quot;performanceGoalString&quot;: &quot;A String&quot;, # A key performance indicator (KPI) string, which can be empty.
# Must be UTF-8 encoded with a length of no more than 100 characters.
#
# Applicable when
# performance_goal_type is set to
# `PERFORMANCE_GOAL_TYPE_OTHER`.
&quot;performanceGoalType&quot;: &quot;A String&quot;, # Required. The type of the performance goal.
},
&quot;insertionOrderId&quot;: &quot;A String&quot;, # Output only. The unique ID of the insertion order. Assigned by the system.
&quot;campaignId&quot;: &quot;A String&quot;, # Required. Immutable. The unique ID of the campaign that the insertion order belongs to.
&quot;name&quot;: &quot;A String&quot;, # Output only. The resource name of the insertion order.
&quot;integrationDetails&quot;: { # Integration details of an entry. # Additional integration details of the insertion order.
&quot;details&quot;: &quot;A String&quot;, # Additional details of the entry in string format.
#
# Must be UTF-8 encoded with a length of no more than 1000 characters.
&quot;integrationCode&quot;: &quot;A String&quot;, # An external identifier to be associated with the entry.
# The integration code will show up together with the entry in many
# places in the system, for example, reporting.
#
# Must be UTF-8 encoded with a length of no more than 500 characters.
},
}</pre>
</div>
</body></html>