Study guide
12.1 Data Security, Org-Wide Defaults (OWD) & Sharing Architecture
Salesforce Accredited Agentforce 360 for Public Sector Professional Exam
Track your progress as you read
Finished sections get a check mark.
1 Chapter 1: Overview, Architecture & Constituent Data Modeling
1.1 AP-222 Exam Blueprint, Passing Standards & Credential Overview 1.2 Public Sector Solutions Layered Architecture & Industry Common Layer 1.3 Person Accounts & Constituent Data Modeling
2 Chapter 2: Licenses, Permits, and Inspections (LPI) — Intake & Issuance
2.1 Regulatory Authorization Types & Application Intake 2.2 Business License & Permit Issuance, Conditions & Status Tracking 2.3 Application Reviews, Multi-Department Approvals & Renewals
3 Chapter 3: Inspections, Code Enforcement, and Compliance
3.1 Inspection Types, Action Plan Templates & Onsite Visit Execution 3.2 Regulatory Codes, Assessment Indicators & In-Field Checklists 3.3 Regulatory Code Violations, Enforcement Actions & Remediation Workflows
4 Chapter 4: Grants Management & Grantmaking Lifecycle
4.1 Funding Programs, Funding Opportunities (NOFOs) & Public Discovery 4.2 Grant Application Intake, Review Workspaces & Multi-Stage Scoring 4.3 Funding Awards, Disbursement Schedules & Post-Award Reporting
5 Chapter 5: Benefits Management & Assistance Programs
5.1 Benefit Programs, Benefit Schedules & Beneficiary Data Architecture 5.2 Discovery Framework Assessments & Question Versioning 5.3 Rules-Based Eligibility Determination & Recertification Lifecycle
6 Chapter 6: Employee Experience & Emergency Response Management
6.1 Public Sector Employee Experience & Workforce Operations 6.2 Emergency Response Management (ERM) Intake, Triage & Incident Dispatch 6.3 Rapid Resource Allocation, Volunteer Coordination & Contact Tracing
7 Chapter 7: Document Processing, Intelligent Automation & Reporting
7.1 Document Checklist Items, Content Management & Upload Portals 7.2 Intelligent Document Automation (IDA), the Document Workspace & the IDA vs. IDA/IFR Decision 7.3 Intelligent Document Reader (OCR with Amazon Textract) & eSignature Integration 7.4 OmniStudio Document Generation & Dynamic PDF Production 7.5 Public Sector Operational Reporting, Compliance Dashboards & CRM Analytics
8 Chapter 8: OmniStudio for Public Sector — Guided Intake & 360 Views
8.1 OmniScript Architecture, Step Design & Conditional Branching 8.2 Data Prefill Patterns, Context Passing & Save-for-Later 8.3 FlexCard Architecture, Constituent 360 Layouts & Action Frameworks
9 Chapter 9: OmniStudio Integration & Server-Side Processing
9.1 Data Mappers (DataRaptors) — Turbo Extract, Extract, Transform & Load 9.2 Integration Procedures — Action Chaining, Batching & Error Handling 9.3 External API Integrations, HTTP Actions & Named Credentials
10 Chapter 10: Business Rules Engine (BRE) & Dynamic Fee Calculation
10.1 Expression Sets — Calculation Steps, Formulas & Versioning 10.2 Decision Tables & Decision Matrices for Policy Decisioning 10.3 Dynamic Fee Schedules, Calculation Procedures & Regulatory Pricing
11 Chapter 11: Experience Cloud Citizen Portals & Service Console
11.1 Public Sector Experience Cloud Site Templates & Citizen Self-Service 11.2 Guest vs. Authenticated User Journeys & Identity Verification 11.3 Multilingual Localization, Custom Labels & Translation Workbench 11.4 Public Sector Service Console, Workspace Tabs & Omni-Channel Routing
12 Chapter 12: Security, Compliance, Government Cloud & Best Practices
12.1 Data Security, Org-Wide Defaults (OWD) & Sharing Architecture 12.2 Government Cloud Tiers, FedRAMP & DoD Compliance 12.3 Salesforce Shield, Field Audit Trail & Platform Encryption 12.4 Declarative-First Strategy, Process Library & Deployment with IDX Workbench
13 Chapter 13: Agentforce & AI Innovation for Public Sector
13.1 Agentforce Architecture, Agent Builder & Public Sector Agents 13.2 Topic Definitions, Instructions, Actions & CRM/Data Cloud Grounding 13.3 Einstein Trust Layer, Guardrails & Responsible AI Governance
14 Chapter 14: Discovery, Requirements & Solution Design
14.1 Documenting Business Needs, Agency Value & Vision for Desired Outcomes 14.2 Discovery & Design Approaches and Solution Documentation 14.3 Mapping Business Processes, Personas & Requirements
15 Chapter 15: Org Setup, Data Management & Integration Governance
15.1 Setting Up an Org for Agentforce Public Sector 15.2 Data Management Strategy, Data Quality & Integration Governance
12.1 Data Security, Org-Wide Defaults (OWD) & Sharing Architecture
Key Takeaways Explain This Topic AI
Organization-Wide Defaults (OWD) for public sector core entities (Person Accounts, IndividualApplication, BusinessLicenseApplication, Visit, and BenefitAssignment) must strictly be configured as Private to comply with statutory PII, CJIS, and HIPAA confidentiality baselines.
The internal sharing architecture follows a defense-in-depth model: Role Hierarchy provides vertical roll-up access, Criteria-Based Sharing Rules grant lateral cross-departmental access, and Public Groups facilitate multi-agency review panels.
Restriction Rules deterministically block record access even if users inherit access via Role Hierarchy or Sharing Rules, making them the mandatory declarative mechanism for isolating sealed juvenile records, whistleblower reports, and confidential investigations.
High-volume Customer Community users do not participate in standard sharing tables; they require Sharing Sets (matching User.ContactId or User.AccountId to target record lookups) and Share Groups to grant internal users access to portal-owned records.
Programmatic Apex Managed Sharing with custom Apex Sharing Reasons is reserved for complex, dynamic multi-party grants (such as rotating peer review panels) that exceed the declarative evaluation capabilities of Sharing Sets and Sharing Rules.
Last updated: September 2026
12.1 Data Security, Org-Wide Defaults (OWD) & Sharing Architecture
Exam Focus: Public sector agencies handle some of the most sensitive constituent data in society—ranging from child protective services cases and criminal history to healthcare disclosures and welfare disbursements. Designing a data access architecture that strictly adheres to statutory confidentiality mandates while simultaneously enabling multi-departmental collaboration is a core requirement of the AP-222 blueprint. Architects must master baseline Organization-Wide Defaults (OWD), internal sharing mechanics (Role Hierarchy, Criteria-Based Sharing, Restriction Rules, Scoping Rules), and external sharing paradigms (Sharing Sets and Share Groups for high-volume Community users).
Public Sector Data Classifications & Statutory Mandates
In commercial CRM deployments, data sharing is often designed around open collaboration—sales teams and service agents frequently share visibility into leads, accounts, and opportunities. In Public Sector Solutions (PSS), this paradigm is reversed: data must remain strictly compartmentalized under the principle of least privilege .
Government agencies operate under rigorous federal, state, and international statutory frameworks:
Personally Identifiable Information (PII) & Sensitive PII: Full legal names, Social Security Numbers (SSN), Individual Taxpayer Identification Numbers (ITIN), biometric data, dates of birth, and banking details. Regulated under state data privacy laws, OMB mandates, and the Privacy Act of 1974.
Criminal Justice Information Services (CJIS): Criminal history record information (CHRI), biometric scans, arrest records, and investigative notes collected by law enforcement and regulatory enforcement agencies. CJIS Security Policy mandates logical separation, encryption at rest, and strict role-based access.
Health Insurance Portability and Accountability Act (HIPAA): Protected Health Information (PHI) and electronic PHI (ePHI) captured during Medicaid enrollment, disability assistance evaluations, or public health contact tracing.
Financial Disclosures & Taxpayer Information: Audited corporate balance sheets, Federal Tax Information (FTI governed by IRS Publication 1075), and personal income verifications submitted during means-tested benefit or grant evaluations.
Failure to enforce airtight data isolation can lead to statutory penalties, revocation of federal agency Authorization to Operate (ATO), and severe public trust compromises.
Baseline Organization-Wide Defaults (OWD): The Private Mandate
Organization-Wide Defaults (OWD) establish the baseline level of access that the most restricted user in an organization has to records they do not own.
On the AP-222 exam, a fundamental architectural rule applies: For all core constituent, licensing, inspection, and benefit entities, the baseline Org-Wide Default must be set to Private .
Setting OWD to Public Read-Only or Public Read/Write on constituent records is an automatic failure on the examination and an unacceptable security vulnerability in government.
Public Sector Object Recommended OWD (Internal) Recommended OWD (External) Architectural Justification
Account (Person Account) Private Private Stores constituent PII, personal phone numbers, home addresses, SSN/ITIN, and household relationships.
Account (Business Account) Private (or Public Read-Only in select commercial registries) Private Commercial entities applying for permits may contain confidential proprietary business financials and trade secrets.
Contact Controlled by Parent (or Private ) Private Inherits permissions from the associated Account.
IndividualApplication Private Private Contains sensitive personal license or permit requests, personal affidavits, and background disclosures.
BusinessLicenseApplication Private Private Contains commercial permit applications, zoning compliance filings, and pending regulatory reviews.
Visit Private Private Field inspection records detailing code enforcement assessments, health violations, and scheduled site visits.
RegulatoryCodeViolation Private Private Substantiated statutory code infractions, pending enforcement actions, and confidential complainant details.
BenefitAssignment / ProgramEnrollment Private Private Contains social safety net participation, Medicaid/SNAP enrollment, and means-tested cash assistance data.
DocumentChecklist Controlled by Parent Controlled by Parent Securely inherits visibility from the parent Application or Account to which files are attached.
Internal Sharing Architecture: Vertical, Lateral & Deterministic Isolation
Once the baseline OWD is established as Private , access is opened selectively to internal staff based on job role, jurisdictional responsibility, and case assignment. +-----------------------------------------------------------------------------------+
- | Internal Sharing Architecture Layering |
- +-----------------------------------------------------------------------------------+
- | [1. OWD: Private] --> Mandatory baseline lockdown for all PSS entities |
- | [2. Role Hierarchy] --> Vertical managerial roll-up access |
- | [3. Criteria Sharing] --> Lateral cross-departmental & jurisdictional access |
- | [4. Public Groups/Queues] --> Multi-agency intake queues and review panels |
- | [5. Restriction Rules] --> Deterministic hard filter (overrides all above) |
- +-----------------------------------------------------------------------------------+
- 1. Role Hierarchy: Vertical Management Roll-Up
The Role Hierarchy automatically grants users higher in the hierarchy the same level of record access as users below them.
In PSS, the Role Hierarchy typically reflects the agency's operational structure (e.g., Agency Director -> Regional Supervisor -> District Case Worker / Field Inspector ).
Architectural Exception ( Grant Access Using Hierarchies ): For custom objects and certain standard objects, administrators can uncheck "Grant Access Using Hierarchies." In public sector scenarios involving Internal Affairs , Whistleblower Complaints , or Confidential Ethics Inquiries , this setting must be disabled to prevent senior agency executives from viewing confidential investigations involving themselves or their direct reports.
2. Criteria-Based Sharing Rules & Public Groups
Criteria-based sharing rules grant record access to defined groups of users when record fields meet specific values:
Jurisdictional Sharing: A rule sharing BusinessLicenseApplication records where Jurisdiction__c == 'Northern District' with the Northern District Reviewers Public Group with Read/Write access.
Program-Specific Sharing: A rule granting the Child Welfare Case Managers Public Group read access to IndividualApplication records where Program_Type__c == 'Foster Care Assistance' .
Public Groups vs. Queues: Queues act as record owners during intake triage (e.g., Unassigned Intake Queue ). Once a record is claimed by an individual worker, Public Groups maintain shared visibility for multi-disciplinary review teams (e.g., Fire Department, Public Works, and Public Health reviewers).
3. Restriction Rules vs. Scoping Rules
Introduced to address complex public sector compliance requirements, Restriction Rules and Scoping Rules represent a critical testing area on the AP-222 exam.
Dimension Restriction Rules Scoping Rules
Core Function Blocks record access deterministically. Overrides and constrains sharing rules. Filters default view noise without altering underlying record sharing permissions.
How It Works Evaluates a user criteria formula AND a record criteria formula. If the criteria are not met, the record is completely invisible across all queries, reports, and search. Controls default records displayed in List Views and SOSL Searches. Users can still toggle to "All Records" to view records they have access to.
Public Sector Use Case Sealed Juvenile Records: Conceals juvenile court records and child welfare cases from standard caseworkers, restricting visibility exclusively to authorized juvenile specialists and judges. Regional Intake Views: Directs Chicago-based building inspectors to see Chicago visits by default, while allowing them to explicitly search downstate records when cross-assigned.
Impact on SOQL / Reports Hard filter: Records excluded by Restriction Rules do not return in SOQL queries or reports, even in WITHOUT SHARING contexts where platform security applies. Soft filter: Excluded records remain accessible if the query does not filter on the scoping context.
Important
Key Exam Distinction: Sharing rules can only grant access; they can never restrict access below the OWD baseline. When an exam question requires hiding a subset of sensitive records (such as sealed cases, confidential informant reports, or VIP constituent records) from users who would otherwise inherit access via Role Hierarchy or Sharing Rules, the ONLY declarative platform solution is a Restriction Rule .
External Sharing Architecture: Portals & High-Volume Community Users
Public agencies engage millions of constituents via Experience Cloud citizen portals. Designing the external sharing architecture requires balancing massive user scalability with strict constituent privacy.
High-Volume Portal Licenses (Customer Community)
The vast majority of public sector constituents are provisioned with Customer Community licenses (high-volume portal licenses).
The Architectural Constraint: High-volume Customer Community users do not utilize the standard Salesforce sharing table ( Object__Share ). Standard sharing rules, role hierarchies, and manual sharing do NOT apply to high-volume portal users.
The Solution: Sharing Sets. A Sharing Set grants high-volume community users access to records that match a relationship between the user's User record (specifically User.ContactId or User.AccountId ) and an Account or Contact lookup field on the target object. +---------------------------+ +--------------------------------+
- | Authenticated Constituent | | Target PSS Record |
- | User Record | | (e.g., IndividualApplication) |
- | * ContactId = 003xx... | | * AccountId = 001xx... |
- | * AccountId = 001xx... | | * Applicant_Contact__c = 003xx.|
- +-------------+-------------+ +----------------+---------------+
- | |
- +-------------> [ Sharing Set ] <----------+
- Matches: User.ContactId ==
- IndividualApplication.Applicant_Contact__c
- Grants: Read/Write Access
- Key Elements of the External Sharing Stack
Sharing Sets:
Evaluates direct relationships: Matches User.AccountId to BusinessLicenseApplication.AccountId (for commercial contractors) or User.ContactId to IndividualApplication.ApplicantContactId (for citizen applicants).
Allows high-volume portal users to securely view, edit, and track their own applications, inspections, and benefits without consuming internal sharing infrastructure.
Share Groups:
Records created and owned by high-volume Customer Community users have no role in the internal hierarchy.
A Share Group is configured to grant specified internal Salesforce users (e.g., intake supervisors or public assistance caseworkers) access to records owned by high-volume community users.
Customer Community Plus & Partner Community Licenses:
Used for specialized external personas requiring advanced sharing capabilities, such as delegated third-party architectural review consultants, external legal counsel, or foster care placement agency partners.
These licenses possess individual roles in the Role Hierarchy, participate in standard Object__Share tables, and support Criteria-Based Sharing Rules and Manual Sharing.
Programmatic Sharing: When Apex Managed Sharing is Required
While declarative configuration is always the primary architecture in PSS, certain complex statutory requirements demand Apex Managed Sharing .
Evaluation Criteria: Declarative vs. Programmatic Sharing
Use Declarative Sharing (Sharing Sets / Sharing Rules) When: Access is based on static user attributes, account relationships, record ownership, or simple picklist criteria (e.g., status, program category, district).
Use Apex Managed Sharing When:
Access must be granted to dynamic, ad-hoc groups of external or internal users that change continuously based on business logic (e.g., assigning three rotating peer reviewers from an external board of 200 medical examiners to evaluate a physician license).
Access criteria require traversing complex multi-object junction relationships that exceed the single-level lookup capabilities of Sharing Sets.
Sharing logic must be recomputed programmatically upon external system webhook events or complex BRE calculation outputs.
Apex Managed Sharing Mechanics
Records are inserted into the object's share table (e.g., BusinessLicenseApplication__Share ).
Developers must define a custom Apex Sharing Reason ( RowCause ). This ensures that if the record owner changes or sharing rules are recalculated, Salesforce does not purge the programmatic access grant.
- 💡 Real-World Exam Scenarios & Case Analysis
- Scenario 1: High-Volume Citizen Permit Tracking
A city building department deploys an Experience Cloud site for residential building permits using Customer Community licenses. After submitting applications, constituents report that their application status tracker dashboard is completely blank, even though the records exist in Salesforce and are assigned to the Intake Queue.
What is the root cause and AP-222 architectural fix?
Root Cause: Customer Community licenses are high-volume portal licenses that do not utilize standard sharing rules or queue sharing. When the application was assigned to the internal Intake Queue , the constituent lost implicit ownership visibility.
Architectural Fix: Configure a Sharing Set on the BusinessLicenseApplication object that matches User.ContactId with the Applicant_Contact__c field on the application, granting Read access.
Scenario 2: Confidential Human Services Records Isolation
A state human services agency manages child welfare investigations alongside general supplemental nutrition assistance (SNAP). SNAP caseworkers and child welfare caseworkers share the same profile and sit at the same level in the role hierarchy. State statute mandates that child welfare investigation records must NEVER be accessible to general SNAP caseworkers under any circumstances.
How should the Lead Architect enforce this requirement?
Ensure the OWD for welfare case records is set to Private .
Implement a Restriction Rule on the case object specifying that if the case record type is Child Welfare Investigation , the record is only accessible if User.Department == 'Child Protective Services' .
Because Restriction Rules filter records after sharing rules, SNAP workers are completely prevented from accessing the records via search, list views, or reports.