feat: add support for flexible webhook

docs: update synthesize speech configs's documentation

PiperOrigin-RevId: 539265734
pull/810/head
Google APIs 2 years ago committed by Copybara-Service
parent 2f59906698
commit 091bc8c603
  1. 17
      google/cloud/dialogflow/cx/v3beta1/audio_config.proto
  2. 3
      google/cloud/dialogflow/cx/v3beta1/test_case.proto
  3. 57
      google/cloud/dialogflow/cx/v3beta1/webhook.proto

@ -320,6 +320,9 @@ message OutputAudioConfig {
int32 sample_rate_hertz = 2; int32 sample_rate_hertz = 2;
// Optional. Configuration of how speech should be synthesized. // Optional. Configuration of how speech should be synthesized.
// If not specified,
// [Agent.text_to_speech_settings][google.cloud.dialogflow.cx.v3beta1.Agent.text_to_speech_settings]
// is applied.
SynthesizeSpeechConfig synthesize_speech_config = 3; SynthesizeSpeechConfig synthesize_speech_config = 3;
} }
@ -331,12 +334,16 @@ message TextToSpeechSettings {
// //
// These settings affect: // These settings affect:
// //
// - The synthesize configuration used in [phone // - The [phone
// gateway](https://cloud.google.com/dialogflow/cx/docs/concept/integration/phone-gateway). // gateway](https://cloud.google.com/dialogflow/cx/docs/concept/integration/phone-gateway)
// synthesize configuration set via
// [Agent.text_to_speech_settings][google.cloud.dialogflow.cx.v3beta1.Agent.text_to_speech_settings].
// //
// - You no longer need to specify // - How speech is synthesized when invoking
// [session][google.cloud.dialogflow.cx.v3beta1.Sessions] APIs.
// [Agent.text_to_speech_settings][google.cloud.dialogflow.cx.v3beta1.Agent.text_to_speech_settings]
// only applies if
// [OutputAudioConfig.synthesize_speech_config][google.cloud.dialogflow.cx.v3beta1.OutputAudioConfig.synthesize_speech_config] // [OutputAudioConfig.synthesize_speech_config][google.cloud.dialogflow.cx.v3beta1.OutputAudioConfig.synthesize_speech_config]
// when invoking API calls. Your agent will use the pre-configured options // is not specified.
// for speech synthesizing.
map<string, SynthesizeSpeechConfig> synthesize_speech_configs = 1; map<string, SynthesizeSpeechConfig> synthesize_speech_configs = 1;
} }

@ -406,7 +406,8 @@ message TestRunDifference {
// The type of diff. // The type of diff.
DiffType type = 1; DiffType type = 1;
// A description of the diff, showing the actual output vs expected output. // A human readable description of the diff, showing the actual output vs
// expected output.
string description = 2; string description = 2;
} }

@ -101,6 +101,45 @@ message Webhook {
// Represents configuration for a generic web service. // Represents configuration for a generic web service.
message GenericWebService { message GenericWebService {
// Represents the type of webhook configuration.
enum WebhookType {
// Default value. This value is unused.
WEBHOOK_TYPE_UNSPECIFIED = 0;
// Represents a standard webhook.
STANDARD = 1;
// Represents a flexible webhook.
FLEXIBLE = 2;
}
// HTTP method to use when calling webhooks.
enum HttpMethod {
// HTTP method not specified.
HTTP_METHOD_UNSPECIFIED = 0;
// HTTP POST Method.
POST = 1;
// HTTP GET Method.
GET = 2;
// HTTP HEAD Method.
HEAD = 3;
// HTTP PUT Method.
PUT = 4;
// HTTP DELETE Method.
DELETE = 5;
// HTTP PATCH Method.
PATCH = 6;
// HTTP OPTIONS Method.
OPTIONS = 7;
}
// Required. The webhook URI for receiving POST requests. It must use https // Required. The webhook URI for receiving POST requests. It must use https
// protocol. // protocol.
string uri = 1 [(google.api.field_behavior) = REQUIRED]; string uri = 1 [(google.api.field_behavior) = REQUIRED];
@ -129,6 +168,24 @@ message Webhook {
// ``` // ```
repeated bytes allowed_ca_certs = 5 repeated bytes allowed_ca_certs = 5
[(google.api.field_behavior) = OPTIONAL]; [(google.api.field_behavior) = OPTIONAL];
// Optional. Type of the webhook.
WebhookType webhook_type = 6 [(google.api.field_behavior) = OPTIONAL];
// Optional. HTTP method for the flexible webhook calls. Standard webhook
// always uses POST.
HttpMethod http_method = 7 [(google.api.field_behavior) = OPTIONAL];
// Optional. Defines a custom JSON object as request body to send to
// flexible webhook.
string request_body = 8 [(google.api.field_behavior) = OPTIONAL];
// Optional. Maps the values extracted from specific fields of the flexible
// webhook response into session parameters.
// - Key: session parameter name
// - Value: field path in the webhook response
map<string, string> parameter_mapping = 9
[(google.api.field_behavior) = OPTIONAL];
} }
// Represents configuration for a [Service // Represents configuration for a [Service

Loading…
Cancel
Save