@cxbuilder/flow-config 2.1.1 → 2.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.jsii +3 -3
- package/CHANGELOG.md +66 -58
- package/README.md +194 -232
- package/dist/backend/Static/static/assets/{index-Cejunttu.js → index-s-cirXNx.js} +17 -12
- package/dist/backend/Static/static/index.html +1 -1
- package/dist/infrastructure/FlowConfigStack.js +1 -1
- package/dist/infrastructure/api/spec.yaml +17 -0
- package/docs/Installation.md +194 -0
- package/docs/UserGuide-Admin.md +431 -0
- package/docs/UserGuide-Edit.md +313 -0
- package/docs/UserGuide-Read.md +324 -0
- package/docs/screenshots/detail-admin.png +0 -0
- package/docs/screenshots/detail-edit.png +0 -0
- package/docs/screenshots/detail-prompts-read.png +0 -0
- package/docs/screenshots/detail-read.png +0 -0
- package/docs/screenshots/detail-variables-admin-select-options.png +0 -0
- package/docs/screenshots/detail-variables-admin.png +0 -0
- package/docs/screenshots/detail-variables-edit.png +0 -0
- package/docs/screenshots/detail-variables-read.png +0 -0
- package/docs/screenshots/landing-edit.png +0 -0
- package/docs/screenshots/landing-read.png +0 -0
- package/docs/screenshots/settings.png +0 -0
- package/package.json +1 -1
- package/docs/screenshots/variables.png +0 -0
- /package/docs/screenshots/{preview.png → detail-preview.png} +0 -0
- /package/docs/screenshots/{prompts.png → detail-prompts-admin.png} +0 -0
- /package/docs/screenshots/{landing.png → landing-admin.png} +0 -0
package/README.md
CHANGED
|
@@ -1,319 +1,281 @@
|
|
|
1
|
-
#
|
|
1
|
+
# FlowConfig for Amazon Connect
|
|
2
2
|
|
|
3
3
|
[](https://github.com/cxbuilder/flow-config/actions/workflows/ci-cd.yml)
|
|
4
4
|
[](https://badge.fury.io/js/@cxbuilder%2Fflow-config)
|
|
5
5
|
[](https://badge.fury.io/py/cxbuilder-flow-config)
|
|
6
6
|
[](https://constructs.dev/packages/@cxbuilder/flow-config)
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
**Empower your business users to manage Amazon Connect contact flow configurations without IT involvement.**
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
FlowConfig is a third-party app for Amazon Connect that lets business users update customer messages, queue settings, and routing variables in real-time—without touching contact flows or deploying code.
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
- [Architecture](./docs/Architecture.md)
|
|
14
|
-
- [DataModel](./docs/DataModel.md)
|
|
12
|
+

|
|
15
13
|
|
|
16
|
-
##
|
|
14
|
+
## The Problem
|
|
17
15
|
|
|
18
|
-
|
|
19
|
-
npm install @cxbuilder/flow-config
|
|
20
|
-
```
|
|
16
|
+
Your contact center needs to respond quickly to changing conditions:
|
|
21
17
|
|
|
22
|
-
|
|
18
|
+
- 🚨 **Emergency closures** require immediate routing changes
|
|
19
|
+
- 🗓️ **Seasonal hours** need frequent prompt updates
|
|
20
|
+
- 🌍 **Multi-language support** means managing dozens of message variants
|
|
21
|
+
- 🏢 **Multiple locations** each need custom greetings and settings
|
|
22
|
+
- ⏱️ **Queue thresholds** must adapt to call volume fluctuations
|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
But every change requires:
|
|
25
|
+
- Opening Amazon Connect contact flow designer
|
|
26
|
+
- Finding and updating multiple text blocks
|
|
27
|
+
- Testing changes
|
|
28
|
+
- Deploying updates
|
|
29
|
+
- Waiting for IT availability
|
|
25
30
|
|
|
26
|
-
|
|
27
|
-
import { FlowConfigStack } from '@cxbuilder/flow-config';
|
|
28
|
-
import * as cdk from 'aws-cdk-lib';
|
|
31
|
+
**There has to be a better way.**
|
|
29
32
|
|
|
30
|
-
|
|
31
|
-
new FlowConfigStack(app, 'FlowConfigStack', {
|
|
32
|
-
prefix: 'my-flow-config',
|
|
33
|
-
env: {
|
|
34
|
-
region: 'us-east-1',
|
|
35
|
-
account: 'YOUR_ACCOUNT_ID',
|
|
36
|
-
},
|
|
37
|
-
cognito: {
|
|
38
|
-
domain: 'https://your-auth-domain.com',
|
|
39
|
-
userPoolId: 'us-east-1_YourPoolId',
|
|
40
|
-
},
|
|
41
|
-
connectInstanceArn:
|
|
42
|
-
'arn:aws:connect:us-east-1:YOUR_ACCOUNT:instance/YOUR_INSTANCE_ID',
|
|
43
|
-
alertEmails: ['admin@yourcompany.com'],
|
|
44
|
-
});
|
|
45
|
-
```
|
|
33
|
+
## The Solution
|
|
46
34
|
|
|
47
|
-
|
|
35
|
+
FlowConfig separates **configuration** from **logic**. Your contact flow designers build reusable flows once, and business users manage the values that drive them.
|
|
48
36
|
|
|
49
|
-
|
|
37
|
+
### What You Can Configure
|
|
50
38
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
39
|
+
**Variables** - Settings that control contact flow behavior:
|
|
40
|
+
- Boolean flags: `closure`, `offerCallback`, `holidayMode`
|
|
41
|
+
- Numbers: `maxWaitTime`, `queueDepth`, `transferTimeout`
|
|
42
|
+
- Text values: `skillLevel`, `routingMode`, `priority`
|
|
54
43
|
|
|
55
|
-
|
|
44
|
+
**Prompts** - Customer-facing messages:
|
|
45
|
+
- Multi-language support (English, Spanish, French, etc.)
|
|
46
|
+
- Separate voice and chat content
|
|
47
|
+
- Text-to-speech preview before going live
|
|
56
48
|
|
|
57
|
-
|
|
58
|
-
const vpcConfig: VpcConfig = {
|
|
59
|
-
vpcId: 'vpc-12345678',
|
|
60
|
-
lambdaSecurityGroupIds: ['sg-lambda123'],
|
|
61
|
-
privateSubnetIds: ['subnet-12345', 'subnet-67890'],
|
|
62
|
-
vpcEndpointSecurityGroupIds: ['sg-endpoint123'],
|
|
63
|
-
};
|
|
49
|
+
### Who Uses FlowConfig
|
|
64
50
|
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
cognito: {
|
|
72
|
-
domain: 'https://your-auth-domain.com',
|
|
73
|
-
userPoolId: 'us-east-1_YourPoolId',
|
|
74
|
-
},
|
|
75
|
-
connectInstanceArn:
|
|
76
|
-
'arn:aws:connect:us-east-1:YOUR_ACCOUNT:instance/YOUR_INSTANCE_ID',
|
|
77
|
-
alertEmails: ['admin@yourcompany.com'],
|
|
78
|
-
vpc: vpcConfig, // Enable VPC private deployment
|
|
79
|
-
});
|
|
80
|
-
```
|
|
51
|
+
**👔 Edit Users**
|
|
52
|
+
- Update all variables and prompts across all flow configurations
|
|
53
|
+
- Change settings during high-volume events or emergencies
|
|
54
|
+
- Update prompts for holidays, closures, and special events
|
|
55
|
+
- Preview voice messages before customers hear them
|
|
56
|
+
- Make changes instantly without IT involvement
|
|
81
57
|
|
|
82
|
-
|
|
58
|
+
**🔧 Administrators (Admin Access)**
|
|
59
|
+
- Create and organize flow configurations
|
|
60
|
+
- Define variable schema types (Text, Number, Boolean, Select)
|
|
61
|
+
- Add/remove variables and prompts
|
|
62
|
+
- Set up multi-language prompts for global operations
|
|
63
|
+
- Import/export configurations across environments
|
|
64
|
+
- Configure application settings (available locales and voices)
|
|
83
65
|
|
|
84
|
-
|
|
66
|
+
**👀 Read-Only Users**
|
|
67
|
+
- View all configurations and settings
|
|
68
|
+
- Monitor what messages customers are currently hearing
|
|
69
|
+
- Review variable values without editing capability
|
|
85
70
|
|
|
86
|
-
|
|
71
|
+
## Quick Links
|
|
87
72
|
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
73
|
+
### 📘 I'm a Business User
|
|
74
|
+
- [Edit User Guide](./docs/UserGuide-Edit.md) - Learn how to update variables and prompts
|
|
75
|
+
- [Administrator Guide](./docs/UserGuide-Admin.md) - Create and manage configurations
|
|
76
|
+
- [Read-Only User Guide](./docs/UserGuide-Read.md) - View configurations
|
|
91
77
|
|
|
92
|
-
|
|
78
|
+
### 🛠️ I'm a Developer/Architect
|
|
79
|
+
- [Installation & Deployment](./docs/Installation.md) - Get started deploying FlowConfig
|
|
80
|
+
- [Architecture](./docs/Architecture.md) - Understand the technical design
|
|
81
|
+
- [Data Model](./docs/DataModel.md) - Explore the data structure
|
|
93
82
|
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
};
|
|
83
|
+
### 🎯 I'm Evaluating This Solution
|
|
84
|
+
- [Screenshots](./docs/screenshots/) - See the interface in action
|
|
85
|
+
- [Use Cases](#common-use-cases) - Real-world scenarios below
|
|
86
|
+
- [Features](#key-features) - What's included
|
|
99
87
|
|
|
100
|
-
|
|
101
|
-
prefix: 'my-flow-config',
|
|
102
|
-
env: {
|
|
103
|
-
region: 'us-east-1',
|
|
104
|
-
account: 'YOUR_ACCOUNT_ID',
|
|
105
|
-
},
|
|
106
|
-
cognito: {
|
|
107
|
-
domain: 'https://your-auth-domain.com',
|
|
108
|
-
userPoolId: 'us-east-1_YourPoolId',
|
|
109
|
-
},
|
|
110
|
-
connectInstanceArn:
|
|
111
|
-
'arn:aws:connect:us-east-1:YOUR_ACCOUNT:instance/YOUR_INSTANCE_ID',
|
|
112
|
-
alertEmails: ['admin@yourcompany.com'],
|
|
113
|
-
globalTable: primaryGlobalTable, // Enable global table
|
|
114
|
-
});
|
|
115
|
-
```
|
|
88
|
+
## Common Use Cases
|
|
116
89
|
|
|
117
|
-
|
|
90
|
+
### 🏢 Multi-Branch Operations
|
|
118
91
|
|
|
119
|
-
|
|
120
|
-
new FlowConfigStack(app, 'FlowConfigStack-Secondary', {
|
|
121
|
-
prefix: 'my-flow-config',
|
|
122
|
-
env: {
|
|
123
|
-
region: 'us-west-2',
|
|
124
|
-
account: 'YOUR_ACCOUNT_ID',
|
|
125
|
-
},
|
|
126
|
-
cognito: {
|
|
127
|
-
domain: 'https://your-auth-domain.com',
|
|
128
|
-
userPoolId: 'us-west-2_YourPoolId',
|
|
129
|
-
},
|
|
130
|
-
connectInstanceArn:
|
|
131
|
-
'arn:aws:connect:us-west-2:YOUR_ACCOUNT:instance/YOUR_INSTANCE_ID',
|
|
132
|
-
alertEmails: ['admin@yourcompany.com'],
|
|
133
|
-
globalTable: {
|
|
134
|
-
isPrimaryRegion: false, // Reference global table
|
|
135
|
-
},
|
|
136
|
-
});
|
|
137
|
-
```
|
|
92
|
+
**Challenge**: 50 branch offices, each with unique phone numbers and custom greetings, but sharing the same contact flow logic.
|
|
138
93
|
|
|
139
|
-
|
|
94
|
+
**Solution**: Create one flow configuration per branch (e.g., `branch-office-austin`, `branch-office-seattle`). Each branch gets custom prompts and settings while using a single, centralized contact flow design.
|
|
140
95
|
|
|
141
|
-
|
|
142
|
-
- **Amazon Connect Integration**: GetConfig Lambda function integrated directly with Connect contact flows
|
|
143
|
-
- **Third-Party App**: Web-based interface embedded in Amazon Connect Agent Workspace
|
|
144
|
-
- **Multi-Language Support**: Configure prompts for different languages and channels (voice/chat)
|
|
145
|
-
- **Real-time Preview**: Text-to-speech preview using Amazon Polly
|
|
146
|
-
- **Secure Access**: Integration with Amazon Connect and AWS Verified Permissions
|
|
147
|
-
- **Flexible Deployment Options**:
|
|
148
|
-
- **Single-Region**: Standard deployment with regional DynamoDB table
|
|
149
|
-
- **Multi-Region**: Global table support with automatic replication across regions
|
|
150
|
-
- **Public Deployment**: Standard internet-accessible API Gateway and Lambda functions
|
|
151
|
-
- **VPC Private Deployment**: Private API Gateway endpoints, VPC-enabled Lambda functions, and VPC endpoints for enhanced security
|
|
96
|
+
**Result**: Onboard new branches in minutes. Local staff can update their own greetings and settings without IT involvement.
|
|
152
97
|
|
|
153
|
-
|
|
98
|
+
---
|
|
154
99
|
|
|
155
|
-
|
|
100
|
+
### 🚨 Emergency Response
|
|
156
101
|
|
|
157
|
-
|
|
102
|
+
**Challenge**: Fire alarm requires immediate call center closure. Every minute of delay means confused customers and wasted agent time.
|
|
158
103
|
|
|
159
|
-
|
|
104
|
+
**Solution**: Business users open FlowConfig, toggle `closure: true`, and save. All new calls immediately hear the closure message and are routed appropriately.
|
|
160
105
|
|
|
161
|
-
|
|
162
|
-
{
|
|
163
|
-
"Details": {
|
|
164
|
-
"Parameters": {
|
|
165
|
-
"id": "main-queue",
|
|
166
|
-
"lang": "es-US"
|
|
167
|
-
},
|
|
168
|
-
"ContactData": {
|
|
169
|
-
"Channel": "VOICE",
|
|
170
|
-
"LanguageCode": "en-US"
|
|
171
|
-
}
|
|
172
|
-
}
|
|
173
|
-
}
|
|
174
|
-
```
|
|
106
|
+
**Result**: Response time measured in seconds, not hours. No contact flow changes, no deployments, no IT tickets.
|
|
175
107
|
|
|
176
|
-
|
|
108
|
+
---
|
|
177
109
|
|
|
178
|
-
|
|
110
|
+
### 🌍 Global Customer Support
|
|
179
111
|
|
|
180
|
-
|
|
181
|
-
- Provided via `Details.Parameters.id`
|
|
112
|
+
**Challenge**: Supporting customers in English, Spanish, and French requires managing hundreds of prompt variants across dozens of contact flows.
|
|
182
113
|
|
|
183
|
-
|
|
114
|
+
**Solution**: Define prompts once in FlowConfig with all language variants. Contact flows automatically select the correct language based on customer preference.
|
|
184
115
|
|
|
185
|
-
|
|
186
|
-
- `Details.ContactData.LanguageCode`
|
|
187
|
-
- Defaults to `"en-US"`
|
|
116
|
+
**Result**: Add a new language by updating prompts in FlowConfig—no contact flow changes required.
|
|
188
117
|
|
|
189
|
-
|
|
190
|
-
- Automatically read from `Details.ContactData.Channel`
|
|
191
|
-
- Supports `"VOICE"` and `"CHAT"`
|
|
192
|
-
- Defaults to `"voice"`
|
|
118
|
+
---
|
|
193
119
|
|
|
194
|
-
###
|
|
120
|
+
### 📊 Dynamic Queue Management
|
|
195
121
|
|
|
196
|
-
|
|
122
|
+
**Challenge**: Call volume spikes require rapid adjustment of queue thresholds, wait times, and callback offerings.
|
|
197
123
|
|
|
198
|
-
|
|
199
|
-
{
|
|
200
|
-
"id": "main-queue",
|
|
201
|
-
"lang": "es-US",
|
|
202
|
-
"channel": "voice"
|
|
203
|
-
}
|
|
204
|
-
```
|
|
124
|
+
**Solution**: Business users adjust variables like `maxQueueDepth`, `maxWaitTime`, and `offerCallback` in real-time based on current conditions.
|
|
205
125
|
|
|
206
|
-
|
|
126
|
+
**Result**: Contact center supervisors respond to changing conditions without waiting for IT or risking contact flow mistakes.
|
|
207
127
|
|
|
208
|
-
|
|
128
|
+
---
|
|
209
129
|
|
|
210
|
-
|
|
211
|
-
- Resolves language from parameters → attributes → default
|
|
212
|
-
- Determines channel from Contact Flow event data
|
|
130
|
+
## Key Features
|
|
213
131
|
|
|
214
|
-
|
|
132
|
+
**For Business Users:**
|
|
133
|
+
- ✅ **No-Code Interface** - Simple web UI embedded in Amazon Connect Agent Workspace
|
|
134
|
+
- 🎧 **Preview Before Publishing** - Hear exactly how prompts will sound using Amazon Polly text-to-speech
|
|
135
|
+
- 🌍 **Multi-Language Support** - Manage prompts in multiple languages with separate voice and chat content
|
|
136
|
+
- ⚡ **Instant Updates** - Changes take effect immediately for new customer contacts
|
|
137
|
+
- 🔒 **Role-Based Access** - Three access levels: Admin, Edit, and Read-Only
|
|
215
138
|
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
- Strips SSML tags from voice content if no chat content exists
|
|
139
|
+
**For IT Teams:**
|
|
140
|
+
- 🏗️ **Serverless Architecture** - Built on AWS Lambda, DynamoDB, and API Gateway
|
|
141
|
+
- 🔌 **Native Connect Integration** - Seamlessly integrates with contact flows via Lambda function
|
|
142
|
+
- 🔐 **Secure by Design** - AWS Cognito authentication with role-based access control
|
|
143
|
+
- 📦 **Easy Deployment** - Single CDK construct deploys the entire stack
|
|
144
|
+
- 🌐 **Flexible Architecture** - Supports single-region, multi-region, public, or VPC-private deployments
|
|
145
|
+
- 📤 **Import/Export** - Move configurations between environments (dev/test/prod)
|
|
224
146
|
|
|
225
|
-
|
|
226
|
-
- Returns a flattened object containing:
|
|
227
|
-
- All variable key-value pairs from the flow config
|
|
228
|
-
- All prompt values resolved for the specified language and channel
|
|
147
|
+
---
|
|
229
148
|
|
|
230
|
-
|
|
149
|
+
## Getting Started
|
|
231
150
|
|
|
232
|
-
|
|
233
|
-
2. **Select the GetConfig Lambda function** (deployed as `${prefix}`)
|
|
234
|
-
3. **Configure parameters**:
|
|
151
|
+
### For Developers
|
|
235
152
|
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
153
|
+
**Installation:**
|
|
154
|
+
|
|
155
|
+
```bash
|
|
156
|
+
npm install @cxbuilder/flow-config
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
**Basic Usage:**
|
|
160
|
+
|
|
161
|
+
```typescript
|
|
162
|
+
import { FlowConfigStack } from '@cxbuilder/flow-config';
|
|
163
|
+
import * as cdk from 'aws-cdk-lib';
|
|
164
|
+
|
|
165
|
+
const app = new cdk.App();
|
|
166
|
+
new FlowConfigStack(app, 'FlowConfigStack', {
|
|
167
|
+
prefix: 'my-flow-config',
|
|
168
|
+
env: { region: 'us-east-1', account: 'YOUR_ACCOUNT_ID' },
|
|
169
|
+
cognito: {
|
|
170
|
+
domain: 'https://your-auth-domain.com',
|
|
171
|
+
userPoolId: 'us-east-1_YourPoolId',
|
|
172
|
+
},
|
|
173
|
+
connectInstanceArn: 'arn:aws:connect:us-east-1:YOUR_ACCOUNT:instance/YOUR_INSTANCE_ID',
|
|
174
|
+
alertEmails: ['admin@yourcompany.com'],
|
|
175
|
+
});
|
|
240
176
|
```
|
|
241
177
|
|
|
242
|
-
|
|
178
|
+
**Next Steps:**
|
|
179
|
+
- See the [Installation Guide](./docs/Installation.md) for detailed deployment instructions
|
|
180
|
+
- Review the [Architecture](./docs/Architecture.md) to understand the technical design
|
|
181
|
+
- Explore advanced configurations (VPC private, multi-region, etc.)
|
|
182
|
+
|
|
183
|
+
### For Contact Flow Designers
|
|
184
|
+
|
|
185
|
+
**Using FlowConfig in Your Contact Flows:**
|
|
186
|
+
|
|
187
|
+
1. Add an "Invoke AWS Lambda function" block
|
|
188
|
+
2. Select the GetConfig Lambda function (automatically deployed)
|
|
189
|
+
3. Pass the configuration ID as a parameter:
|
|
243
190
|
|
|
244
191
|
```json
|
|
245
192
|
{
|
|
246
|
-
"id": "main-queue"
|
|
247
|
-
"lang": "es-US"
|
|
193
|
+
"id": "main-queue"
|
|
248
194
|
}
|
|
249
195
|
```
|
|
250
196
|
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
197
|
+
4. Use the returned values in subsequent blocks:
|
|
198
|
+
- Variables: `$.External.closure`, `$.External.maxWaitTime`
|
|
199
|
+
- Prompts: `$.External.welcome`, `$.External.holdMessage`
|
|
254
200
|
|
|
255
|
-
|
|
256
|
-
- **Play prompt**: Use `$.External.promptName`
|
|
257
|
-
- **Check contact attributes**: Reference returned variables for routing decisions
|
|
258
|
-
|
|
259
|
-
### Example Contact Flow Integration
|
|
201
|
+
**Example Flow:**
|
|
260
202
|
|
|
261
203
|
```
|
|
262
|
-
[
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
204
|
+
[Entry Point] → [Invoke Lambda: GetConfig with id="main-queue"]
|
|
205
|
+
↓
|
|
206
|
+
[Check: $.External.closure = true?]
|
|
207
|
+
↓ ↓
|
|
208
|
+
[Yes: Play [No: Continue
|
|
209
|
+
$.External. to queue]
|
|
210
|
+
closureMessage]
|
|
269
211
|
```
|
|
270
212
|
|
|
271
|
-
|
|
213
|
+
For detailed Lambda integration instructions, see the [Technical Reference](#technical-reference) below.
|
|
272
214
|
|
|
273
|
-
|
|
274
|
-
- The combined size of returned variables and prompts should be less than this limit
|
|
275
|
-
- For large flow configs with many prompts or languages, consider implementing pagination or selective loading
|
|
215
|
+
---
|
|
276
216
|
|
|
277
|
-
|
|
217
|
+
## Technical Reference
|
|
278
218
|
|
|
279
|
-
|
|
219
|
+
### GetConfig Lambda Integration
|
|
280
220
|
|
|
281
|
-
|
|
221
|
+
The GetConfig Lambda function is used within contact flows to access your flow configs. This function is automatically integrated with your Amazon Connect instance during deployment.
|
|
282
222
|
|
|
283
|
-
|
|
223
|
+
**Lambda Parameters:**
|
|
284
224
|
|
|
285
|
-
|
|
225
|
+
- **Required**: `id` - The flow configuration identifier
|
|
226
|
+
- **Optional**: `lang` - Language code (defaults to contact's language or `en-US`)
|
|
227
|
+
- **Auto-detected**: `channel` - Voice or chat (detected from contact data)
|
|
286
228
|
|
|
287
|
-
|
|
229
|
+
**Lambda Response:**
|
|
288
230
|
|
|
289
|
-
|
|
290
|
-
- [OpenAPI Editor](https://marketplace.visualstudio.com/items?itemName=42Crunch.vscode-openapi)
|
|
291
|
-
- [OpenApy TypeScript Generator](https://openapi-ts.pages.dev/introduction)
|
|
231
|
+
Returns a flattened object containing all variables and prompts from the configuration:
|
|
292
232
|
|
|
293
|
-
|
|
233
|
+
```json
|
|
234
|
+
{
|
|
235
|
+
"closure": "false",
|
|
236
|
+
"maxWaitTime": "600",
|
|
237
|
+
"offerCallback": "true",
|
|
238
|
+
"welcome": "Thank you for calling...",
|
|
239
|
+
"holdMessage": "Please continue to hold..."
|
|
240
|
+
}
|
|
241
|
+
```
|
|
294
242
|
|
|
295
|
-
|
|
243
|
+
**Key Behaviors:**
|
|
296
244
|
|
|
297
|
-
|
|
245
|
+
- Automatically selects the correct language variant based on customer preference
|
|
246
|
+
- Returns chat-specific content for chat contacts (or strips SSML from voice content)
|
|
247
|
+
- Includes all variables as key-value pairs
|
|
248
|
+
- 32KB response size limit (Amazon Connect restriction)
|
|
298
249
|
|
|
299
|
-
|
|
300
|
-
# Start local development server
|
|
301
|
-
npm start
|
|
250
|
+
**Detailed Documentation:**
|
|
302
251
|
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
252
|
+
For complete API documentation, event structures, and advanced usage, see:
|
|
253
|
+
- [Architecture Documentation](./docs/Architecture.md) - Full Lambda integration details
|
|
254
|
+
- [Data Model](./docs/DataModel.md) - Configuration structure and schemas
|
|
306
255
|
|
|
307
|
-
|
|
256
|
+
---
|
|
308
257
|
|
|
309
|
-
|
|
258
|
+
## Development
|
|
310
259
|
|
|
311
|
-
|
|
260
|
+
For developers contributing to FlowConfig or customizing the deployment:
|
|
261
|
+
|
|
262
|
+
**Frontend Development:**
|
|
312
263
|
|
|
313
264
|
```bash
|
|
314
|
-
#
|
|
315
|
-
npm run build
|
|
265
|
+
npm start # Local dev server
|
|
266
|
+
npm run build # Production build
|
|
267
|
+
```
|
|
268
|
+
|
|
269
|
+
**Lambda Development:**
|
|
316
270
|
|
|
317
|
-
|
|
318
|
-
npm run build
|
|
271
|
+
```bash
|
|
272
|
+
npm run build:lambdas # Bundle Lambda functions
|
|
273
|
+
npm run build # Full build (CDK + Frontend + Lambdas)
|
|
319
274
|
```
|
|
275
|
+
|
|
276
|
+
**Additional Resources:**
|
|
277
|
+
- Uses [Lambda PowerTools](https://docs.powertools.aws.dev/lambda/typescript/latest/) for logging
|
|
278
|
+
- OpenAPI spec for API Gateway enables client generation in any language
|
|
279
|
+
- Frontend built with React and Amazon CloudScape Design System
|
|
280
|
+
|
|
281
|
+
For detailed development setup, see [Installation Guide](./docs/Installation.md).
|