Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 36 additions & 2 deletions mmv1/products/ces/Deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@ examples:
app_display_name: my-app
app_id: app-id
deployment_display_name: my-deployment
- name: ces_deployment_full
primary_resource_id: my-deployment
vars:
app_display_name: my-app
app_id: app-id
deployment_display_name: my-deployment
parameters:
- name: location
type: String
Expand Down Expand Up @@ -69,6 +75,8 @@ properties:
TWILIO
GOOGLE_TELEPHONY_PLATFORM
CONTACT_CENTER_AS_A_SERVICE
FIVE9
CONTACT_CENTER_INTEGRATION
- name: disableBargeInControl
type: Boolean
description: |-
Expand Down Expand Up @@ -103,21 +111,47 @@ properties:
description: |-
The modality of the web widget.
Possible values:
UNKNOWN_MODALITY
MODALITY_UNSPECIFIED
CHAT_AND_VOICE
VOICE_ONLY
CHAT_ONLY
CHAT_VOICE_AND_VIDEO
- name: theme
type: String
description: |-
The theme of the web widget.
Possible values:
UNKNOWN_THEME
THEME_UNSPECIFIED
LIGHT
DARK
- name: webWidgetTitle
type: String
description: The title of the web widget.
- name: securitySettings
type: NestedObject
description: The security settings of the web widget.
properties:
- name: enablePublicAccess
type: Boolean
description: |-
Indicates whether public access to the web widget is enabled. If true, the web widget will be publicly accessible. If false, the web widget must be integrated with your own authentication and authorization system to return valid credentials for accessing the CES agent.
send_empty_value: true
- name: enableOriginCheck
type: Boolean
description: |-
Indicates whether origin check for the web widget is enabled. If true, the web widget will check the origin of the website that loads the web widget and only allow it to be loaded in the same origin or any of the allowed origins.
send_empty_value: true
- name: allowedOrigins
type: Array
description: |-
The origins that are allowed to host the web widget. An origin is defined by RFC 6454. If empty, all origins are allowed. A maximum of 100 origins is allowed. Example: "https://example.com"
item_type:
type: String
- name: enableRecaptcha
type: Boolean
description: |-
Indicates whether reCAPTCHA verification for the web widget is enabled.
send_empty_value: true
- name: createTime
type: String
description: Timestamp when this deployment was created.
Expand Down
34 changes: 34 additions & 0 deletions mmv1/templates/terraform/examples/ces_deployment_full.tf.tmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
resource "google_ces_app" "my-app" {
location = "us"
display_name = "{{index $.Vars "app_display_name"}}"
app_id = "{{index $.Vars "app_id"}}"
time_zone_settings {
time_zone = "America/Los_Angeles"
}
}
resource "google_ces_deployment" "{{$.PrimaryResourceId}}" {
location = "us"
display_name = "{{index $.Vars "deployment_display_name"}}"
app = google_ces_app.my-app.name
app_version = "projects/example-project/locations/us/apps/example-app/versions/example-version"
channel_profile {
channel_type = "API"
disable_barge_in_control = true
disable_dtmf = true
persona_property {
persona = "CHATTY"
}
profile_id = "temp_profile_id"
web_widget_config {
modality = "CHAT_AND_VOICE"
theme = "DARK"
web_widget_title = "temp_webwidget_title"
security_settings {
enable_public_access = true
enable_origin_check = true
allowed_origins = ["https://example.com", "https://test.com"]
enable_recaptcha = true
}
}
}
}
12 changes: 12 additions & 0 deletions mmv1/third_party/terraform/services/ces/ces_deployment_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,12 @@ resource "google_ces_deployment" "my-deployment" {
modality = "CHAT_AND_VOICE"
theme = "DARK"
web_widget_title = "temp_webwidget_title"
security_settings {
enable_public_access = true
enable_origin_check = true
allowed_origins = ["https://example.com", "https://test.com"]
enable_recaptcha = true
}
}
}
}
Expand Down Expand Up @@ -107,6 +113,12 @@ resource "google_ces_deployment" "my-deployment" {
modality = "CHAT_ONLY"
theme = "LIGHT"
web_widget_title = "temp_webwidget_title"
security_settings {
enable_public_access = false
enable_origin_check = false
allowed_origins = ["https://updated.com"]
enable_recaptcha = false
}
}
}
}
Expand Down
Loading