Get current Open instanceGuid, from Multiple Tabs
I am trying to get instanceGuid of currently open tab,
for example, in below Screenshot, we can see two users tab are open,
1) Test User 74
2) Test User 102
Now, when I get all instances, using below code
client.get('instances').then(function(instancesData) {
var instances = instancesData.instances;
});
In response I am getting two User Instances,
{
"5a5ec8ca-b4a9-40c3-a420-f0a786a69878": {
"host": "zendesk",
"product": "support",
"location": "background",
"instanceGuid": "5a5ec8ca-b4a9-40c3-a420-f0a786a69878",
"account": {
"subdomain": "d3v-reliablepbxcorp"
},
"status": "registered"
},
"8afab703-9ead-4b5b-9578-e59e0673f491": {
"host": "zendesk",
"product": "support",
"location": "top_bar",
"instanceGuid": "8afab703-9ead-4b5b-9578-e59e0673f491",
"account": {
"subdomain": "d3v-reliablepbxcorp"
},
"status": "registered"
},
"b420af61-15e3-400d-abd9-2fee9e64ae52": {
"host": "zendesk",
"product": "support",
"location": "user_sidebar",
"instanceGuid": "b420af61-15e3-400d-abd9-2fee9e64ae52",
"account": {
"subdomain": "d3v-reliablepbxcorp"
},
"userId": 9621219576093,
"status": "registered"
},
"3cd3b4fb-7bab-474e-995b-0df42d6636e4": {
"host": "zendesk",
"product": "support",
"location": "user_sidebar",
"instanceGuid": "3cd3b4fb-7bab-474e-995b-0df42d6636e4",
"account": {
"subdomain": "d3v-reliablepbxcorp"
},
"userId": 9473787975965,
"status": "registered"
}
}
So, Out of them, How do I know which one is currently open tab?
Por favor, entrar para comentar.
0 Comentários