# REST Resource: sellers.orders

- [Resource: Order](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders#Order)
  - [JSON representation](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders#Order.SCHEMA_REPRESENTATION)
- [State](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders#State)
- [CancellationReason](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders#CancellationReason)
- [Methods](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders#METHODS_SUMMARY)

## Resource: Order

An order is a collection of `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders.lines#Line` which specify when and where to display ads.

| JSON representation |
|---|
| ``` { "name": string, "externalId": string, "displayName": string, "description": string, "state": enum (`https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders#State`), "createTime": string, "updateTime": string, "advertiserInfo": { object (`https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/AdvertiserInfo`) }, "cancellationReason": enum (`https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders#CancellationReason`) } ``` |

| Fields ||
|---|---|
| `name` | `string` The resource name of the order. Format: sellers/{seller}/orders/{order} |
| `externalId` | `string` An id used to map this entity to external sources. |
| `displayName` | `string` The display name of the order. Must be UTF-8 encoded with a maximum size of 240 bytes. |
| `description` | `string` Additional freeform field to describe the order. |
| `state` | ``enum (`https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders#State`)`` Output only. The state of the order. Seller can use the following custom methods: `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders/completeOrderReservation#google.ads.xbid.outofhome.v1.OrderManagementService.CompleteOrderReservation`, `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders/completeOrderBooking#google.ads.xbid.outofhome.v1.OrderManagementService.CompleteOrderBooking` to set to one of the following: - `STATE_RESERVATION_COMPLETE` - `STATE_BOOKING_COMPLETE`. All other order states are set by the buyer. |
| `createTime` | ``string (`https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` format)`` Output only. Creation timestamp for the order. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: `"2014-10-02T15:01:23Z"` and `"2014-10-02T15:01:23.045123456Z"`. |
| `updateTime` | ``string (`https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` format)`` Output only. Last updated timestamp for the order. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: `"2014-10-02T15:01:23Z"` and `"2014-10-02T15:01:23.045123456Z"`. |
| `advertiserInfo` | ``object (`https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/AdvertiserInfo`)`` Advertiser info. |
| `cancellationReason` | ``enum (`https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders#CancellationReason`)`` Output only. Cancellation reason. |

## State

The state of the order.

| Enums ||
|---|---|
| `STATE_UNSPECIFIED` | The default value when the order state has not been specified or is unknown in this version. |
| `STATE_PENDING_RESERVATION` | The order contains: - one or more lines in pending reservation state. - zero or more lines in reserved state. - zero lines in all other states. |
| `STATE_RESERVATION_COMPLETE` | The order contains: - one or more lines in either reserved or rejected by seller states. - zero lines in all other states. |
| `STATE_PENDING_BOOKING` | The order contains: - one or more lines in either pending booking or rejected by seller states. - zero lines in all other states. |
| `STATE_BOOKING_COMPLETE` | The order contains: - one or more lines in either booked or rejected by seller states. - zero lines in all other states. |
| `STATE_CANCELLED_BY_BUYER` | The order contains: - one or more lines in either cancelled by buyer or rejected by seller states. - zero lines in all other states. |
| `STATE_PENDING_RESERVATION_EXPIRED` | The order contains: - one or more lines in pending reservation expired. - zero lines in all other states. |
| `STATE_RESERVED_EXPIRED` | The order contains: - one or more lines in reserved expired. - zero lines in all other states. |

## CancellationReason

The reason for cancellation, if the order has been canceled.

| Enums ||
|---|---|
| `CANCELLATION_REASON_UNSPECIFIED` | The default value when the cancellation reason has not been specified or is unknown in this version. |
| `CANCELLATION_REASON_BUYER_REQUESTED` | The buyer requested cancellation of the order. |
| `CANCELLATION_REASON_INVALID_ADVERTISER_INFO` | The provided advertiser info was invalid. |

| ## Methods ||
|---|---|
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders/completeOrderBooking` | Completes the order booking. |
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders/completeOrderReservation` | Completes the order reservation. |
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders/create` | Creates a new order. |
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders/get` | Retrieves an individual order. |
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders/list` | Lists orders. |
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1/sellers.orders/patch` | Updates an existing order. |