Skip to main content

Veritran Docs

Configure

This function allows you to configure the Glia Visitor Widgets SDK from scratch. You should use this function early in the app's lifecycle (e.g. when starting the application). This way, by the time you need to start the communication, the configuration will already be completed and the engagement will initialize immediately.

In this function, you must configure the input register values shown in the Input Registers section.

Function ID

Register

Value

110

1

Input Registers

Register

Description

Mandatory

Value

390

Configuration JSON

Yes

String containing the following information:

  • siteApiKeyId: API key ID generated in Glia Hub.

  • siteApiKeySecret: API Key Secret generated in Glia Hub.

  • siteId: ID of the site associated with your app, generated in Glia Hub.

  • environmentRegion: Region associated to your app in Glia Hub. Possible values include: us and eur. If a different value is set, the API returns CONFIGURATION_INVALID_ENVIRONMENT_REGION.

  • companyName: Company name set in Glia Hub. Make sure to enter the correct company name as it does not automatically sync it with the site configuration.

  • screenSharingMode: This parameter is only used with Android devices. It allows you to define the way in which the user's screen is shared with the operator. Possible values include: BOUNDED and UNBOUNDED. If the sharing mode is set as bounded, it shares the user's screen only when the app is running in the foreground and is paused if the app goes to the background. This is the default behavior if no parameters are configured. Otherwise, if the sharing mode is set as unbounded, it shares the user's screen at all times, even if the app goes to the background or if the user navigates to a different app.

The JSON here provided should be structured as follows:

{
"siteApiKeyId":"9ba0450a-7cda-48fb-893a-303456abe852",
"siteApiKeySecret":"gls_YgUfIGSYM4NCQwaaAeekQLxaEmvfCTz402nw",
"siteId":"e5be85e9-dd26-4cbd-b0cd-ac375bb5ec95",
"environmentRegion":"us",
"companyName":"VERITRAN",
"screenSharingMode":"BOUNDED"
}

391

Unified UI customization JSON

No

String containing color and style settings to customize the chat. Refer to Glia documentation to learn more about the customization options available.

The JSON here provided should be structured as follows:

{
    "globalColors": {
        "primary": string,
        "secondary": string,
        "baseNormal": string,
        "baseLight": string,
        "baseDark": string,
        "baseShade": string,
        "background": string,
        "systemNegative": string
    }
    "chatScreen": { Object Chat },
    "callScreen": { Object Call },
    "surveyScreen": { Object Survey },
    "bubble": { Object Bubble },
    "alert": { Object Alert },
    "callVisualizer": { Object CallVisualizer },
    "secureConversationsWelcomeScreen": { Object SecureConversationsWelcomeScreen },
    "secureConversationsConfirmationScreen": { Object SecureConversationsConfirmationScreen },
    "webBrowserScreen": { Object WebBrowser },
    "snackBar": { Object SnackBar }
}
Output Registers

Register

Description

Value

112

Call Result

000

NO_ERROR

001

GENERIC_ERROR

002

CONFIGURATION_JSON_FORMAT_ERROR

003

UNIFIED_UI_CUSTOMIZATION_JSON_FORMAT_ERROR

004

INVALID_ENGAGEMENT_TYPE_PARAMETER

005

MISSING_CONFIGURATION_PARAMETERS

006

MISSING_START_ENGAGEMENT_PARAMETERS

007

CONFIGURATION_INITIALIZATION_ERROR

008

START_ENGAGEMENT_INITIALIZATION_ERROR

009

CLEAR_VISITOR_SESSION_ERROR

010

CONFIGURATION_INVALID_ENVIRONMENT_REGION