Skip to main content
Skip table of contents

Connecting to LiveChat via SQL

You can use SQL to connect to LiveChat in the CData Virtuality Studio or the Code Editor in the Web UI.

Pre-requisites

  • You need the username, password, ClientId, ClientSecret.

How to Connect

Before you start retrieving data, you need to run the connector script for LiveChat in the CData Virtuality Studio or the Web UI and input your credentials in the following line: 

SQL
CALL SYSADMIN.createConnection (
    name => 'livechat_src'
    ,jbossCLITemplateName => 'ws'
    ,connectionOrResourceAdapterProperties => 'EndPoint=https://api.livechatinc.com/reports,AuthUserName=<AuthUserName>,AuthPassword=<AuthPassword>,ClientId=<ClientId>,ClientSecret=<ClientSecret>'
);;
 
CALL SYSADMIN.createDataSource (
    name => 'livechat_src'
    ,translator => 'livechat'
    ,modelProperties => 'multitenancy_tablename=<Multitenancy Tablename>'
    ,translatorProperties => ''
);;

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.