Group Query
-
Do we have an accurate way to query XO Groups and their members via REST api?
I am able to get this via xo-cli groups.getAll but was hoping this could be done via rest, this would be useful for reporting in larger environments like the one I am operating in
-
Question for @julien-f
-
@M92 Hello, no, groups are not exposed at this time, will do it ASAP.
-
Thanks Julien, will we also be able to use Filter in the query?
A nice to have is if the username inside the groups is returned instead of just the UUID, but I can match this from another query/table if I need to.
I am not sure if this is resolved either but there was an issue where results were truncated after 100 lines in some queries. I have far more than 100 lines to return, but this may already be fixed
-
@M92 There is now a
/groups
collection which lists all the groups and two new collections,/groups/:id/users
and/users/:id/groups
which list respectively all users in a group and all groups a user belongs to.These new collections have the same behaviours than the others, which means they accept the
fields
,filter
andlimit
parameters.And yes the
limit
parameter should work correctly, let me know if you have any issue. -
Do I need to switch release channel on XOA? I swapped to latest over stable but no luck
Appreciate the fast turnaround
-
@M92 These changes will be in the next release. To try them now you would need to build from sources.
-
@Danp No problem, I will build from sources to at least test and modify a few scripts we are running. Thanks!
-
As @Danp said, changes appear first in the GitHub repo and are available for the XOAs at the next release in the
latest
channel.But, as it appear, we just did a new patch release (5.91.2) which also contains the REST API changes we talked about