ASKLAINFOC ONE CHAT

Install

Put ASKLA on your site

One script tag on every page. ASKLA then answers from the pages in your sitemap, and your team sees every chat in the back office.

1. Add the script

Paste this before </body> on every page, so the chat follows visitors from page to page. Your site's key is in the back office under Settings.

<script src="https://askla.chat/widget.js"
  data-key="pk_your_site_key" defer></script>

Running ASKLA on your own server? Load widget.js from your server's address instead. Add your site's address to the allowed origins in Settings, so no other site can use your key.

2. Point ASKLA at your pages

In the back office, under Content, give ASKLA your sitemap. It reads the pages listed there, and any single page or text you add, and nothing else. Re-read the sitemap whenever your site changes, from the back office or on a schedule you set up: changed pages update, and pages that left the sitemap are removed, along with saved answers that cited them.

3. Choose how it looks and behaves

Set these as attributes on the script tag. Each site's defaults live in Settings.

AttributeWhat it does
data-styleThe chat window: soft (the default), glass, sharp, minimal or welcome. Overrides the style chosen in the back office, for this page.
data-launcherThe button: pill (the default), orb, bar (a question box), mascot or tab (on the page edge).
data-themeThe v0.7.2 name, still read: brand means Sharp, soft means Soft.
data-schemelight, dark or auto to follow the visitor's device.
data-opentrue opens the chat on page load.
data-storageremember (180 days, the default), session (forgotten when the tab closes, for kiosks and shared computers) or none (the chat lasts for the page).
data-fontsfalse stops ASKLA loading its own font, if your site already serves Manrope.

4. Open ASKLA from your own buttons

Any element with data-one-chat opens the chat. Give it a value to ask that question straight away.

<button data-one-chat="Do you support InvoiceNow?">Ask about InvoiceNow</button>

From a script: INFOCOneChat.open(), INFOCOneChat.open('your question'), INFOCOneChat.talk() for the "talk to a person" route, and INFOCOneChat.close(). Single-page apps call INFOCOneChat.navigate('/new/path') after each route change, so suggestions and analytics follow the page.

ASKLA remembers a returning visitor with one random token in your site's storage. If your banner asks first, pass on the visitor's choice:

// after the visitor chooses in your banner
INFOCOneChat.consent(true)   // may remember the visitor
INFOCOneChat.consent(false)  // forget now, on every page and open tab

A "no" holds on every later page without the banner calling again. A page set to data-storage="session" stays that way even after a "yes".

Inside a CMS

Put the script in your site template's footer, so every page has it. The back office can also run inside your CMS: list the CMS address under allowed back-office origins, and your team works in one place.

Questions while you set up? Ask ASKLA on this page, or email the INFOC team.