Skip to main content

auth.Group

Groups are a generic way of categorizing users to apply permissions, or some other label, to those users. A user can belong to any number of groups.

A user in a group automatically has all the permissions granted to that group. For example, if the group 'Site editors' has the permission can_edit_home_page, any user in that group will have that permission.

Beyond permissions, groups are a convenient way to categorize users to apply some label, or extended functionality, to them. For example, you could create a group 'Special users', and you could write code that would do special things to those users -- such as giving them access to a members-only portion of your site, or sending them members-only email messages.

Fields

Field Type Description
id Integer ID
name String (up to 150) name
natural_key
permissions.all List

all related auth.Permission objects

permissions.count Integer

number of related auth.Permission objects

user_set.all List

all related auth.User objects

user_set.count Integer

number of related auth.User objects

‹ Back to Model documentation