Salesforce

Salesforce

The Salesforce Connector provides an API to work with Salesforce objects.

This connector is available in the following products and regions:

Service Class Regions
Logic Apps Standard All Logic Apps regions
Flow Premium All Flow regions
PowerApps Premium All PowerApps regions

To use this integration, you will need access to a Salesforce account with API access enabled (note that the trials do not have API access).. To make a connection, select Sign In. You will be prompted to provide your Salesforce login, follow the remainder of the screens to create a connection.

You're now ready to start using this integration.

Known Issues and Limitations

  1. There is a limit on the number of fields a query to Salesforce can contain. The limit varies depending on the type of the columns, the number of computed columns, etc. When you receive an error "Query is either selecting too many fields or the filter conditions are too complicated" it means that your query exceeds the limit. To avoid this, use "Select Query" advanced option and specify fields that you really need.
  2. Salesforce session settings can block this integration. Please ensure that setting "Lock sessions to the IP address from which they originated" is disabled.

PowerApps delegable functions and operations for Salesforce

These PowerApps operations, for a given data type, may be delegated to Salesforce for processing (rather than processing locally within PowerApps).

Top-level functions

  Delegable
Average No
Filter Yes
LookUp Yes
Max No
Min No
Search Yes
Sort Yes
SortByColumns Yes
Sum No

Filter and LookUp predicates

  Salesforce
Not Yes
IsBlank No
TrimEnds No
Len No
+, - No
<, <=, =, <>, >, >= Yes
And (&&), Or (||), Not (!) Yes
in Yes
StartsWith No

Throttling Limits

Name Calls Renewal Period
API calls per connection 900 60 seconds

Creating a connection

To connect your account, you will need the following information:

Login URI (Environment)
string
The Salesforce Login URI. For Production, leave blank or use https://login.salesforce.com
Salesforce API Version
string
The Salesforce API Version. For default, leave blank or use v34.0

Actions

Close or abort a job

Closes or aborts a job. Use UploadComplete to close a job, or Aborted to abort a job. If you close a job, Salesforce queues the job and uploaded data for processing, and you can’t add any additional job data. If you abort a job, the job does not get queued or processed.

Required Parameters

Job ID
string
Job ID
state
string
state

Returns

Body
JobInfo

Create a job

Creates a job, which represents a bulk operation (and associated data) that is sent to Salesforce for asynchronous processing. Provide job data via an Upload Job Data request.

Required Parameters

Object
string
Object
Operation
string
Operation

Optional Parameters

Column Delimiter
string
Column Delimiter
External ID Field Name
string
External ID Field Name
Line Ending
string
Line Ending

Returns

Body
JobInfo

Create a job (V2)

Creates a job, which represents a bulk operation (and associated data) that is sent to Salesforce for asynchronous processing. Provide job data via an Upload Job Data request.

Required Parameters

Object
string
The object type for the data being processed.
Operation
string
The processing operation for the job.

Optional Parameters

Column Delimiter
string
The column delimiter used for CSV job data.
External ID Field Name
string
The external ID field in the object being updated. Only needed for upsert operations. Field values must also exist in CSV job data.
Line Ending
string
The line ending used for CSV job data, marking the end of a data row.
Content Type
string
The content type for the job.

Returns

Body
CreateJobResponse

Output for 'CreateJobV2' operation

Create record

This operation creates a record and allows null values.

Required Parameters

Salesforce Object Type
string
table name
Record
dynamic
Record

Returns

The outputs of this operation are dynamic.

Create record [DEPRECATED]

This operation creates a record.

Required Parameters

Salesforce Object Type
string
The Salesforce object type like 'Leads'.
Record
dynamic
The record to create.

Returns

The outputs of this operation are dynamic.

Delete a job

Deletes a job. To be deleted, a job must have a state of UploadComplete, JobComplete, Aborted, or Failed.

Required Parameters

Job ID
string
Job ID

Returns

Body
JobInfo

Delete record

This operation deletes a record.

Required Parameters

Salesforce Object Type
string
The Salesforce object type like 'Leads'.
Record Id
string
The unique identifier of record to delete.

Returns

Body
JobInfo

Get a Record by External ID

This operation retrieves a record using an external ID.

Required Parameters

Salesforce Object Type
string
The Salesforce object type like 'Leads'.
External ID Field
string
Field marked as external ID field on Salesforce object.
External ID
string
External ID of the record to retrieve.

Returns

The outputs of this operation are dynamic.

Get all jobs

Get a list of all jobs

Optional Parameters

Concurrency Mode
string
Concurrency Mode
Is PK Chunking Enabled
boolean
Is PK Chunking Enabled
Job Type
string
Job Type
Query Locator
string
Query Locator

Returns

Get job info

Retrieves detailed information about a job.

Required Parameters

Job ID
string
Job ID

Returns

Get job results

Retrieves a list of records based on the result type for a completed job.

Required Parameters

Job ID
string
Job ID
Result Type
string
Result Type

Returns

Body
JobInfo

Get object types

This operation lists the available Salesforce object types.

Required Parameters

Job ID
string
Job ID
state
string
state

Returns

Body
TablesList

Represents a list of tables.

Get record

This operation gets a record.

Required Parameters

Salesforce Object Type
string
table name
Record Id
string
item key

Optional Parameters

Select Query
string
Specific fields to retrieve from entries (default = all).

Returns

The outputs of this operation are dynamic.

Get record [DEPRECATED]

This operation gets a record.

Required Parameters

Salesforce Object Type
string
The Salesforce object type like 'Leads'.
Record Id
string
The unique identifier of record to get.

Returns

The outputs of this operation are dynamic.

Get records

This operation gets records of a certain Salesforce object type like 'Leads'.

Required Parameters

Salesforce Object Type
string
The Salesforce object type like 'Leads'.

Optional Parameters

Filter Query
string
An ODATA filter query to restrict the entries returned (e.g. stringColumn eq 'string' OR numberColumn lt 123).
Order By
string
An ODATA orderBy query for specifying the order of entries.
Top Count
integer
Total number of entries to retrieve (default = all).
Skip Count
integer
The number of entries to skip (default = 0).
Select Query
string
Specific fields to retrieve from entries (default = all).

Returns

The outputs of this operation are dynamic.

Insert or Update (Upsert) a Record by External ID

This operation inserts or updates (upserts) a record using an external ID.

Required Parameters

Salesforce Object Type
string
The Salesforce object type like 'Leads'.
External ID Field
string
Field marked as external ID field on Salesforce object.
External ID
string
External ID of the record to upsert.
Record
dynamic
The record with changed properties.

Returns

The outputs of this operation are dynamic.

Update record

This operation updates a record and allows null values.

Required Parameters

Salesforce Object Type
string
table name
Record Id
string
item key
item to be updated
dynamic
item to be updated

Optional Parameters

Select Query
string
Specific fields to retrieve from entries (default = all).

Returns

The outputs of this operation are dynamic.

Update record [DEPRECATED]

This operation updates a record.

Required Parameters

Salesforce Object Type
string
The Salesforce object type like 'Leads'.
Record Id
string
The unique identifier of record to update.
Record
dynamic
The record with changed properties.

Returns

The outputs of this operation are dynamic.

Upload job data

Uploads data for a job using CSV data.

Required Parameters

Job ID
string
Job ID
CSV File Content
binary
CSV Data to upload

Returns

Body
JobInfo

Triggers

When a record is created

This operation triggers when there are newly created records.

Required Parameters

Salesforce Object Type
string
The Salesforce object type like 'Leads'.

Optional Parameters

Filter Query
string
An ODATA filter query to restrict the entries returned (e.g. stringColumn eq 'string' OR numberColumn lt 123).
Order By
string
An ODATA orderBy query for specifying the order of entries.
Select Query
string
Specific fields to retrieve from entries (default = all).

Returns

The outputs of this operation are dynamic.

When a record is modified

This operation triggers when there are newly modified records.

Required Parameters

Salesforce Object Type
string
The Salesforce object type like 'Leads'.

Optional Parameters

Filter Query
string
An ODATA filter query to restrict the entries returned (e.g. stringColumn eq 'string' OR numberColumn lt 123).
Order By
string
An ODATA orderBy query for specifying the order of entries.
Select Query
string
Specific fields to retrieve from entries (default = all).

Returns

The outputs of this operation are dynamic.

Definitions

CreateJobResponse

Output for 'CreateJobV2' operation

API Version
float
The API version that the job was created in.
Column Delimiter
string
The column delimiter used for CSV job data.
Concurrency Mode
string
The concurrency mode for the job.
Content Type
string
The content type for the job.
Content Url
string
The URL to use for Upload Job Data requests for this job. Only valid if the job is in 'Open' state.
Created By Id
string
The ID of the user who created the job.
Created Date
date-time
The date and time in the UTC time zone when the job was created.
External ID Field Name
string
The external ID field in the object being updated. Only needed for upsert operations. Field values must also exist in CSV job data.
Id
string
Unique ID for this job.
Job Type
string
The job’s type.
Line Ending
string
The line ending used for CSV job data, marking the end of a data row.
Object
string
The object type for the data being processed.
Operation
string
The processing operation for the job.
State
string
The current state of processing for the job.
System Modstamp
date-time
Date and time in the UTC time zone when the job finished.

Table

Represents a table.

DisplayName
string
The display name of the table.
Name
string
The name of the table. The name is used at runtime.

TablesList

Represents a list of tables.

value
array of Table
List of Tables

GetAllJobsResponse

Done
boolean
Done
Next Recored URL
string
Next Record URL
records
array of JobInfo

JobInfo

API Version
float
API Version
Column Delimiter
string
Column Delimiter
Concurrency Mode
string
Concurrency Mode
Content Type
string
Content Type
Content URL
string
Content URL
Created By ID
string
Created By ID
Created Date
date-time
Created Date
External ID Field Name
string
External ID Field Name
ID
string
ID
Job Type
string
Job Type
Line Ending
string
Line Ending
Object
string
Object
Operation
string
Operation
State
string
State
System Mod Stamp
date-time
System Mod Stamp

CheckJobResponse

APEX Processing Time
number
APEX Processing Time
API Active Processing Time
number
API Active Processing Time
API Version
string
API Version
Column Delimiter
string
Column Delimiter
Concurrency Mode
string
Concurrency Mode
Content Type
string
Content Type
Content URL
string
Content URL
Created By ID
string
Created By ID
Created Date
date-time
Created Date
External Field Name
string
External Field Name
ID
string
ID
Job Type
string
Job Type
Line Ending
string
Line Ending
Object
string
Object
Operation
string
Operation
Retries
number
Retries
State
string
State
Total Processing Time
number
Total Processing Time
systemModStamp
date-time