def list_employees(order_by='id'):
 ret = {}
 (status, result) = _query(action='employees', command='directory')
 root = ET.fromstring(result)
 directory = root.getchildren()
 for cat in directory:
  if (cat.tag != 'employees'):
   continue
  for item in cat:
   emp_id = item.items()[0][1]
   emp_ret = {'id': emp_id}
   for details in item.getchildren():
    emp_ret[details.items()[0][1]] = details.text
   ret[emp_ret[order_by]] = emp_ret
 return ret

def list_employees ( order_by = 'id' ) : ret = { } ( status , result ) = _query ( action = 'employees' , command = 'directory' ) root = ET . fromstring ( result ) directory = root . getchildren ( ) for cat in directory : if ( cat . tag != 'employees' ) : continue for item in cat : emp_id = item . items ( ) [ 0 ] [ 1 ] emp_ret = { 'id' : emp_id } for details in item . getchildren ( ) : emp_ret [ details . items ( ) [ 0 ] [ 1 ] ] = details . text ret [ emp_ret [ order_by ] ] = emp_ret return ret
show all employees for this company .