Integration · Technical Guide

Salesforce Nonprofit Cloud Integration: A Technical Guide to the Gratefully AI Layer

How Gratefully connects to Salesforce Nonprofit Cloud (NPC) and the Nonprofit Success Pack (NPSP) - the SObjects we read, the sync model, the OAuth scopes, and the security boundaries your IT team will want to verify.

Gratefully is a layer on top of Salesforce - not a replacement

If your nonprofit runs on Salesforce Nonprofit Cloud (NPC) or the legacy Nonprofit Success Pack (NPSP), Salesforce remains your system of record. Constituents, gifts, recurring schedules, pledges, soft credits, and campaign hierarchies stay exactly where they are.

Gratefully connects via the standard Salesforce REST and Bulk APIs and builds a parallel knowledge graph that combines your structured Salesforce records with the unstructured material that lives outside of fields - gift officer notes, email threads, meeting recaps, board memos, and attached documents. That graph is what makes natural-language queries cited, grounded, and useful.

The integration is read-only by default and requires no schema changes, no custom objects, and no managed package install.

Standard and NPSP SObjects we read

Gratefully consumes the standard NPC / NPSP object model. No custom fields are required, but custom fields on the objects below are automatically picked up.

SObjectPurposeAccess
Account (Household / Organization)
Pulled with RecordType, Household Naming, and primary contact relationships preserved.
Donor entity, household roll-up, organization profileRead
Contact
Email, mailing address, do-not-contact flags, salutation rules, and affiliation links.
Individual donor, board member, volunteer, prospectRead
Opportunity (Gift / Pledge / Recurring Donation)
Includes Stage, CloseDate, Amount, Campaign, and NPSP roll-up fields (npo02__).
Single gifts, soft credits, pledges, recurring schedulesRead
Campaign + CampaignMember
Used for RFM cohorting and natural-language queries like 'donors who gave to the gala but not the annual fund'.
Appeal performance, donor cohorts, segmentationRead
Task / Event / ContentNote
The unstructured layer most CRMs treat as second-class - and the primary source of institutional memory.
Logged calls, meetings, and free-text notesRead
EmailMessage / Activity
Body, ToAddress, FromAddress, and ThreadIdentifier indexed for retrieval and entity resolution.
Inbound and outbound donor correspondenceRead
ContentDocument / Attachment
Streamed through the parsing layer; PII detected at write time before being chunked into the knowledge graph.
PDFs, proposals, gift agreements, prospect briefsRead
User
Enables 'what was David working on?' continuity queries after a staff transition.
Map staff to interaction history for handoff continuityRead

Sync architecture: bulk backfill, then change data capture

Initial load uses the Salesforce Bulk API 2.0 to backfill the SObjects above. For a typical mid-sized nonprofit (50k–500k constituents, 1M–5M activities), backfill completes in under an hour and respects org-level API limits with adaptive throttling.

Ongoing sync uses Change Data Capture (CDC) on Account, Contact, Opportunity, Task, Event, EmailMessage, and ContentDocument. Updates land in the knowledge graph in near real time - gift officers can query notes they entered minutes earlier.

When CDC isn't enabled on a given org, Gratefully falls back to incremental polling on SystemModstamp with a default 5-minute cadence. Both paths are idempotent and resumable.

Salesforce NPC / NPSPBulk API + CDCPII redactionEntity resolutionKnowledge graph
Records pass through PII detection before they ever enter the searchable graph.

Authentication and OAuth scopes

Connection uses the Salesforce OAuth 2.0 Web Server Flow against a dedicated Gratefully Connected App. Your Salesforce admin installs the connected app, approves the scopes below, and assigns a least-privilege integration user (recommended) for Gratefully to authenticate as.

ScopeWhy
apiRead REST/Bulk API access to standard and NPSP objects.
refresh_token, offline_accessLong-lived background sync without re-prompting users.
lightning, contentRead ContentDocument bodies (notes, files, gift agreements).
eclair_apiOptional - used only if Tableau CRM (Einstein Analytics) datasets are exposed.

Refresh tokens are stored encrypted at rest. Tokens can be revoked at any time from Salesforce Setup → Connected Apps OAuth Usage. Revocation halts ingestion within one polling cycle.

Entity resolution across Salesforce and unstructured sources

A donor named in a Salesforce Contact, a separate Account, a spousal Affiliation, an email signature, and a meeting note may resolve to the same human being - or to a parent, a spouse, or a trustee acting on their behalf. The resolution layer is what makes plain-English queries reliable.

Gratefully's resolver uses a hybrid of deterministic keys (Salesforce IDs, email domain, household roll-up) and probabilistic matching (name normalization, address fuzzy matching, affiliation graph traversal). Every resolved mention carries a confidence score and a pointer back to the originating Salesforce record.

For a deeper walkthrough of how the resolver works, see the Nonprofit Knowledge Graphs whitepaper.

Security boundaries your IT team will want to verify

Read-only by default

The default connected app requests no write scopes. Gratefully cannot create, edit, or delete Salesforce records unless your admin explicitly grants write scopes for a specific workflow.

Isolated per-org tenancy

Each nonprofit's Salesforce data lands in a dedicated, encrypted tenant. Data is never used to train shared or third-party models - enforced architecturally, not by policy.

Field-level filtering

Sensitive fields (SSN, payment tokens, custom protected fields) can be excluded at the connector level before they ever leave Salesforce.

Full audit trail

Every retrieval, prompt, and generated answer is logged with the originating SObject IDs - exportable for board oversight or incident review.

Full details on architecture, redaction, and audit logging live in the Nonprofit AI Data Security guide and the AI Policy Pack.

What plain-English queries look like against your Salesforce data

"Which Major Gift Opportunities in 'Cultivation' stage haven't had a logged Task in 60 days?"

Resolves: Opportunity.StageName + Task.ActivityDate + OwnerId - answered with citations to each record.

"Summarize everything we know about the Harrison household before tomorrow's meeting."

Resolves: Account (Household) roll-up + Contacts + Opportunities + ContentNotes + EmailMessage threads - synthesized with source links.

"What was David working on across all his Opportunities and Tasks before he left?"

Resolves: User → OwnerId across SObjects + last 90 days of unstructured notes - continuity handoff in one query.

"Donors who gave to the 2024 Gala Campaign but not the 2025 Annual Fund, sorted by total giving."

Resolves: CampaignMember + Opportunity roll-ups + NPSP household totals.

Setup: under 60 minutes, no managed package

  1. Salesforce admin authorizes the Gratefully Connected App (read-only scopes) and assigns the integration user profile.
  2. Choose which SObjects and which custom fields are in scope. Sensitive fields can be excluded here.
  3. Bulk API 2.0 backfill runs in the background. You can start querying historical data as soon as the first batch lands.
  4. CDC (or fallback polling) keeps the knowledge graph current. Audit logs and citations become available immediately.

Ready to connect Salesforce?

Add an intelligence layer to Nonprofit Cloud in an afternoon

Salesforce remains the system of record. Gratefully adds the cited, plain-English intelligence layer that surfaces everything your team knows - including the parts that don't fit in a Salesforce field.

Related reading: Nonprofit Knowledge Graphs whitepaper · AI Data Security guide · Institutional memory loss

Share this guide