Class: Google::Apis::DialogflowV2::GoogleCloudDialogflowCxV3beta1SessionInfo

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/dialogflow_v2/classes.rb,
lib/google/apis/dialogflow_v2/representations.rb,
lib/google/apis/dialogflow_v2/representations.rb

Overview

Represents session information communicated to and from the webhook.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudDialogflowCxV3beta1SessionInfo

Returns a new instance of GoogleCloudDialogflowCxV3beta1SessionInfo.



5530
5531
5532
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5530

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#parametersHash<String,Object>

Optional for WebhookRequest. Optional for WebhookResponse. All parameters collected from forms and intents during the session. Parameters can be created, updated, or removed by the webhook. To remove a parameter from the session, the webhook should explicitly set the parameter value to null in WebhookResponse. The map is keyed by parameters' display names. Corresponds to the JSON property parameters

Returns:

  • (Hash<String,Object>)


5520
5521
5522
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5520

def parameters
  @parameters
end

#sessionString

Always present for WebhookRequest. Ignored for WebhookResponse. The unique identifier of the session. This field can be used by the webhook to identify a session. Format: projects//locations//agents//sessions/ or projects// locations//agents//environments//sessions/ if environment is specified. Corresponds to the JSON property session

Returns:

  • (String)


5528
5529
5530
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5528

def session
  @session
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



5535
5536
5537
5538
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5535

def update!(**args)
  @parameters = args[:parameters] if args.key?(:parameters)
  @session = args[:session] if args.key?(:session)
end