Google Analytics Admin V1beta Client - Class KeyEvent (0.23.0)

Reference documentation and code samples for the Google Analytics Admin V1beta Client class KeyEvent.

A key event in a Google Analytics property.

Generated from protobuf message google.analytics.admin.v1beta.KeyEvent

Namespace

Google \ Analytics \ Admin \ V1beta

Methods

__construct

Constructor.

Parameters
NameDescription
dataarray

Optional. Data for populating the Message object.

↳ namestring

Output only. Resource name of this key event. Format: properties/{property}/keyEvents/{key_event}

↳ event_namestring

Immutable. The event name for this key event. Examples: 'click', 'purchase'

↳ create_timeGoogle\Protobuf\Timestamp

Output only. Time when this key event was created in the property.

↳ deletablebool

Output only. If set to true, this event can be deleted.

↳ custombool

Output only. If set to true, this key event refers to a custom event. If set to false, this key event refers to a default event in GA. Default events typically have special meaning in GA. Default events are usually created for you by the GA system, but in some cases can be created by property admins. Custom events count towards the maximum number of custom key events that may be created per property.

↳ counting_methodint

Required. The method by which Key Events will be counted across multiple events within a session.

↳ default_valueGoogle\Analytics\Admin\V1beta\KeyEvent\DefaultValue

Optional. Defines a default value/currency for a key event.

getName

Output only. Resource name of this key event.

Format: properties/{property}/keyEvents/{key_event}

Returns
TypeDescription
string

setName

Output only. Resource name of this key event.

Format: properties/{property}/keyEvents/{key_event}

Parameter
NameDescription
varstring
Returns
TypeDescription
$this

getEventName

Immutable. The event name for this key event.

Examples: 'click', 'purchase'

Returns
TypeDescription
string

setEventName

Immutable. The event name for this key event.

Examples: 'click', 'purchase'

Parameter
NameDescription
varstring
Returns
TypeDescription
$this

getCreateTime

Output only. Time when this key event was created in the property.

Returns
TypeDescription
Google\Protobuf\Timestamp|null

hasCreateTime

clearCreateTime

setCreateTime

Output only. Time when this key event was created in the property.

Parameter
NameDescription
varGoogle\Protobuf\Timestamp
Returns
TypeDescription
$this

getDeletable

Output only. If set to true, this event can be deleted.

Returns
TypeDescription
bool

setDeletable

Output only. If set to true, this event can be deleted.

Parameter
NameDescription
varbool
Returns
TypeDescription
$this

getCustom

Output only. If set to true, this key event refers to a custom event. If set to false, this key event refers to a default event in GA. Default events typically have special meaning in GA. Default events are usually created for you by the GA system, but in some cases can be created by property admins. Custom events count towards the maximum number of custom key events that may be created per property.

Returns
TypeDescription
bool

setCustom

Output only. If set to true, this key event refers to a custom event. If set to false, this key event refers to a default event in GA. Default events typically have special meaning in GA. Default events are usually created for you by the GA system, but in some cases can be created by property admins. Custom events count towards the maximum number of custom key events that may be created per property.

Parameter
NameDescription
varbool
Returns
TypeDescription
$this

getCountingMethod

Required. The method by which Key Events will be counted across multiple events within a session.

Returns
TypeDescription
int

setCountingMethod

Required. The method by which Key Events will be counted across multiple events within a session.

Parameter
NameDescription
varint
Returns
TypeDescription
$this

getDefaultValue

Optional. Defines a default value/currency for a key event.

Returns
TypeDescription
Google\Analytics\Admin\V1beta\KeyEvent\DefaultValue|null

hasDefaultValue

clearDefaultValue

setDefaultValue

Optional. Defines a default value/currency for a key event.

Parameter
NameDescription
varGoogle\Analytics\Admin\V1beta\KeyEvent\DefaultValue
Returns
TypeDescription
$this