generated/google/apis/dialogflow_v2beta1/service.rb in google-api-client-0.30.2 vs generated/google/apis/dialogflow_v2beta1/service.rb in google-api-client-0.30.3

- old
+ new

@@ -29,11 +29,11 @@ # require 'google/apis/dialogflow_v2beta1' # # Dialogflow = Google::Apis::DialogflowV2beta1 # Alias the module # service = Dialogflow::DialogflowService.new # - # @see https://cloud.google.com/dialogflow-enterprise/ + # @see https://cloud.google.com/dialogflow/ class DialogflowService < Google::Apis::Core::BaseService # @return [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. attr_accessor :key @@ -46,10 +46,78 @@ def initialize super('https://dialogflow.googleapis.com/', '') @batch_path = 'batch' end + # Creates/updates the specified agent. + # @param [String] parent + # Required. The project of this agent. + # Format: `projects/<Project ID>`. + # @param [Google::Apis::DialogflowV2beta1::GoogleCloudDialogflowV2beta1Agent] google_cloud_dialogflow_v2beta1_agent_object + # @param [String] update_mask + # Optional. The mask to control which fields get updated. + # @param [String] fields + # Selector specifying which fields to include in a partial response. + # @param [String] quota_user + # 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. + # @param [Google::Apis::RequestOptions] options + # Request-specific options + # + # @yield [result, err] Result & error if block supplied + # @yieldparam result [Google::Apis::DialogflowV2beta1::GoogleCloudDialogflowV2beta1Agent] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::DialogflowV2beta1::GoogleCloudDialogflowV2beta1Agent] + # + # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried + # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification + # @raise [Google::Apis::AuthorizationError] Authorization is required + def agent_project(parent, google_cloud_dialogflow_v2beta1_agent_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'v2beta1/{+parent}/agent', options) + command.request_representation = Google::Apis::DialogflowV2beta1::GoogleCloudDialogflowV2beta1Agent::Representation + command.request_object = google_cloud_dialogflow_v2beta1_agent_object + command.response_representation = Google::Apis::DialogflowV2beta1::GoogleCloudDialogflowV2beta1Agent::Representation + command.response_class = Google::Apis::DialogflowV2beta1::GoogleCloudDialogflowV2beta1Agent + 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 + + # Deletes the specified agent. + # @param [String] parent + # Required. The project that the agent to delete is associated with. + # Format: `projects/<Project ID>`. + # @param [String] fields + # Selector specifying which fields to include in a partial response. + # @param [String] quota_user + # 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. + # @param [Google::Apis::RequestOptions] options + # Request-specific options + # + # @yield [result, err] Result & error if block supplied + # @yieldparam result [Google::Apis::DialogflowV2beta1::GoogleProtobufEmpty] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::DialogflowV2beta1::GoogleProtobufEmpty] + # + # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried + # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification + # @raise [Google::Apis::AuthorizationError] Authorization is required + def delete_project_agent(parent, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:delete, 'v2beta1/{+parent}/agent', options) + command.response_representation = Google::Apis::DialogflowV2beta1::GoogleProtobufEmpty::Representation + command.response_class = Google::Apis::DialogflowV2beta1::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 + # Retrieves the specified agent. # @param [String] parent # Required. The project that the agent to fetch is associated with. # Format: `projects/<Project ID>`. # @param [String] fields @@ -345,12 +413,11 @@ # @param [Google::Apis::DialogflowV2beta1::GoogleCloudDialogflowV2beta1EntityType] google_cloud_dialogflow_v2beta1_entity_type_object # @param [String] language_code # Optional. The language of entity synonyms defined in `entity_type`. If not # specified, the agent's default language is used. # [Many - # languages](https://cloud.google.com/dialogflow-enterprise/docs/reference/ - # language) + # languages](https://cloud.google.com/dialogflow/docs/reference/language) # are supported. Note: languages must be enabled in the agent before they can # be used. # @param [String] fields # Selector specifying which fields to include in a partial response. # @param [String] quota_user @@ -418,12 +485,11 @@ # Format: `projects/<Project ID>/agent/entityTypes/<EntityType ID>`. # @param [String] language_code # Optional. The language to retrieve entity synonyms for. If not specified, # the agent's default language is used. # [Many - # languages](https://cloud.google.com/dialogflow-enterprise/docs/reference/ - # language) + # languages](https://cloud.google.com/dialogflow/docs/reference/language) # are supported. Note: languages must be enabled in the agent before they can # be used. # @param [String] fields # Selector specifying which fields to include in a partial response. # @param [String] quota_user @@ -458,12 +524,11 @@ # Format: `projects/<Project ID>/agent`. # @param [String] language_code # Optional. The language to list entity synonyms for. If not specified, # the agent's default language is used. # [Many - # languages](https://cloud.google.com/dialogflow-enterprise/docs/reference/ - # language) + # languages](https://cloud.google.com/dialogflow/docs/reference/language) # are supported. Note: languages must be enabled in the agent before they can # be used. # @param [Fixnum] page_size # Optional. The maximum number of items to return in a single page. By # default 100 and at most 1000. @@ -508,12 +573,11 @@ # @param [Google::Apis::DialogflowV2beta1::GoogleCloudDialogflowV2beta1EntityType] google_cloud_dialogflow_v2beta1_entity_type_object # @param [String] language_code # Optional. The language of entity synonyms defined in `entity_type`. If not # specified, the agent's default language is used. # [Many - # languages](https://cloud.google.com/dialogflow-enterprise/docs/reference/ - # language) + # languages](https://cloud.google.com/dialogflow/docs/reference/language) # are supported. Note: languages must be enabled in the agent before they can # be used. # @param [String] update_mask # Optional. The mask to control which fields get updated. # @param [String] fields @@ -696,11 +760,11 @@ # Required. The name of the session this query is sent to. Format: # `projects/<Project ID>/agent/sessions/<Session ID>`, or # `projects/<Project ID>/agent/environments/<Environment ID>/users/<User # ID>/sessions/<Session ID>`. 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 + # "-". It's up to the API caller to choose an appropriate `Session ID` and # `User Id`. They can be a random numbers or some type of user and session # identifiers (preferably hashed). The length of the `Session ID` and # `User ID` must not exceed 36 characters. # @param [Google::Apis::DialogflowV2beta1::GoogleCloudDialogflowV2beta1DetectIntentRequest] google_cloud_dialogflow_v2beta1_detect_intent_request_object # @param [String] fields @@ -1201,12 +1265,11 @@ # Optional. The resource view to apply to the returned intent. # @param [String] language_code # Optional. The language of training phrases, parameters and rich messages # defined in `intent`. If not specified, the agent's default language is # used. [Many - # languages](https://cloud.google.com/dialogflow-enterprise/docs/reference/ - # language) + # languages](https://cloud.google.com/dialogflow/docs/reference/language) # are supported. Note: languages must be enabled in the agent before they can # be used. # @param [String] fields # Selector specifying which fields to include in a partial response. # @param [String] quota_user @@ -1278,12 +1341,11 @@ # Optional. The resource view to apply to the returned intent. # @param [String] language_code # Optional. The language to retrieve training phrases, parameters and rich # messages for. If not specified, the agent's default language is used. # [Many - # languages](https://cloud.google.com/dialogflow-enterprise/docs/reference/ - # language) + # languages](https://cloud.google.com/dialogflow/docs/reference/language) # are supported. Note: languages must be enabled in the agent before they can # be used. # @param [String] fields # Selector specifying which fields to include in a partial response. # @param [String] quota_user @@ -1321,12 +1383,11 @@ # Optional. The resource view to apply to the returned intent. # @param [String] language_code # Optional. The language to list training phrases, parameters and rich # messages for. If not specified, the agent's default language is used. # [Many - # languages](https://cloud.google.com/dialogflow-enterprise/docs/reference/ - # language) + # languages](https://cloud.google.com/dialogflow/docs/reference/language) # are supported. Note: languages must be enabled in the agent before they can # be used. # @param [Fixnum] page_size # Optional. The maximum number of items to return in a single page. By # default 100 and at most 1000. @@ -1374,12 +1435,11 @@ # Optional. The resource view to apply to the returned intent. # @param [String] language_code # Optional. The language of training phrases, parameters and rich messages # defined in `intent`. If not specified, the agent's default language is # used. [Many - # languages](https://cloud.google.com/dialogflow-enterprise/docs/reference/ - # language) + # languages](https://cloud.google.com/dialogflow/docs/reference/language) # are supported. Note: languages must be enabled in the agent before they can # be used. # @param [String] update_mask # Optional. The mask to control which fields get updated. # @param [String] fields @@ -1879,10 +1939,10 @@ # Required. The name of the session this query is sent to. Format: # `projects/<Project ID>/agent/sessions/<Session ID>`, or # `projects/<Project ID>/agent/environments/<Environment ID>/users/<User # ID>/sessions/<Session ID>`. 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 + # "-". It's up to the API caller to choose an appropriate `Session ID` and # `User Id`. They can be a random numbers or some type of user and session # identifiers (preferably hashed). The length of the `Session ID` and # `User ID` must not exceed 36 characters. # @param [Google::Apis::DialogflowV2beta1::GoogleCloudDialogflowV2beta1DetectIntentRequest] google_cloud_dialogflow_v2beta1_detect_intent_request_object # @param [String] fields