# Google Cloud Dialogflow Cx V3 Client - Class Flow (0.11.1)

0.11.1 (latest) 0.11.0 0.10.2 0.9.2 0.8.1 0.7.2 0.6.0 0.5.2 0.4.1 0.3.4 0.2.1 0.1.1 Reference documentation and code samples for the Google Cloud Dialogflow Cx V3 Client class Flow.

Flows represents the conversation flows when you build your chatbot agent.

A flow consists of many pages connected by the transition routes.
Conversations always start with the built-in Start Flow (with an all-0 ID).
Transition routes can direct the conversation session from the current flow
(parent flow) to another flow (sub flow). When the sub flow is finished,
Dialogflow will bring the session back to the parent flow, where the sub flow
is started.
Usually, when a transition route is followed by a matched intent, the intent
will be "consumed". This means the intent won't activate more transition
routes. However, when the followed transition route moves the conversation
session into a different flow, the matched intent can be carried over and to
be consumed in the target flow.

Generated from protobuf message `google.cloud.dialogflow.cx.v3.Flow`

## Namespace

Google \\ Cloud \\ Dialogflow \\ Cx \\ V3

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` The unique identifier of the flow. Format: `projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/flows/<FlowID>`. |
| `↳ display_name` | `string` Required. The human-readable name of the flow. |
| `↳ description` | `string` The description of the flow. The maximum length is 500 characters. If exceeded, the request is rejected. |
| `↳ transition_routes` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.TransitionRoute>` A flow's transition routes serve two purposes: \* \* They are responsible for matching the user's first utterances in the flow. \* \* They are inherited by every page's transition routes and can support use cases such as the user saying "help" or "can I talk to a human?", which can be handled in a common way regardless of the current page. Transition routes defined in the page have higher priority than those defined in the flow. TransitionRoutes are evaluated in the following order: \* \* TransitionRoutes with intent specified. \* \* TransitionRoutes with only condition specified. TransitionRoutes with intent specified are inherited by pages in the flow. |
| `↳ event_handlers` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.EventHandler>` A flow's event handlers serve two purposes: \* \* They are responsible for handling events (e.g. no match, webhook errors) in the flow. \* \* They are inherited by every page's event handlers, which can be used to handle common events regardless of the current page. Event handlers defined in the page have higher priority than those defined in the flow. Unlike [transition_routes](https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.Flow#_Google_Cloud_Dialogflow_Cx_V3_Flow__getTransitionRoutes__), these handlers are evaluated on a first-match basis. The first one that matches the event get executed, with the rest being ignored. |
| `↳ transition_route_groups` | `string[]` A flow's transition route group serve two purposes: \* \* They are responsible for matching the user's first utterances in the flow. \* \* They are inherited by every page's transition route groups. Transition route groups defined in the page have higher priority than those defined in the flow. Format: `projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/flows/<FlowID>/transitionRouteGroups/<TransitionRouteGroupID>` or `projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/transitionRouteGroups/<TransitionRouteGroupID>` for agent-level groups. |
| `↳ nlu_settings` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.NluSettings` NLU related settings of the flow. |
| `↳ advanced_settings` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.AdvancedSettings` Hierarchical advanced settings for this flow. The settings exposed at the lower level overrides the settings exposed at the higher level. |
| `↳ knowledge_connector_settings` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.KnowledgeConnectorSettings` Optional. Knowledge connector configuration. |
| `↳ input_parameter_definitions` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.ParameterDefinition>` Optional. Defined structured input parameters for this flow. |
| `↳ output_parameter_definitions` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.ParameterDefinition>` Optional. Defined structured output parameters for this flow. |
| `↳ multi_language_settings` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.Flow.MultiLanguageSettings` Optional. Multi-lingual agent settings for this flow. |
| `↳ locked` | `bool` Indicates whether the flow is locked for changes. If the flow is locked, modifications to the flow will be rejected. |

### getName

The unique identifier of the flow.

Format:
`projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/flows/<FlowID>`.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setName

The unique identifier of the flow.

Format:
`projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/flows/<FlowID>`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getDisplayName

Required. The human-readable name of the flow.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setDisplayName

Required. The human-readable name of the flow.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getDescription

The description of the flow. The maximum length is 500 characters. If
exceeded, the request is rejected.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setDescription

The description of the flow. The maximum length is 500 characters. If
exceeded, the request is rejected.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getTransitionRoutes

A flow's transition routes serve two purposes:

- They are responsible for matching the user's first utterances in the
  flow.

- They are inherited by every page's transition routes and can support use cases such as the user
  saying "help" or "can I talk to a human?", which can be handled in a common
  way regardless of the current page. Transition routes defined in the page
  have higher priority than those defined in the flow.
  TransitionRoutes are evaluated in the following order:

- TransitionRoutes with intent specified.
- TransitionRoutes with only condition specified. TransitionRoutes with intent specified are inherited by pages in the flow.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.TransitionRoute>` |   |

### setTransitionRoutes

A flow's transition routes serve two purposes:

- They are responsible for matching the user's first utterances in the
  flow.

- They are inherited by every page's transition routes and can support use cases such as the user
  saying "help" or "can I talk to a human?", which can be handled in a common
  way regardless of the current page. Transition routes defined in the page
  have higher priority than those defined in the flow.
  TransitionRoutes are evaluated in the following order:

- TransitionRoutes with intent specified.
- TransitionRoutes with only condition specified. TransitionRoutes with intent specified are inherited by pages in the flow.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.TransitionRoute>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getEventHandlers

A flow's event handlers serve two purposes:

- They are responsible for handling events (e.g. no match,
  webhook errors) in the flow.

- They are inherited by every page's event handlers, which can be used to handle common events
  regardless of the current page. Event handlers defined in the page
  have higher priority than those defined in the flow.
  Unlike
  [transition_routes](https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.Flow#_Google_Cloud_Dialogflow_Cx_V3_Flow__getTransitionRoutes__),
  these handlers are evaluated on a first-match basis. The first one that
  matches the event get executed, with the rest being ignored.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.EventHandler>` |   |

### setEventHandlers

A flow's event handlers serve two purposes:

- They are responsible for handling events (e.g. no match,
  webhook errors) in the flow.

- They are inherited by every page's event handlers, which can be used to handle common events
  regardless of the current page. Event handlers defined in the page
  have higher priority than those defined in the flow.
  Unlike
  [transition_routes](https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.Flow#_Google_Cloud_Dialogflow_Cx_V3_Flow__getTransitionRoutes__),
  these handlers are evaluated on a first-match basis. The first one that
  matches the event get executed, with the rest being ignored.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.EventHandler>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getTransitionRouteGroups

A flow's transition route group serve two purposes:

- They are responsible for matching the user's first utterances in the
  flow.

- They are inherited by every page's transition route groups. Transition route groups
  defined in the page have higher priority than those defined in the flow.
  Format:
  `projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/flows/<FlowID>/transitionRouteGroups/<TransitionRouteGroupID>`
  or
  `projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/transitionRouteGroups/<TransitionRouteGroupID>`
  for agent-level groups.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<string>` |   |

### setTransitionRouteGroups

A flow's transition route group serve two purposes:

- They are responsible for matching the user's first utterances in the
  flow.

- They are inherited by every page's transition route groups. Transition route groups
  defined in the page have higher priority than those defined in the flow.
  Format:
  `projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/flows/<FlowID>/transitionRouteGroups/<TransitionRouteGroupID>`
  or
  `projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/transitionRouteGroups/<TransitionRouteGroupID>`
  for agent-level groups.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string[]` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getNluSettings

NLU related settings of the flow.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.NluSettings|null` |   |

### hasNluSettings

### clearNluSettings

### setNluSettings

NLU related settings of the flow.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.NluSettings` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAdvancedSettings

Hierarchical advanced settings for this flow. The settings exposed at the
lower level overrides the settings exposed at the higher level.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.AdvancedSettings|null` |   |

### hasAdvancedSettings

### clearAdvancedSettings

### setAdvancedSettings

Hierarchical advanced settings for this flow. The settings exposed at the
lower level overrides the settings exposed at the higher level.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.AdvancedSettings` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getKnowledgeConnectorSettings

Optional. Knowledge connector configuration.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.KnowledgeConnectorSettings|null` |   |

### hasKnowledgeConnectorSettings

### clearKnowledgeConnectorSettings

### setKnowledgeConnectorSettings

Optional. Knowledge connector configuration.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.KnowledgeConnectorSettings` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getInputParameterDefinitions

Optional. Defined structured input parameters for this flow.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.ParameterDefinition>` |   |

### setInputParameterDefinitions

Optional. Defined structured input parameters for this flow.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.ParameterDefinition>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getOutputParameterDefinitions

Optional. Defined structured output parameters for this flow.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.ParameterDefinition>` |   |

### setOutputParameterDefinitions

Optional. Defined structured output parameters for this flow.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.ParameterDefinition>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getMultiLanguageSettings

Optional. Multi-lingual agent settings for this flow.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.Flow.MultiLanguageSettings|null` |   |

### hasMultiLanguageSettings

### clearMultiLanguageSettings

### setMultiLanguageSettings

Optional. Multi-lingual agent settings for this flow.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.Flow.MultiLanguageSettings` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getLocked

Indicates whether the flow is locked for changes. If the flow is locked,
modifications to the flow will be rejected.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### setLocked

Indicates whether the flow is locked for changes. If the flow is locked,
modifications to the flow will be rejected.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |