API Stability Preview

The groupsAndUsersWithPermissionsOnAsset() GraphQL query is used to search groups and users with permissions on the asset.

Syntax

Below is the syntax for the groupsAndUsersWithPermissionsOnAsset() query field:

graphql
groupsAndUsersWithPermissionsOnAsset(
      searchDomainName: string!, 
      assetType: AssetPermissionsAssetType!, 
      assetId: string!, 
      searchFilter: string, 
      groupsOrUsersFilters: [GroupsOrUsersFilter!], 
      limit: integer, 
      skip: integer, 
      orderBy: OrderBy, 
      includeEmptyPermissionSet: boolean!
   ): UserOrGroupAssetPermissionSearchResultSet!

searchDomainName is the name of the search domain to search. For files, use the name of the file. For assetTypes (see Given Datatypes below). If includeEmptyPermissionSet is set to true, users and groups that don't have access to the asset will be included.

Below is an example of this query field with a few values requested:

Show:
graphql
query {
	groupsAndUsersWithPermissionsOnAsset(
    searchDomainName: "humio",
    assetType: SavedQuery,
    assetId: "1S2bN2y5JwrzP6wEHHAQtL7bicF8mS0Y",
    groupsOrUsersFilters: Users,
    includeEmptyPermissionSet: false
  )
  { totalResults  }
}
Example Responses
Show:
json
{
  "data": {
    "groupsAndUsersWithPermissionsOnAsset": {
      "totalResults": 0
    }
  }
}

Given Datatypes

AssetPermissionsAssetType is an enumerated list of choices.

Table: AssetPermissionsAssetType

ParameterTypeRequiredDefaultStabilityDescription
Some arguments may be required, as indicated in the Required column. For some fields, this column indicates that a result will always be returned for this column.
Table last updated: Sep 13, 2024
Actionboolean  PreviewThe asset permission is related to an action.
AggregateAlertboolean  PreviewThe asset permission is related to an aggregate alert.
Dashboardboolean  PreviewThe asset permission is related to a dashboard.
Fileboolean  PreviewThe asset permission is related to a file.
FilterAlertboolean  PreviewThe asset permission is related to a filter alert.
LegacyAlertboolean  PreviewThe asset permission is related to a legacy alert.
SavedQueryboolean  PreviewThe asset permission is related to a saved query.
ScheduledReportboolean  PreviewThe asset permission is related to a scheduled report.
ScheduledSearchboolean  PreviewThe asset permission is related to a scheduled search.

GroupsOrUsersFilter is an enumerated list of two choices:

Table: GroupsOrUsersFilter

ParameterTypeRequiredDefaultStabilityDescription
Some arguments may be required, as indicated in the Required column. For some fields, this column indicates that a result will always be returned for this column.
Table last updated: Feb 27, 2025
Userboolean  PreviewWhether the filter is based on a user.
Groupboolean  PreviewWhether the filter is based on a group.

Returned Datatypes

The returned datatype UserOrGroupAssetPermissionSearchResultSet has a couple of parameters, and some sub-parameters. Below is a list of them:

Table: UserOrGroupAssetPermissionSearchResultSet

ParameterTypeRequiredDefaultStabilityDescription
Some arguments may be required, as indicated in the Required column. For some fields, this column indicates that a result will always be returned for this column.
Table last updated: Mar 3, 2025
results[UserOrGroupTypeAndPermissions]yes PreviewThe paginated result set. See UserOrGroupTypeAndPermissions.
totalResultsintegeryes PreviewThe total number of matching results.