0.17.0 (latest) 0.16.0 0.15.1 0.14.1 0.8.0 0.7.0 0.6.2 0.5.0 0.4.1 0.3.1 0.2.0 0.1.3 Reference documentation and code samples for the Google Ads Ad Manager V1 Client class Order.

The `Order` resource.

Generated from protobuf message `google.ads.admanager.v1.Order`

## Namespace

Google \\ Ads \\ AdManager \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` Identifier. The resource name of the `Order`. Format: `networks/{network_code}/orders/{order_id}` |
| `↳ order_id` | `int|string` Output only. Deprecated: Order ID. |
| `↳ display_name` | `string` Required. The display name of the Order. This value has a maximum length of 255 characters. |
| `↳ programmatic` | `bool` Optional. Specifies whether or not the Order is a programmatic order. |
| `↳ trafficker` | `string` Required. The resource name of the User responsible for trafficking the Order. Format: "networks/{network_code}/users/{user_id}" |
| `↳ advertiser_contacts` | `string[]` Optional. Unordered list. The resource names of Contacts from the advertiser of this Order. Format: "networks/{network_code}/contacts/{contact_id}" |
| `↳ advertiser` | `string` Required. The resource name of the Company, which is of type Company.Type.ADVERTISER, to which this order belongs. Format: "networks/{network_code}/companies/{company_id}" |
| `↳ agency_contacts` | `string[]` Optional. The resource names of Contacts from the advertising Agency of this Order. Format: "networks/{network_code}/contacts/{contact_id}" |
| `↳ agency` | `string` Optional. The resource name of the Company, which is of type Company.Type.AGENCY, with which this order is associated. Format: "networks/{network_code}/companies/{company_id}" |
| `↳ applied_teams` | `string[]` Optional. The resource names of Teams directly applied to this Order. Format: "networks/{network_code}/teams/{team_id}" |
| `↳ effective_teams` | `string[]` Output only. The resource names of Teams applied to this Order including inherited values. Format: "networks/{network_code}/teams/{team_id}" |
| `↳ creator` | `string` Output only. The resource name of the User who created the Order on behalf of the advertiser. Format: "networks/{network_code}/users/{user_id}" |
| `↳ currency_code` | `string` Output only. The ISO 4217 3-letter currency code for the currency used by the Order. This value is the network's currency code. |
| `↳ start_time` | `Google\Protobuf\Timestamp` Output only. The instant at which the Order and its associated Line items are eligible to begin serving. This attribute is derived from the Line item of the order that has the earliest `LineItem.start_time`. |
| `↳ end_time` | `Google\Protobuf\Timestamp` Output only. The instant at which the Order and its associated Line items stop being served. This attribute is derived from the Line item of the order that has the latest `LineItem.end_time`. |
| `↳ unlimited_end_time` | `bool` Output only. Deprecated: Indicates whether or not this Order has an end time. |
| `↳ end_time_unlimited` | `bool` Output only. Indicates whether or not this Order has an end time. |
| `↳ external_order_id` | `int` Optional. An arbitrary ID to associate to the Order, which can be used as a key to an external system. |
| `↳ archived` | `bool` Output only. The archival status of the Order. |
| `↳ last_modified_by_app` | `string` Output only. The application which modified this order. |
| `↳ update_time` | `Google\Protobuf\Timestamp` Output only. The instant this Order was last modified. |
| `↳ notes` | `string` Optional. Provides any additional notes that may annotate the Order. This attribute has a maximum length of 65,535 characters. |
| `↳ po_number` | `string` Optional. The purchase order number for the Order. This value has a maximum length of 63 characters. |
| `↳ status` | `int` Output only. The status of the Order. |
| `↳ salesperson` | `string` Optional. The resource name of the User responsible for the sales of the Order. Format: "networks/{network_code}/users/{user_id}" |
| `↳ secondary_salespeople` | `string[]` Optional. Unordered list. The resource names of the secondary salespeople associated with the order. Format: "networks/{network_code}/users/{user_id}" |
| `↳ secondary_traffickers` | `string[]` Optional. Unordered list. The resource names of the secondary traffickers associated with the order. Format: "networks/{network_code}/users/{user_id}" |
| `↳ applied_labels` | `array<AppliedLabel>` Optional. The set of labels applied directly to this order. |
| `↳ effective_applied_labels` | `array<AppliedLabel>` Output only. Contains the set of labels applied directly to the order as well as those inherited from the company that owns the order. If a label has been negated, only the negated label is returned. This field is assigned by Google. |
| `↳ custom_field_values` | `array<CustomFieldValue>` Optional. The set of custom field values to this order. |
| `↳ impressions_delivered` | `int|string` Output only. The total number of impressions delivered for Line items in this order. |
| `↳ total_clicks_delivered` | `int|string` Output only. Total clicks delivered for all Line items of this `Order`. This value is calculated from the associated `LineItem` values. |
| `↳ total_viewable_impressions_delivered` | `int|string` Output only. Total viewable impressions delivered for all Line items of this `Order`. This value is calculated from the associated `LineItem` values. |

### getName

Identifier. The resource name of the `Order`.

Format: `networks/{network_code}/orders/{order_id}`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setName

Identifier. The resource name of the `Order`.

Format: `networks/{network_code}/orders/{order_id}`

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getOrderId

Output only. Deprecated: Order ID.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int|string` |   |

### hasOrderId

### clearOrderId

### setOrderId

Output only. Deprecated: Order ID.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int|string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getDisplayName

Required. The display name of the Order. This value has a maximum length
of 255 characters.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasDisplayName

### clearDisplayName

### setDisplayName

Required. The display name of the Order. This value has a maximum length
of 255 characters.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getProgrammatic

Optional. Specifies whether or not the Order is a programmatic order.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### hasProgrammatic

### clearProgrammatic

### setProgrammatic

Optional. Specifies whether or not the Order is a programmatic order.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getTrafficker

Required. The resource name of the User responsible for trafficking the
Order. Format: "networks/{network_code}/users/{user_id}"

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasTrafficker

### clearTrafficker

### setTrafficker

Required. The resource name of the User responsible for trafficking the
Order. Format: "networks/{network_code}/users/{user_id}"

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAdvertiserContacts

Optional. Unordered list. The resource names of Contacts from the
advertiser of this Order. Format:
"networks/{network_code}/contacts/{contact_id}"

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\RepeatedField<string>` |   |

### setAdvertiserContacts

Optional. Unordered list. The resource names of Contacts from the
advertiser of this Order. Format:
"networks/{network_code}/contacts/{contact_id}"

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string[]` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAdvertiser

Required. The resource name of the Company, which is of type
Company.Type.ADVERTISER, to which this order belongs. Format:
"networks/{network_code}/companies/{company_id}"

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasAdvertiser

### clearAdvertiser

### setAdvertiser

Required. The resource name of the Company, which is of type
Company.Type.ADVERTISER, to which this order belongs. Format:
"networks/{network_code}/companies/{company_id}"

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAgencyContacts

Optional. The resource names of Contacts from the advertising Agency of
this Order. Format: "networks/{network_code}/contacts/{contact_id}"

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\RepeatedField<string>` |   |

### setAgencyContacts

Optional. The resource names of Contacts from the advertising Agency of
this Order. Format: "networks/{network_code}/contacts/{contact_id}"

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string[]` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAgency

Optional. The resource name of the Company, which is of type
Company.Type.AGENCY, with which this order is associated. Format:
"networks/{network_code}/companies/{company_id}"

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasAgency

### clearAgency

### setAgency

Optional. The resource name of the Company, which is of type
Company.Type.AGENCY, with which this order is associated. Format:
"networks/{network_code}/companies/{company_id}"

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAppliedTeams

Optional. The resource names of Teams directly applied to this Order.

Format: "networks/{network_code}/teams/{team_id}"

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\RepeatedField<string>` |   |

### setAppliedTeams

Optional. The resource names of Teams directly applied to this Order.

Format: "networks/{network_code}/teams/{team_id}"

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string[]` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getEffectiveTeams

Output only. The resource names of Teams applied to this Order including
inherited values. Format: "networks/{network_code}/teams/{team_id}"

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\RepeatedField<string>` |   |

### setEffectiveTeams

Output only. The resource names of Teams applied to this Order including
inherited values. Format: "networks/{network_code}/teams/{team_id}"

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string[]` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCreator

Output only. The resource name of the User who created the Order on behalf
of the advertiser. Format: "networks/{network_code}/users/{user_id}"

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasCreator

### clearCreator

### setCreator

Output only. The resource name of the User who created the Order on behalf
of the advertiser. Format: "networks/{network_code}/users/{user_id}"

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCurrencyCode

Output only. The ISO 4217 3-letter currency code for the currency used by
the Order. This value is the network's currency code.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasCurrencyCode

### clearCurrencyCode

### setCurrencyCode

Output only. The ISO 4217 3-letter currency code for the currency used by
the Order. This value is the network's currency code.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getStartTime

Output only. The instant at which the Order and its associated Line items
are eligible to begin serving. This attribute is derived from the Line item
of the order that has the earliest `LineItem.start_time`.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\Timestamp|null` |   |

### hasStartTime

### clearStartTime

### setStartTime

Output only. The instant at which the Order and its associated Line items
are eligible to begin serving. This attribute is derived from the Line item
of the order that has the earliest `LineItem.start_time`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `Google\Protobuf\Timestamp` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getEndTime

Output only. The instant at which the Order and its associated Line items
stop being served. This attribute is derived from the Line item of the
order that has the latest `LineItem.end_time`.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\Timestamp|null` |   |

### hasEndTime

### clearEndTime

### setEndTime

Output only. The instant at which the Order and its associated Line items
stop being served. This attribute is derived from the Line item of the
order that has the latest `LineItem.end_time`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `Google\Protobuf\Timestamp` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getUnlimitedEndTime

Output only. Deprecated: Indicates whether or not this Order has an end
time.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### hasUnlimitedEndTime

### clearUnlimitedEndTime

### setUnlimitedEndTime

Output only. Deprecated: Indicates whether or not this Order has an end
time.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getEndTimeUnlimited

Output only. Indicates whether or not this Order has an end time.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### hasEndTimeUnlimited

### clearEndTimeUnlimited

### setEndTimeUnlimited

Output only. Indicates whether or not this Order has an end time.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getExternalOrderId

Optional. An arbitrary ID to associate to the Order, which can be used as a
key to an external system.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` |   |

### hasExternalOrderId

### clearExternalOrderId

### setExternalOrderId

Optional. An arbitrary ID to associate to the Order, which can be used as a
key to an external system.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getArchived

Output only. The archival status of the Order.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### hasArchived

### clearArchived

### setArchived

Output only. The archival status of the Order.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getLastModifiedByApp

Output only. The application which modified this order.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasLastModifiedByApp

### clearLastModifiedByApp

### setLastModifiedByApp

Output only. The application which modified this order.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getUpdateTime

Output only. The instant this Order was last modified.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\Timestamp|null` |   |

### hasUpdateTime

### clearUpdateTime

### setUpdateTime

Output only. The instant this Order was last modified.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `Google\Protobuf\Timestamp` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getNotes

Optional. Provides any additional notes that may annotate the Order. This
attribute has a maximum length of 65,535 characters.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasNotes

### clearNotes

### setNotes

Optional. Provides any additional notes that may annotate the Order. This
attribute has a maximum length of 65,535 characters.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getPoNumber

Optional. The purchase order number for the Order. This value has a maximum
length of 63 characters.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasPoNumber

### clearPoNumber

### setPoNumber

Optional. The purchase order number for the Order. This value has a maximum
length of 63 characters.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getStatus

Output only. The status of the Order.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` |   |

### hasStatus

### clearStatus

### setStatus

Output only. The status of the Order.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getSalesperson

Optional. The resource name of the User responsible for the sales of the
Order. Format: "networks/{network_code}/users/{user_id}"

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasSalesperson

### clearSalesperson

### setSalesperson

Optional. The resource name of the User responsible for the sales of the
Order. Format: "networks/{network_code}/users/{user_id}"

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getSecondarySalespeople

Optional. Unordered list. The resource names of the secondary salespeople
associated with the order. Format:
"networks/{network_code}/users/{user_id}"

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\RepeatedField<string>` |   |

### setSecondarySalespeople

Optional. Unordered list. The resource names of the secondary salespeople
associated with the order. Format:
"networks/{network_code}/users/{user_id}"

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string[]` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getSecondaryTraffickers

Optional. Unordered list. The resource names of the secondary traffickers
associated with the order. Format:
"networks/{network_code}/users/{user_id}"

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\RepeatedField<string>` |   |

### setSecondaryTraffickers

Optional. Unordered list. The resource names of the secondary traffickers
associated with the order. Format:
"networks/{network_code}/users/{user_id}"

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string[]` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAppliedLabels

Optional. The set of labels applied directly to this order.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\RepeatedField<AppliedLabel>` |   |

### setAppliedLabels

Optional. The set of labels applied directly to this order.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<AppliedLabel>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getEffectiveAppliedLabels

Output only. Contains the set of labels applied directly to the order as
well as those inherited from the company that owns the order. If a label
has been negated, only the negated label is returned. This field is
assigned by Google.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\RepeatedField<AppliedLabel>` |   |

### setEffectiveAppliedLabels

Output only. Contains the set of labels applied directly to the order as
well as those inherited from the company that owns the order. If a label
has been negated, only the negated label is returned. This field is
assigned by Google.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<AppliedLabel>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCustomFieldValues

Optional. The set of custom field values to this order.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\RepeatedField<CustomFieldValue>` |   |

### setCustomFieldValues

Optional. The set of custom field values to this order.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<CustomFieldValue>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getImpressionsDelivered

Output only. The total number of impressions delivered for Line items in
this order.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int|string` |   |

### hasImpressionsDelivered

### clearImpressionsDelivered

### setImpressionsDelivered

Output only. The total number of impressions delivered for Line items in
this order.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int|string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getTotalClicksDelivered

Output only. Total clicks delivered for all Line items of this `Order`.

This value is calculated from the associated `LineItem` values.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int|string` |   |

### hasTotalClicksDelivered

### clearTotalClicksDelivered

### setTotalClicksDelivered

Output only. Total clicks delivered for all Line items of this `Order`.

This value is calculated from the associated `LineItem` values.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int|string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getTotalViewableImpressionsDelivered

Output only. Total viewable impressions delivered for all Line items of
this `Order`. This value is calculated from the associated `LineItem`
values.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int|string` |   |

### hasTotalViewableImpressionsDelivered

### clearTotalViewableImpressionsDelivered

### setTotalViewableImpressionsDelivered

Output only. Total viewable impressions delivered for all Line items of
this `Order`. This value is calculated from the associated `LineItem`
values.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int|string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |