As a Salesforce Architect, one of our most important responsibilities is ensuring that Salesforce integrates smoothly with other systems. In the real world, Salesforce is rarely used alone. Businesses expect a complete, 360° view of their customer information, which means pulling data together from CRM, ERP, billing, marketing, and many other systems. This is where APIs (Application Programming Interfaces) come in.
APIs are the foundation of Salesforce integrations. They enable different systems to talk to each other, share data, and automate processes. But our role as an architect is not just about knowing what an API is. We need to be able to design integrations that are reliable, scalable, and secure, and that meet the specific business needs.
Table of Contents
What is an API in Salesforce?
An API is like a contract or a set of rules that defines how two software systems interact. Instead of worrying about the inner workings of Salesforce—like how it stores or processes data—you can use an API to perform common actions such as create, read, update, or delete records (CRUD operations).
Think of an API as a restaurant menu. We don’t need to see how the chef prepares the food in the kitchen. We just need to know what’s on the menu and how to place an order.
Why APIs Are So Important for Salesforce Architects
When we are designing solutions at an enterprise level, APIs are essential because they help with:
- Integration: Connecting Salesforce with ERP, data warehouses, marketing tools, custom applications, and more.
- Scalability: Handling very large amounts of data or transactions without slowing down Salesforce.
- Extensibility: Letting external apps, customers, or partners safely interact with Salesforce data.
- Automation: Driving workflows, real-time events, and complex orchestrations without manual effort.
As a Salesforce Architect, the API we choose and when to choose it matter a lot. The right choice can make the system run faster, stay more reliable, and give users a smoother experience. On the other hand, the wrong choice can cause slow performance, errors, or frustration for end users
Salesforce API Landscape
1. Core Data Access API
1.1. REST API
The REST API is one of the easiest ways to connect Salesforce with other systems. It uses a simple, web-based approach (just like how your browser talks to websites) to let applications read, create, update, or delete data in Salesforce.
Because it’s lightweight and easy to use, the REST API is a great choice when building mobile apps or web applications. For example, if you’re building a mobile sales app that needs to show customer records from Salesforce, the REST API can fetch and update that data quickly.
Different REST APIs in Salesforce
1.1.1 User Interface API
This is used to build custom UI or mobile apps using the same API that powers Lightning Experience and Salesforce on Android, iOS, and mobile web. Example: If you’re creating a custom app screen where users can see list views, edit records, or use dependent picklists just like in Salesforce, use the UI API.
1.1.2 Connect REST API
Salesforce Connect API, also called Connect REST API, lets us access Salesforce data and features like Chatter feeds, files, and notifications through code. It’s mainly used to connect Salesforce with other systems or to build custom apps. Example: If the customer community site needs to display managed CMS articles or allow users to post in Chatter, you’d use the Connect REST API.
1.1.3 Bulk API
Salesforce Bulk API is a REST-based tool that helps work with very large amounts of data. It runs tasks in the background and is especially useful for adding, updating, deleting, or finding lots of records in Salesforce at once. Example: If you’re importing millions of leads from a marketing system into Salesforce, the Bulk API handles that much faster and more efficiently than standard REST API calls.
1.2. SOAP API
SOAP API in Salesforce is a protocol-based API that uses XML messages and WSDL files to enable structured, strongly typed communication between Salesforce and other systems. It is ideal when working with enterprise applications that already rely on SOAP or when strict contracts and robust error handling are required.
Example: A bank’s Java-based core system needs to sync customer loan records with Salesforce. Since the core system already uses SOAP/WSDL for external integrations, the bank imports Salesforce’s Partner WSDL.
This generates ready-made create()
, update()
, and query()
methods in Java, making it easy to insert loan applications, update repayment details, or fetch records with minimal coding. Using REST API here would require custom coding and JSON handling, whereas SOAP’s WSDL-based contract fits naturally into the bank’s existing architecture.
Refer to the post Difference between Salesforce WSDL Files to learn about different types of WSDL in Salesforce.
1.3 Bulk API (v1 & v2)
Bulk API is a Salesforce REST API designed for handling very large volumes of data—thousands to millions of records. Instead of sending records one by one, it processes them in bulk, making it ideal for data migrations, large imports, or cleanup jobs. There are two versions: Bulk API v1 and Bulk API v2.
With v1, you must split the data into batches (for example, 200 batches of 10,000 records each when updating 2 million Accounts). This gives you fine control—if one batch fails, you can reprocess just that batch. In contrast, v2 is simpler: you upload one large file, Salesforce automatically splits and processes it behind the scenes, and you get a single job report. In short, use v1 for complex jobs needing batch-level control, and v2 for straightforward large data loads where ease and speed matter most.
1.4 GraphQL API
GraphQL API in Salesforce is a modern way to request exactly the data you need, nothing more and nothing less. Unlike REST APIs, where you might get fixed sets of fields or need multiple calls to different endpoints, GraphQL lets you query multiple objects and fields in a single request. This makes it faster and more efficient, especially for mobile apps or front-end applications that need to display complex data in one screen.
Usage Example: Suppose you’re building a mobile app that shows a customer’s account details, their recent opportunities, and related contacts. With GraphQL, you can write one query that fetches all this information at once, specifying only the fields you need—like account name, opportunity stage, and contact email. This reduces the number of API calls, improves performance, and gives developers more flexibility when building UI or integrations.
2. Event-Driven & Streaming APIs
In Salesforce, event-driven architecture enables systems to react in real-time to business events or system events, such as a new opportunity being created, a record being updated, or a platform event being published. This allows applications to process data asynchronously and respond immediately to changes, rather than relying on periodic polling. Salesforce provides Streaming APIs as the primary mechanism to implement this pattern. Streaming APIs use a publish-subscribe model where clients subscribe to specific channels (like PushTopics, Platform Events, or Change Data Capture) and receive notifications whenever an event occurs.
By combining event-driven principles with Streaming APIs, Salesforce enables seamless real-time integrations. For example, an external system can subscribe to a platform event to trigger order processing whenever a new order is created in Salesforce. Similarly, Change Data Capture can notify connected systems of updates to critical records instantly. This approach improves efficiency, reduces data latency, and ensures that business processes and integrations are always in sync with the latest events in Salesforce.
Key Types of Streaming APIs in Salesforce
2.1 Platform Events
Platform Events are custom or standard events that represent business processes in Salesforce. It can be published by Salesforce or external systems and can be subscribed to by Apex triggers, flows, or external systems. Example: A company wants to notify an external inventory system whenever a new order is placed in Salesforce.
2.2 Change Data Capture
Change Data Capture (CDC) in Salesforce is a real-time event-driven feature that automatically tracks changes (create, update, delete, and undelete) to Salesforce records and publishes them as events. External systems or internal processes can subscribe to these events to react immediately without constantly polling Salesforce for updates. This ensures efficient, near-instant synchronization between Salesforce and other systems.
Example:
Suppose we need to notify data changes to an external ERP system whenever a record is updated (e.g., a billing address changes); CDC can publish this change as an event.
2.3 PushTopic
A PushTopic in Salesforce is a Streaming API feature that allows external systems to receive real-time notifications whenever specific changes occur in Salesforce records. It is tied to standard or custom objects, and the notifications are triggered based on an SOQL query that defines which records and fields to monitor.
PushTopics can be configured to notify subscribers for create, update, delete, or undelete operations, ensuring that external systems stay in sync with important Salesforce data changes. For example, a PushTopic can be set up to alert an external application whenever an Opportunity’s Stage changes to “Closed Won,” enabling immediate processing or follow-up actions.
2.4 Generic Events
Generic events refer to custom, reusable events that are not tied to a specific standard object or business process. They are designed to handle generic scenarios where you want to communicate or trigger actions across systems or processes. For example, you want to notify an external system that your API is down temporarily and should not be consumed.
3. Specialized APIs
3.1 Metadata API
The Metadata API in Salesforce helps us in managing and moving Salesforce objects like custom objects, fields, page layouts, workflows, profiles, permission sets, Apex code, and Lightning components. With this API, we can automatically transfer these configurations between different Salesforce environments (for example, from a sandbox to production), making deployments easier and keeping everything consistent. Unlike REST or SOAP APIs, which work with actual records, the Metadata API works with the metadata and configuration of org.
Real-life example: A company has multiple Salesforce environments—a sandbox for development, UAT for testing, and production. A developer adds new objects, fields, and layouts in the sandbox. Instead of creating them again manually in UAT and production, the Metadata API can copy these changes automatically. This saves time, avoids mistakes, and keeps everything consistent. DeveOps tools (Copado, Gearset, autorabit, etc) use this API for deployment.
3.2 Tooling API
The Salesforce Tooling API is a specialized API designed for developers and administrators to interact with development and setup components in real-time. It allows us to programmatically manage Apex classes, triggers, Visualforce pages, Lightning components, and debug logs without using the Salesforce UI.
For example, a developer can build a custom IDE or automation tool to fetch Apex logs, create or edit triggers, and monitor code execution directly through the API. This makes the Tooling API ideal for tasks that require quick, programmatic access to development metadata and real-time insights.
3.3 Connect REST API
Connect REST API is a specialized Salesforce API designed to access and interact with Chatter and social collaboration features within Salesforce. It provides a simple, REST-based interface to work with feeds, groups, users, files, and recommendations. Unlike standard REST APIs, the Connect REST API is optimized for social collaboration data and supports actions like posting to feeds, commenting, liking, following records, and accessing user profiles.
3.4 Apex REST API
Apex REST in Salesforce lets developers build custom REST web services using Apex code. It’s helpful when the standard Salesforce REST API doesn’t meet your needs or when you want to share custom business logic with other systems. Apex REST services can handle HTTP methods like GET, POST, PUT, PATCH, and DELETE, so external apps can easily work with Salesforce data or perform specific actions
4. Analytics & AI APIs
4.1 Analytics REST API
The Analytics API (also called Einstein Analytics REST API) lets developers and admins interact programmatically with CRM Analytics (formerly Einstein Analytics / Wave Analytics). It helps us access, explore, and manipulate datasets, dashboards, and lenses using REST endpoints, instead of doing everything manually in the Salesforce UI.
Usage of Analytics API
It can be used to
- Automate analytics tasks – like refreshing datasets or exporting reports.
- Embed dashboards into custom apps (Salesforce or external).
- Query data programmatically using SAQL (Salesforce Analytics Query Language).
- Integrate analytics with external systems – e.g., exporting Salesforce insights to a third-party app.
- Create or update analytics assets (datasets, dashboards, lenses) automatically via code.
4.2 Einstein Vision & Language APIs
Einstein Vision and Language APIs are part of Salesforce Einstein, which provides AI-as-a-service. They let you bring machine learning into your Salesforce apps without needing to build complex ML models from scratch.
4.2.1 Einstein Vision API
Einstein Vision is an AI / computer-vision API suite that adds image recognition, object detection, and OCR capabilities to applications.
Examples:
- A retailer uses it to classify product photos (e.g., identifying whether an uploaded image is a shirt, shoes, or bag).
- A service company can analyze damaged car photos to estimate claim categories.
- Healthcare apps can classify medical images (e.g., skin conditions).
4.2.2 Einstein Language API
The Einstein Language API is a set of natural language processing (NLP) services provided by Salesforce Einstein. It is designed to help developers analyze and understand text data. It utilizes machine learning models to classify, interpret, and extract meaning from written content, enabling smarter and more automated interactions within Salesforce applications.
- Intent API: This API helps us identify the underlying intent or purpose behind a given text.
- Example: If a customer sends, “I want to cancel my subscription”, the API can classify it under “cancellation request”.
- Use case: Route customer inquiries to the right department automatically.
- Sentiment API: This helps us determine the sentiment of a text — whether it is positive, negative, or neutral.
- Example: “The service was amazing” → positive sentiment.
- Use case: Track customer satisfaction, flag unhappy customer feedback for faster response
- Named Entity Recognition (NER) API – Named Entity Recognition API helps in extracting entities like names, dates, locations, etc.
- Example: “Schedule a meeting with John tomorrow in New York” → Entities: Person = John, Date = Tomorrow, Location = New York.
5. Industry & Business APIs
5.1 CPQ & Billing APIs
Salesforce provides a set of REST and SOAP APIs for CPQ & Billing so that external systems (ERPs, eCommerce, custom apps) can integrate with them. These APIs allow developers to programmatically interact with CPQ and Billing data without only relying on the Salesforce UI.
5.2 Marketing Cloud APIs (REST & SOAP)
Salesforce Marketing Cloud APIs let us integrate Marketing Cloud with external systems, automate processes, and extend platform capabilities. The two main types are REST API and SOAP API, each serving different use cases:
The REST API in Marketing Cloud is designed for modern, lightweight, and stateless operations. It’s easier to use and integrates well with web and mobile apps.
The SOAP API is the older, more comprehensive API. It’s WSDL-based and suited for enterprise-level operations that need detailed data access and management.
5.3 Commerce Cloud APIs
Salesforce Commerce Cloud APIs are a collection of APIs that help us build, extend, and integrate eCommerce capabilities with Salesforce’s Commerce Cloud platform. They provide programmatic access to storefront data, customer information, product catalogs, pricing, promotions, and order management, allowing businesses to create personalized and connected shopping experiences.
Summary
APIs are more than just technical tools—they’re key enablers for Salesforce Architects. Choosing the right API at the right time can be the difference between an integration that breaks under pressure and one that scales smoothly across the enterprise.
👉 Learn and master the full set of APIs.
👉 Match each API to the right business need.
👉 Document and standardize your approach so it’s easy to maintain in the future.
With a smart API strategy, you’re not just linking systems—you’re building a strong, scalable integration layer that supports digital growth.
✅ Pro Tip for Architects: Keep an API selection matrix for your org. Map business use cases to the right Salesforce APIs to reduce confusion and keep solutions consistent across teams.
References
Related Posts
- Extract Driver License Detail from Image using Einstein API
- Named Entity Recognition using Salesforce Einstein API
- Create OCR App using Salesforce Einstein OCR API
- Extract Text From Image using Google Cloud Vision
- Apex Code Coverage In Custom Object
- Get All Used Custom Metadata Detail
- Find Referenced Metadata using Salesforce Dependency API
- Extract list of all fields from Page Layout
- Call Tooling API from Lightning Web Component