SoqlQuery
Query Salesforce using SOQL.
Execute a SOQL query against Salesforce.
type: "io.kestra.plugin.ee.salesforce.SoqlQuery"
Examples
Query Salesforce Contacts and store as ION file.
id: query_salesforce_contacts
namespace: company.sales
tasks:
- id: query_contacts
type: io.kestra.plugin.ee.salesforce.SoqlQuery
connection:
username: "{{ secret('SALESFORCE_USERNAME') }}"
password: "{{ secret('SALESFORCE_PASSWORD') }}"
authEndpoint: "{{ secret('SALESFORCE_AUTH_ENDPOINT') }}"
query: "SELECT Id, FirstName, LastName, Email FROM Contact WHERE CreatedDate = LAST_WEEK"
fetchType: STORE
Properties
connection *RequiredNon-dynamicSalesforceConnection
Salesforce connection properties.
query *Requiredstring
SOQL query to execute
The SOQL query to run against Salesforce
batchSize integerstring
2000
Maximum batch size
Number of records to include in each batch, the minimum is 200, and the maximum is 2,000.
fetchType string
NONE
STORE
FETCH
FETCH_ONE
NONE
The way you want to store the data.
FETCH_ONE output the first row, FETCH output all the rows, STORE store all rows in a file, NONE do nothing.
queryMore booleanstring
true
Query More Flag
Whether to fetch more records if there are more beyond the first batch (default: true)
Outputs
row object
Map containing the first row of fetched data.
Only populated if using fetchType=FETCH_ONE
.
rows array
List containing the fetched data.
Only populated if using fetchType=FETCH
.
size integer
The number of rows fetched.
total integer
The total number of the rows fetched without pagination.
uri string
uri
The URI of the stored data.
Only populated if using fetchType=STORE
.
Definitions
io.kestra.plugin.ee.salesforce.SalesforceConnection
password *Requiredstring
Salesforce password
The password for authenticating with Salesforce API. Depending on your Salesforce instance, you may need to append the security token to your password (e.g., '
username *Requiredstring
Salesforce username
The username for authenticating with Salesforce API
authEndpoint string
https://login.salesforce.com/services/Soap/u/63.0/
Salesforce authentication endpoint
The Salesforce SOAP API authentication endpoint URL