public class AgentsClient : ClientBase<Agents.AgentsClient>
Client for Agents
Namespace
Google.Cloud.Dialogflow.V2Assembly
Google.Cloud.Dialogflow.V2.dll
Constructors
AgentsClient()
protected AgentsClient()
Protected parameterless constructor to allow creation of test doubles.
AgentsClient(CallInvoker)
public AgentsClient(CallInvoker callInvoker)
Creates a new client for Agents that uses a custom CallInvoker
.
Parameter | |
---|---|
Name | Description |
callInvoker | CallInvoker The callInvoker to use to make remote calls. |
AgentsClient(Channel)
[Obsolete("This constructor overload is present for compatibility only, and will be removed in the next major version")]
public AgentsClient(Channel channel)
Creates a new client using a channel.
Parameter | |
---|---|
Name | Description |
channel | Grpc.Core.Channel The channel to use to make remote calls. |
AgentsClient(ChannelBase)
public AgentsClient(ChannelBase channel)
Creates a new client for Agents
Parameter | |
---|---|
Name | Description |
channel | ChannelBase The channel to use to make remote calls. |
AgentsClient(ClientBase.ClientBaseConfiguration)
protected AgentsClient(ClientBase.ClientBaseConfiguration configuration)
Protected constructor to allow creation of configured clients.
Parameter | |
---|---|
Name | Description |
configuration | ClientBase.ClientBaseConfiguration The client configuration. |
Methods
CreateOperationsClient()
public virtual Operations.OperationsClient CreateOperationsClient()
Creates a new instance of Operations.OperationsClient using the same call invoker as this client.
Returns | |
---|---|
Type | Description |
Operations.OperationsClient | A new Operations client for the same target as this client. |
DeleteAgent(DeleteAgentRequest, CallOptions)
public virtual Empty DeleteAgent(DeleteAgentRequest request, CallOptions options)
Deletes the specified agent.
Parameters | |
---|---|
Name | Description |
request | DeleteAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Empty | The response received from the server. |
DeleteAgent(DeleteAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Empty DeleteAgent(DeleteAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Deletes the specified agent.
Parameters | |
---|---|
Name | Description |
request | DeleteAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Empty | The response received from the server. |
DeleteAgentAsync(DeleteAgentRequest, CallOptions)
public virtual AsyncUnaryCall<Empty> DeleteAgentAsync(DeleteAgentRequest request, CallOptions options)
Deletes the specified agent.
Parameters | |
---|---|
Name | Description |
request | DeleteAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Empty> | The call object. |
DeleteAgentAsync(DeleteAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Empty> DeleteAgentAsync(DeleteAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Deletes the specified agent.
Parameters | |
---|---|
Name | Description |
request | DeleteAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Empty> | The call object. |
ExportAgent(ExportAgentRequest, CallOptions)
public virtual Operation ExportAgent(ExportAgentRequest request, CallOptions options)
Exports the specified agent to a ZIP file.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: [ExportAgentResponse][google.cloud.dialogflow.v2.ExportAgentResponse]
Parameters | |
---|---|
Name | Description |
request | ExportAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
ExportAgent(ExportAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Operation ExportAgent(ExportAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Exports the specified agent to a ZIP file.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: [ExportAgentResponse][google.cloud.dialogflow.v2.ExportAgentResponse]
Parameters | |
---|---|
Name | Description |
request | ExportAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
ExportAgentAsync(ExportAgentRequest, CallOptions)
public virtual AsyncUnaryCall<Operation> ExportAgentAsync(ExportAgentRequest request, CallOptions options)
Exports the specified agent to a ZIP file.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: [ExportAgentResponse][google.cloud.dialogflow.v2.ExportAgentResponse]
Parameters | |
---|---|
Name | Description |
request | ExportAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
ExportAgentAsync(ExportAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Operation> ExportAgentAsync(ExportAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Exports the specified agent to a ZIP file.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: [ExportAgentResponse][google.cloud.dialogflow.v2.ExportAgentResponse]
Parameters | |
---|---|
Name | Description |
request | ExportAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
GetAgent(GetAgentRequest, CallOptions)
public virtual Agent GetAgent(GetAgentRequest request, CallOptions options)
Retrieves the specified agent.
Parameters | |
---|---|
Name | Description |
request | GetAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Agent | The response received from the server. |
GetAgent(GetAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Agent GetAgent(GetAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Retrieves the specified agent.
Parameters | |
---|---|
Name | Description |
request | GetAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Agent | The response received from the server. |
GetAgentAsync(GetAgentRequest, CallOptions)
public virtual AsyncUnaryCall<Agent> GetAgentAsync(GetAgentRequest request, CallOptions options)
Retrieves the specified agent.
Parameters | |
---|---|
Name | Description |
request | GetAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Agent> | The call object. |
GetAgentAsync(GetAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Agent> GetAgentAsync(GetAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Retrieves the specified agent.
Parameters | |
---|---|
Name | Description |
request | GetAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Agent> | The call object. |
GetValidationResult(GetValidationResultRequest, CallOptions)
public virtual ValidationResult GetValidationResult(GetValidationResultRequest request, CallOptions options)
Gets agent validation result. Agent validation is performed during training time and is updated automatically when training is completed.
Parameters | |
---|---|
Name | Description |
request | GetValidationResultRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
ValidationResult | The response received from the server. |
GetValidationResult(GetValidationResultRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual ValidationResult GetValidationResult(GetValidationResultRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Gets agent validation result. Agent validation is performed during training time and is updated automatically when training is completed.
Parameters | |
---|---|
Name | Description |
request | GetValidationResultRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
ValidationResult | The response received from the server. |
GetValidationResultAsync(GetValidationResultRequest, CallOptions)
public virtual AsyncUnaryCall<ValidationResult> GetValidationResultAsync(GetValidationResultRequest request, CallOptions options)
Gets agent validation result. Agent validation is performed during training time and is updated automatically when training is completed.
Parameters | |
---|---|
Name | Description |
request | GetValidationResultRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<ValidationResult> | The call object. |
GetValidationResultAsync(GetValidationResultRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<ValidationResult> GetValidationResultAsync(GetValidationResultRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Gets agent validation result. Agent validation is performed during training time and is updated automatically when training is completed.
Parameters | |
---|---|
Name | Description |
request | GetValidationResultRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<ValidationResult> | The call object. |
ImportAgent(ImportAgentRequest, CallOptions)
public virtual Operation ImportAgent(ImportAgentRequest request, CallOptions options)
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][google.cloud.dialogflow.v2.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][google.cloud.dialogflow.v2.Agents.TrainAgent] and wait for the operation it returns in order to train explicitly.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
The operation only tracks when importing is complete, not when it is done training.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | ImportAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
ImportAgent(ImportAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Operation ImportAgent(ImportAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
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][google.cloud.dialogflow.v2.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][google.cloud.dialogflow.v2.Agents.TrainAgent] and wait for the operation it returns in order to train explicitly.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
The operation only tracks when importing is complete, not when it is done training.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | ImportAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
ImportAgentAsync(ImportAgentRequest, CallOptions)
public virtual AsyncUnaryCall<Operation> ImportAgentAsync(ImportAgentRequest request, CallOptions options)
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][google.cloud.dialogflow.v2.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][google.cloud.dialogflow.v2.Agents.TrainAgent] and wait for the operation it returns in order to train explicitly.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
The operation only tracks when importing is complete, not when it is done training.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | ImportAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
ImportAgentAsync(ImportAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Operation> ImportAgentAsync(ImportAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
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][google.cloud.dialogflow.v2.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][google.cloud.dialogflow.v2.Agents.TrainAgent] and wait for the operation it returns in order to train explicitly.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
The operation only tracks when importing is complete, not when it is done training.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | ImportAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
NewInstance(ClientBase.ClientBaseConfiguration)
protected override Agents.AgentsClient NewInstance(ClientBase.ClientBaseConfiguration configuration)
Creates a new instance of client from given ClientBaseConfiguration
.
Parameter | |
---|---|
Name | Description |
configuration | ClientBase.ClientBaseConfiguration |
Returns | |
---|---|
Type | Description |
Agents.AgentsClient |
RestoreAgent(RestoreAgentRequest, CallOptions)
public virtual Operation RestoreAgent(RestoreAgentRequest request, CallOptions options)
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][google.cloud.dialogflow.v2.Agents.TrainAgent] and wait for the operation it returns in order to train explicitly.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
The operation only tracks when restoring is complete, not when it is done training.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | RestoreAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
RestoreAgent(RestoreAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Operation RestoreAgent(RestoreAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
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][google.cloud.dialogflow.v2.Agents.TrainAgent] and wait for the operation it returns in order to train explicitly.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
The operation only tracks when restoring is complete, not when it is done training.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | RestoreAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
RestoreAgentAsync(RestoreAgentRequest, CallOptions)
public virtual AsyncUnaryCall<Operation> RestoreAgentAsync(RestoreAgentRequest request, CallOptions options)
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][google.cloud.dialogflow.v2.Agents.TrainAgent] and wait for the operation it returns in order to train explicitly.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
The operation only tracks when restoring is complete, not when it is done training.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | RestoreAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
RestoreAgentAsync(RestoreAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Operation> RestoreAgentAsync(RestoreAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
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][google.cloud.dialogflow.v2.Agents.TrainAgent] and wait for the operation it returns in order to train explicitly.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
The operation only tracks when restoring is complete, not when it is done training.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | RestoreAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
SearchAgents(SearchAgentsRequest, CallOptions)
public virtual SearchAgentsResponse SearchAgents(SearchAgentsRequest request, CallOptions options)
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 | |
---|---|
Name | Description |
request | SearchAgentsRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
SearchAgentsResponse | The response received from the server. |
SearchAgents(SearchAgentsRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual SearchAgentsResponse SearchAgents(SearchAgentsRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
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 | |
---|---|
Name | Description |
request | SearchAgentsRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
SearchAgentsResponse | The response received from the server. |
SearchAgentsAsync(SearchAgentsRequest, CallOptions)
public virtual AsyncUnaryCall<SearchAgentsResponse> SearchAgentsAsync(SearchAgentsRequest request, CallOptions options)
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 | |
---|---|
Name | Description |
request | SearchAgentsRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<SearchAgentsResponse> | The call object. |
SearchAgentsAsync(SearchAgentsRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<SearchAgentsResponse> SearchAgentsAsync(SearchAgentsRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
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 | |
---|---|
Name | Description |
request | SearchAgentsRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<SearchAgentsResponse> | The call object. |
SetAgent(SetAgentRequest, CallOptions)
public virtual Agent SetAgent(SetAgentRequest request, CallOptions options)
Creates/updates the specified agent.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | SetAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Agent | The response received from the server. |
SetAgent(SetAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Agent SetAgent(SetAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Creates/updates the specified agent.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | SetAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Agent | The response received from the server. |
SetAgentAsync(SetAgentRequest, CallOptions)
public virtual AsyncUnaryCall<Agent> SetAgentAsync(SetAgentRequest request, CallOptions options)
Creates/updates the specified agent.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | SetAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Agent> | The call object. |
SetAgentAsync(SetAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Agent> SetAgentAsync(SetAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Creates/updates the specified agent.
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | SetAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Agent> | The call object. |
TrainAgent(TrainAgentRequest, CallOptions)
public virtual Operation TrainAgent(TrainAgentRequest request, CallOptions options)
Trains the specified agent.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | TrainAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
TrainAgent(TrainAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Operation TrainAgent(TrainAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Trains the specified agent.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | TrainAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
TrainAgentAsync(TrainAgentRequest, CallOptions)
public virtual AsyncUnaryCall<Operation> TrainAgentAsync(TrainAgentRequest request, CallOptions options)
Trains the specified agent.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | TrainAgentRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
TrainAgentAsync(TrainAgentRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Operation> TrainAgentAsync(TrainAgentRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Trains the specified agent.
This method is a long-running
operation.
The returned Operation
type has the following method-specific fields:
metadata
: An empty Struct messageresponse
: An Empty message
Note: You should always train an agent prior to sending it queries. See the training documentation.
Parameters | |
---|---|
Name | Description |
request | TrainAgentRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |