getSelectedId of ui.tree, Methods Webix Docs
returns the id(s) of the selected item(s)
string|array getSelectedId( [boolean as_array] );
as_array
If you have not checked yet, be sure to visit site of our main product Webix widget library and page of tree ui product.