-3

为了Store.Presence.find( phonenumber+ '@c.us').then(function(r){ console.log(r)})在whatsApp中获取用户的状态(在线/离线)和输入状态,我在检索结果对象后使用了该功能,我总是得到错误的离线状态,因为我用我的电话号码进行了测试。

那么 WhatsAPI 中存在(在线/离线)状态和打字功能的最新功能是什么?

4

1 回答 1

0
    var check = window.setInterval( function() {
        Store.Presence.find( phonenumber + '@c.us' ).then(  function(d) {
            if (d.isOnline) {
                console.log( phonenumber + " is ONLINE" );
                // do something with it
            }
        });
    } , 2000);

还在工作。

于 2017-12-31T21:37:52.203 回答