I've using this method to list informations of the phones (for a web site developping in PHP)
https://<server IP>:<server port>/inyama/service/logicaldevice/getForwarding
My algorithm :
- open session avaya
- for all phone (X = 1 : 10)
Getforwarding (phone X)
print (fwdTo for phone X)
- close session
The response of the API is HTTP 202 Accepted
But I have not the response for phone X , i can have twice response for the same phone
exemple of response :
{"ns3_telephonyPresenceEvent":{"telephonyPresence":{"forDevice":"201618","stateUnknown":"false","canPickup":"false","ringing":"false","onhook":"true","online":"false","dndon":"false","inservice":"true","fwdon":"false","fwdTo":{}}}
for example :
GetForwarding (phone 201618) => response for phone 201829
GetForwarding (phone 201829) =>response for phone 201732
GetForwarding (phone 201732) =>response for phone 201829
I change my algorithm to open and close session for each Getforwarding : I have the good response but the page who I print informations is too long (15 seconds for only 10 phones).
have you a idea why my first algorithm is not OK ?
or how I can developp this ?
tks
|