Google Cloud Dialogflow V2 Client - Class Message (1.0.1)

Reference documentation and code samples for the Google Cloud Dialogflow V2 Client class Message.

A rich response message.

Corresponds to the intent Response field in the Dialogflow console. For more information, see Rich response messages.

Generated from protobuf message google.cloud.dialogflow.v2.Intent.Message

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ text Google\Cloud\Dialogflow\V2\Intent\Message\Text

The text response.

↳ image Google\Cloud\Dialogflow\V2\Intent\Message\Image

The image response.

↳ quick_replies Google\Cloud\Dialogflow\V2\Intent\Message\QuickReplies

The quick replies response.

↳ card Google\Cloud\Dialogflow\V2\Intent\Message\Card

The card response.

↳ payload Google\Protobuf\Struct

A custom platform-specific response.

↳ simple_responses Google\Cloud\Dialogflow\V2\Intent\Message\SimpleResponses

The voice and text-only responses for Actions on Google.

↳ basic_card Google\Cloud\Dialogflow\V2\Intent\Message\BasicCard

The basic card response for Actions on Google.

↳ suggestions Google\Cloud\Dialogflow\V2\Intent\Message\Suggestions

The suggestion chips for Actions on Google.

↳ link_out_suggestion Google\Cloud\Dialogflow\V2\Intent\Message\LinkOutSuggestion

The link out suggestion chip for Actions on Google.

↳ list_select Google\Cloud\Dialogflow\V2\Intent\Message\ListSelect

The list card response for Actions on Google.

↳ carousel_select Google\Cloud\Dialogflow\V2\Intent\Message\CarouselSelect

The carousel card response for Actions on Google.

↳ browse_carousel_card Google\Cloud\Dialogflow\V2\Intent\Message\BrowseCarouselCard

Browse carousel card for Actions on Google.

↳ table_card Google\Cloud\Dialogflow\V2\Intent\Message\TableCard

Table card for Actions on Google.

↳ media_content Google\Cloud\Dialogflow\V2\Intent\Message\MediaContent

The media content card for Actions on Google.

↳ platform int

Optional. The platform that this message is intended for.

getText

The text response.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.Text text = 1;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\Text|null

hasText

setText

The text response.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.Text text = 1;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\Text
Returns
TypeDescription
$this

getImage

The image response.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.Image image = 2;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\Image|null

hasImage

setImage

The image response.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.Image image = 2;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\Image
Returns
TypeDescription
$this

getQuickReplies

The quick replies response.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.QuickReplies quick_replies = 3;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\QuickReplies|null

hasQuickReplies

setQuickReplies

The quick replies response.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.QuickReplies quick_replies = 3;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\QuickReplies
Returns
TypeDescription
$this

getCard

The card response.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.Card card = 4;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\Card|null

hasCard

setCard

The card response.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.Card card = 4;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\Card
Returns
TypeDescription
$this

getPayload

A custom platform-specific response.

Generated from protobuf field .google.protobuf.Struct payload = 5;

Returns
TypeDescription
Google\Protobuf\Struct|null

hasPayload

setPayload

A custom platform-specific response.

Generated from protobuf field .google.protobuf.Struct payload = 5;

Parameter
NameDescription
var Google\Protobuf\Struct
Returns
TypeDescription
$this

getSimpleResponses

The voice and text-only responses for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.SimpleResponses simple_responses = 7;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\SimpleResponses|null

hasSimpleResponses

setSimpleResponses

The voice and text-only responses for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.SimpleResponses simple_responses = 7;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\SimpleResponses
Returns
TypeDescription
$this

getBasicCard

The basic card response for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.BasicCard basic_card = 8;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\BasicCard|null

hasBasicCard

setBasicCard

The basic card response for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.BasicCard basic_card = 8;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\BasicCard
Returns
TypeDescription
$this

getSuggestions

The suggestion chips for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.Suggestions suggestions = 9;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\Suggestions|null

hasSuggestions

setSuggestions

The suggestion chips for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.Suggestions suggestions = 9;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\Suggestions
Returns
TypeDescription
$this

getLinkOutSuggestion

The link out suggestion chip for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.LinkOutSuggestion link_out_suggestion = 10;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\LinkOutSuggestion|null

hasLinkOutSuggestion

setLinkOutSuggestion

The link out suggestion chip for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.LinkOutSuggestion link_out_suggestion = 10;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\LinkOutSuggestion
Returns
TypeDescription
$this

getListSelect

The list card response for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.ListSelect list_select = 11;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\ListSelect|null

hasListSelect

setListSelect

The list card response for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.ListSelect list_select = 11;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\ListSelect
Returns
TypeDescription
$this

getCarouselSelect

The carousel card response for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.CarouselSelect carousel_select = 12;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\CarouselSelect|null

hasCarouselSelect

setCarouselSelect

The carousel card response for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.CarouselSelect carousel_select = 12;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\CarouselSelect
Returns
TypeDescription
$this

getBrowseCarouselCard

Browse carousel card for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard browse_carousel_card = 22;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\BrowseCarouselCard|null

hasBrowseCarouselCard

setBrowseCarouselCard

Browse carousel card for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard browse_carousel_card = 22;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\BrowseCarouselCard
Returns
TypeDescription
$this

getTableCard

Table card for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.TableCard table_card = 23;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\TableCard|null

hasTableCard

setTableCard

Table card for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.TableCard table_card = 23;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\TableCard
Returns
TypeDescription
$this

getMediaContent

The media content card for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.MediaContent media_content = 24;

Returns
TypeDescription
Google\Cloud\Dialogflow\V2\Intent\Message\MediaContent|null

hasMediaContent

setMediaContent

The media content card for Actions on Google.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.MediaContent media_content = 24;

Parameter
NameDescription
var Google\Cloud\Dialogflow\V2\Intent\Message\MediaContent
Returns
TypeDescription
$this

getPlatform

Optional. The platform that this message is intended for.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.Platform platform = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

setPlatform

Optional. The platform that this message is intended for.

Generated from protobuf field .google.cloud.dialogflow.v2.Intent.Message.Platform platform = 6 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
var int
Returns
TypeDescription
$this

getMessage

Returns
TypeDescription
string