# REST Resource: orders.lines.assignments

- [Resource: Assignment](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments#Assignment)
  - [JSON representation](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments#Assignment.SCHEMA_REPRESENTATION)
- [State](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments#State)
- [AdUnitCreativeDisapprovals](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments#AdUnitCreativeDisapprovals)
  - [JSON representation](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments#AdUnitCreativeDisapprovals.SCHEMA_REPRESENTATION)
- [Methods](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments#METHODS_SUMMARY)

## Resource: Assignment

An assignment binding creatives to lines.

| JSON representation |
|---|
| ``` { "name": string, "externalId": string, "creativeAsset": string, "state": enum (`https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments#State`), // Union field `disapproval_type` can be only one of the following: "disapproval": { object (`Disapproval`) }, "adUnitDisapprovals": { object (`https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments#AdUnitCreativeDisapprovals`) } // End of list of possible types for union field `disapproval_type`. } ``` |

| Fields ||
|---|---|
| `name` | `string` Output only. The resource name of the creative assignment in the format: `orders/{order_id}/lines/{line_id}/assignments/{id}`. |
| `externalId` | `string` Optional. Seller managed ID presumably in their own system. Once set unlikely to change. It should not be used internally and constraints are not enforced. |
| `creativeAsset` | `string` Output only. The creative asset that will be served for the line. Format = creativeAssets/123 |
| `state` | ``enum (`https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments#State`)`` Output only. If STATE_DISAPPROVED then disapproval details must be provided. |
| Union field `disapproval_type`. Output only. The assignment's disapproval details. Can be either line level or ad unit level. The assignment's disapproval details specified at either the assignment or ad unit level. This allows providing disapproval details that only apply to a subset of the ad units targeted by this line. `disapproval_type` can be only one of the following: ||
| `disapproval` | ``object (`Disapproval`)`` Disapproval details for the assignment that apply to all ad units. |
| `adUnitDisapprovals` | ``object (`https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments#AdUnitCreativeDisapprovals`)`` Disapproval info on a per ad unit granularity. |

## State

Possible values for assignment state.

| Enums ||
|---|---|
| `STATE_UNSPECIFIED` | The default value when the assignment state is not specified or is unknown in this version. |
| `STATE_PENDING_REVIEW` | When the creative details are provided by the buyer and the seller review is pending. |
| `STATE_APPROVED` | When the creative has been approved by the seller. |
| `STATE_DISAPPROVED` | When the creative has been disapproved by the seller. Disapproval details must be provided. |
| `STATE_REVOKED` | When the creative has been revoked by the buyer or by the system. |

## AdUnitCreativeDisapprovals

Ad unit specific disapproval reasons.

| JSON representation |
|---|
| ``` { "disapprovals": { string: { object (`Disapproval`) }, ... } } ``` |

| Fields ||
|---|---|
| `disapprovals` | ``map (key: string, value: object (`Disapproval`))`` Key is the ad unit name (e.g. adUnits/123) and the value is the disapproval info. An object containing a list of `"key": value` pairs. Example: `{ "name": "wrench", "mass": "1.3kg", "count": "3" }`. |

| ## Methods ||
|---|---|
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments/approve` | Approves an existing assignment. |
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments/disapprove` | Disapproves an existing assignment. |
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments/get` | Retrieves an individual assignment for a line. |
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments/list` | Lists assignments for a line. |
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/orders.lines.assignments/patch` | Updates an existing assignment. |