---
title: "Connect Pigment with Salesforce"
slug: "connect-salesforce"
description: "Connect Salesforce to your Pigment Workspace to import report data effortlessly. Learn to configure connections and use SOQL for custom queries."
tags: ["Importing Exporting Data", "Pigment Workspace", "Salesforce Integration", "SOQL Queries"]
updated: 2026-01-09T13:26:34Z
published: 2026-01-09T13:26:34Z
---

> ## Documentation Index
> Fetch the complete documentation index at: https://kb.pigment.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Connect Pigment with Salesforce

![](https://cdn.document360.io/e47cfe35-dc28-40c7-a083-6cf003073d8e/Images/Documentation/image(7).png)

This article explains how to connect Salesforce with your Pigment Workspace to retrieve any of your Salesforce report data into Pigment Blocks.

As with all other native Pigment integrations, you’ll first need to configure a Connection in the Integration library page. Once configured, this connection can be used by any Application that is authorized as a data source. These authorized Apps are defined during the ‘Import Data’ configuration step. Now, let’s see how to configure and use this native integration!

## Configure the Salesforce Connection

> ℹ️ **Note**
> 
> You need to be a Workspace Admin to be allowed to configure.

In the sidebar, click the Settings tab to navigate to the Integration page. Once there find the Salesforce connector and click on “+ Add”.

![](https://cdn.document360.io/e47cfe35-dc28-40c7-a083-6cf003073d8e/Images/Documentation/e7715c61-d383-45d8-80d3-37da65bb7d06.png)

| If it’s your first Salesforce Connection, click on “Setup a connection”. | ![](https://cdn.document360.io/e47cfe35-dc28-40c7-a083-6cf003073d8e/Images/Documentation/7c50c610-fcf1-4fec-812b-170415ff97ea.png) |
| --- | --- |
| For all your Connections, you need to provide the following information: - A name: this name will allow you to identify the Connection when you use it in other Applications - Application access: list the Applications which should be allowed to use this Connection. Select the Salesforce environment (“Production” or “Sandbox”). Click on **Connect** to start the OAuth app connection process. | ![](https://cdn.document360.io/e47cfe35-dc28-40c7-a083-6cf003073d8e/Images/Documentation/01884570-7e5a-4cda-a129-3a1b37da0c4f.png) |
| Here are the permissions required by the Pigment integration. Click on **Allow**. > ℹ️ **Note** > > If you are not already logged in to your Salesforce account, a first modal will ask you to log-in. > [!WARNING] > **⚠️****Important** > > Pop-ups might be blocked by your browser, please make sure you enable them. | ![](https://cdn.document360.io/e47cfe35-dc28-40c7-a083-6cf003073d8e/Images/Documentation/e9dd90e9-d654-4d39-a2ba-a92805f27bfe.png) |
| Click on **Setup**to finish the process. | ![](https://cdn.document360.io/e47cfe35-dc28-40c7-a083-6cf003073d8e/Images/Documentation/52c945b5-a34f-48a5-a82a-fc82066beb21.png) |

> [!NOTE]
> ℹ️ **Note**
> 
> The Pigment connector with Salesforce is an OAuth connected app using the following [OAuth scopes](https://help.salesforce.com/s/articleView?id=sf.remoteaccess_oauth_tokens_scopes.htm):
> 
> - **Access the identity URL service**
> - **Manage user data via APIs**
> - **Manage user data via Web browsers**
> - **Perform requests at any time**
> 
> As a Salesforce Admin, you can review the Pigment OAuth app usage from the **Connected Apps OAuth Usage** page ([doc](https://help.salesforce.com/s/articleView?id=sf.connected_app_manage_current_sessions.htm&amp;type=5)).

## Load a Salesforce report into Pigment

Once the Salesforce Connection is configured, open any Application for which this Connection is available and open the “Import Data” interface.

Instead of “Upload file”, select the Integration option and select your Salesforce Connection.

![](https://cdn.document360.io/e47cfe35-dc28-40c7-a083-6cf003073d8e/Images/Documentation/dae2f0ed-b59a-4663-b6db-5847c0cfb04b.png)

Now, you just need to add the Report ID of the report you want to load into Pigment. You can find this Report ID in the Salesforce URL when you open that report. It should look like an 18 character long code (ex: `00O7R000007wbfpUAA` ). Once you have this ID, add it and click on “Start Import”.

![](https://cdn.document360.io/e47cfe35-dc28-40c7-a083-6cf003073d8e/Images/Documentation/6c2d7947-0d49-43f4-93ef-ed2fc3fd3e36.png)

The report data should load in Pigment within a few seconds.

> [!CAUTION]
> **🛡️****Warning**
> 
> The “Report” import mode only allows you to load up to 2000 rows of data. For a larger amount of data, please use the “Custom Query” import mode.

## Load raw Salesforce data into Pigment with Custom Queries

For large datasets, the “Report” import mode is too limited. The preferred solution is to use the Custom Query Mode.

![](https://cdn.document360.io/e47cfe35-dc28-40c7-a083-6cf003073d8e/Images/Documentation/87f9c1e0-cf8a-4ae9-800c-7fb7c04b2f0a.png)

Here is an example of SOQL query to load some filed of the Opportunity Table:

```plaintext
SELECT  Id,  AccountId,  Name,  Probability,  IsClosed,  IsWon,  CreatedDate 
FROM Opportunity
```

Once your SOQL query is inputted, you can just click on “Start Import” and continue the standard import flow.

### Resources for those new to Salesforce SOQL

> [!NOTE]
> ℹ️ **Note**
> 
> Writing SOQL can be difficult for new SFDC users. Reach out to your Salesforce Admin for help.

- **Salesforce GSheet addon**: use the import mode and click on “SOQL Query” once you selected the data you want to load. The SOQL query will appear in a modal, you can just copy/past it in Pigment. Link: [https://workspace.google.com/marketplace/app/salesforce_connector/857627895310](https://workspace.google.com/marketplace/app/salesforce_connector/857627895310)
- **Salesforce Developer Documentation - SOQL:** The official Salesforce documentation on SOQL provides comprehensive information, examples, and best practices. It's a great starting point for learning about SOQL. Link: [**https://developer.salesforce.com/docs/atlas.en-us.soql_sosl.meta/soql_sosl/sforce_api_calls_soql_intro.htm**](https://developer.salesforce.com/docs/atlas.en-us.soql_sosl.meta/soql_sosl/sforce_api_calls_soql_intro.htm)
- **Trailhead - Apex & SOQL for Developers:** Trailhead is Salesforce's interactive learning platform. This module covers SOQL and Apex programming in-depth and includes hands-on exercises to practice your skills. Link: [**https://trailhead.salesforce.com/en/content/learn/modules/apex_database**](https://trailhead.salesforce.com/en/content/learn/modules/apex_database)
- **SOQL Builder:**An interactive extension in VS Code by Salesforce that allows you to visually build and run SOQL queries against your org, see results, and export them”Link: **https://developer.salesforce.com/docs/platform/sfvscode-extensions/guide/soql-builder.html**
- **Salesforce Stack Exchange:** The Salesforce community is very active on Stack Exchange. You can find a plethora of SOQL-related questions, answers, and discussions that can help you learn and troubleshoot. Link: [**https://salesforce.stackexchange.com/**](https://salesforce.stackexchange.com/)
- **Advanced SOQL Queries Cheat Sheet:** A cheat sheet with various examples of advanced SOQL queries to handle complex scenarios like relationship queries, aggregate functions, subqueries, etc. Link: [**https://resources.docs.salesforce.com/latest/latest/en-us/sfdc/pdf/salesforce_soql_sosl.pdf**](https://resources.docs.salesforce.com/latest/latest/en-us/sfdc/pdf/salesforce_soql_sosl.pdf)
- **Salesforce Ben - SOQL Guide:** This blog post from Salesforce Ben covers the basics of SOQL and provides practical examples to illustrate how to write effective queries. Link: **https://www.salesforceben.com/salesforce-soql-queries-and-limits/**
- **Developerforce YouTube Channel - SOQL Videos:** Salesforce's official Developerforce YouTube channel has video tutorials on various Salesforce development topics, including SOQL. Link: [**https://www.youtube.com/user/developerforce/search?query=soql**](https://www.youtube.com/user/developerforce/search?query=soql)
- **Salesforce Query editor(developer consol)**: powerful and fast but not very user friendly. Link: [https://help.salesforce.com/s/articleView?id=sf.code_dev_console_tab_query_editor.htm&type=5](https://help.salesforce.com/s/articleView?id=sf.code_dev_console_tab_query_editor.htm&amp;type=5)
- **Workbench**: a third party tool very user friendly to write SOQL queries when you are not familiar with that syntax. Link:[https://workbench.developerforce.com/login.php](https://workbench.developerforce.com/login.php)

Remember that practice is key to mastering SOQL. Experiment with different queries, join Salesforce developer communities, and leverage these resources to become proficient in writing SOQL queries in Salesforce.
