Metadata
Audit
Every custom object, field, CMT, platform event, and custom setting in the Delivery Hub package. Click any section to expand field details.
Culling Candidates
Fields and objects worth reviewing before the next install. Organized by risk level.
Remove or Consolidate
BountyClaim__c (9 fields)
This object was built for the bounty marketplace feature which is on hold. It has no Apex references in the core app — only exists for the future marketplace. Consider removing from the package entirely until the marketplace is actually built. Same goes for the 9 bounty-related fields on WorkItem__c (BountyAmountCurrency__c, BountyDeadlineDate__c, BountyDifficultyPk__c, BountyMaxClaimsNumber__c, BountySkillsTxt__c, BountyStatusPk__c, BountyTokenTxt__c, BountyEnabledDateTime__c).
OpenAIConfiguration__mdt — REMOVED
Deleted in PR #475. The OpenAI API key is now only stored on DeliveryHubSettings__c.OpenAIApiKeyTxt__c. The fallback query in DeliveryWorkItemController was removed. CMT object, records, and layout deleted.
DeliveryHubSettings__c — DateTime toggle pattern — RESOLVED
Previously flagged as bloat. PR #477 validated this pattern by migrating 6 Bool fields across WorkItem__c, NetworkEntity__c, and DeliverySavedFilter__c to DateTime-only fields — confirming that DateTime stamps replace booleans entirely. The settings DateTime fields remain as-is because they serve a dual purpose: the Bool is the runtime toggle, the DateTime is the audit stamp. No longer a culling candidate.
Potential Simplification
WorkItem__c — 50 fields is a lot
This object carries fields for 5+ features: core delivery, bounties, recurring items, SLA tracking, sync, and templates. That's intentional (one object, many modes via WorkflowTypeTxt__c). But some field groups are feature-specific and could be moved to child objects if the count feels uncomfortable. The bounty fields (9) and recurring fields (3) are the best candidates — they're only relevant for specific work item types.
Text-based lookups — actually mostly native
After auditing every field definition, almost all "Id" fields (WorkItemId__c, NetworkEntityId__c, DocumentId__c, etc.) are native Salesforce Lookup or MasterDetail relationships — not text. Only TemplateSourceId__c on WorkItem__c is stored as text (18 chars). This means cascade delete, related lists, and referential integrity all work natively. The text-based lookup concern was overblown — the schema is well-designed.
DeveloperCapacity__mdt — new in Phase 4
This is the newest addition. It stores developer hours/allocation as CMT records. The velocity dashboard works fine without any DeveloperCapacity records — it gracefully degrades to velocity-only mode. If you're not sure you want capacity planning in the package yet, this CMT could be deferred. It has zero dependencies — removing it just hides the capacity section of the dashboard.
CloudNimbusGlobalSettings__mdt (2 fields)
Only has EnabledBool__c and EndpointUrlTxt__c. This seems to overlap with NetworkEntity__c (which has IntegrationEndpointUrlTxt__c) and DeliveryHubSettings__c. What is this CMT for that the other two don't cover? May be consolidatable.
Solid Foundation — No Changes Needed
Workflow CMTs (4) — WorkflowType, WorkflowStage, WorkflowPersonaView, WorkflowStageRequirement. These are the core engine. Well-structured, heavily used, proven in production.
Core objects — WorkItem__c (minus bounty fields), NetworkEntity__c, WorkItemComment__c, WorkLog__c, WorkRequest__c. These are the data model. All actively used by MF.
Sync infrastructure — SyncItem__c, DeliverySync__e. Battle-tested with the MF sync chain.
Document engine — DeliveryDocument__c, DeliveryTransaction__c, DocumentTemplate__mdt. Used for invoicing. Actively generating documents.
Supporting objects — ActivityLog__c, PortalAccess__c, DeliverySavedFilter__c, WorkItemDependency__c, TrackedField__mdt, SLARule__mdt, WorkflowEscalationRule__mdt. Each serves a clear, distinct purpose.
Platform Events (4) — Lightweight, no storage cost, essential for real-time features.
Custom Objects (14)
The core data model. Every object listed with all its fields.
Core (18 fields)
Bounty (9 fields)
Recurring (4 fields)
SLA (3 fields)
Sync (3 fields)
ETA / Budget (10 fields)
Template (2 fields)
External (1 fields)
Custom Settings (1)
Hierarchy custom setting controlling every feature toggle in the package.
AI (9 fields)
Sync (4 fields)
Notifications (8 fields)
Work Requests (2 fields)
Activity (3 fields)
Field Tracking (3 fields)
Board (3 fields)
Digest (5 fields)
Status Page (3 fields)
Documents & Invoicing (4 fields)
WorkLog (1 fields)
Escalation (1 fields)
Pattern: Most features have a paired Bool + DateTime field. The Bool is the runtime toggle; the DateTime records when the feature was first enabled (for audit trail). On custom objects, Bool fields are being migrated to DateTime-only (PR #477) — the non-null check replaces the boolean, and the timestamp provides audit data. Custom Settings are hierarchy-type, meaning they can be overridden at profile or user level.
Custom Metadata Types (10)
All configuration is CMT. Deployable, admin-editable, no DML required. OpenAIConfiguration__mdt was removed in PR #475.
Ships with: Software_Delivery, Loan_Approval, Customer_Onboarding, HR_Recruiting, Marketing_Campaign
Platform Events (4)
Async real-time communication. Decoupled publishers and subscribers.
DeliverySync__e
5 fieldsSync notifications. Fired when data changes need to propagate.
DeliveryDocEvent__e
4 fieldsDocument generation events. Triggers async PDF rendering.
DeliveryEscalation__e
5 fieldsEscalation alerts. Fired when an item breaches its SLA or escalation rule.
DeliveryWorkItemChange__e
3 fieldsWork item stage change notifications. Powers real-time board updates.
Naming Convention
Every field name tells you its type. No guessing.
| Suffix | Type |
|---|---|
| Txt__c | Text field |
| Bool__c | Checkbox (legacy — migrating to DateTime) |
| Pk__c | Picklist |
| Number__c | Number |
| Currency__c | Currency |
| Date__c | Date |
| DateTime__c | DateTime |
| Id__c | Lookup (text ID, not native relationship) |
| __mdt | Custom Metadata Type |
| __e | Platform Event |
| __c | Custom Object or Custom Setting |
Schema Philosophy
The design decisions behind the data model.
Text-based lookups for cross-org sync
Fields like WorkItemId__c store Salesforce record IDs as text, not native lookup relationships. This is intentional -- native lookups break across orgs because IDs are org-specific. Text-based IDs allow the sync engine to resolve references after ingest.
CMT for all configuration
Custom Metadata Types (WorkflowType, WorkflowStage, etc.) store all workflow config. CMT records deploy with the package via git, survive org refreshes, and are queryable in Apex without DML. This means adding a new workflow type is a metadata deployment, not a code change.
Custom Settings for runtime toggles
DeliveryHubSettings__c is a hierarchy custom setting with ~46 fields. Custom Settings are org-wide, queryable without SOQL (via getInstance()), and can be overridden at profile or user level. The Bool + DateTime pattern tracks both the toggle state and when it was first enabled. On custom objects, this pattern has evolved further — Bool fields are being replaced entirely by DateTime stamps (non-null = enabled).
Platform Events for real-time notifications
Four platform events handle async communication: sync propagation, document generation, escalation alerts, and board updates. Events decouple publishers from subscribers and support retry semantics.
Naming suffix convention for instant type recognition
Every custom field ends with a type suffix (Txt, Bool, Pk, Number, Currency, Date, DateTime, Id). This means you can read any field name and immediately know its data type without checking the schema -- a significant productivity gain when the package has ~230 fields.
Bool to DateTime migration — booleans have no value in 2026
Boolean fields are being systematically replaced with DateTime stamps. Instead of IsActiveBool__c = true, the field becomes ActivatedDateTime__c = 2026-03-27T14:30:00Z. This tells you BOTH if something is enabled (non-null) AND when it was enabled — richer audit data at zero extra cost. Six fields were converted in PR #477: IsActiveBool__c, IsBountyBool__c, IsRecurringBool__c, IsTemplateBool__c on WorkItem__c, EnableVendorPushBool__c on NetworkEntity__c, and IsDefaultBool__c on DeliverySavedFilter__c. The existing Bool+DateTime pattern on DeliveryHubSettings__c (for feature toggles) was the precursor to this approach.
Related Pages
See how this metadata evolved across phases, or dive into the architecture that uses it.