最近搜索
没有最近搜索

webmaster groupgia
已加入2023年2月13日
·
最后活动2023年2月13日
关注
0
关注者
0
活动总数
2
投票
0
订阅
1
活动概览
标记
文章
帖子
社区评论
文章评论
活动概览
的最新活动 webmaster groupgia
webmaster groupgia 进行了评论,
评论Setting up Zendesk Chat
Hello good morning,
I am trying to send all the information to the chat but it does not work, I access the intranet from another computer and the history appears empty starting a new conversation
The code is the following:
window.zESettings = {
webWidget: {
authenticate: {
chat: {
jwtFn: function(callback) {
fetch(localStorage["ChatToken"]).then(function(res) {
res.text().then(function(jwt) {
callback(jwt);
});
});
}
}
}
}
};
And the code on the server is the following:
$payload = [
'name' => $nombrecliente ,
'email' => $email,
'external_id' => $ID,
'iat' => time(),
'nbf' => 1357000000
];
$key = '**';
/**
* IMPORTANT:
* You must specify supported algorithms for your application. See
* https://tools.ietf.org/html/draft-ietf-jose-json-web-algorithms-40
* for a list of spec-compliant algorithms.
*/
$jwt = JWT::encode($payload, $key, 'HS256');
This should make our client see his chat history when accessing the intranet, is that correct?
查看评论 · 已于 2023年2月13日 发布 · webmaster groupgia
0
关注者
0
投票
0
评论