Google Cloud Dialogflow Cx V3 Client - Class Variant (0.2.1)

Reference documentation and code samples for the Google Cloud Dialogflow Cx V3 Client class Variant.

A single flow version with specified traffic allocation.

Generated from protobuf message google.cloud.dialogflow.cx.v3.VersionVariants.Variant

Namespace

Google \ Cloud \ Dialogflow \ Cx \ V3 \ VersionVariants

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ version string

The name of the flow version. Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>.

↳ traffic_allocation float

Percentage of the traffic which should be routed to this version of flow. Traffic allocation for a single flow must sum up to 1.0.

↳ is_control_group bool

Whether the variant is for the control group.

getVersion

The name of the flow version.

Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>.

Returns
TypeDescription
string

setVersion

The name of the flow version.

Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>.

Parameter
NameDescription
var string
Returns
TypeDescription
$this

getTrafficAllocation

Percentage of the traffic which should be routed to this version of flow. Traffic allocation for a single flow must sum up to 1.0.

Returns
TypeDescription
float

setTrafficAllocation

Percentage of the traffic which should be routed to this version of flow. Traffic allocation for a single flow must sum up to 1.0.

Parameter
NameDescription
var float
Returns
TypeDescription
$this

getIsControlGroup

Whether the variant is for the control group.

Returns
TypeDescription
bool

setIsControlGroup

Whether the variant is for the control group.

Parameter
NameDescription
var bool
Returns
TypeDescription
$this