Skip to content

feat: add Salesforce CRM integration#79

Merged
Empreiteiro merged 1 commit intomainfrom
feature/salesforce-integration
Mar 18, 2026
Merged

feat: add Salesforce CRM integration#79
Empreiteiro merged 1 commit intomainfrom
feature/salesforce-integration

Conversation

@Empreiteiro
Copy link
Copy Markdown
Owner

@Empreiteiro Empreiteiro commented Mar 18, 2026

Summary

  • Add Salesforce CRM as a new data source with full SOQL-based data fetching (API v59.0)
  • Support 8 Salesforce objects: Accounts, Contacts, Opportunities, Leads, Cases, Tasks, Campaigns, Users
  • Include 5 report templates: Sales Pipeline, Lead Conversion, Account Overview, Campaign ROI, Support Cases
  • OAuth-based auth using access token + instance URL, with pagination via nextRecordsUrl

Changes

  • New files:
    • backend/app/scripts/ask_salesforce.py — SOQL query engine, table loading, LLM + SQLite Q&A
    • backend/app/routers/salesforce_router.py — test-connection, discover, refresh-metadata endpoints
    • src/components/SalesforceSourceForm.tsx — frontend form with access token + instance URL inputs
  • Updated files:
    • backend/app/routers/ask.py — route Salesforce source type to ask_salesforce
    • backend/app/routers/crud.py — add "salesforce" to valid source types
    • backend/app/main.py — register salesforce_router
    • src/components/AddSourceModal.tsx — add Salesforce option and form rendering
    • src/services/apiClient.ts — add salesforceTestConnection, salesforceDiscover, salesforceRefreshMetadata
    • src/contexts/LanguageContext.tsx — add i18n keys for EN, PT, ES

Test plan

  • Verify npm run typecheck passes (confirmed)
  • Test connection with a Salesforce sandbox instance
  • Test object discovery returns correct counts for all 8 tables
  • Test Q&A flow with sample questions from report templates
  • Verify i18n strings render correctly in EN, PT, and ES

Closes #65

🤖 Generated with Claude Code

@Empreiteiro Empreiteiro changed the title Feature/salesforce integration feat: add Salesforce CRM integration Mar 18, 2026
@Empreiteiro Empreiteiro force-pushed the feature/salesforce-integration branch from 7df61f3 to 3c2ce43 Compare March 18, 2026 21:55
…ates

Add Salesforce CRM as a new data source type. Fetches accounts, contacts,
opportunities, leads, cases, tasks, campaigns, and users via Salesforce
REST API. Includes 5 pre-configured report templates.

Closes #65

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@Empreiteiro Empreiteiro force-pushed the feature/salesforce-integration branch from 3c2ce43 to f30cd27 Compare March 18, 2026 21:59
@Empreiteiro Empreiteiro merged commit ec3811f into main Mar 18, 2026
0 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: Salesforce CRM integration with fixed schema and report templates

1 participant