list_permissions
async
¶
list_permissions(
workspace_id: WorkspaceId,
*,
config_overrides: Optional[AsyncgrafanaClientConfig] = None,
max_results: Optional[int] = None,
next_token: Optional[PaginationToken] = None,
user_type: Optional[UserType] = None,
user_id: Optional[SsoId] = None,
group_id: Optional[SsoId] = None,
) -> ListPermissionsResponse
Lists the users and groups who have the Grafana Admin and Editor roles in this workspace. If you use this operation without specifying userId or groupId, the operation returns the roles of all users and groups. If you specify a userId or a groupId, only the roles for that user or group are returned. If you do this, you can specify only one userId or one groupId.
Parameters:
-
max_results(Optional[int], default:None) –The maximum number of results to include in the response.
-
next_token(Optional[PaginationToken], default:None) –The token to use when requesting the next set of results. You received this token from a previous
ListPermissionsoperation. -
user_type(Optional[UserType], default:None) –(Optional) If you specify
SSO_USER, then only the permissions of IAM Identity Center users are returned. If you specifySSO_GROUP, only the permissions of IAM Identity Center groups are returned. -
user_id(Optional[SsoId], default:None) –(Optional) Limits the results to only the user that matches this ID.
-
group_id(Optional[SsoId], default:None) –(Optional) Limits the results to only the group that matches this ID.
-
workspace_id(WorkspaceId) –The ID of the workspace to list permissions for. This parameter is required.
Raises:
-
AccessDeniedException–You do not have sufficient permissions to perform this action.
-
InternalServerException–Unexpected error while processing the request. Retry the request.
-
ResourceNotFoundException–The request references a resource that does not exist.
-
ThrottlingException–The request was denied because of request throttling. Retry the request.
-
ValidationException–The value of a parameter in the request caused an error.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_grafana/_services/async_grafana.py
1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 | |