New to Claude Skills? Learn how to install them →

forcedotcom on GitHub

Salesforce Integration Patterns

OfficialFree

Streamline Salesforce integration architecture effortlessly.

Get this skill

Free · Opens the source repo

What Salesforce Integration Patterns does

The integration-connectivity-generate skill is designed to facilitate the setup and management of Salesforce integration patterns, focusing on critical components such as Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture (CDC). This skill provides a structured approach to building integration solutions, ensuring that developers can efficiently manage authentication and communication between Salesforce and external systems.

When utilizing this skill, users can expect a comprehensive workflow that guides them through selecting the appropriate integration pattern based on their specific needs. The skill emphasizes the importance of secure authentication methods, recommending the use of Named Credentials and External Credentials to avoid hardcoding sensitive information. It also provides templates and assets for various integration scenarios, allowing for quick generation of necessary metadata files and configurations.

This skill is particularly beneficial for developers and architects who are tasked with implementing or maintaining integration solutions within Salesforce. By leveraging the provided resources and following best practices outlined in the skill, users can ensure that their integrations are robust, secure, and aligned with Salesforce's architectural guidelines. The skill also includes operational safeguards to validate integration safety, such as timeout handling and retry strategies, which are crucial for maintaining reliable communication between systems.

Overall, integration-connectivity-generate is an essential tool for any Salesforce developer looking to streamline their integration processes and adhere to best practices in integration architecture.

When to use it

Use this skill when configuring Named Credentials, External Services, or handling REST/SOAP callouts within Salesforce.

When not to use it

Avoid this skill for tasks related to OAuth app setup, Apex-only logic, or data import/export operations.

What you can build with it

Setting Up Named Credentials

Use this skill to generate and configure Named Credentials for secure API access in Salesforce.

Implementing Platform Events

Leverage this skill to publish and subscribe to Platform Events, facilitating event-driven architecture.

Creating REST/SOAP Callouts

Utilize the skill to establish outbound REST or SOAP callouts, ensuring proper authentication and error handling.

How to install Salesforce Integration Patterns

View source

1. Install with the skills CLI

npx skills add forcedotcom/sf-skills/integration-connectivity-generate --agent claude-code

2. Or install it manually

Download the skill folder and drop it into ~/.claude/skills/ for all projects, or .claude/skills/ to scope it to one repo. Restart Claude Code so it picks up the new skill.

Anthropic's agentic coding CLI, and the reference implementation of Agent Skills. Drop a skill folder into ~/.claude/skills and Claude Code loads it automatically whenever a task matches the skill's description. Claude Code docs

Inside SKILL.md

Written by forcedotcom

integration-connectivity-generate: Salesforce Integration Patterns Expert

Use this skill when the user needs integration architecture and runtime plumbing: Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, CDC, and event-driven integration design.

When This Skill Owns the Task

Use integration-connectivity-generate when the work involves:

  • .namedCredential-meta.xml or External Credential metadata
  • outbound REST/SOAP callouts
  • External Service registration from OpenAPI specs
  • Platform Events, CDC, and event-driven architecture
  • choosing sync vs async integration patterns

Delegate elsewhere when the user is:


Required Context to Gather First

Ask for or infer:

  • integration style: outbound callout, inbound event, External Service, CDC, platform event
  • auth method
  • sync vs async requirement
  • system endpoint / spec details
  • rate limits, retry expectations, and failure tolerance
  • whether this is net-new design or repair of an existing integration

Recommended Workflow

1. Choose the integration pattern

NeedDefault pattern
authenticated outbound API callNamed Credential / External Credential + Apex or Flow
spec-driven API clientExternal Service
trigger-originated calloutasync callout pattern
decoupled event publishingPlatform Events
change-stream consumptionCDC

2. Choose the auth model

Prefer secure runtime-managed auth:

  • Named Credentials / External Credentials
  • OAuth or JWT via the right credential model
  • no hardcoded secrets in code

3. Generate from the right templates

Use the provided assets under:

  • assets/named-credentials/
  • assets/external-credentials/
  • assets/external-services/
  • assets/callouts/
  • assets/platform-events/
  • assets/cdc/
  • assets/soap/

4. Validate operational safety

Check:

  • timeout and retry handling
  • async strategy for trigger-originated work
  • logging / observability
  • event retention and subscriber implications

5. Hand off deployment or implementation details

Use:


High-Signal Rules

  • never hardcode credentials
  • do not do synchronous callouts from triggers
  • define timeout behavior explicitly
  • plan retries for transient failures
  • use middleware / event-driven patterns when outbound volume is high
  • prefer External Credentials architecture for new development when supported

Common anti-patterns:

  • sync trigger callouts
  • no retry or dead-letter strategy
  • no request/response logging
  • mixing auth setup responsibilities with runtime integration design

Output Format

When finishing, report in this order:

  1. Integration pattern chosen
  2. Auth model chosen
  3. Files created or updated
  4. Operational safeguards
  5. Deployment / testing next step

Suggested shape:

Integration: <summary>
Pattern: <named credential / external service / event / cdc / callout>
Files: <paths>
Safety: <timeouts, retries, async, logging>
Next step: <deploy, register, test, or implement>

Cross-Skill Integration

NeedDelegate toReason
OAuth app setupintegration-connectivity-connected-app-configureconsumer key / cert / app config
advanced callout service codeplatform-apex-generateApex implementation
declarative HTTP callout / Flow wrapperautomation-flow-generateFlow orchestration
deploy integration metadataplatform-metadata-deployvalidation and rollout
use integration from Agentforceagentforce-generateagent action composition

Reference Map

Start here

Event-driven / platform patterns

CLI / automation / scoring

Asset templates

  • assets/named-credentials/ — Named Credential XML templates (OAuth, JWT, Certificate, Custom auth)
  • assets/external-credentials/ — External Credential XML templates (OAuth, JWT)
  • assets/external-services/ — External Service registration template and operations guide
  • assets/callouts/ — REST sync, Queueable, retry handler, and HTTP response handler Apex templates
  • assets/platform-events/ — Platform Event definition, publisher, and subscriber templates
  • assets/cdc/ — CDC handler and subscriber trigger templates
  • assets/soap/ — SOAP callout service template and wsdl2apex guide
  • assets/endpoint-security/ — Remote Site Setting and CSP Trusted Site XML templates

Automation hooks

  • scripts/suggest_credential_setup.py — auto-suggests credential configuration steps when integration files are detected
  • scripts/validate_integration.py — validates integration patterns before agent responses

Output Expectations

When this skill completes an integration task, it produces:

  1. Credential metadata — one or more files in assets/named-credentials/ or assets/external-credentials/ filled with org-specific values
  2. Callout Apex class — a .cls file using the Named Credential pattern, with async/sync pattern chosen based on context
  3. Event/CDC artifacts — Platform Event .object-meta.xml, subscriber trigger, or CDC config (when event-driven pattern is chosen)
  4. Endpoint security metadata — Remote Site Setting and/or CSP Trusted Site XML files
  5. Scoring report — 120-point score across 6 categories (Security, Error Handling, Bulkification, Architecture, Best Practices, Documentation)
  6. Next step — a deployment or testing instruction for the generated artifacts

Score Guide

ScoreMeaning
108+strong production-ready integration design
90–107good design with some hardening left
72–89workable but needs architectural review
< 72unsafe / incomplete for deployment

Pre-Delivery Checklist

  • Never hardcode credentials — all secrets stored in Named Credentials or External Credentials

Frequently asked questions about Salesforce Integration Patterns

Similar skills