[YMCS/YDMP Free Trial Program]Yealink would like to offer Free Trial Program of Yealink device management service for our current eligible customers. You can see the details below.
https://www.yealink.com/ydmp-freetrial-2020


Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
cli friendly API for import/export/delete handset directories & blacklists?
Author Message
warthog9 Offline
Junior Member
**

Posts: 2
Joined: Sep 2021
Reputation: 0
Post: #1
cli friendly API for import/export/delete handset directories & blacklists?
So I'll preface this that I know the W60's web interface has a directory section the ability to export and import the local handset directories, that's not what I'm looking for (though I have no scripting up a selenium browser puppeting to get me access to these, I'll be publishing that once I've got it cleaned up some).

What I'm really looking for is some mechanism to call into the W60 from (preferably) a restful api and get the dump of the handset directories, and wipe them (I personally need the upload anything back, but if this exists it could be useful). My intention is to pull whatever edits / contacts are on the handset and slowly merge them upwards in the stack (remote directory, and up into the fully centralized directory that's more easily shareable across not only the W60 and it's handsets but other phones and situations).

Other Yealink phones have a bit of an API under /cgi-bin/ConfigManApp.com however in attempting to poke at that to get anything useful I didn't get anywhere, and there's precious little documentation about that (in particular with respect to the W60). In an ideal world there would be 3 (ok 4) commands under that:
/cgi-bin/ConfigManApp.com?9990&username=<username>&password=<password> (list handsets to query)
/cgi-bin/ConfigManApp.com?9991&handset=1&addressbook=[xml|csv]&username=<username>&password=<password> (where handset is either an index or name from 9990)
/cgi-bin/ConfigManApp.com?9992&handset=1&delete_addressbook&username=<username>&password=<password> (again where handset is either an index or name from 9990)

I don't actually care about the number involved 999[012] are there for illustrative purposes only. But I'm not seeing that kind of API. I've gone ahead and scripted up basically that API through Selenium, but that's not entirely ideal (although obviously better than nothing).

I've also noticed that handsets note a directory group of "Blacklist"

<group display_name="Blacklist" />

but Blacklist entries in the handset(s) don't seem to actually be stored / exported there. As far as I can tell the blacklist is not accessible in any way from the W60 which seems odd, and I suspect is a bug that those aren't being included in the directory export and the directory delete. Is anyone familiar with what's going on there?

(09-06-2021 04:51 AM)warthog9 Wrote:  [...]

but Blacklist entries in the handset(s) don't seem to actually be stored / exported there. As far as I can tell the blacklist is not accessible in any way from the W60 which seems odd, and I suspect is a bug that those aren't being included in the directory export and the directory delete. Is anyone familiar with what's going on there?

Also as a note the XML that the exporter generates is technically invalid as an empty root_contact generates:

<root_contact />

which generates

# xmllint somefile.xml
somefile.xml:6: parser error : Extra content at the end of the document
<root_contact />
^
#

It's also worth noting that the exported xml files have multiple roots and realistically need to be wrapped in a central single root element to be correct
(This post was last modified: 09-06-2021 05:41 AM by warthog9.)
09-06-2021 04:51 AM
Find all posts by this user    like0    dislike0 Quote this message in a reply
Kylo_Yealink Offline
Junior Member
**

Posts: 2
Joined: May 2021
Reputation: 0
Post: #2
RE: cli friendly API for import/export/delete handset directories & blacklists?
Dear Customer,

This is Kylo from Yealink technical support team, nice to work with you.

1. We don't have any API for W60B.
2. The "/cgi-bin/ConfigManApp.com" you mentioned is one of our phone's features, Action URI, for more information, you can refer to page 443 of Administrator Guide, and FAQ below.
https://support.yealink.com/en/portal/do...adf39aab72
https://support.yealink.com/en/portal/kn...eb70693585
3. Blacklist is a server-based feature, but our phone can support another feature called Blocklist which prevents numbers on the list from calling you.
The "group display_name=Blacklist" may have been written by programmers incorrectly.

I also created a Ticket for you, and you can contact us through Ticket.
https://ticket.yealink.com/page/question...?id=160457

Thank you.

Regards,
Kylo
09-09-2021 07:47 PM
Find all posts by this user    like0    dislike0 Quote this message in a reply
warthog9 Offline
Junior Member
**

Posts: 2
Joined: Sep 2021
Reputation: 0
Post: #3
RE: cli friendly API for import/export/delete handset directories & blacklists?
1) That's unfortunate, I think having a basic API (at least for getting the phonebook and being able to wipe it) would be particularly useful. I do have a selenium setup that can handle this, and I may publish it since I know I've seen requests from others looking for a way to interact with those without having to manually log into the website as a normal user.

2) Thanks for those pointers, it looks like that might be close to what I want, but it doesn't (at least currently) support interacting with the handset phonebooks. The closest thing looks like it might be the "phonecfg=set" and "phonecfg=get", but those don't get me quite close enough. It would be nice if this could be extended to just output (even just straight text) the handset directory, and provide a mechanism to wipe it. This would actually eliminate my need for selenium entirely.

3) The handsets have the ability to add numbers to a blocklist / blacklist that seems to be blocked at the w60 itself, which is fine. I was just hoping to be able to access those, at least similarly to the local handset directory, so that they can be aggregated further up the stack and not directly live on the w60 itself. Since the directory export included the category, I'm definitely hoping that can be included in the export, as well as allow for erasing them at the same time as the local handset directory.

As for the bug I'm getting permission denied, but I do greatly appreciate the bug being opened :-)
09-11-2021 12:55 PM
Find all posts by this user    like0    dislike0 Quote this message in a reply
Kylo_Yealink Offline
Junior Member
**

Posts: 2
Joined: May 2021
Reputation: 0
Post: #4
RE: cli friendly API for import/export/delete handset directories & blacklists?
Hi there,

Trust you had a nice weekend.

You can add numbers to Blocklist on W60, a photo is attached for your reference.
About how to add numbers to Blocklist, press History (Left shortcut), select the desired number then press Options (Right shortcut).

We can't search blocklist on the handset (GUI), but we can find it on the web page (WUI).

If you can't access our Ticket system, could you send us a photo when you access the Ticket I made for you?


Regards,
Kylo


Attached File(s) Thumbnail(s)
   
09-13-2021 06:05 PM
Find all posts by this user    like0    dislike0 Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  [W70B Basis + W73H Handset] 2nd line for foreign country calls der.ronny@gmx.net 1 224 03-20-2024 09:34 PM
Last Post: complex1
  Handset won't ring while on the charger. therring 1 2,157 04-03-2023 09:40 PM
Last Post: FSUE
  W56H handset no tones or ring swdatanet 2 4,432 12-14-2022 07:14 PM
Last Post: adamjames1
  W73P (UK) Contacts Import Kestrel4765 0 1,481 08-22-2022 01:17 AM
Last Post: Kestrel4765
  increase volume on earpiece on W56H handset? Simon from Sydney 0 2,362 05-14-2022 01:08 PM
Last Post: Simon from Sydney
  The handset terminal does not see the base station wasp-1111 2 5,092 01-07-2022 12:14 AM
Last Post: Yisroel_MongoTEL
  W90 W53 W59R Handset Keylock seatelOne 1 5,961 05-01-2021 03:15 PM
Last Post: MISTELECOS
  W60B Handset Intercom meeks726 4 9,997 12-02-2020 03:08 AM
Last Post: meeks726
  incorrect pin during registration of a second handset barny 12 29,639 09-04-2020 06:26 AM
Last Post: kientrucduytan
  W59R Handset jmbjmbjmb 1 6,058 08-16-2020 08:57 PM
Last Post: Yisroel_MongoTEL

Forum Jump:


User(s) browsing this thread: 1 Guest(s)

Contact Us   Yealink   Return to Top   Return to Content   Lite (Archive) Mode   RSS Syndication