Localization
Overview
The CCG widget supports language translation for both Embedded and Hosted experiences. Content can be displayed in English or Spanish, with more languages planned for the future. Language can be set programmatically via the session request or, in Hosted experience, by the user via a dropdown.
Supported Languages
| Language | Code |
|---|---|
| English | en |
| Spanish | es |
Language Translation Feature Matrix
| User Type | Embedded: Inline | Embedded: Modal | Embedded: Drawer | Hosted |
|---|---|---|---|---|
| Auth user, Guest user | ✅ | ✅ | ✅ | ✅ |
| Agent | ❌ | ❌ | ❌ | ✅ |
Language Selector Dropdown
CCG provides a language selector dropdown in the Hosted experience, allowing users to switch languages mid-session.
| User Type | Embedded: Inline | Embedded: Modal | Embedded: Drawer | Hosted |
|---|---|---|---|---|
| Auth user, Guest user, Agent | ❌ | ❌ | ❌ | ✅ |
- The dropdown is restricted to Hosted because it triggers a widget reload to apply the language. In embedded widgets, this would require reloading the merchant's page.
- There is no configuration to show or hide this dropdown — it is always present in Hosted experience.
How to Set Preferred Language
Set preferredLanguage in the config.options of the POST Session Request.
Refer to the API documentation for full request details.
Example: Set Preferred Language
{
"config": {
"modes": ["PAYMENT"],
"options": {
"saveDisabled": false,
"preferredLanguage": "es"
}
}
}
Hide the Language Selector Dropdown (Hosted Only)
For agent sessions, you can hide the language selector dropdown using the hideApplicationLanguageSelector flag.
This flag only controls the dropdown for agent sessions. It does not affect agent-initiated customer sessions.
Example: Hide Language Selector Dropdown
{
"appearance": {
"visibility": {
"hideApplicationLanguageSelector": true
}
}
}
Scope & Limitations
The following items are outside the scope of widget language translation:
- API responses from CCG or Stripe — merchants are responsible for translating these.
- Name and Nickname values entered by customers will not be translated.
- Privacy Policy — provide your own translated version. See Optum Privacy Policy.
- ACH mandate, ACH Consent Text, NPS survey/questionnaire
- Text and Email to Add — future feature
- Terms and Conditions — check with legal for translation requirements.
Related Documentation
- Child Session Translation — Agent flow for translating customer (child) sessions
- Widget Capabilities
- Sessions API
- API Reference