Google_Service_Dialogflow_Resource_ProjectsAgent
extends Google_Service_Resource
in package
The "agent" collection of methods.
Typical usage is:
$dialogflowService = new Google_Service_Dialogflow(...);
$agent = $dialogflowService->agent;
Table of Contents
- $client : Google_Client
- $methods : array<string|int, mixed>
- $resourceName : string
- $rootUrl : string
- $serviceName : string
- $servicePath : string
- $stackParameters : mixed
- __construct() : mixed
- call() : Google_Http_Request|expectedClass
- TODO: This function needs simplifying.
- createRequestUri() : string
- Parse/expand request parameters and create a fully qualified request uri.
- export() : Google_Service_Dialogflow_GoogleLongrunningOperation
- Exports the specified agent to a ZIP file. Operation (agent.export)
- getFulfillment() : Google_Service_Dialogflow_GoogleCloudDialogflowV2Fulfillment
- Retrieves the fulfillment. (agent.getFulfillment)
- getValidationResult() : Google_Service_Dialogflow_GoogleCloudDialogflowV2ValidationResult
- Gets agent validation result. Agent validation is performed during training time and is updated automatically when training is completed.
- import() : Google_Service_Dialogflow_GoogleLongrunningOperation
- 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. 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 and wait for the operation it returns in order to train explicitly. Operation An operation which tracks when importing is complete. It only tracks when the draft agent is updated not when it is done training. (agent.import)
- restore() : Google_Service_Dialogflow_GoogleLongrunningOperation
- 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 and wait for the operation it returns in order to train explicitly. Operation An operation which tracks when restoring is complete. It only tracks when the draft agent is updated not when it is done training. (agent.restore)
- search() : Google_Service_Dialogflow_GoogleCloudDialogflowV2SearchAgentsResponse
- 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](https://cloud.google.com/apis/design/design_patterns#list_sub- collections). (agent.search)
- train() : Google_Service_Dialogflow_GoogleLongrunningOperation
- Trains the specified agent. Operation (agent.train)
- updateFulfillment() : Google_Service_Dialogflow_GoogleCloudDialogflowV2Fulfillment
- Updates the fulfillment. (agent.updateFulfillment)
- convertToArrayAndStripNulls() : mixed
Properties
$client
private
Google_Client
$client
$methods
private
array<string|int, mixed>
$methods
$resourceName
private
string
$resourceName
$rootUrl
private
string
$rootUrl
$serviceName
private
string
$serviceName
$servicePath
private
string
$servicePath
$stackParameters
private
mixed
$stackParameters
= array('alt' => array('type' => 'string', 'location' => 'query'), 'fields' => array('type' => 'string', 'location' => 'query'), 'trace' => array('type' => 'string', 'location' => 'query'), 'userIp' => array('type' => 'string', 'location' => 'query'), 'quotaUser' => array('type' => 'string', 'location' => 'query'), 'data' => array('type' => 'string', 'location' => 'body'), 'mimeType' => array('type' => 'string', 'location' => 'header'), 'uploadType' => array('type' => 'string', 'location' => 'query'), 'mediaUpload' => array('type' => 'complex', 'location' => 'query'), 'prettyPrint' => array('type' => 'string', 'location' => 'query'))
Methods
__construct()
public
__construct(mixed $service, mixed $serviceName, mixed $resourceName, mixed $resource) : mixed
Parameters
- $service : mixed
- $serviceName : mixed
- $resourceName : mixed
- $resource : mixed
Return values
mixed —call()
TODO: This function needs simplifying.
public
call( $name, $arguments[, $expectedClass = null ]) : Google_Http_Request|expectedClass
Parameters
Tags
Return values
Google_Http_Request|expectedClass —createRequestUri()
Parse/expand request parameters and create a fully qualified request uri.
public
createRequestUri(string $restPath, array<string|int, mixed> $params) : string
Parameters
- $restPath : string
- $params : array<string|int, mixed>
Tags
Return values
string —$requestUrl
export()
Exports the specified agent to a ZIP file. Operation (agent.export)
public
export(string $parent, Google_Service_Dialogflow_GoogleCloudDialogflowV2ExportAgentRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Dialogflow_GoogleLongrunningOperation
Parameters
- $parent : string
-
Required. The project that the agent to export is associated with. Format:
projects/. - $postBody : Google_Service_Dialogflow_GoogleCloudDialogflowV2ExportAgentRequest
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Return values
Google_Service_Dialogflow_GoogleLongrunningOperation —getFulfillment()
Retrieves the fulfillment. (agent.getFulfillment)
public
getFulfillment(string $name[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Dialogflow_GoogleCloudDialogflowV2Fulfillment
Parameters
- $name : string
-
Required. The name of the fulfillment. Format:
projects//agent/fulfillment. - $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Return values
Google_Service_Dialogflow_GoogleCloudDialogflowV2Fulfillment —getValidationResult()
Gets agent validation result. Agent validation is performed during training time and is updated automatically when training is completed.
public
getValidationResult(string $parent[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Dialogflow_GoogleCloudDialogflowV2ValidationResult
(agent.getValidationResult)
Parameters
- $parent : string
-
Required. The project that the agent is associated with. Format:
projects/. - $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Tags
Return values
Google_Service_Dialogflow_GoogleCloudDialogflowV2ValidationResult —import()
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. 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 and wait for the operation it returns in order to train explicitly. Operation An operation which tracks when importing is complete. It only tracks when the draft agent is updated not when it is done training. (agent.import)
public
import(string $parent, Google_Service_Dialogflow_GoogleCloudDialogflowV2ImportAgentRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Dialogflow_GoogleLongrunningOperation
Parameters
- $parent : string
-
Required. The project that the agent to import is associated with. Format:
projects/. - $postBody : Google_Service_Dialogflow_GoogleCloudDialogflowV2ImportAgentRequest
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Return values
Google_Service_Dialogflow_GoogleLongrunningOperation —restore()
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 and wait for the operation it returns in order to train explicitly. Operation An operation which tracks when restoring is complete. It only tracks when the draft agent is updated not when it is done training. (agent.restore)
public
restore(string $parent, Google_Service_Dialogflow_GoogleCloudDialogflowV2RestoreAgentRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Dialogflow_GoogleLongrunningOperation
Parameters
- $parent : string
-
Required. The project that the agent to restore is associated with. Format:
projects/. - $postBody : Google_Service_Dialogflow_GoogleCloudDialogflowV2RestoreAgentRequest
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Return values
Google_Service_Dialogflow_GoogleLongrunningOperation —search()
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](https://cloud.google.com/apis/design/design_patterns#list_sub- collections). (agent.search)
public
search(string $parent[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Dialogflow_GoogleCloudDialogflowV2SearchAgentsResponse
Parameters
- $parent : string
-
Required. The project to list agents from. Format:
projects/. - $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Tags
Return values
Google_Service_Dialogflow_GoogleCloudDialogflowV2SearchAgentsResponse —train()
Trains the specified agent. Operation (agent.train)
public
train(string $parent, Google_Service_Dialogflow_GoogleCloudDialogflowV2TrainAgentRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Dialogflow_GoogleLongrunningOperation
Parameters
- $parent : string
-
Required. The project that the agent to train is associated with. Format:
projects/. - $postBody : Google_Service_Dialogflow_GoogleCloudDialogflowV2TrainAgentRequest
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Return values
Google_Service_Dialogflow_GoogleLongrunningOperation —updateFulfillment()
Updates the fulfillment. (agent.updateFulfillment)
public
updateFulfillment(string $name, Google_Service_Dialogflow_GoogleCloudDialogflowV2Fulfillment $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Dialogflow_GoogleCloudDialogflowV2Fulfillment
Parameters
- $name : string
-
Required. The unique identifier of the fulfillment. Format:
projects//agent/fulfillment. - $postBody : Google_Service_Dialogflow_GoogleCloudDialogflowV2Fulfillment
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Tags
Return values
Google_Service_Dialogflow_GoogleCloudDialogflowV2Fulfillment —convertToArrayAndStripNulls()
protected
convertToArrayAndStripNulls(mixed $o) : mixed
Parameters
- $o : mixed