ParticipantRole defines a role that a participant can have in the context of a parent record, including the role's name, activation status, and default sharing access. It configures the role itself; it does not identify a particular participant or assign that participant to a record.
The parentObject setting determines the role's object context. The default sharing access is separate from both activation and a participant's effective access, meaning the access the participant ultimately has through all applicable mechanisms.
Key Elements
| Element | What the Element Controls |
|---|---|
defaultAccessLevel |
Required. Default sharing access granted through the role. Allowed values are Edit for Read/Write, Read for Read Only, and None for no default sharing access. |
isActive |
Boolean indicating whether the role is activated. This is separate from defaultAccessLevel. |
masterLabel |
Required. The role's name. This label is distinct from the metadata component's fullName. |
parentObject |
Required. The object context for the role. Supported standard-object values are Account, Budget, IndividualApplication, Interaction, InteractionSummary, FinancialDeal, FundingAward, FundingOpportunity, Opportunity, and Team. Custom objects are also supported. |
fullName |
Inherited metadata component identifier. It identifies the component rather than supplying the role's label or identifying a participant. |
Behavior and Constraints
Default sharing is not a complete access determination. A value of None means the role grants no default sharing access. It does not establish that the participant cannot access the parent record through other means.
Activation and sharing are independent settings. A role with defaultAccessLevel set to Read or Edit is not necessarily active. Check isActive separately rather than inferring activation from the access level.
parentObject identifies an object, not an individual parent record. For a custom-object role, it references the corresponding CustomObject metadata component. Configuring this dependency does not assign a participant to any record.
Deployment and Retrieval
ParticipantRole components use the .participantRole suffix and are stored in the participantRoles folder. The definition requires defaultAccessLevel, masterLabel, and parentObject.
The type supports the * wildcard in a package.xml manifest. To select all components of this type, use * as the members value in a types entry whose name is ParticipantRole. See Deploying and Retrieving Metadata with the Zip File for the file-based manifest structure.
The type extends the Metadata base type and inherits fullName. Keep that component identity distinct from masterLabel, which supplies the role's name.
Relationships
The object dependency comes from parentObject. For custom objects, this is a metadata reference to the object definition, not a reference to a record within it.
References
-
CustomObject:parentObject, when the role's context is a custom object.
Common Questions
Does defaultAccessLevel set to None block record access?
No. None means no default sharing access is granted through the role. A participant can still have access through other means.
Does setting Read or Edit activate a participant role?
No. defaultAccessLevel controls default sharing, while isActive indicates activation. Check the two settings separately.
Can a ParticipantRole use a custom object as its parent?
Yes. parentObject supports custom objects and references the corresponding CustomObject metadata component. It does not identify an individual parent record.
How do I retrieve all ParticipantRole metadata components?
Use a package.xml entry with name set to ParticipantRole and members set to *. The components use the participantRoles folder and the .participantRole suffix.