1. 接口
1. detectIntent, connector -> dialogflow cx
https://cloud.google.com/dialogflow/cx/docs/reference/rest/v3/projects.locations.agents.environments.sessions/detectIntent
- POST https://{endpoint}/v3/{session=projects/*/locations/*/agents/*/environments/*/sessions/*}:detectIntent
request:
{
"queryParams": {
object (QueryParameters)
},
"queryInput": {
object (QueryInput)
},
"outputAudioConfig": {
object (OutputAudioConfig)
}
}
QueryParameters:
{
"timeZone": string,
"geoLocation": {
object (LatLng)
},
"sessionEntityTypes": [
{
object (SessionEntityType)
}
],
"payload": {
object
},
"parameters": {
object
},
"currentPage": string,
"disableWebhook": boolean,
"analyzeQueryTextSentiment": boolean,
"webhookHeaders": {
string: string,
...
},
"flowVersions": [
string
],
"channel": string,
"sessionTtl": string,
"endUserMetadata": {
object
},
"searchConfig": {
object (SearchConfig)
},
"populateDataStoreConnectionSignals": boolean
}
object (Struct format)
Additional parameters to be put into [session parameters][SessionInfo.parameters]. To remove a parameter from the session, clients should explicitly set the parameter value to null.
You can reference the session parameters in the agent with the following format: $session.params.parameter-id.
Depending on your protocol or client library language, this is a map, associative array, symbol table, dictionary, or JSON object composed of a collection of (MapKey, MapValue) pairs:
MapKey type: string
MapKey value: parameter name
MapValue type: If parameter's entity type is a composite entity then use map, otherwise, depending on the parameter value type, it could be one of string, number, boolean, null, list or map.
MapValue value: If parameter's entity type is a composite entity then use map from composite entity property names to property values, otherwise, use parameter value.
response:
{
"responseId": string,
"queryResult": {
object (QueryResult)
},
"outputAudio": string,
"outputAudioConfig": {
object (OutputAudioConfig)
},
"responseType": enum (ResponseType),
"allowCancellation": boolean
}
2. sessions
3. webhook, dialogflow cx -> cloud run
https://cloud.google.com/dialogflow/cx/docs/reference/rest/v3/WebhookRequest
{
"detectIntentResponseId": string,
"languageCode": string,
"fulfillmentInfo": {
object (FulfillmentInfo)
},
"intentInfo": {
object (IntentInfo)
},
"pageInfo": {
object (PageInfo)
},
"sessionInfo": {
object (SessionInfo)
},
"messages": [
{
object (ResponseMessage)
}
],
"payload": {
object
},
"sentimentAnalysisResult": {
object (SentimentAnalysisResult)
},
"languageInfo": {
object (LanguageInfo)
},
// Union field query can be only one of the following:
"text": string,
"triggerIntent": string,
"transcript": string,
"triggerEvent": string,
"dtmfDigits": string
// End of list of possible types for union field query.
}
sessionInfo:
{
"session": string,
"parameters": {
string: value,
...
}
}
map (key: string, value: value (Value format))
Optional for WebhookRequest. Optional for WebhookResponse. All parameters collected from forms and intents during the session. Parameters can be created, updated, or removed by the webhook. To remove a parameter from the session, the webhook should explicitly set the parameter value to null in WebhookResponse. The map is keyed by parameters' display names.
An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
https://cloud.google.com/dialogflow/cx/docs/reference/rest/v3/WebhookResponse
WebhookResponse:
{
"fulfillmentResponse": {
object (FulfillmentResponse)
},
"pageInfo": {
object (PageInfo)
},
"sessionInfo": {
object (SessionInfo)
},
"payload": {
object
},
// Union field transition can be only one of the following:
"targetPage": string,
"targetFlow": string
// End of list of possible types for union field transition.
}
fulfillmentResponse:
{
"messages": [
{
object (ResponseMessage)
}
],
"mergeBehavior": enum (MergeBehavior)
}
Identity and Access Management (IAM)
TODO:
1. Liveperson UI
2. Add market parameter
Secret Manager:
SYSTEM_CONFIG_DEV
大写key -> secret_key
config文件:
大写key -> secret_key
小写key -> handler
小写key -> parameters
大写key -> 小写key
2189

被折叠的 条评论
为什么被折叠?



