Back to all work

Role-Specific Account Intelligence with Salesforce and Vertex AI

Status
Completed
Confidentiality
Anonymized. Anonymized professional case study. All records, summaries, identifiers, and diagrams are synthetic. I've withheld proprietary schemas and prompts.

Built a security-aware asynchronous integration that generated source-attributed summaries while avoiding unchanged repeat model calls.

I designed and implemented an Apex integration that assembled accessible context from more than 12 generalized Salesforce data categories, fingerprinted the payload with SHA-256, and called Gemini through Vertex AI only when the source changed. It produced separate source-attributed summaries for Sales, Support, and Finance while keeping credentials and model settings outside source code.

Type
Professional
Categories
  • AI & Machine Learning
  • Software & Automation
  • Data & Dashboards
Technologies
  • Salesforce
  • Apex
  • SOQL
  • Vertex AI
  • Gemini API
  • SHA-256
  • REST APIs

Context

Sales, support, and finance users who need role-specific context from distributed account records.

  • Private object and field names, prompts, records, endpoints, credentials, and production summaries cannot be published.
  • Salesforce governor limits and callout rules required asynchronous execution.
  • Generated summaries support human review and cannot replace authoritative records.

Problem

Relevant account context was spread across numerous records, while each department needed a different grounded view and external model calls had to respect platform, access-control, configuration, and sensitive-data constraints.

My contribution

I implemented the access-aware aggregation, structured payload, deterministic change detection, asynchronous callout, response handling, role-specific summary updates, completion notification, and sensitive-data-aware diagnostics. I also applied source-attribution and output constraints and externalized credentials and model settings.

Approach

Check field-level access, assemble a deterministic JSON snapshot, compare its SHA-256 fingerprint with prior state, skip unchanged requests, call Vertex AI through governed Salesforce configuration, store bounded role-specific outputs, and notify the initiating user.

Artifacts

Outcomes

  • Produced separate Sales, Support, and Finance summary paths.
  • Used deterministic payload hashing to bypass unchanged repeat calls.
  • Kept authentication and model configuration outside Apex source.

Limitations and current status

  • Source code, test classes, callout mocks, logs, model evaluations, and deployment evidence weren't available for independent review.
  • I make no claims about accuracy, latency, reliability, cost savings, adoption, or formal compliance certification.