Code Monkey home page Code Monkey logo

touchpoint-example's Introduction

Touchpoint example

This is an example of integrating a site with Touchpoint.

Some preset topics are defined in config.json and each is associated with a team. After the user chooses a topic, the server checks if the associated team is available. If it is, the chat is sent to that team, and if it isn't, it is sent to the default team.

If the default team is not available, it will display an email form instead of offering live chat.

Running

# Install dependencies
npm install

# Run
node server.js

Configuration

Configuration is in config.json:

  • site should be https://touchpoint.telviva.com without a trailing /.
  • customerId is the ID of the Touchpoint customer to use. You can find this by logging in on Touchpoint and typing Meteor.user().customerId in the console.
  • port is the port to listen on
  • topics: for example,
[
	{"name": "priceq", "topic": "I have a question about prices", "team": "Sales"},
	{"name": "salesq", "topic": "I have a general sales question", "team": "Sales"},
	{"name": "newhelp", "topic": "I'm a new customer who needs help", "team": "On-boarding"},
	{"name": "login", "topic": "I can't log in", "team": "Support"},
	{"name": "post", "topic": "I'm having problems posting", "team": "Support"},
	{"name": "supportq", "topic": "I have some other issue", "team": "Support"}
]
  • The names are arbitrary identifiers (but they must be unique) and the teams should match the name of a team configured in Touchpoint.
  • userId and authToken are the credentials of an admin user in your customer. You can get these by running:
curl https://touchpoint.telviva.com/api/login -d "[email protected]&password=yourpassword"

touchpoint-example's People

Contributors

michaelstephendavies avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.