Class: Google::Apis::DialogflowV2::DialogflowService

Inherits:
Core::BaseService
  • Object
show all
Defined in:
generated/google/apis/dialogflow_v2/service.rb

Overview

Dialogflow API

Builds conversational interfaces (for example, chatbots, and voice-powered apps and devices).

Examples:

require 'google/apis/dialogflow_v2'

Dialogflow = Google::Apis::DialogflowV2 # Alias the module
service = Dialogflow::DialogflowService.new

See Also:

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeDialogflowService

Returns a new instance of DialogflowService.



46
47
48
49
# File 'generated/google/apis/dialogflow_v2/service.rb', line 46

def initialize
  super('https://dialogflow.googleapis.com/', '')
  @batch_path = 'batch'
end

Instance Attribute Details

#keyString

Returns API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.

Returns:

  • (String)

    API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.



39
40
41
# File 'generated/google/apis/dialogflow_v2/service.rb', line 39

def key
  @key
end

#quota_userString

Returns Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

Returns:

  • (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.



44
45
46
# File 'generated/google/apis/dialogflow_v2/service.rb', line 44

def quota_user
  @quota_user
end

Instance Method Details

#batch_project_agent_entity_type_delete(parent, google_cloud_dialogflow_v2_batch_delete_entity_types_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Deletes entity types in the specified agent. Operation

Parameters:

  • parent (String)

    Required. The name of the agent to delete all entities types for. Format: projects//agent.

  • google_cloud_dialogflow_v2_batch_delete_entity_types_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



468
469
470
471
472
473
474
475
476
477
478
# File 'generated/google/apis/dialogflow_v2/service.rb', line 468

def batch_project_agent_entity_type_delete(parent, google_cloud_dialogflow_v2_batch_delete_entity_types_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/entityTypes:batchDelete', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_batch_delete_entity_types_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#batch_project_agent_entity_type_entity_create(parent, google_cloud_dialogflow_v2_batch_create_entities_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Creates multiple new entities in the specified entity type. Operation

Parameters:

  • parent (String)

    Required. The name of the entity type to create entities in. Format: projects/ /agent/entityTypes/.

  • google_cloud_dialogflow_v2_batch_create_entities_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchCreateEntitiesRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



729
730
731
732
733
734
735
736
737
738
739
# File 'generated/google/apis/dialogflow_v2/service.rb', line 729

def batch_project_agent_entity_type_entity_create(parent, google_cloud_dialogflow_v2_batch_create_entities_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/entities:batchCreate', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchCreateEntitiesRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_batch_create_entities_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#batch_project_agent_entity_type_entity_delete(parent, google_cloud_dialogflow_v2_batch_delete_entities_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Deletes entities in the specified entity type. Operation

Parameters:

  • parent (String)

    Required. The name of the entity type to delete entries for. Format: projects/ /agent/entityTypes/.

  • google_cloud_dialogflow_v2_batch_delete_entities_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchDeleteEntitiesRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



763
764
765
766
767
768
769
770
771
772
773
# File 'generated/google/apis/dialogflow_v2/service.rb', line 763

def batch_project_agent_entity_type_entity_delete(parent, google_cloud_dialogflow_v2_batch_delete_entities_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/entities:batchDelete', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchDeleteEntitiesRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_batch_delete_entities_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#batch_project_agent_entity_type_entity_update(parent, google_cloud_dialogflow_v2_batch_update_entities_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Updates or creates multiple entities in the specified entity type. This method does not affect entities in the entity type that aren't explicitly specified in the request. Operation

Parameters:

  • parent (String)

    Required. The name of the entity type to update or create entities in. Format: projects//agent/entityTypes/.

  • google_cloud_dialogflow_v2_batch_update_entities_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchUpdateEntitiesRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



799
800
801
802
803
804
805
806
807
808
809
# File 'generated/google/apis/dialogflow_v2/service.rb', line 799

def batch_project_agent_entity_type_entity_update(parent, google_cloud_dialogflow_v2_batch_update_entities_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/entities:batchUpdate', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchUpdateEntitiesRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_batch_update_entities_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#batch_project_agent_entity_type_update(parent, google_cloud_dialogflow_v2_batch_update_entity_types_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Updates/Creates multiple entity types in the specified agent. Operation

Parameters:

  • parent (String)

    Required. The name of the agent to update or create entity types in. Format: projects//agent.

  • google_cloud_dialogflow_v2_batch_update_entity_types_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



502
503
504
505
506
507
508
509
510
511
512
# File 'generated/google/apis/dialogflow_v2/service.rb', line 502

def batch_project_agent_entity_type_update(parent, google_cloud_dialogflow_v2_batch_update_entity_types_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/entityTypes:batchUpdate', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_batch_update_entity_types_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#batch_project_agent_intent_delete(parent, google_cloud_dialogflow_v2_batch_delete_intents_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Deletes intents in the specified agent. Operation

Parameters:

  • parent (String)

    Required. The name of the agent to delete all entities types for. Format: projects//agent.

  • google_cloud_dialogflow_v2_batch_delete_intents_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchDeleteIntentsRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1332

def batch_project_agent_intent_delete(parent, google_cloud_dialogflow_v2_batch_delete_intents_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/intents:batchDelete', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchDeleteIntentsRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_batch_delete_intents_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#batch_project_agent_intent_update(parent, google_cloud_dialogflow_v2_batch_update_intents_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Updates/Creates multiple intents in the specified agent. Operation

Parameters:

  • parent (String)

    Required. The name of the agent to update or create intents in. Format: projects//agent.

  • google_cloud_dialogflow_v2_batch_update_intents_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchUpdateIntentsRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1366

def batch_project_agent_intent_update(parent, google_cloud_dialogflow_v2_batch_update_intents_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/intents:batchUpdate', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2BatchUpdateIntentsRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_batch_update_intents_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#cancel_project_location_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleProtobufEmpty

Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns google.rpc.Code.UNIMPLEMENTED. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to Code.CANCELLED.

Parameters:

  • name (String)

    The name of the operation resource to be cancelled.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2073
2074
2075
2076
2077
2078
2079
2080
2081
# File 'generated/google/apis/dialogflow_v2/service.rb', line 2073

def cancel_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+name}:cancel', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#cancel_project_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleProtobufEmpty

Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns google.rpc.Code.UNIMPLEMENTED. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to Code.CANCELLED.

Parameters:

  • name (String)

    The name of the operation resource to be cancelled.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2187
2188
2189
2190
2191
2192
2193
2194
2195
# File 'generated/google/apis/dialogflow_v2/service.rb', line 2187

def cancel_project_operation(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+name}:cancel', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_project_agent_entity_type(parent, google_cloud_dialogflow_v2_entity_type_object = nil, language_code: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType

Creates an entity type in the specified agent.

Parameters:

  • parent (String)

    Required. The agent to create a entity type for. Format: projects//agent.

  • google_cloud_dialogflow_v2_entity_type_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType) (defaults to: nil)
  • language_code (String) (defaults to: nil)

    Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see Multilingual intent and entity data.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



540
541
542
543
544
545
546
547
548
549
550
551
# File 'generated/google/apis/dialogflow_v2/service.rb', line 540

def create_project_agent_entity_type(parent, google_cloud_dialogflow_v2_entity_type_object = nil, language_code: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/entityTypes', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType::Representation
  command.request_object = google_cloud_dialogflow_v2_entity_type_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType
  command.params['parent'] = parent unless parent.nil?
  command.query['languageCode'] = language_code unless language_code.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_project_agent_environment_user_session_context(parent, google_cloud_dialogflow_v2_context_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context

Creates a context. If the specified context already exists, overrides the context.

Parameters:

  • parent (String)

    Required. The session to create a context for. Format: projects//agent/ sessions/ or projects//agent/environments//users//sessions/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • google_cloud_dialogflow_v2_context_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



954
955
956
957
958
959
960
961
962
963
964
# File 'generated/google/apis/dialogflow_v2/service.rb', line 954

def create_project_agent_environment_user_session_context(parent, google_cloud_dialogflow_v2_context_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/contexts', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context::Representation
  command.request_object = google_cloud_dialogflow_v2_context_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_project_agent_environment_user_session_entity_type(parent, google_cloud_dialogflow_v2_session_entity_type_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType

Creates a session entity type. If the specified session entity type already exists, overrides the session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.

Parameters:

  • parent (String)

    Required. The session to create a session entity type for. Format: projects// agent/sessions/ or projects//agent/environments//users// sessions/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • google_cloud_dialogflow_v2_session_entity_type_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1143

def create_project_agent_environment_user_session_entity_type(parent, google_cloud_dialogflow_v2_session_entity_type_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/entityTypes', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType::Representation
  command.request_object = google_cloud_dialogflow_v2_session_entity_type_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_project_agent_intent(parent, google_cloud_dialogflow_v2_intent_object = nil, intent_view: nil, language_code: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent

Creates an intent in the specified agent.

Parameters:

  • parent (String)

    Required. The agent to create a intent for. Format: projects//agent.

  • google_cloud_dialogflow_v2_intent_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent) (defaults to: nil)
  • intent_view (String) (defaults to: nil)

    Optional. The resource view to apply to the returned intent.

  • language_code (String) (defaults to: nil)

    Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see Multilingual intent and entity data.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1406

def create_project_agent_intent(parent, google_cloud_dialogflow_v2_intent_object = nil, intent_view: nil, language_code: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/intents', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent::Representation
  command.request_object = google_cloud_dialogflow_v2_intent_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent
  command.params['parent'] = parent unless parent.nil?
  command.query['intentView'] = intent_view unless intent_view.nil?
  command.query['languageCode'] = language_code unless language_code.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_project_agent_session_context(parent, google_cloud_dialogflow_v2_context_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context

Creates a context. If the specified context already exists, overrides the context.

Parameters:

  • parent (String)

    Required. The session to create a context for. Format: projects//agent/ sessions/ or projects//agent/environments//users//sessions/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • google_cloud_dialogflow_v2_context_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1690

def create_project_agent_session_context(parent, google_cloud_dialogflow_v2_context_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/contexts', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context::Representation
  command.request_object = google_cloud_dialogflow_v2_context_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_project_agent_session_entity_type(parent, google_cloud_dialogflow_v2_session_entity_type_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType

Creates a session entity type. If the specified session entity type already exists, overrides the session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.

Parameters:

  • parent (String)

    Required. The session to create a session entity type for. Format: projects// agent/sessions/ or projects//agent/environments//users// sessions/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • google_cloud_dialogflow_v2_session_entity_type_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1879

def create_project_agent_session_entity_type(parent, google_cloud_dialogflow_v2_session_entity_type_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/entityTypes', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType::Representation
  command.request_object = google_cloud_dialogflow_v2_session_entity_type_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_project_agent(parent, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleProtobufEmpty

Deletes the specified agent.

Parameters:

  • parent (String)

    Required. The project that the agent to delete is associated with. Format: projects/.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



72
73
74
75
76
77
78
79
80
# File 'generated/google/apis/dialogflow_v2/service.rb', line 72

def delete_project_agent(parent, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v2/{+parent}/agent', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleProtobufEmpty
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_project_agent_entity_type(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleProtobufEmpty

Deletes the specified entity type.

Parameters:

  • name (String)

    Required. The name of the entity type to delete. Format: projects//agent/ entityTypes/.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



574
575
576
577
578
579
580
581
582
# File 'generated/google/apis/dialogflow_v2/service.rb', line 574

def delete_project_agent_entity_type(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_project_agent_environment_user_session_context(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleProtobufEmpty

Deletes the specified context.

Parameters:

  • name (String)

    Required. The name of the context to delete. Format: projects//agent/sessions/ /contexts/ or projects//agent/environments//users//sessions//contexts/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



989
990
991
992
993
994
995
996
997
# File 'generated/google/apis/dialogflow_v2/service.rb', line 989

def delete_project_agent_environment_user_session_context(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_project_agent_environment_user_session_contexts(parent, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleProtobufEmpty

Deletes all active contexts in the specified session.

Parameters:

  • parent (String)

    Required. The name of the session to delete all contexts from. Format: projects//agent/sessions/ or projects//agent/environments//users//sessions/. If Environment ID is not specified we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



871
872
873
874
875
876
877
878
879
# File 'generated/google/apis/dialogflow_v2/service.rb', line 871

def delete_project_agent_environment_user_session_contexts(parent, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v2/{+parent}/contexts', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleProtobufEmpty
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_project_agent_environment_user_session_entity_type(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleProtobufEmpty

Deletes the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.

Parameters:

  • name (String)

    Required. The name of the entity type to delete. Format: projects//agent/ sessions//entityTypes/ or projects//agent/environments//users//sessions// entityTypes/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1180
1181
1182
1183
1184
1185
1186
1187
1188
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1180

def delete_project_agent_environment_user_session_entity_type(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_project_agent_intent(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleProtobufEmpty

Deletes the specified intent and its direct or indirect followup intents.

Parameters:

  • name (String)

    Required. The name of the intent to delete. If this intent has direct or indirect followup intents, we also delete them. Format: projects//agent/ intents/.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1442
1443
1444
1445
1446
1447
1448
1449
1450
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1442

def delete_project_agent_intent(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_project_agent_session_context(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleProtobufEmpty

Deletes the specified context.

Parameters:

  • name (String)

    Required. The name of the context to delete. Format: projects//agent/sessions/ /contexts/ or projects//agent/environments//users//sessions//contexts/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1725
1726
1727
1728
1729
1730
1731
1732
1733
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1725

def delete_project_agent_session_context(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_project_agent_session_contexts(parent, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleProtobufEmpty

Deletes all active contexts in the specified session.

Parameters:

  • parent (String)

    Required. The name of the session to delete all contexts from. Format: projects//agent/sessions/ or projects//agent/environments//users//sessions/. If Environment ID is not specified we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1607
1608
1609
1610
1611
1612
1613
1614
1615
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1607

def delete_project_agent_session_contexts(parent, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v2/{+parent}/contexts', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleProtobufEmpty
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_project_agent_session_entity_type(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleProtobufEmpty

Deletes the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.

Parameters:

  • name (String)

    Required. The name of the entity type to delete. Format: projects//agent/ sessions//entityTypes/ or projects//agent/environments//users//sessions// entityTypes/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1916
1917
1918
1919
1920
1921
1922
1923
1924
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1916

def delete_project_agent_session_entity_type(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#detect_project_agent_environment_user_session_intent(session, google_cloud_dialogflow_v2_detect_intent_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2DetectIntentResponse

Processes a natural language query and returns structured, actionable data as a result. This method is not idempotent, because it may cause contexts and session entity types to be updated, which in turn might affect results of future queries. Note: Always use agent versions for production traffic. See Versions and environments.

Parameters:

  • session (String)

    Required. The name of the session this query is sent to. Format: projects// agent/sessions/, or projects//agent/environments//users//sessions/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we are using "-". It's up to the API caller to choose an appropriate Session ID and User Id. They can be a random number or some type of user and session identifiers (preferably hashed). The length of the Session ID and User ID must not exceed 36 characters. For more information, see the API interactions guide. Note: Always use agent versions for production traffic. See Versions and environments.

  • google_cloud_dialogflow_v2_detect_intent_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2DetectIntentRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



917
918
919
920
921
922
923
924
925
926
927
# File 'generated/google/apis/dialogflow_v2/service.rb', line 917

def detect_project_agent_environment_user_session_intent(session, google_cloud_dialogflow_v2_detect_intent_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+session}:detectIntent', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2DetectIntentRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_detect_intent_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2DetectIntentResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2DetectIntentResponse
  command.params['session'] = session unless session.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#detect_project_agent_session_intent(session, google_cloud_dialogflow_v2_detect_intent_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2DetectIntentResponse

Processes a natural language query and returns structured, actionable data as a result. This method is not idempotent, because it may cause contexts and session entity types to be updated, which in turn might affect results of future queries. Note: Always use agent versions for production traffic. See Versions and environments.

Parameters:

  • session (String)

    Required. The name of the session this query is sent to. Format: projects// agent/sessions/, or projects//agent/environments//users//sessions/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we are using "-". It's up to the API caller to choose an appropriate Session ID and User Id. They can be a random number or some type of user and session identifiers (preferably hashed). The length of the Session ID and User ID must not exceed 36 characters. For more information, see the API interactions guide. Note: Always use agent versions for production traffic. See Versions and environments.

  • google_cloud_dialogflow_v2_detect_intent_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2DetectIntentRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1653

def detect_project_agent_session_intent(session, google_cloud_dialogflow_v2_detect_intent_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+session}:detectIntent', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2DetectIntentRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_detect_intent_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2DetectIntentResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2DetectIntentResponse
  command.params['session'] = session unless session.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#export_project_agent(parent, google_cloud_dialogflow_v2_export_agent_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Exports the specified agent to a ZIP file. Operation

Parameters:

  • parent (String)

    Required. The project that the agent to export is associated with. Format: projects/.

  • google_cloud_dialogflow_v2_export_agent_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ExportAgentRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



171
172
173
174
175
176
177
178
179
180
181
# File 'generated/google/apis/dialogflow_v2/service.rb', line 171

def export_project_agent(parent, google_cloud_dialogflow_v2_export_agent_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/agent:export', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ExportAgentRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_export_agent_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_project_agent(parent, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Agent

Retrieves the specified agent.

Parameters:

  • parent (String)

    Required. The project that the agent to fetch is associated with. Format: projects/.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



103
104
105
106
107
108
109
110
111
# File 'generated/google/apis/dialogflow_v2/service.rb', line 103

def get_project_agent(parent, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+parent}/agent', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Agent::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Agent
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_project_agent_entity_type(name, language_code: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType

Retrieves the specified entity type.

Parameters:

  • name (String)

    Required. The name of the entity type. Format: projects//agent/entityTypes/.

  • language_code (String) (defaults to: nil)

    Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see Multilingual intent and entity data.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



609
610
611
612
613
614
615
616
617
618
# File 'generated/google/apis/dialogflow_v2/service.rb', line 609

def get_project_agent_entity_type(name, language_code: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType
  command.params['name'] = name unless name.nil?
  command.query['languageCode'] = language_code unless language_code.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_project_agent_environment_user_session_context(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context

Retrieves the specified context.

Parameters:

  • name (String)

    Required. The name of the context. Format: projects//agent/sessions//contexts/ or projects//agent/environments//users//sessions//contexts/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1022
1023
1024
1025
1026
1027
1028
1029
1030
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1022

def get_project_agent_environment_user_session_context(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_project_agent_environment_user_session_entity_type(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType

Retrieves the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.

Parameters:

  • name (String)

    Required. The name of the session entity type. Format: projects//agent/ sessions//entityTypes/ or projects//agent/environments//users//sessions// entityTypes/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1215
1216
1217
1218
1219
1220
1221
1222
1223
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1215

def get_project_agent_environment_user_session_entity_type(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_project_agent_fulfillment(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Fulfillment

Retrieves the fulfillment.

Parameters:

  • name (String)

    Required. The name of the fulfillment. Format: projects//agent/fulfillment.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



203
204
205
206
207
208
209
210
211
# File 'generated/google/apis/dialogflow_v2/service.rb', line 203

def get_project_agent_fulfillment(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Fulfillment::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Fulfillment
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_project_agent_intent(name, intent_view: nil, language_code: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent

Retrieves the specified intent.

Parameters:

  • name (String)

    Required. The name of the intent. Format: projects//agent/intents/.

  • intent_view (String) (defaults to: nil)

    Optional. The resource view to apply to the returned intent.

  • language_code (String) (defaults to: nil)

    Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see Multilingual intent and entity data.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1479

def get_project_agent_intent(name, intent_view: nil, language_code: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent
  command.params['name'] = name unless name.nil?
  command.query['intentView'] = intent_view unless intent_view.nil?
  command.query['languageCode'] = language_code unless language_code.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_project_agent_session_context(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context

Retrieves the specified context.

Parameters:

  • name (String)

    Required. The name of the context. Format: projects//agent/sessions//contexts/ or projects//agent/environments//users//sessions//contexts/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1758
1759
1760
1761
1762
1763
1764
1765
1766
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1758

def get_project_agent_session_context(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_project_agent_session_entity_type(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType

Retrieves the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.

Parameters:

  • name (String)

    Required. The name of the session entity type. Format: projects//agent/ sessions//entityTypes/ or projects//agent/environments//users//sessions// entityTypes/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1951
1952
1953
1954
1955
1956
1957
1958
1959
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1951

def get_project_agent_session_entity_type(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_project_agent_validation_result(parent, language_code: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ValidationResult

Gets agent validation result. Agent validation is performed during training time and is updated automatically when training is completed.

Parameters:

  • parent (String)

    Required. The project that the agent is associated with. Format: projects/.

  • language_code (String) (defaults to: nil)

    Optional. The language for which you want a validation result. If not specified, the agent's default language is used. Many languages are supported. Note: languages must be enabled in the agent before they can be used.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



239
240
241
242
243
244
245
246
247
248
# File 'generated/google/apis/dialogflow_v2/service.rb', line 239

def get_project_agent_validation_result(parent, language_code: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+parent}/agent/validationResult', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ValidationResult::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ValidationResult
  command.params['parent'] = parent unless parent.nil?
  command.query['languageCode'] = language_code unless language_code.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_project_location_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.

Parameters:

  • name (String)

    The name of the operation resource.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2104
2105
2106
2107
2108
2109
2110
2111
2112
# File 'generated/google/apis/dialogflow_v2/service.rb', line 2104

def get_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_project_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.

Parameters:

  • name (String)

    The name of the operation resource.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2218
2219
2220
2221
2222
2223
2224
2225
2226
# File 'generated/google/apis/dialogflow_v2/service.rb', line 2218

def get_project_operation(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+name}', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#import_project_agent(parent, google_cloud_dialogflow_v2_import_agent_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Imports the specified agent from a ZIP file. Uploads new intents and entity types without deleting the existing ones. Intents and entity types with the same name are replaced with the new versions from ImportAgentRequest. After the import, the imported draft agent will be trained automatically (unless disabled in agent settings). However, once the import is done, training may not be completed yet. Please call TrainAgent and wait for the operation it returns in order to train explicitly. Operation An operation which tracks when importing is complete. It only tracks when the draft agent is updated not when it is done training.

Parameters:

  • parent (String)

    Required. The project that the agent to import is associated with. Format: projects/.

  • google_cloud_dialogflow_v2_import_agent_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ImportAgentRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



280
281
282
283
284
285
286
287
288
289
290
# File 'generated/google/apis/dialogflow_v2/service.rb', line 280

def import_project_agent(parent, google_cloud_dialogflow_v2_import_agent_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/agent:import', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ImportAgentRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_import_agent_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_project_agent_entity_types(parent, language_code: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListEntityTypesResponse

Returns the list of all entity types in the specified agent.

Parameters:

  • parent (String)

    Required. The agent to list all entity types from. Format: projects//agent.

  • language_code (String) (defaults to: nil)

    Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see Multilingual intent and entity data.

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.

  • page_token (String) (defaults to: nil)

    Optional. The next_page_token value returned from a previous list request.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



650
651
652
653
654
655
656
657
658
659
660
661
# File 'generated/google/apis/dialogflow_v2/service.rb', line 650

def list_project_agent_entity_types(parent, language_code: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+parent}/entityTypes', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListEntityTypesResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListEntityTypesResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['languageCode'] = language_code unless language_code.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_project_agent_environment_user_session_contexts(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListContextsResponse

Returns the list of all contexts in the specified session.

Parameters:

  • parent (String)

    Required. The session to list all contexts from. Format: projects//agent/ sessions/ or projects//agent/environments//users//sessions/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.

  • page_token (String) (defaults to: nil)

    Optional. The next_page_token value returned from a previous list request.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1060

def list_project_agent_environment_user_session_contexts(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+parent}/contexts', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListContextsResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListContextsResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_project_agent_environment_user_session_entity_types(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListSessionEntityTypesResponse

Returns the list of all session entity types in the specified session. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.

Parameters:

  • parent (String)

    Required. The session to list all session entity types from. Format: projects/ /agent/sessions/ or projects//agent/environments//users// sessions/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.

  • page_token (String) (defaults to: nil)

    Optional. The next_page_token value returned from a previous list request.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1255

def list_project_agent_environment_user_session_entity_types(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+parent}/entityTypes', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListSessionEntityTypesResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListSessionEntityTypesResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_project_agent_environments(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListEnvironmentsResponse

Returns the list of all non-draft environments of the specified agent.

Parameters:

  • parent (String)

    Required. The agent to list all environments from. Format: projects//agent.

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.

  • page_token (String) (defaults to: nil)

    Optional. The next_page_token value returned from a previous list request.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



836
837
838
839
840
841
842
843
844
845
846
# File 'generated/google/apis/dialogflow_v2/service.rb', line 836

def list_project_agent_environments(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+parent}/environments', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListEnvironmentsResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListEnvironmentsResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_project_agent_intents(parent, intent_view: nil, language_code: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListIntentsResponse

Returns the list of all intents in the specified agent.

Parameters:

  • parent (String)

    Required. The agent to list all intents from. Format: projects//agent.

  • intent_view (String) (defaults to: nil)

    Optional. The resource view to apply to the returned intent.

  • language_code (String) (defaults to: nil)

    Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see Multilingual intent and entity data.

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.

  • page_token (String) (defaults to: nil)

    Optional. The next_page_token value returned from a previous list request.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1523

def list_project_agent_intents(parent, intent_view: nil, language_code: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+parent}/intents', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListIntentsResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListIntentsResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['intentView'] = intent_view unless intent_view.nil?
  command.query['languageCode'] = language_code unless language_code.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_project_agent_session_contexts(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListContextsResponse

Returns the list of all contexts in the specified session.

Parameters:

  • parent (String)

    Required. The session to list all contexts from. Format: projects//agent/ sessions/ or projects//agent/environments//users//sessions/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.

  • page_token (String) (defaults to: nil)

    Optional. The next_page_token value returned from a previous list request.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1796

def list_project_agent_session_contexts(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+parent}/contexts', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListContextsResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListContextsResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_project_agent_session_entity_types(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListSessionEntityTypesResponse

Returns the list of all session entity types in the specified session. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.

Parameters:

  • parent (String)

    Required. The session to list all session entity types from. Format: projects/ /agent/sessions/ or projects//agent/environments//users// sessions/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user.

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.

  • page_token (String) (defaults to: nil)

    Optional. The next_page_token value returned from a previous list request.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1991

def list_project_agent_session_entity_types(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+parent}/entityTypes', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListSessionEntityTypesResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2ListSessionEntityTypesResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_project_location_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningListOperationsResponse

Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns UNIMPLEMENTED. NOTE: the name binding allows API services to override the binding to use different resource name schemes, such as users/*/operations. To override the binding, API services can add a binding such as "/v1/name=users/*/operations" to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.

Parameters:

  • name (String)

    The name of the operation's parent resource.

  • filter (String) (defaults to: nil)

    The standard list filter.

  • page_size (Fixnum) (defaults to: nil)

    The standard list page size.

  • page_token (String) (defaults to: nil)

    The standard list page token.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
# File 'generated/google/apis/dialogflow_v2/service.rb', line 2147

def list_project_location_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+name}/operations', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningListOperationsResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningListOperationsResponse
  command.params['name'] = name unless name.nil?
  command.query['filter'] = filter unless filter.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_project_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningListOperationsResponse

Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns UNIMPLEMENTED. NOTE: the name binding allows API services to override the binding to use different resource name schemes, such as users/*/operations. To override the binding, API services can add a binding such as "/v1/name=users/*/operations" to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.

Parameters:

  • name (String)

    The name of the operation's parent resource.

  • filter (String) (defaults to: nil)

    The standard list filter.

  • page_size (Fixnum) (defaults to: nil)

    The standard list page size.

  • page_token (String) (defaults to: nil)

    The standard list page token.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
# File 'generated/google/apis/dialogflow_v2/service.rb', line 2261

def list_project_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+name}/operations', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningListOperationsResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningListOperationsResponse
  command.params['name'] = name unless name.nil?
  command.query['filter'] = filter unless filter.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#patch_project_agent_entity_type(name, google_cloud_dialogflow_v2_entity_type_object = nil, language_code: nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType

Updates the specified entity type.

Parameters:

  • name (String)

    The unique identifier of the entity type. Required for EntityTypes. UpdateEntityType and EntityTypes.BatchUpdateEntityTypes methods. Format: projects//agent/entityTypes/.

  • google_cloud_dialogflow_v2_entity_type_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType) (defaults to: nil)
  • language_code (String) (defaults to: nil)

    Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see Multilingual intent and entity data.

  • update_mask (String) (defaults to: nil)

    Optional. The mask to control which fields get updated.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



693
694
695
696
697
698
699
700
701
702
703
704
705
# File 'generated/google/apis/dialogflow_v2/service.rb', line 693

def patch_project_agent_entity_type(name, google_cloud_dialogflow_v2_entity_type_object = nil, language_code: nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v2/{+name}', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType::Representation
  command.request_object = google_cloud_dialogflow_v2_entity_type_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2EntityType
  command.params['name'] = name unless name.nil?
  command.query['languageCode'] = language_code unless language_code.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#patch_project_agent_environment_user_session_context(name, google_cloud_dialogflow_v2_context_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context

Updates the specified context.

Parameters:

  • name (String)

    Required. The unique identifier of the context. Format: projects//agent/ sessions//contexts/, or projects//agent/environments//users//sessions// contexts/. The Context ID is always converted to lowercase, may only contain characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user. The following context names are reserved for internal use by Dialogflow. You should not use these contexts or create contexts with these names: * __system_counters__ * * _id_dialog_context * *_dialog_params_size

  • google_cloud_dialogflow_v2_context_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Optional. The mask to control which fields get updated.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1103

def patch_project_agent_environment_user_session_context(name, google_cloud_dialogflow_v2_context_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v2/{+name}', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context::Representation
  command.request_object = google_cloud_dialogflow_v2_context_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context
  command.params['name'] = name unless name.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#patch_project_agent_environment_user_session_entity_type(name, google_cloud_dialogflow_v2_session_entity_type_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType

Updates the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.

Parameters:

  • name (String)

    Required. The unique identifier of this session entity type. Format: projects/ /agent/sessions//entityTypes/, or projects//agent/environments//users// sessions//entityTypes/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default ' -' user. `` must be the display name of an existing entity type in the same agent that will be overridden or supplemented.

  • google_cloud_dialogflow_v2_session_entity_type_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Optional. The mask to control which fields get updated.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1297

def patch_project_agent_environment_user_session_entity_type(name, google_cloud_dialogflow_v2_session_entity_type_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v2/{+name}', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType::Representation
  command.request_object = google_cloud_dialogflow_v2_session_entity_type_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType
  command.params['name'] = name unless name.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#patch_project_agent_intent(name, google_cloud_dialogflow_v2_intent_object = nil, intent_view: nil, language_code: nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent

Updates the specified intent.

Parameters:

  • name (String)

    Optional. The unique identifier of this intent. Required for Intents. UpdateIntent and Intents.BatchUpdateIntents methods. Format: projects//agent/ intents/.

  • google_cloud_dialogflow_v2_intent_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent) (defaults to: nil)
  • intent_view (String) (defaults to: nil)

    Optional. The resource view to apply to the returned intent.

  • language_code (String) (defaults to: nil)

    Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see Multilingual intent and entity data.

  • update_mask (String) (defaults to: nil)

    Optional. The mask to control which fields get updated.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1569

def patch_project_agent_intent(name, google_cloud_dialogflow_v2_intent_object = nil, intent_view: nil, language_code: nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v2/{+name}', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent::Representation
  command.request_object = google_cloud_dialogflow_v2_intent_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Intent
  command.params['name'] = name unless name.nil?
  command.query['intentView'] = intent_view unless intent_view.nil?
  command.query['languageCode'] = language_code unless language_code.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#patch_project_agent_session_context(name, google_cloud_dialogflow_v2_context_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context

Updates the specified context.

Parameters:

  • name (String)

    Required. The unique identifier of the context. Format: projects//agent/ sessions//contexts/, or projects//agent/environments//users//sessions// contexts/. The Context ID is always converted to lowercase, may only contain characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user. The following context names are reserved for internal use by Dialogflow. You should not use these contexts or create contexts with these names: * __system_counters__ * * _id_dialog_context * *_dialog_params_size

  • google_cloud_dialogflow_v2_context_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Optional. The mask to control which fields get updated.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
# File 'generated/google/apis/dialogflow_v2/service.rb', line 1839

def patch_project_agent_session_context(name, google_cloud_dialogflow_v2_context_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v2/{+name}', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context::Representation
  command.request_object = google_cloud_dialogflow_v2_context_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Context
  command.params['name'] = name unless name.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#patch_project_agent_session_entity_type(name, google_cloud_dialogflow_v2_session_entity_type_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType

Updates the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.

Parameters:

  • name (String)

    Required. The unique identifier of this session entity type. Format: projects/ /agent/sessions//entityTypes/, or projects//agent/environments//users// sessions//entityTypes/. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default ' -' user. `` must be the display name of an existing entity type in the same agent that will be overridden or supplemented.

  • google_cloud_dialogflow_v2_session_entity_type_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Optional. The mask to control which fields get updated.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
# File 'generated/google/apis/dialogflow_v2/service.rb', line 2033

def patch_project_agent_session_entity_type(name, google_cloud_dialogflow_v2_session_entity_type_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v2/{+name}', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType::Representation
  command.request_object = google_cloud_dialogflow_v2_session_entity_type_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SessionEntityType
  command.params['name'] = name unless name.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#restore_project_agent(parent, google_cloud_dialogflow_v2_restore_agent_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Restores the specified agent from a ZIP file. Replaces the current agent version with a new one. All the intents and entity types in the older version are deleted. After the restore, the restored draft agent will be trained automatically (unless disabled in agent settings). However, once the restore is done, training may not be completed yet. Please call TrainAgent and wait for the operation it returns in order to train explicitly. Operation An operation which tracks when restoring is complete. It only tracks when the draft agent is updated not when it is done training.

Parameters:

  • parent (String)

    Required. The project that the agent to restore is associated with. Format: projects/.

  • google_cloud_dialogflow_v2_restore_agent_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2RestoreAgentRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



321
322
323
324
325
326
327
328
329
330
331
# File 'generated/google/apis/dialogflow_v2/service.rb', line 321

def restore_project_agent(parent, google_cloud_dialogflow_v2_restore_agent_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/agent:restore', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2RestoreAgentRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_restore_agent_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#search_project_agents(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SearchAgentsResponse

Returns the list of agents. Since there is at most one conversational agent per project, this method is useful primarily for listing all agents across projects the caller has access to. One can achieve that with a wildcard project collection id "-". Refer to List Sub-Collections.

Parameters:

  • parent (String)

    Required. The project to list agents from. Format: projects/.

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.

  • page_token (String) (defaults to: nil)

    The next_page_token value returned from a previous list request.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



362
363
364
365
366
367
368
369
370
371
372
# File 'generated/google/apis/dialogflow_v2/service.rb', line 362

def search_project_agents(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v2/{+parent}/agent:search', options)
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SearchAgentsResponse::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2SearchAgentsResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#set_project_agent(parent, google_cloud_dialogflow_v2_agent_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Agent

Creates/updates the specified agent.

Parameters:

  • parent (String)

    Required. The project of this agent. Format: projects/.

  • google_cloud_dialogflow_v2_agent_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Agent) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Optional. The mask to control which fields get updated.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



136
137
138
139
140
141
142
143
144
145
146
147
# File 'generated/google/apis/dialogflow_v2/service.rb', line 136

def set_project_agent(parent, google_cloud_dialogflow_v2_agent_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/agent', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Agent::Representation
  command.request_object = google_cloud_dialogflow_v2_agent_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Agent::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Agent
  command.params['parent'] = parent unless parent.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#train_project_agent(parent, google_cloud_dialogflow_v2_train_agent_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleLongrunningOperation

Trains the specified agent. Operation

Parameters:

  • parent (String)

    Required. The project that the agent to train is associated with. Format: projects/.

  • google_cloud_dialogflow_v2_train_agent_request_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2TrainAgentRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



396
397
398
399
400
401
402
403
404
405
406
# File 'generated/google/apis/dialogflow_v2/service.rb', line 396

def train_project_agent(parent, google_cloud_dialogflow_v2_train_agent_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v2/{+parent}/agent:train', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2TrainAgentRequest::Representation
  command.request_object = google_cloud_dialogflow_v2_train_agent_request_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleLongrunningOperation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#update_project_agent_fulfillment(name, google_cloud_dialogflow_v2_fulfillment_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Fulfillment

Updates the fulfillment.

Parameters:

  • name (String)

    Required. The unique identifier of the fulfillment. Format: projects//agent/ fulfillment.

  • google_cloud_dialogflow_v2_fulfillment_object (Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Fulfillment) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Required. The mask to control which fields get updated. If the mask is not present, all fields will be updated.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



433
434
435
436
437
438
439
440
441
442
443
444
# File 'generated/google/apis/dialogflow_v2/service.rb', line 433

def update_project_agent_fulfillment(name, google_cloud_dialogflow_v2_fulfillment_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v2/{+name}', options)
  command.request_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Fulfillment::Representation
  command.request_object = google_cloud_dialogflow_v2_fulfillment_object
  command.response_representation = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Fulfillment::Representation
  command.response_class = Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Fulfillment
  command.params['name'] = name unless name.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end