Newer Version Available

This content describes an older version of this product. View Latest

PermissionSetGroup (Beta)

Represents a group of permission sets and the permissions within them. Use permission set groups to organize permissions based on job functions or tasks. Then, you can package the groups as needed. This type extends the Metadata metadata type and inherits its fullName field.

Declarative Metadata File Suffix and Directory Location

Permission set groups are stored in the permissionsetgroups directory. The file name matches the permission set API name and the extension is .permissionsetgroup. For example, a permission set group with the name Finance_Mgmt_PermSetGroup is stored in permissionsetgroups/Finance_Mgmt_PermSetGroup.permissionsetgroup.

Version

Permission set groups are available in API version 45.0 and later.

As a beta feature, PermissionSetGroup is a preview and isn’t part of the “Services” under your master subscription agreement with Salesforce. Use this feature at your sole discretion, and make your purchase decisions only on the basis of generally available products and features. Salesforce doesn’t guarantee general availability of this feature within any particular time frame or at all, and we can discontinue it at any time. This feature is for evaluation purposes only, not for production use. It’s offered as is and isn’t supported, and Salesforce has no liability for any harm or damage arising out of or in connection with it. All restrictions, Salesforce reservation of rights, obligations concerning the Services, and terms for related Non-Salesforce Applications and Content apply equally to your use of this feature. You can provide feedback and suggestions for PermissionSetGroup in the Trailblazer Community.

Note

Fields

Field Field Type Description
description string The permission set group description provided by the permission set group creator.
label string Required. The permission set group label.
mutingPermissionSets string A permission set containing permissions to disable in the permission set group. Available in API version 46.0 and later.
permissionSets string A permission set or permission sets included in the permission set group.
status string Indicates permission set group recalculation status. Valid values are:
  • Updated—The group is current.
  • Outdated—The group requires recalculation.
  • Updating—The group is in recalculation mode.
  • Failed—The group recalculation failed.

Declarative Metadata Sample Definition

When adding a permission set group, you can do something like this. Individual permissions are included in the permission set referenced, not in the permission set group.

1<?xml version="1.0" encoding="UTF-8"?>
2<PermissionSetGroup xmlns="http://soap.sforce.com/2006/04/metadata">
3     <fullName>Finance_Mgmt_PermSetGroup</fullName>
4     <description>Finance_Mgmt_PermSetGroup desc</description>
5     <label>Finance_Mgmt_PermSetGroup</label>
6     <permissionSets>Billing_PS</permissionSets>
7</PermissionSetGroup>

The permission set Billing_PS contains the individual permissions included in Finance_Mgmt_PermSetGroup.

1<?xml version="1.0" encoding="UTF-8"?>
2<PermissionSet xmlns="http://soap.sforce.com/2006/04/metadata">
3     <fullName>Billing_PS</fullName>
4     <description>Billing_PS</description>
5     <label>Billing_PS</label>
6     <license>Salesforce</license>
7     <userPermissions>
8          <enabled>true</enabled>
9          <name>ViewSetup</name>
10     </userPermissions>
11     <userPermissions>
12          <enabled>true</enabled>
13          <name>ViewRoles</name>
14     </userPermissions>
15     <userPermissions>
16          <enabled>true</enabled>
17          <name>EditBillingInfo</name>
18    </userPermissions>
19</PermissionSet>

This example package.xml manifest retrieves the PermissionSetGroup metadata for an org. When you retrieve permission set groups, also retrieve the related components. For example, to retrieve PermissionSetGroup, you must also retrieve PermissionSet.

1<?xml version="1.0" encoding="UTF-8"?>
2<Package xmlns="http://soap.sforce.com/2006/04/metadata">
3     <types>
4          <members>Finance_Mgmt_PermSetGroup</members>
5          <name>PermissionSetGroup</name>
6     </types>
7     <types>
8          <members>Billing_PS</members>
9          <name>PermissionSet</name>
10     </types>
11     <version>45.0</version>
12</Package>