Page 1 of 1

API Output fields

Posted: Tue Mar 28, 2017 9:27 am
by jeremycoulter
HI.
Is there a way to specify what fields are output by the API when you call in particular "ip/hotspot/active/print"
I noticed that what was out put on an RB with ver 5.X is different to whats output by v 6.x.


Thanks, Jeremy

Re: API Output fields

Posted: Tue Mar 28, 2017 11:26 am
by boen_robot
You can filter properties by using an argument called ".proplist" (including the dot), which is a comma separated list of properties to include.

For example
/ip/hotspot/active/print
=.proplist=user,login-by
may return for example
!re
=user=user1
=login-by=cookie

!re
=user=user2
=login-by=mac
However, you can't rename properties, or include ones that are not there, so any differences between v5 and v6 are still going to be there.