Reference documentation and code samples for the Dialogflow CX V3 API class Google::Cloud::Dialogflow::CX::V3::Deployments::Client.
Client for the Deployments service.
Service for managing Deployments.
Inherits
- Object
Methods
.configure
def self.configure() { |config| ... } -> Client::ConfigurationConfigure the Deployments Client class.
See Configuration for a description of the configuration fields.
- (config) — Configure the Client client.
- config (Client::Configuration)
# Modify the configuration for all Deployments clients ::Google::Cloud::Dialogflow::CX::V3::Deployments::Client.configure do |config| config.timeout = 10.0 end
#configure
def configure() { |config| ... } -> Client::ConfigurationConfigure the Deployments 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)
#get_deployment
def get_deployment(request, options = nil) -> ::Google::Cloud::Dialogflow::CX::V3::Deployment
def get_deployment(name: nil) -> ::Google::Cloud::Dialogflow::CX::V3::DeploymentRetrieves the specified Deployment.
def get_deployment(request, options = nil) -> ::Google::Cloud::Dialogflow::CX::V3::Deploymentget_deployment via a request object, either of type
GetDeploymentRequest or an equivalent Hash.
- request (::Google::Cloud::Dialogflow::CX::V3::GetDeploymentRequest, ::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_deployment(name: nil) -> ::Google::Cloud::Dialogflow::CX::V3::Deploymentget_deployment 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
Deployment. Format:
projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>/deployments/<Deployment ID>.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::Dialogflow::CX::V3::Deployment)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC 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::Deployments::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::Dialogflow::CX::V3::GetDeploymentRequest.new # Call the get_deployment method. result = client.get_deployment request # The returned object is of type Google::Cloud::Dialogflow::CX::V3::Deployment. p result
#initialize
def initialize() { |config| ... } -> ClientCreate a new Deployments client object.
- (config) — Configure the Deployments client.
- config (Client::Configuration)
- (Client) — a new instance of Client
# Create a client using the default configuration client = ::Google::Cloud::Dialogflow::CX::V3::Deployments::Client.new # Create a client using a custom configuration client = ::Google::Cloud::Dialogflow::CX::V3::Deployments::Client.new do |config| config.timeout = 10.0 end
#list_deployments
def list_deployments(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::Deployment>
def list_deployments(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::Deployment>Returns the list of all deployments in the specified Environment.
def list_deployments(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::Deployment>list_deployments via a request object, either of type
ListDeploymentsRequest or an equivalent Hash.
- request (::Google::Cloud::Dialogflow::CX::V3::ListDeploymentsRequest, ::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_deployments(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::Deployment>list_deployments 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 Environment to
list all environments for. Format:
projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>. - page_size (::Integer) — The maximum number of items to return in a single page. By default 20 and at most 100.
- page_token (::String) — The next_page_token value returned from a previous list request.
- (response, operation) — Access the result along with the RPC operation
- response (::Gapic::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::Deployment>)
- operation (::GRPC::ActiveCall::Operation)
- (::Gapic::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::Deployment>)
- (::Google::Cloud::Error) — if the RPC 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::Deployments::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::Dialogflow::CX::V3::ListDeploymentsRequest.new # Call the list_deployments method. result = client.list_deployments 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::Deployment. p item end
#location_client
def location_client() -> Google::Cloud::Location::Locations::ClientGet the associated client for mix-in of the Locations.
- (Google::Cloud::Location::Locations::Client)