crisp-im / node-crisp-api

:zap: Crisp API Node Wrapper
https://docs.crisp.chat/guides/rest-api/
MIT License
99 stars 39 forks source link

Event not triggering - session:request:initiated #17

Closed rodmi714 closed 3 years ago

rodmi714 commented 4 years ago

This is the code I'm using:


'use strict'

const TOKEN = {
    identifier: '<my-identifier>',
    key: '<my-key>'
}

let Crisp = require('node-crisp-api')

let CrispClient = new Crisp()

console.info('Authenticating...')

CrispClient.authenticate(TOKEN.identifier, TOKEN.key)

console.info('Listening for events...')

CrispClient.on('session:request:initiated', function (message) {
    console.info("Got 'session:request:initiated' event:", message)
})

console.info('Now listening.')
baptistejamin commented 3 years ago

Hello!

Do you still have the same problem on last versions?