REST Resource: networks.customFields
Stay organized with collections
Save and categorize content based on your preferences.
Resource: CustomField
An additional, user-created field on an entity.
Fields |
name |
string
Identifier. The resource name of the CustomField . Format: networks/{networkCode}/customFields/{customField}
|
options[] |
object (CustomFieldOption )
Optional. The drop-down options for the CustomField . Only applicable for CustomField with the drop-down data type.
|
customFieldId |
string (int64 format)
Output only. Unique ID of the CustomField. This attribute is assigned by Google.
|
displayName |
string
Required. Name of the CustomField. The max length is 127 characters.
|
description |
string
Optional. A description of the custom field. The maximum length is 511 characters.
|
status |
enum (CustomFieldStatus )
Output only. The status of the CustomField .
|
entityType |
enum (CustomFieldEntityType )
Required. The type of entity the CustomField can be applied to.
|
dataType |
enum (CustomFieldDataType )
Required. The data type of the CustomField .
|
visibility |
enum (CustomFieldVisibility )
Required. The visibility of the CustomField .
|
CustomFieldStatus
The status of the CustomField.
Enums |
CUSTOM_FIELD_STATUS_UNSPECIFIED |
No value specified |
ACTIVE |
The CustomField is active. |
INACTIVE |
The CustomField is inactive. |
CustomFieldEntityType
The types of entities that a CustomField can be applied to.
Enums |
CUSTOM_FIELD_ENTITY_TYPE_UNSPECIFIED |
No value specified |
LINE_ITEM |
The CustomField is applied to LineItems. |
ORDER |
The CustomField is applied to Orders. |
CREATIVE |
The CustomField is applied to Creatives. |
PROPOSAL |
The CustomField is applied to Proposals. |
PROPOSAL_LINE_ITEM |
The CustomField is applied to ProposalLineItems. |
CustomFieldDataType
The data type for a CustomField.
Enums |
CUSTOM_FIELD_DATA_TYPE_UNSPECIFIED |
No value specified |
STRING |
A string field The max length is 255 characters. |
NUMBER |
A number field. |
TOGGLE |
A "Yes" or "No" toggle field. |
DROP_DOWN |
A drop-down field. |
CustomFieldVisibility
The visibility level of a CustomField.
Enums |
CUSTOM_FIELD_VISIBILITY_UNSPECIFIED |
No value specified |
HIDDEN |
The CustomField is not visible in the UI and only visible through the API. |
READ_ONLY |
The CustomField is visible in the UI and only editable through the API. |
EDITABLE |
The CustomField is visible and editable in both the API and UI. |
CustomFieldOption
An option for a drop-down CustomField
.
JSON representation |
{
"customFieldOptionId": string,
"displayName": string
} |
Fields |
customFieldOptionId |
string (int64 format)
Output only. CustomFieldOption ID.
|
displayName |
string
Required. The display name of the CustomFieldOption . This value has a maximum length of 127 characters.
|
Methods |
|
API to retrieve a CustomField object. |
|
API to retrieve a list of CustomField objects. |
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-20 UTC.
[null,null,["Last updated 2025-08-20 UTC."],[[["\u003cp\u003eCustomFields are user-created fields that can be applied to entities like Line Items, Orders, Creatives, and Proposals to add additional information.\u003c/p\u003e\n"],["\u003cp\u003eThey offer various data types such as string, number, toggle, and drop-down, each with specific properties and constraints.\u003c/p\u003e\n"],["\u003cp\u003eCustomFields can have different visibility levels, controlling whether they are visible and editable in the UI and through the API.\u003c/p\u003e\n"],["\u003cp\u003eYou can manage CustomFields through the API, including retrieving individual fields or a list of fields.\u003c/p\u003e\n"],["\u003cp\u003eCustomFields with drop-down data types require predefined options that are represented by \u003ccode\u003eCustomFieldOption\u003c/code\u003e objects, each with a display name.\u003c/p\u003e\n"]]],["CustomFields are user-defined fields on entities, identified by a unique ID and name. They have properties like `displayName`, `description`, `status`, `entityType`, `dataType`, and `visibility`. `CustomFieldOptions` provide choices for drop-down fields. Supported data types are string, number, toggle, and drop-down. Visibility can be hidden, read-only, or editable. Status can be active or inactive. The API offers `get` and `list` methods to retrieve `CustomField` objects.\n"],null,["# REST Resource: networks.customFields\n\n- [Resource: CustomField](#CustomField)\n - [JSON representation](#CustomField.SCHEMA_REPRESENTATION)\n- [CustomFieldStatus](#CustomFieldStatus)\n- [CustomFieldEntityType](#CustomFieldEntityType)\n- [CustomFieldDataType](#CustomFieldDataType)\n- [CustomFieldVisibility](#CustomFieldVisibility)\n- [CustomFieldOption](#CustomFieldOption)\n - [JSON representation](#CustomFieldOption.SCHEMA_REPRESENTATION)\n- [Methods](#METHODS_SUMMARY)\n\nResource: CustomField\n---------------------\n\nAn additional, user-created field on an entity.\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"name\": string, \"options\": [ { object (/ad-manager/api/beta/reference/rest/v1/networks.customFields#CustomFieldOption) } ], \"customFieldId\": string, \"displayName\": string, \"description\": string, \"status\": enum (/ad-manager/api/beta/reference/rest/v1/networks.customFields#CustomFieldStatus), \"entityType\": enum (/ad-manager/api/beta/reference/rest/v1/networks.customFields#CustomFieldEntityType), \"dataType\": enum (/ad-manager/api/beta/reference/rest/v1/networks.customFields#CustomFieldDataType), \"visibility\": enum (/ad-manager/api/beta/reference/rest/v1/networks.customFields#CustomFieldVisibility) } ``` |\n\n| Fields ||\n|-----------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `name` | `string` Identifier. The resource name of the `CustomField`. Format: `networks/{networkCode}/customFields/{customField}` |\n| `options[]` | `object (`[CustomFieldOption](/ad-manager/api/beta/reference/rest/v1/networks.customFields#CustomFieldOption)`)` Optional. The drop-down options for the `CustomField`. Only applicable for `CustomField` with the drop-down data type. |\n| `customFieldId` | `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` Output only. Unique ID of the CustomField. This attribute is assigned by Google. |\n| `displayName` | `string` Required. Name of the CustomField. The max length is 127 characters. |\n| `description` | `string` Optional. A description of the custom field. The maximum length is 511 characters. |\n| `status` | `enum (`[CustomFieldStatus](/ad-manager/api/beta/reference/rest/v1/networks.customFields#CustomFieldStatus)`)` Output only. The status of the `CustomField`. |\n| `entityType` | `enum (`[CustomFieldEntityType](/ad-manager/api/beta/reference/rest/v1/networks.customFields#CustomFieldEntityType)`)` Required. The type of entity the `CustomField` can be applied to. |\n| `dataType` | `enum (`[CustomFieldDataType](/ad-manager/api/beta/reference/rest/v1/networks.customFields#CustomFieldDataType)`)` Required. The data type of the `CustomField`. |\n| `visibility` | `enum (`[CustomFieldVisibility](/ad-manager/api/beta/reference/rest/v1/networks.customFields#CustomFieldVisibility)`)` Required. The visibility of the `CustomField`. |\n\nCustomFieldStatus\n-----------------\n\nThe status of the CustomField.\n\n| Enums ||\n|-----------------------------------|------------------------------|\n| `CUSTOM_FIELD_STATUS_UNSPECIFIED` | No value specified |\n| `ACTIVE` | The CustomField is active. |\n| `INACTIVE` | The CustomField is inactive. |\n\nCustomFieldEntityType\n---------------------\n\nThe types of entities that a CustomField can be applied to.\n\n| Enums ||\n|----------------------------------------|--------------------------------------------------|\n| `CUSTOM_FIELD_ENTITY_TYPE_UNSPECIFIED` | No value specified |\n| `LINE_ITEM` | The CustomField is applied to LineItems. |\n| `ORDER` | The CustomField is applied to Orders. |\n| `CREATIVE` | The CustomField is applied to Creatives. |\n| `PROPOSAL` | The CustomField is applied to Proposals. |\n| `PROPOSAL_LINE_ITEM` | The CustomField is applied to ProposalLineItems. |\n\nCustomFieldDataType\n-------------------\n\nThe data type for a CustomField.\n\n| Enums ||\n|--------------------------------------|--------------------------------------------------|\n| `CUSTOM_FIELD_DATA_TYPE_UNSPECIFIED` | No value specified |\n| `STRING` | A string field The max length is 255 characters. |\n| `NUMBER` | A number field. |\n| `TOGGLE` | A \"Yes\" or \"No\" toggle field. |\n| `DROP_DOWN` | A drop-down field. |\n\nCustomFieldVisibility\n---------------------\n\nThe visibility level of a CustomField.\n\n| Enums ||\n|---------------------------------------|----------------------------------------------------------------------------|\n| `CUSTOM_FIELD_VISIBILITY_UNSPECIFIED` | No value specified |\n| `HIDDEN` | The CustomField is not visible in the UI and only visible through the API. |\n| `READ_ONLY` | The CustomField is visible in the UI and only editable through the API. |\n| `EDITABLE` | The CustomField is visible and editable in both the API and UI. |\n\nCustomFieldOption\n-----------------\n\nAn option for a drop-down `CustomField`.\n\n| JSON representation |\n|------------------------------------------------------------------|\n| ``` { \"customFieldOptionId\": string, \"displayName\": string } ``` |\n\n| Fields ||\n|-----------------------|--------------------------------------------------------------------------------------------------------------------------|\n| `customFieldOptionId` | `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` Output only. `CustomFieldOption` ID. |\n| `displayName` | `string` Required. The display name of the `CustomFieldOption`. This value has a maximum length of 127 characters. |\n\n| Methods ------- ||\n|-------------------------------------------------------------------------------|--------------------------------------------------|\n| ### [get](/ad-manager/api/beta/reference/rest/v1/networks.customFields/get) | API to retrieve a `CustomField` object. |\n| ### [list](/ad-manager/api/beta/reference/rest/v1/networks.customFields/list) | API to retrieve a list of `CustomField` objects. |"]]