Skip to content
Last updated

Zendesk Export Integration CLI

You can export data results from TD to Zendesk Sunshine using CLI (TD Toolbelt).

Prerequisites

  • TD Toolbelt is installed.
  • Basic knowledge of Zendesk Sunshine and Zendesk account.

Limitations

The query must match require columns(name & data type) with target event.

Using the Command Line to Create Your Connection

You can use the CLI to configure your connection.

Configuration keys and descriptions as follows:

Config KeyTypeRequiredDescription
typestringyeszendesk
login_urlstringyesLogin URL for Zendesk
auth_methodstringyesbasic or token or oauth
usernamestringyes if auth_method is basic or tokenYour Zendesk username
passwordstringyes if auth_method is basicZendesk password
tokenstringyes if auth_method is tokenZendesk token
access_tokenstringyes if auth_method is oauthZendesk OAuth access token
targetstringyeswhich export Zendesk target: event_profile, event_profile_id or event_user_id
skip_invalid_recordsstringnocontinue when have invalid record

Connection and Query Examples

Create a event for profiles

td query --database my_db \
         --result '{
            "type": "zendesk",
            "login_url": "https://{example}.zendesk.com",
            "auth_method": "basic",
            "password": "xxxxx",
            "username": "xxxxx",
            "target": "event_profile",
            "skip_invalid_records": false
         }'
         'SELECT profile_source, profile_type, profile_identifier_1, 
          event_source, event_type, event_properties
          FROM your_table;'

Create a event for profile id

td query --database my_db \
         --result '{
            "type": "zendesk",
            "login_url": "https://{example}.zendesk.com",
            "auth_method": "basic",
            "password": "xxxxx",
            "username": "xxxxx",
            "target": "event_profile_id",
            "skip_invalid_records": false
         }'
         'SELECT profile_id, event_source, event_type, event_properties
          FROM your_table;'

Create a event for user id

td query --database my_db \
         --result '{
            "type": "zendesk",
            "login_url": "https://{example}.zendesk.com",
            "auth_method": "basic",
            "password": "xxxxx",
            "username": "xxxxx",
            "target": "event_user_id",
            "skip_invalid_records": false
         }'
         'SELECT user_id, profile_source, profile_type, profile_identifier_1, 
          event_source, event_type, event_properties
          FROM your_table;'