gift-entry-and-processing

Configure and operate NPSP Gift Entry: gift entry templates, batch gift entry, payment processing, donation allocation, and receipting workflows. NOT for standard opportunity creation or direct GiftTransaction DML outside the Gift Entry framework.

Best use case

gift-entry-and-processing is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Configure and operate NPSP Gift Entry: gift entry templates, batch gift entry, payment processing, donation allocation, and receipting workflows. NOT for standard opportunity creation or direct GiftTransaction DML outside the Gift Entry framework.

Teams using gift-entry-and-processing 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

$curl -o ~/.claude/skills/gift-entry-and-processing/SKILL.md --create-dirs "https://raw.githubusercontent.com/PranavNagrecha/AwesomeSalesforceSkills/main/skills/admin/gift-entry-and-processing/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/gift-entry-and-processing/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How gift-entry-and-processing Compares

Feature / Agentgift-entry-and-processingStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Configure and operate NPSP Gift Entry: gift entry templates, batch gift entry, payment processing, donation allocation, and receipting workflows. NOT for standard opportunity creation or direct GiftTransaction DML outside the Gift Entry framework.

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

# Gift Entry and Processing

This skill activates when a practitioner needs to configure, troubleshoot, or extend the NPSP Gift Entry feature — covering template setup, batch entry, the staging-to-target promotion pipeline via `processGiftEntries`, payment processing, donation allocation, and receipt tracking. It does NOT cover direct Opportunity creation or manual DML against GiftTransaction outside the Gift Entry framework.

---

## Before Starting

Gather this context before working on anything in this domain:

- **Advanced Mapping must be enabled.** Navigate to NPSP Settings > Advanced Mapping and enable it before attempting to activate the Gift Entry feature. Gift Entry will not activate without it.
- **API version constraint.** The `GiftEntry` staging object is available at API v59.0+. The `TaxReceiptStatus` field on `GiftTransaction` is available at API v62.0+. Verify the org's API version before relying on these.
- **Template type constraint.** The Default Gift Entry Template is the only template that supports single-gift entry in the standard Gift Entry UI. Custom templates are batch-only. This is a hard platform constraint, not a configuration choice.
- **Common wrong assumption:** practitioners assume Gift Entry writes directly to Opportunity or GiftTransaction via DML. In reality, it creates a `GiftEntry` staging record first, and the `processGiftEntries` invocable action performs the promotion.

---

## Core Concepts

### Staging Object: GiftEntry

Every gift submitted through Gift Entry creates a `GiftEntry__c` (or `GiftEntry` in API v59.0+ schema) staging record. This record holds all raw gift data — donor, amount, payment method, designations — before the data is validated and committed to target objects. The staging record persists until `processGiftEntries` is explicitly called. If that action is never invoked, the gift lives only in staging and no GiftTransaction, GiftDesignation, or GiftSoftCredit record is ever created.

### processGiftEntries Invocable Action

`processGiftEntries` is the platform action that promotes a `GiftEntry` staging record to its target records:

- `GiftTransaction` — the canonical donation record
- `GiftDesignation` — maps the gift amount to one or more fund/program allocations
- `GiftSoftCredit` — assigns soft credit to relationships (e.g., household members)

The action accepts an `isDryRun` parameter. When `isDryRun=true`, it validates the staging record against all rules and field mappings without committing anything. This is the correct pre-processing gate for large batches. When `isDryRun=false` (default), it commits the records.

### Gift Entry Templates

Templates define the fields, sections, payment options, and allocations presented to gift entry users. Two template contexts exist:

- **Default Gift Entry Template** — system-provided; supports single-gift entry in the standard UI; cannot be deleted; customizable but not replaceable for single-entry mode.
- **Custom templates** — administrator-created; batch-only; define a layout and field set specific to a campaign, fiscal period, or entry team.

Activating the Gift Entry feature requires at minimum that the Default Gift Entry Template is active.

### TaxReceiptStatus and Receipting

`TaxReceiptStatus` on `GiftTransaction` tracks whether a tax receipt has been issued, is pending, or is not applicable. This field is only available at API v62.0+. Orgs on earlier API versions should use a custom field or a separate receipting object.

---

## Common Patterns

### Pattern 1: Single-Gift Entry with Dry Run Validation

**When to use:** A frontline fundraiser is entering one gift at a time, and the org wants validation before committing.

**How it works:**
1. User opens Gift Entry, selects the Default Gift Entry Template.
2. Fills in donor, amount, payment method, and designation fields.
3. Staff clicks "Validate" — this triggers `processGiftEntries` with `isDryRun=true` in the background.
4. Errors (missing required fields, invalid payment method, allocation mismatch) surface immediately.
5. Staff corrects errors, then clicks "Process" — `processGiftEntries` runs with `isDryRun=false`.
6. `GiftTransaction`, `GiftDesignation`, and optionally `GiftSoftCredit` records are created.

**Why not direct DML:** Writing directly to `Opportunity` or `GiftTransaction` bypasses Advanced Mapping field mappings, skips designation logic, and prevents receipt tracking via `TaxReceiptStatus`.

### Pattern 2: Batch Gift Entry for Year-End Processing

**When to use:** Finance team processes hundreds of mailed checks at fiscal year-end.

**How it works:**
1. Admin creates a custom batch template scoped to the year-end campaign.
2. Staff opens Batch Gift Entry, selects the custom template, enters all gifts in the batch grid.
3. Before submitting, runs a dry-run pass via `processGiftEntries` with `isDryRun=true` across all staged records — surfaces any issues.
4. Fixes flagged records in the grid.
5. Submits the batch — `processGiftEntries` runs in sequence for each staging record.
6. All promoted `GiftTransaction` records have `TaxReceiptStatus` set to `PENDING` for downstream receipt generation.

**Why not a data load:** Direct imports via Data Loader bypass Gift Entry entirely. They produce raw `GiftTransaction` records without `GiftDesignation` allocation logic and without the Advanced Mapping field transformations.

---

## Decision Guidance

| Situation | Recommended Approach | Reason |
|---|---|---|
| Single gift entered by a fundraiser | Default Gift Entry Template | Only template type that supports single-entry UI |
| Bulk gifts from a mailer or event | Custom batch template + Batch Gift Entry | Batch templates support multi-record grid; batch processing is more efficient |
| Validating before committing a large batch | processGiftEntries with isDryRun=true | Catches field mapping and allocation errors without any DB commits |
| Receipting for tax purposes | TaxReceiptStatus on GiftTransaction (API v62.0+) | Platform-native receipt status tracking; integrates with downstream receipt flows |
| Org is on API < v62.0 | Custom receipt status field on GiftTransaction | TaxReceiptStatus not available; document the workaround in a skill note |
| Advanced Mapping not yet enabled | Enable Advanced Mapping in NPSP Settings first | Gift Entry feature activation blocked without it |

---

## Recommended Workflow

Step-by-step instructions for an AI agent or practitioner working on this task:

1. **Verify prerequisites.** Confirm NPSP is installed, Advanced Mapping is enabled (NPSP Settings > Advanced Mapping), and the org is on API v59.0+. If Advanced Mapping is off, enable it before proceeding — Gift Entry activation will fail otherwise.
2. **Activate Gift Entry.** In NPSP Settings > Gift Entry, toggle the feature on. Confirm the Default Gift Entry Template is listed as active.
3. **Configure the Default Gift Entry Template for single-gift entry.** Add required fields (donor lookup, amount, payment method, fund designation), configure payment gateway if applicable, and save.
4. **Create a custom batch template if batch entry is needed.** Set the template name, batch entry fields, allocation default, and link to the relevant campaign or fund.
5. **Test with isDryRun=true.** Submit a test staging record and invoke `processGiftEntries` with `isDryRun=true`. Confirm validation messages match expectations and no target records are created.
6. **Process and verify target records.** Run `processGiftEntries` with `isDryRun=false` on the test record. Confirm `GiftTransaction`, `GiftDesignation`, and `GiftSoftCredit` records are created with correct field values per Advanced Mapping rules.
7. **Configure receipting.** If on API v62.0+, set the default `TaxReceiptStatus` value on processed `GiftTransaction` records and wire up any receipt automation.

---

## Review Checklist

Run through these before marking work in this area complete:

- [ ] Advanced Mapping is enabled in NPSP Settings
- [ ] Default Gift Entry Template is active and has required fields configured
- [ ] Custom batch templates (if any) are batch-only and correctly scoped
- [ ] processGiftEntries dry-run pass executes without errors on test staging records
- [ ] processGiftEntries full-run creates GiftTransaction, GiftDesignation, and GiftSoftCredit records
- [ ] TaxReceiptStatus is set on GiftTransaction records (API v62.0+ only; document workaround if on earlier version)
- [ ] No GiftEntry staging records remain in a permanently unprocessed state after testing

---

## Salesforce-Specific Gotchas

Non-obvious platform behaviors that cause real production problems:

1. **Advanced Mapping gate** — Gift Entry feature activation silently fails or produces an error if Advanced Mapping has never been enabled. Many practitioners skip this step assuming NPSP installs with it on by default. It does not. Enable it first, every time.
2. **Staging records persist if processGiftEntries is never called** — There is no automatic cleanup of `GiftEntry` staging records. If an integration or custom flow creates staging records but never invokes `processGiftEntries`, the gifts accumulate in staging indefinitely and never appear as GiftTransactions in reporting.
3. **Default template is the only single-entry template** — Attempting to use a custom template for single-gift entry produces no UI entry point. Custom templates surface only in Batch Gift Entry. This is a hard constraint, not a missing configuration.
4. **isDryRun does not roll back — it never commits** — `isDryRun=true` is a validation-only pass; it does not create records and does not need a rollback. Some practitioners apply transaction guards around dry-run calls, which adds no value and can introduce lock contention.
5. **TaxReceiptStatus API version dependency** — Querying `TaxReceiptStatus` on `GiftTransaction` in orgs below API v62.0 returns an "invalid field" error. Always check the org's API version before referencing this field in Apex, Flow, or SOQL.

---

## Output Artifacts

| Artifact | Description |
|---|---|
| Active Default Gift Entry Template | Configured single-entry template with required fields and payment options |
| Custom Batch Gift Entry Template | Batch-only template linked to a campaign or fiscal period |
| processGiftEntries invocation pattern | Documented dry-run and commit invocation sequence with error handling |
| GiftTransaction records | Promoted donation records with designation and soft credit allocations |
| TaxReceiptStatus configuration | Receipting status field wired to downstream automation (API v62.0+ orgs) |

---

## Related Skills

- `recurring-donations-setup` — Configure NPSP recurring donations, which feed staging records into Gift Entry differently than one-time gifts
- `npsp-data-model` — Understand the full NPSP object graph that Gift Entry writes into
- `gift-entry-and-processing` is the upstream step before any `care-program-management` or financial reporting workflows that consume GiftTransaction records

Related Skills

recursion-and-re-entry-prevention

8
from PranavNagrecha/AwesomeSalesforceSkills

Use when a record-triggered Flow re-fires on the same record because its own DML (or a downstream Flow's DML) re-satisfies the entry criteria — causing CPU-limit failures, duplicated side effects, or 'Maximum Trigger Depth Exceeded' errors. Triggers: 'flow infinite loop', 'flow re-firing on same record', 'flow updates field then runs again', 'flow A and flow B keep updating each other', 'maximum trigger depth exceeded record-triggered flow', 'flow recursion limit hit'. NOT for Apex trigger recursion (use apex/recursive-trigger-prevention) or for Loop element design inside a single Flow run (use flow/flow-loop-element-patterns).

flow-collection-processing

8
from PranavNagrecha/AwesomeSalesforceSkills

Use when building or reviewing Flow logic that processes lists of records using Loop, Assignment, Collection Filter, Collection Sort, or Transform elements. Triggers: 'iterate over collection in flow', 'flow loop add to collection', 'collection filter element', 'transform element flow', 'update records from collection variable', 'collection sort flow'. NOT for individual single-record retrieval (use Get Records alone), NOT for Apex-based collection manipulation, NOT for flow bulkification performance analysis (see flow-bulkification).

flow-batch-processing-alternatives

8
from PranavNagrecha/AwesomeSalesforceSkills

Use when a Scheduled Flow or Record-Triggered Flow needs to process more records than Flow can safely handle in a single run. Covers Flow limit realities, scheduled-path chunking, Data Cloud batch transforms, and Apex Queueable/Batch escalation. Does NOT cover choosing async across a general workflow (see async-selection decision tree).

gift-history-import

8
from PranavNagrecha/AwesomeSalesforceSkills

Use when migrating donation or gift history into Salesforce NPSP using the NPSP Data Importer (BDI) — covers DataImport__c staging, payment mapping, soft credit creation via Opportunity Contact Roles, GAU allocation, and campaign attribution. NOT for standard Opportunity import via Data Loader, NPC gift records, or recurring donation setup.

xss-and-injection-prevention

8
from PranavNagrecha/AwesomeSalesforceSkills

Use when writing or reviewing Visualforce pages, Apex controllers, or LWC components that output user-supplied data, build dynamic queries, or construct HTTP responses. Triggers: 'XSS in Visualforce', 'SOQL injection vulnerability', 'how to encode output in Apex', 'JSENCODE Visualforce', 'open redirect prevention'. NOT for Apex CRUD/FLS enforcement (use soql-security or apex-crud-and-fls), NOT for Shield encryption (use shield-encryption-key-management), NOT for AppExchange security review process (use secure-coding-review-checklist).

visualforce-security-and-modernization

8
from PranavNagrecha/AwesomeSalesforceSkills

Use when hardening or modernizing legacy Visualforce pages — covers the platform CSRF token model and when disabling it is a security regression, view state encryption guarantees and the 170 KB ceiling, FLS/CRUD enforcement gaps on `<apex:outputField>` and on getters that return sObjects, `<apex:includeScript>` interaction with the org Content Security Policy, hosting LWC inside a VF page via `lightning:container` / `lightning-out`, and the retire-vs-harden-vs-leave-alone decision for an inventory of legacy pages. Triggers: 'should I rewrite this Visualforce page in LWC', 'CSRF protection disabled on Visualforce page is that safe', 'community user sees a field they should not on a Visualforce page', 'view state encryption is that enough for sensitive data', 'how do I host an LWC inside a Visualforce page', 'apex:dynamicComponent and apex:actionFunction safe to keep'. NOT for greenfield Visualforce architecture (use apex/visualforce-fundamentals — controller types, view state pattern selection, PDF rendering); NOT for Visualforce email template authoring (use apex/visualforce-email-templates if/when that skill is authored); NOT for general Apex security review across triggers and async (use apex/soql-security and security/secure-coding-review-checklist).

transaction-security-policies

8
from PranavNagrecha/AwesomeSalesforceSkills

Transaction Security policy creation and configuration: condition builder, enhanced policies, enforcement actions (block, MFA, notification, end session), real-time monitoring mode, and policy troubleshooting. NOT for Event Monitoring log analysis or Shield Event Monitoring setup (use event-monitoring). NOT for Apex testing or debug-log analysis.

sso-saml-troubleshooting

8
from PranavNagrecha/AwesomeSalesforceSkills

Diagnosing broken SAML SSO into Salesforce — IdP-initiated vs SP-initiated flows, signing-certificate validity / expiry, NameID format mismatches, RelayState handling, audience / entityId / issuer mismatches, clock skew, the SAML Assertion Validator in Setup, the Login History debug log, and the My Domain prerequisite for SSO. Covers the standard diagnostic loop: read the SAML response, identify which check failed, fix at the IdP or SP. NOT for OAuth / OpenID Connect SSO (see security/oauth-openid-troubleshooting), NOT for setting up SSO from scratch (see security/sso-saml-setup).

shield-kms-byok-setup

8
from PranavNagrecha/AwesomeSalesforceSkills

Configure Shield Platform Encryption with customer-supplied (BYOK) or customer-held (Cache-Only Key Service) tenant secrets, rotate them, and recover. NOT for Classic Encryption or field masking.

shield-event-log-retention-strategy

8
from PranavNagrecha/AwesomeSalesforceSkills

Use when designing Salesforce Shield Event Monitoring retention, SIEM routing, and storage-tier strategy — which event types to keep, for how long, where, and how to answer audit queries across hot/warm/cold tiers. Triggers: 'shield event log retention', 'route event monitoring to splunk', 'how long to keep login history', 'siem salesforce integration', 'event monitoring storage tier'. NOT for enabling Shield (see salesforce-shield-deployment).

session-management-and-timeout

8
from PranavNagrecha/AwesomeSalesforceSkills

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.

session-high-assurance-policies

8
from PranavNagrecha/AwesomeSalesforceSkills

Enforce step-up authentication for sensitive pages/objects using High Assurance session level and login flow policies. NOT for initial MFA enrollment UX.