Reference documentation and code samples for the Data Analytics API with Gemini V1BETA API class Google::Cloud::GeminiDataAnalytics::V1beta::DataA2AService::Client.
Client for the DataA2AService service.
DataA2AService defines the Agent-to-Agent (A2A) protocol service for Gemini Data Analytics.
Inherits
- Object
Methods
.configure
def self.configure() { |config| ... } -> Client::ConfigurationConfigure the DataA2AService Client class.
See Configuration for a description of the configuration fields.
- (config) — Configure the Client client.
- config (Client::Configuration)
# Modify the configuration for all DataA2AService clients ::Google::Cloud::GeminiDataAnalytics::V1beta::DataA2AService::Client.configure do |config| config.timeout = 10.0 end
#configure
def configure() { |config| ... } -> Client::ConfigurationConfigure the DataA2AService 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_agent_card
def get_agent_card(request, options = nil) -> ::Google::Cloud::GeminiDataAnalytics::V1beta::AgentCard
def get_agent_card(tenant: nil) -> ::Google::Cloud::GeminiDataAnalytics::V1beta::AgentCardGetAgentCard returns the agent card for the agent.
def get_agent_card(request, options = nil) -> ::Google::Cloud::GeminiDataAnalytics::V1beta::AgentCardget_agent_card via a request object, either of type
GetAgentCardRequest or an equivalent Hash.
- request (::Google::Cloud::GeminiDataAnalytics::V1beta::GetAgentCardRequest, ::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_agent_card(tenant: nil) -> ::Google::Cloud::GeminiDataAnalytics::V1beta::AgentCardget_agent_card 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).
- tenant (::String) — Optional. Optional tenant, provided as a path parameter.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::GeminiDataAnalytics::V1beta::AgentCard)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/gemini_data_analytics/v1beta" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::GeminiDataAnalytics::V1beta::DataA2AService::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::GeminiDataAnalytics::V1beta::GetAgentCardRequest.new # Call the get_agent_card method. result = client.get_agent_card request # The returned object is of type Google::Cloud::GeminiDataAnalytics::V1beta::AgentCard. p result
#initialize
def initialize() { |config| ... } -> ClientCreate a new DataA2AService client object.
- (config) — Configure the DataA2AService client.
- config (Client::Configuration)
- (Client) — a new instance of Client
# Create a client using the default configuration client = ::Google::Cloud::GeminiDataAnalytics::V1beta::DataA2AService::Client.new # Create a client using a custom configuration client = ::Google::Cloud::GeminiDataAnalytics::V1beta::DataA2AService::Client.new do |config| config.timeout = 10.0 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)
#logger
def logger() -> LoggerThe logger used for request/response debug logging.
- (Logger)
#send_message
def send_message(request, options = nil) -> ::Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageResponse
def send_message(message: nil, configuration: nil, metadata: nil, tenant: nil) -> ::Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageResponseSend a message to the agent. This is a blocking call that will return the task once it is completed.
def send_message(request, options = nil) -> ::Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageResponsesend_message via a request object, either of type
SendMessageRequest or an equivalent Hash.
- request (::Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageRequest, ::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 send_message(message: nil, configuration: nil, metadata: nil, tenant: nil) -> ::Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageResponsesend_message 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).
- message (::Google::Cloud::GeminiDataAnalytics::V1beta::A2AMessage, ::Hash) — Required. The message to send to the agent.
- configuration (::Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageConfiguration, ::Hash) — Optional. Configuration for the send request.
- metadata (::Google::Protobuf::Struct, ::Hash) — Optional. Optional metadata for the request.
- tenant (::String) — Optional. Optional tenant, provided as a path parameter.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageResponse)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/gemini_data_analytics/v1beta" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::GeminiDataAnalytics::V1beta::DataA2AService::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageRequest.new # Call the send_message method. result = client.send_message request # The returned object is of type Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageResponse. p result
#send_streaming_message
def send_streaming_message(request, options = nil) -> ::Enumerable<::Google::Cloud::GeminiDataAnalytics::V1beta::StreamResponse>
def send_streaming_message(message: nil, configuration: nil, metadata: nil, tenant: nil) -> ::Enumerable<::Google::Cloud::GeminiDataAnalytics::V1beta::StreamResponse>SendStreamingMessage is a streaming call that will return a stream of task update events until the Task is in an interrupted or terminal state.
def send_streaming_message(request, options = nil) -> ::Enumerable<::Google::Cloud::GeminiDataAnalytics::V1beta::StreamResponse>send_streaming_message via a request object, either of type
SendMessageRequest or an equivalent Hash.
- request (::Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageRequest, ::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 send_streaming_message(message: nil, configuration: nil, metadata: nil, tenant: nil) -> ::Enumerable<::Google::Cloud::GeminiDataAnalytics::V1beta::StreamResponse>send_streaming_message 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).
- message (::Google::Cloud::GeminiDataAnalytics::V1beta::A2AMessage, ::Hash) — Required. The message to send to the agent.
- configuration (::Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageConfiguration, ::Hash) — Optional. Configuration for the send request.
- metadata (::Google::Protobuf::Struct, ::Hash) — Optional. Optional metadata for the request.
- tenant (::String) — Optional. Optional tenant, provided as a path parameter.
- (response, operation) — Access the result along with the RPC operation
- response (::Enumerable<::Google::Cloud::GeminiDataAnalytics::V1beta::StreamResponse>)
- operation (::GRPC::ActiveCall::Operation)
- (::Enumerable<::Google::Cloud::GeminiDataAnalytics::V1beta::StreamResponse>)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/gemini_data_analytics/v1beta" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::GeminiDataAnalytics::V1beta::DataA2AService::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::GeminiDataAnalytics::V1beta::SendMessageRequest.new # Call the send_streaming_message method to start streaming. output = client.send_streaming_message request # The returned object is a streamed enumerable yielding elements of type # ::Google::Cloud::GeminiDataAnalytics::V1beta::StreamResponse output.each do |current_response| p current_response end
#universe_domain
def universe_domain() -> StringThe effective universe domain
- (String)