duplicate-management
Use when designing, reviewing, or troubleshooting Salesforce duplicate prevention, matching rules, duplicate rules, and merge governance. Triggers: 'duplicate rule', 'matching rule', 'merge strategy', 'dedupe', 'survivorship', 'D&B', 'same contact twice'. NOT for choosing data-load tooling unless duplicate control is the main problem.
Best use case
duplicate-management is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Use when designing, reviewing, or troubleshooting Salesforce duplicate prevention, matching rules, duplicate rules, and merge governance. Triggers: 'duplicate rule', 'matching rule', 'merge strategy', 'dedupe', 'survivorship', 'D&B', 'same contact twice'. NOT for choosing data-load tooling unless duplicate control is the main problem.
Teams using duplicate-management should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/duplicate-management/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How duplicate-management Compares
| Feature / Agent | duplicate-management | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Use when designing, reviewing, or troubleshooting Salesforce duplicate prevention, matching rules, duplicate rules, and merge governance. Triggers: 'duplicate rule', 'matching rule', 'merge strategy', 'dedupe', 'survivorship', 'D&B', 'same contact twice'. NOT for choosing data-load tooling unless duplicate control is the main problem.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
You are a Salesforce Admin expert in duplicate prevention and stewardship. Your goal is to stop bad duplicates from entering the org, route uncertain matches to the right people, and make merge decisions consistent instead of improvisational. ## Before Starting Check for `salesforce-context.md` in the project root. If present, read it first. Only ask for information not already covered there. Gather if not available: - Which objects have the duplicate problem: Leads, Contacts, Accounts, custom objects? - Is the main pain prevention at entry, cleanup after the fact, or both? - Should the rule block saves, alert users, or route to stewards? - What source systems or integrations also create records? - What fields are reliable identifiers versus messy user-entered data? - Who owns duplicate review and merge decisions operationally? ## How This Skill Works ### Mode 1: Build from Scratch Use this for a new dedupe strategy or when the org has baseline duplicate management turned off. 1. Start with the business cost of duplicates, object by object. 2. Pick matching logic that fits the data reality: exact, fuzzy, or composite. 3. Decide where to block and where to alert with steward follow-up. 4. Define survivorship and merge rules before anyone mass-merges records. 5. Test matching with dirty real-world samples, not idealized data. 6. Measure duplicate outcomes after go-live so the rules can be tuned. ### Mode 2: Review Existing Use this for inherited matching rules, noisy alert banners, or cleanup projects with no governance. 1. Check whether rules are active, object-specific, and still aligned to business process. 2. Check whether alert-only rules actually have an owner who reviews them. 3. Check whether integrations and imports bypass or undermine the duplicate strategy. 4. Check whether merge behavior is documented or just tribal knowledge. 5. Check whether the team is treating duplicate cleanup as a project instead of an ongoing operational control. ### Mode 3: Troubleshoot Use this when users complain about false positives, false negatives, or bad merges. 1. Identify whether the issue is matching logic, user behavior, source-data quality, or missing stewardship. 2. Review real duplicate cases and false-positive examples side by side. 3. Confirm whether the wrong field was treated as a stable identity key. 4. Confirm whether alert fatigue made a technically correct rule operationally useless. 5. Tune rules in sandbox, test with realistic samples, then roll out deliberately. ## Duplicate Control Decision Matrix | Goal | Best Fit | Why | |------|----------|-----| | Stop obvious duplicates at the moment of entry | Exact or strong composite match with blocking duplicate rule | High confidence and clear user feedback | | Catch likely duplicates that still need human judgment | Fuzzy or weighted match with alert + steward workflow | Balances prevention with operational reality | | Protect imports and integrations from replay or reruns | External IDs and idempotent upserts | System identity is stronger than fuzzy dedupe | | Clean up historical mess across many records | Stewardship process with survivorship rules and merge queue | Cleanup needs governance, not just a button | **Rule:** An alert without an owner is not duplicate management. It is noise with branding. ## Operating Rules | Rule | Discipline | |---|---| | Prevention beats cleanup | If duplicates arrive faster than you can merge them, the process is already failing. | | Use the right identity fields | Email, domain, external IDs, and composite business keys are not interchangeable. | | Normalize before matching | Name formatting, phone cleanup, and domain cleanup improve rule quality. | | Document survivorship | Users should know which record wins and why. | | Measure duplicate debt | Track alerts, merges, false positives, and recurring sources. | ## Recommended Workflow Step-by-step instructions for an AI agent or practitioner activating this skill: 1. Gather context — confirm the org edition, relevant objects, and current configuration state 2. Review official sources — check the references in this skill's well-architected.md before making changes 3. Implement or advise — apply the patterns from Core Concepts and Common Patterns sections above 4. Validate — run the skill's checker script and verify against the Review Checklist below 5. Document — record any deviations from standard patterns and update the template if needed --- ## Salesforce-Specific Gotchas | Gotcha | Why it bites | |---|---| | Fuzzy matching is useful and dangerous | It catches real duplicates and also produces false positives if you tune lazily. | | Alert mode often becomes ignored mode | If no steward reviews it, the org silently accumulates duplicates. | | Merge behavior can destroy trust | If the "winning" record feels arbitrary, users stop trusting cleanup work. | | Integrations and migrations can bypass good admin rules | Duplicate management must include system-created data, not just UI saves. | | D&B or enrichment tools do not replace governance | They can improve matching inputs, but they do not own your process. | ## Proactive Triggers Surface these WITHOUT being asked: | Trigger | Action | |---|---| | No data steward or business owner exists | Flag. Duplicate operations need ownership. | | Only one weak field is used for matching | Raise false-positive/false-negative risk. | | Imports are planned without external IDs | Coordinate immediately with data-import strategy. | | Duplicate cleanup is treated as a one-time project | Push for ongoing metrics and ownership. | | Users complain about duplicate alerts but nobody samples the actual records | Require evidence-driven tuning, not anecdotal disabling. | ## Output Artifacts | When you ask for... | You get... | |---------------------|------------| | Duplicate strategy | Matching, rule behavior, and stewardship recommendation | | Rule review | Findings on false-positive risk, ownership gaps, and merge process | | Merge governance | Survivorship and steward workflow guidance | | Troubleshooting help | Root-cause path for noisy or weak duplicate controls | ## Related Skills - **admin/data-import-and-management**: Use when duplicate risk is driven by a load, migration, or upsert strategy. NOT for ongoing rule governance. - **admin/validation-rules**: Use when data-quality enforcement beyond duplicate logic is the main need. NOT for matching-rule design. - **admin/reports-and-dashboards**: Use when the next step is measuring duplicate debt or steward workload with reporting. NOT for rule logic itself.
Related Skills
session-management-and-timeout
Use this skill when configuring session timeout values, concurrent session limits, session IP locking, or logout behavior in Salesforce. Covers org-wide session settings, profile-level overrides, Connected App session policies, and Metadata API SecuritySettings deployment. NOT for OAuth token refresh flows, login IP ranges, or MFA/identity-provider configuration.
oauth-token-management
Use when work depends on how Salesforce OAuth access and refresh tokens are issued, refreshed, rotated, revoked, or introspected for a Connected App or API client—including unexpected logouts, invalid_grant after refresh, or designing token incident response. NOT for choosing which OAuth grant or Connected App flow to implement (use integration/oauth-flows-and-connected-apps), Named Credential packaging (use integration/named-credentials-setup), or broad Connected App IP and PKCE policy hardening without a token-lifecycle angle (use security/connected-app-security-policies).
certificate-and-key-management
Use this skill when creating, uploading, or rotating certificates in Salesforce, configuring mutual TLS (mTLS) client authentication, managing the Java KeyStore for CA-signed certificates, diagnosing certificate expiry in JWT OAuth flows, or understanding which certificate types Salesforce supports and how to migrate them between orgs. NOT for Named Credential configuration (use named-credentials-setup skill), NOT for Shield Platform Encryption key management. Trigger keywords: Certificate and Key Management, self-signed certificate, CA-signed certificate, mutual TLS, mTLS, keystore, JKS, PKCS12, certificate rotation, certificate expiry, JWT certificate.
flexcard-state-management
Use when designing FlexCard actions, conditional visibility, and state that must survive navigation, refresh, or parent/child card transitions. Triggers: 'flexcard state', 'flexcard conditional visibility', 'flexcard actions', 'flexcard refresh', 'child flexcard state'. NOT for raw LWC state or for OmniScript step state.
lwc-state-management
Share state across LWCs using pub/sub, Lightning Message Service, @wire, and reactive stores. NOT for in-component reactivity.
lwc-focus-management
Use when building LWCs that need to manage focus explicitly — modal dialogs, wizard flows, dynamic inserts, list updates, error summaries, and focus after async work. Covers focus restoration, focus traps, programmatic focus across shadow DOM, and patterns for announcing changes to assistive tech. Does NOT cover general LWC a11y audit (see lwc-accessibility).
revenue-lifecycle-management
Use this skill when implementing or troubleshooting Salesforce Revenue Lifecycle Management (RLM) — the native Revenue Cloud product covering order-to-cash lifecycle, Dynamic Revenue Orchestrator (DRO) fulfillment plan design, asset amendments, billing schedule creation via Connect API, and invoice management. Triggers on: Dynamic Revenue Orchestrator, RLM order decomposition, DRO fulfillment swimlanes, native Revenue Cloud billing schedule, asset lifecycle management Salesforce. NOT for CPQ quoting or pricing rules (use cpq-* skills), not for the legacy Salesforce Billing managed package with blng__* objects (different product entirely), not for standard Order objects without Revenue Cloud features.
loyalty-management-setup
Use this skill when setting up or extending Salesforce Loyalty Management — including program and currency creation, tier group design, qualifying vs. non-qualifying point currency separation, DPE batch job activation, partner loyalty configuration, and member portal setup on Experience Cloud. Triggers on: Loyalty Management setup, loyalty tier setup Salesforce, qualifying points vs redemption points, DPE batch job for loyalty, partner loyalty program Salesforce, loyalty member portal. NOT for Marketing Cloud engagement program design (separate product), not for B2B loyalty via Sales Cloud (standard opportunity, not loyalty program), not for general Experience Cloud site setup (use experience-cloud-setup skill).
scratch-org-management
Use this skill when designing, configuring, or troubleshooting scratch orgs: definition file structure, edition selection, allocation limits, Org Shape, CI automation via ScratchOrgInfo, and lifecycle management from the Dev Hub. NOT for SFDX CLI basics (use sf-cli-and-sfdx-essentials), sandbox management, or production org administration.
release-management
Use when planning, coordinating, or governing Salesforce releases: version numbering, rollback strategy, release notes, go/no-go criteria, release calendar, and sandbox preview alignment. NOT for deployment mechanics (use devops/post-deployment-validation or devops/change-set-deployment).
pipeline-secrets-management
Store and inject Salesforce auth URLs, JWT keys, and API credentials into CI without leaking them. NOT for runtime secrets in Apex.
isv-license-management-and-trialforce
Use when an ISV partner is wiring license enforcement, trial provisioning, or feature-flag distribution into a managed package — covers License Management App (LMA) install and registration, Lead/License object lifecycle, Trialforce Management Org (TMO) and Trialforce Source Org (TSO) split, Trialforce templates, SignupRequest API, AppExchange Checkout integration, and Feature Parameters (LmoToSubscriber / SubscriberToLmo) as the cross-org configuration channel. Triggers: 'register package with LMA', 'set up Trialforce', 'add feature parameter to managed package', 'license expired in subscriber org', 'AppExchange Checkout licensing'. NOT for general managed-package version creation, ancestor pinning, or PostInstall handler design (use managed-package-development); NOT for second-generation packaging mechanics (use second-generation-managed-packages); NOT for non-ISV experience-cloud login licensing (use experience-cloud-licensing-model).