MonoCloud Authentication SDK
    Preparing search index...
    isUserInGroup: (
        user: MonoCloudUser | IdTokenClaims,
        groups: string[],
        groupsClaim?: string,
        matchAll?: boolean,
    ) => boolean

    Checks if a user is a member of a specified group or groups.

    Type Declaration

      • (
            user: MonoCloudUser | IdTokenClaims,
            groups: string[],
            groupsClaim?: string,
            matchAll?: boolean,
        ): boolean
      • Parameters

        • user: MonoCloudUser | IdTokenClaims

          The user.

        • groups: string[]

          An array of group names or IDs to check membership against.

        • OptionalgroupsClaim: string

          The claim in the user object that contains groups.

        • OptionalmatchAll: boolean

          If true, requires the user to be in all specified groups; if false, checks if the user is in at least one of the groups.

        Returns boolean

        true if the user is in the specified groups, false otherwise.