Search code examples
javascriptjsonapiqliksense

How to connect to a Qlik Engine API


I've been searching on Qlik documentation about how to connect a JS code to Qlik Engine, but apparently there is no concrete instructions about that, or am I misunderstanding the documentation?

According, it says that the WebSocket is assignes to a variable in the following declaration:

var ws = new WebSocket("ws://localhost:4848/app/");

Also the documentation talks about the JSON object that Engine API must receive and the JSON that outputs. But, what happens after that? How to I know if it is really connected? Does exists a kind of ws.connect("?") function? That's what I'm looking trough the documentation...

Greetings!


Solution

  • You can use Enigma.js which is a JS wrapper for communicating with the Engine API. Enigma is the official Qlik JS library. Check out the Enigma basic example to get started

    qsocks was the first JS wrapper (deprecated)

    For reactive applications RxQ can be used