REST Resource: projects.locations.tagTemplates.fields

Resource: TagTemplateField

The template for an individual field within a tag template.

JSON representation
{
  "name": string,
  "displayName": string,
  "type": {
    object (FieldType)
  },
  "isRequired": boolean,
  "order": integer
}
Fields
name

string

Output only. The resource name of the tag template field in URL format. Example:

  • projects/{project_id}/locations/{location}/tagTemplates/{tagTemplate}/fields/{field}

Note that this TagTemplateField may not actually be stored in the location in this name.

displayName

string

The display name for this field. Defaults to an empty string.

type

object (FieldType)

Required. The type of value this tag field can contain.

isRequired

boolean

Whether this is a required field. Defaults to false.

order

integer

The order of this field with respect to other fields in this tag template. For example, a higher value can indicate a more important field. The value can be negative. Multiple fields can have the same order, and field orders within a tag do not have to be sequential.

FieldType

JSON representation
{

  // Union field type_decl can be only one of the following:
  "primitiveType": enum (PrimitiveType),
  "enumType": {
    object (EnumType)
  }
  // End of list of possible types for union field type_decl.
}
Fields
Union field type_decl. Required. type_decl can be only one of the following:
primitiveType

enum (PrimitiveType)

Represents primitive types - string, bool etc.

enumType

object (EnumType)

Represents an enum type.

PrimitiveType

Enums
PRIMITIVE_TYPE_UNSPECIFIED This is the default invalid value for a type.
DOUBLE A double precision number.
STRING An UTF-8 string.
BOOL A boolean value.
TIMESTAMP A timestamp.

EnumType

JSON representation
{
  "allowedValues": [
    {
      object (EnumValue)
    }
  ]
}
Fields
allowedValues[]

object (EnumValue)

The set of allowed values for this enum. This set must not be empty, the display names of the values in this set must not be empty and the display names of the values must be case-insensitively unique within this set. The order of items in this list is preserved. This field can be used to create, remove and reorder enum values. In order to rename enum value use enumValues.rename method. Can have up to 500 allowed values.

EnumValue

JSON representation
{
  "displayName": string
}
Fields
displayName

string

Required. The display name of the enum value. Must not be an empty string.

Methods

create

Creates a field in a tag template.

delete

Deletes a field in a tag template and all uses of that field.

patch

Updates a field in a tag template.

rename

Renames a field in a tag template.