Hi Team,
I have tried the below code to fetch the group info. Which was successful. But I couldn't able to fetch the contents of the Group.
val portalQueryParameters =
PortalQueryParameters(query = getString(R.string.group_id), limit = 20 )
val groups = portal.findGroups(portalQueryParameters)
I can fetch the group info such as Title which is all good. but I tried to below codes to fetch the item of a particular group based on Id.
val groupId = groups.getOrNull()?.results?.get(0)?.id
val portalGroupContentSearchParameters = PortalGroupContentSearchParameters.query(query = groupId ?: "")
val items = groups.getOrNull()?.results?.get(0)?.findItems(portalGroupContentSearchParameters)
Is that something I am missing. result is success but the item count is 0. But I can view the content items from a ArcGIS web login. I can see 2 items.
I also tried the below code snippet. Items are 0.
val portalQueryParameters =
PortalQueryParameters(query = getString(R.string.group_id), limit = 20 )
val items = portal.findItems(portalQueryParameters)
Is that something related to user access to group items?
Need your help in understanding the flow.
Thanks