Reference documentation and code samples for the Dialogflow CX V3 API class Google::Cloud::Dialogflow::CX::V3::SessionEntityTypes::Rest::Client.
REST client for the SessionEntityTypes service.
Service for managing SessionEntityTypes.
Inherits
- Object
Methods
.configure
def self.configure() { |config| ... } -> Client::Configuration
Configure the SessionEntityTypes Client class.
See Configuration for a description of the configuration fields.
- (config) — Configure the Client client.
- config (Client::Configuration)
# Modify the configuration for all SessionEntityTypes clients ::Google::Cloud::Dialogflow::CX::V3::SessionEntityTypes::Rest::Client.configure do |config| config.timeout = 10.0 end
#configure
def configure() { |config| ... } -> Client::Configuration
Configure the SessionEntityTypes Client instance.
The configuration is set to the derived mode, meaning that values can be changed, but structural changes (adding new fields, etc.) are not allowed. Structural changes should be made on Client.configure.
See Configuration for a description of the configuration fields.
- (config) — Configure the Client client.
- config (Client::Configuration)
#create_session_entity_type
def create_session_entity_type(request, options = nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
def create_session_entity_type(parent: nil, session_entity_type: nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
Creates a session entity type.
def create_session_entity_type(request, options = nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
create_session_entity_type
via a request object, either of type
CreateSessionEntityTypeRequest or an equivalent Hash.
- request (::Google::Cloud::Dialogflow::CX::V3::CreateSessionEntityTypeRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
def create_session_entity_type(parent: nil, session_entity_type: nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
create_session_entity_type
via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The session to create a session entity type for.
Format:
projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/sessions/<Session ID>
orprojects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>/sessions/<Session ID>
. IfEnvironment ID
is not specified, we assume default 'draft' environment. - session_entity_type (::Google::Cloud::Dialogflow::CX::V3::SessionEntityType, ::Hash) — Required. The session entity type to create.
- (result, operation) — Access the result along with the TransportOperation object
- result (::Google::Cloud::Dialogflow::CX::V3::SessionEntityType)
- operation (::Gapic::Rest::TransportOperation)
- (::Google::Cloud::Error) — if the REST call is aborted.
Basic example
require "google/cloud/dialogflow/cx/v3" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::Dialogflow::CX::V3::SessionEntityTypes::Rest::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::Dialogflow::CX::V3::CreateSessionEntityTypeRequest.new # Call the create_session_entity_type method. result = client.create_session_entity_type request # The returned object is of type Google::Cloud::Dialogflow::CX::V3::SessionEntityType. p result
#delete_session_entity_type
def delete_session_entity_type(request, options = nil) -> ::Google::Protobuf::Empty
def delete_session_entity_type(name: nil) -> ::Google::Protobuf::Empty
Deletes the specified session entity type.
def delete_session_entity_type(request, options = nil) -> ::Google::Protobuf::Empty
delete_session_entity_type
via a request object, either of type
DeleteSessionEntityTypeRequest or an equivalent Hash.
- request (::Google::Cloud::Dialogflow::CX::V3::DeleteSessionEntityTypeRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
def delete_session_entity_type(name: nil) -> ::Google::Protobuf::Empty
delete_session_entity_type
via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
name (::String) — Required. The name of the session entity type to delete.
Format:
projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/sessions/<Session ID>/entityTypes/<Entity Type ID>
orprojects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>/sessions/<Session ID>/entityTypes/<Entity Type ID>
. IfEnvironment ID
is not specified, we assume default 'draft' environment.
- (result, operation) — Access the result along with the TransportOperation object
- result (::Google::Protobuf::Empty)
- operation (::Gapic::Rest::TransportOperation)
- (::Google::Cloud::Error) — if the REST call is aborted.
Basic example
require "google/cloud/dialogflow/cx/v3" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::Dialogflow::CX::V3::SessionEntityTypes::Rest::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::Dialogflow::CX::V3::DeleteSessionEntityTypeRequest.new # Call the delete_session_entity_type method. result = client.delete_session_entity_type request # The returned object is of type Google::Protobuf::Empty. p result
#get_session_entity_type
def get_session_entity_type(request, options = nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
def get_session_entity_type(name: nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
Retrieves the specified session entity type.
def get_session_entity_type(request, options = nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
get_session_entity_type
via a request object, either of type
GetSessionEntityTypeRequest or an equivalent Hash.
- request (::Google::Cloud::Dialogflow::CX::V3::GetSessionEntityTypeRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
def get_session_entity_type(name: nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
get_session_entity_type
via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
name (::String) — Required. The name of the session entity type.
Format:
projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/sessions/<Session ID>/entityTypes/<Entity Type ID>
orprojects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>/sessions/<Session ID>/entityTypes/<Entity Type ID>
. IfEnvironment ID
is not specified, we assume default 'draft' environment.
- (result, operation) — Access the result along with the TransportOperation object
- result (::Google::Cloud::Dialogflow::CX::V3::SessionEntityType)
- operation (::Gapic::Rest::TransportOperation)
- (::Google::Cloud::Error) — if the REST call is aborted.
Basic example
require "google/cloud/dialogflow/cx/v3" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::Dialogflow::CX::V3::SessionEntityTypes::Rest::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::Dialogflow::CX::V3::GetSessionEntityTypeRequest.new # Call the get_session_entity_type method. result = client.get_session_entity_type request # The returned object is of type Google::Cloud::Dialogflow::CX::V3::SessionEntityType. p result
#initialize
def initialize() { |config| ... } -> Client
Create a new SessionEntityTypes REST client object.
- (config) — Configure the SessionEntityTypes client.
- config (Client::Configuration)
- (Client) — a new instance of Client
# Create a client using the default configuration client = ::Google::Cloud::Dialogflow::CX::V3::SessionEntityTypes::Rest::Client.new # Create a client using a custom configuration client = ::Google::Cloud::Dialogflow::CX::V3::SessionEntityTypes::Rest::Client.new do |config| config.timeout = 10.0 end
#list_session_entity_types
def list_session_entity_types(request, options = nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::SessionEntityType>
def list_session_entity_types(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::SessionEntityType>
Returns the list of all session entity types in the specified session.
def list_session_entity_types(request, options = nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::SessionEntityType>
list_session_entity_types
via a request object, either of type
ListSessionEntityTypesRequest or an equivalent Hash.
- request (::Google::Cloud::Dialogflow::CX::V3::ListSessionEntityTypesRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
def list_session_entity_types(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::SessionEntityType>
list_session_entity_types
via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The session to list all session entity types from.
Format:
projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/sessions/<Session ID>
orprojects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>/sessions/<Session ID>
. IfEnvironment ID
is not specified, we assume default 'draft' environment. - page_size (::Integer) — The maximum number of items to return in a single page. By default 100 and at most 1000.
- page_token (::String) — The next_page_token value returned from a previous list request.
- (result, operation) — Access the result along with the TransportOperation object
- result (::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::SessionEntityType>)
- operation (::Gapic::Rest::TransportOperation)
- (::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::SessionEntityType>)
- (::Google::Cloud::Error) — if the REST call is aborted.
Basic example
require "google/cloud/dialogflow/cx/v3" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::Dialogflow::CX::V3::SessionEntityTypes::Rest::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::Dialogflow::CX::V3::ListSessionEntityTypesRequest.new # Call the list_session_entity_types method. result = client.list_session_entity_types request # The returned object is of type Gapic::PagedEnumerable. You can iterate # over elements, and API calls will be issued to fetch pages as needed. result.each do |item| # Each element is of type ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType. p item end
#location_client
def location_client() -> Google::Cloud::Location::Locations::Rest::Client
Get the associated client for mix-in of the Locations.
- (Google::Cloud::Location::Locations::Rest::Client)
#universe_domain
def universe_domain() -> String
The effective universe domain
- (String)
#update_session_entity_type
def update_session_entity_type(request, options = nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
def update_session_entity_type(session_entity_type: nil, update_mask: nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
Updates the specified session entity type.
def update_session_entity_type(request, options = nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
update_session_entity_type
via a request object, either of type
UpdateSessionEntityTypeRequest or an equivalent Hash.
- request (::Google::Cloud::Dialogflow::CX::V3::UpdateSessionEntityTypeRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
def update_session_entity_type(session_entity_type: nil, update_mask: nil) -> ::Google::Cloud::Dialogflow::CX::V3::SessionEntityType
update_session_entity_type
via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
session_entity_type (::Google::Cloud::Dialogflow::CX::V3::SessionEntityType, ::Hash) — Required. The session entity type to update.
Format:
projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/sessions/<Session ID>/entityTypes/<Entity Type ID>
orprojects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>/sessions/<Session ID>/entityTypes/<Entity Type ID>
. IfEnvironment ID
is not specified, we assume default 'draft' environment. - update_mask (::Google::Protobuf::FieldMask, ::Hash) — The mask to control which fields get updated.
- (result, operation) — Access the result along with the TransportOperation object
- result (::Google::Cloud::Dialogflow::CX::V3::SessionEntityType)
- operation (::Gapic::Rest::TransportOperation)
- (::Google::Cloud::Error) — if the REST call is aborted.
Basic example
require "google/cloud/dialogflow/cx/v3" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::Dialogflow::CX::V3::SessionEntityTypes::Rest::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::Dialogflow::CX::V3::UpdateSessionEntityTypeRequest.new # Call the update_session_entity_type method. result = client.update_session_entity_type request # The returned object is of type Google::Cloud::Dialogflow::CX::V3::SessionEntityType. p result