Salesforce REST Connector Reference¶
The following operations allow you to work with the Salesforce REST Connector v2.x that provides seamless integration with the Salesforce REST API v59.0. Click on an operation name to see the parameter details and samples on how to use it.
Salesforce REST Connector Connection Configuration¶
Salesforce REST API uses the OAuth protocol to allow application users to securely access data without having to reveal their user credentials. For more information on how authentication is done in Salesforce, see Understanding Authentication. You can provide only access token and use it until it expires. After expiry, you will be responsible for getting a new access token and using it. Alternatively, you have the option of providing refresh token, client secret, and client ID which will be used to get access token initially and after every expiry by the connector itself. You will not be required to handle access token expiry in this case.
There also an option to use basic authentication with username and password.
Connection configuration
In the 'Properties' section of each operation, users can configure connection-related information. Once the configuration is created, it can be reused in other operations.
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
apiVersion | The version of the Salesforce API. | Yes | v59.0 |
accessToken | The access token to authenticate your API calls. | No | XXXXXXXXXXXX (Replace with your access token) |
apiUrl | The instance URL for your organization. | Yes | https://ap2.salesforce.com |
hostName | SalesforceOAuth endpoint when issuing authentication requests in your application. | Yes | https://login.salesforce.com |
refreshToken | The refresh token that you received to refresh the API access token. | No | XXXXXXXXXXXX (Replace with your refresh token) |
tokenEndpointHostname | The endpoint of the refresh token that you invoke to refresh the API access token. | No | XXXXXXXXXXXX (Replace this with your refresh token endpoint) |
clientId | The consumer key of the connected application that you created. | No | XXXXXXXXXXXX (Replace with your client ID) |
clientSecret | The consumer secret of the connected application that you created. | No | XXXXXXXXXXXX (Replace with your client secret) |
blocking | Indicates whether the connector needs to perform blocking invocations to Salesforce. | Yes | false |
Sample configuration
<salesforcerest.init>
<accessToken>{$ctx:accessToken}</accessToken>
<apiUrl>{$ctx:apiUrl}</apiUrl>
<hostName>{$ctx:hostName}</hostName>
<apiVersion>{$ctx:apiVersion}</apiVersion>
<blocking>{$ctx:blocking}</blocking>
</salesforcerest.init>
Sample request
{
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"blocking" : "false"
}
Or if you want the connector to handle token expiry
Sample configuration
<salesforcerest.init>
<apiUrl>{$ctx:apiUrl}</apiUrl>
<hostName>{$ctx:hostName}</hostName>
<apiVersion>{$ctx:apiVersion}</apiVersion>
<refreshToken>{$ctx:refreshToken}</refreshToken>
<clientId>{$ctx:clientId}</clientId>
<clientSecret>{$ctx:clientSecret}</clientSecret>
<blocking>{$ctx:blocking}</blocking>
</salesforcerest.init>
Sample request
{
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"refreshToken":"XXXXXXXXXXXX (Replace with your refresh token)",
"apiUrl":"https://(your_instance).salesforce.com",
"clientId": "XXXXXXXXXXXX (Replace with your client ID)",
"clientSecret": "XXXXXXXXXXXX (Replace with your client secret)",
"blocking" : "false"
}
Connection Configuration Parameters for username/password flow
The connection configuration parameters that are required to interact with the Salesforce REST API using a username/password flow. See the related API documentation for more information.
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
apiVersion | The version of the Salesforce API. | Yes | v59.0 |
apiUrl | The instance URL for your organization. | Yes | https://ap2.salesforce.com |
hostName | SalesforceOAuth endpoint when issuing authentication requests in your application. | Yes | https://login.salesforce.com |
clientId | The consumer key of the connected application that you created. | Yes | XXXXXXXXXXXX (Replace with your client ID) |
clientSecret | The consumer secret of the connected application that you created. | Yes | XXXXXXXXXXXX (Replace with your client secret) |
username | The username for Salesforce. | Yes | [email protected] |
password | The password for Salesforce (need to append the password with security key). | Yes | xxxxxxxxxxxxxxxxxxxxxx |
blocking | Indicates whether the connector needs to perform blocking invocations to Salesforce. | Yes | false |
Sample configuration
<salesforcerest.init>
<apiUrl>{$ctx:apiUrl}</apiUrl>
<clientId>{$ctx:clientId}</clientId>
<clientSecret>{$ctx:clientSecret}</clientSecret>
<hostName>{$ctx:hostName}</hostName>
<apiVersion>{$ctx:apiVersion}</apiVersion>
<username>{$ctx:username}</username>
<password>{$ctx:password}</password>
<blocking>{$ctx:blocking}</blocking>
</salesforcerest.init>
Sample request
{
"clientId": "xxxxxxxxxxxxxxxxxxxxxxxx",
"clientSecret": "xxxxxxxxxxxxxxxxxxxxxxxx",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"username": "[email protected]",
"password": "xxxxxxxxxxxxxxxxxxxxxx",
"apiUrl":"https://(your_instance).salesforce.com",
"blocking" : "false"
}
AppMenu¶
listAppMenuTypes
To retrieve a list of App Menu types in the Salesforce app dropdown menu, use salesforcerest.listAppMenuTypes and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/appMenu/
Sample configuration
<salesforcerest.listAppMenuTypes/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"blocking" : "false"
}
Sample response
{
"AppSwitcher": "/services/data/v59.0/appMenu/AppSwitcher",
"Salesforce1": "/services/data/v59.0/appMenu/Salesforce1",
"NetworkTabs": "/services/data/v59.0/appMenu/NetworkTabs"
}
listAppMenuItems
To retrieve a list of items in either the Salesforce app drop-down menu or the Salesforce1 navigation menu, use salesforcerest.listAppMenuItems and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/appMenu/AppSwitcher/
Sample configuration
<salesforcerest.listAppMenuItems/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"blocking" : "false"
}
Sample response
{
"appMenuItems": [
{
"colors": null,
"content": null,
"icons": null,
"label": "Sales",
"name": "02u5j000004hYzj",
"type": "Tabset",
"url": "/home/home.jsp?tsid=02u5j000004hYzj"
},
{
"colors": null,
"content": null,
"icons": null,
"label": "Service",
"name": "02u5j000004hYzz",
"type": "Tabset",
"url": "/home/home.jsp?tsid=02u5j000004hYzz"
},
.
.
]
}
returnHeadersForAppMenuItems
To retrieve only the headers that are returned by the listAppMenuItems operation, use salesforcerest.returnHeadersForAppMenuItems and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/appMenu/AppSwitcher/
Sample configuration
<salesforcerest.returnHeadersForAppMenuItems/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"blocking" : "false"
}
listAppMenuMobileItems
To retrieve a list of the App Menu items in the Salesforce mobile app for Android and iOS and the mobile web navigation menu., use salesforcerest.listAppMenuMobileItems and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/appMenu/Salesforce1/
Sample configuration
<salesforcerest.listAppMenuMobileItems/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"blocking" : "false"
}
Sample response
{
"appMenuItems": [
{
"colors": [
{
"color": "1B96FF",
"context": "primary",
"theme": "theme4"
}
],
"content": null,
"icons": [
{
.
.
],
"label": "Chatter",
"name": "F",
"type": "Standard.Feed",
"url": "/feed"
},
.
.
]
}
returnHeadersForAppMenuMobileItems
To retrieve only the headers that are returned by the listAppMenuMobileItems operation, use salesforcerest.returnHeadersForAppMenuMobileItems and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/appMenu/Salesforce1/
Sample configuration
<salesforcerest.returnHeadersForAppMenuMobileItems/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"blocking" : "false"
}
tabs
To retrieve a list of all tabs, use salesforcerest.tabs. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/tabs/
Sample configuration
<salesforcerest.tabs/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample response
{"output":"[{\"colors\":[{\"color\":\"4dca76\",\"context\":\"primary\",\"theme\":\"theme4\"},{\"color\":\"319431\",\"context\":\"primary\",\"theme\":\"theme3\"}],\"custom\":true,\"iconUrl\":\"https://sampletest-dev-ed.my.salesforce.com/img/icon/form32.png\",..}
returnHeadersForTabs
To retrieve only the headers that are returned by the tabs operation, use salesforcerest.returnHeadersForTabs. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/tabs/
Sample configuration
<salesforcerest.returnHeadersForTabs/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
themes
To retrieve a list of icons and colors used by themes in the Salesforce application, use salesforcerest.themes. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/theme
Sample configuration
<salesforcerest.themes/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample response
{
"themeItems":[
{
"name":"Account",
"icons":[
{
"width":32,
"theme":"theme3",
"contentType":"image/png",
"url":"https://kesavan-dev-ed.my.salesforce.com/img/icon/accounts32.png",
"height":32
}
]
}
]
}
Approvals¶
listApprovals
To retrieve the list of approvals in Salesforce, use salesforcerest.listApprovals. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/process/approvals/
Sample configuration
<salesforcerest.listApprovals/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample response
{
"approvals" : {
"Account" : [ {
"description" : null,
"id" : "04aD00000008Py9",
"name" : "Account Approval Process",
"object" : "Account",
"sortOrder" : 1
} ]
}
}
returnHeadersForApprovals
To return only the headers that are returned by the listApprovals operation, use salesforcerest.returnHeadersForApprovals. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/process/approvals/
Sample configuration
<salesforcerest.returnHeadersForApprovals/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
submitApproveOrRejectApprovals
To submit a particular record if that entity supports an approval process and one has already been defined, use salesforcerest.submitApproveOrRejectApprovals. Records can be approved and rejected if the current user is an assigned approver. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/process/approvals/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
fieldAndValue | The .json format property used to submit, approve, or reject the approvals. | Yes | { "requests" : [{ "actionType": "Submit", "contextId": "001D000000I8mIm", "nextApproverIds": ["005D00000015rY9"], "comments":"this is a test", "contextActorId": "005D00000015rZy", "processDefinitionNameOrId" : "PTO_Request_Process", "skipEntryCriteria": "true"}] } |
Sample configuration
<salesforcerest.submitApproveOrRejectApprovals>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.submitApproveOrRejectApprovals>
Sample request
The following is a sample request that can be handled by the submitApproveOrRejectApprovals operation to submit a record or a collection of records for approval.
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"fieldAndValue":{
"requests" : [{
"actionType": "Submit",
"contextId": "001D000000I8mIm",
"nextApproverIds": ["005D00000015rY9"],
"comments":"this is a test",
"contextActorId": "005D00000015rZy",
"processDefinitionNameOrId" : "PTO_Request_Process",
"skipEntryCriteria": "true"}]
}
}
Sample response
Given below is a sample response for the above request.
[ {
"actorIds" : [ "005D00000015rY9IAI" ],
"entityId" : "001D000000I8mImIAJ",
"errors" : null,
"instanceId" : "04gD0000000Cvm5IAC",
"instanceStatus" : "Pending",
"newWorkitemIds" : [ "04iD0000000Cw6SIAS" ],
"success" : true
} ]
Composite¶
listCompositeResources
To retrieve a list of URIs for composite resources, use salesforcerest.listCompositeResources. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/composite
Sample configuration
<salesforcerest.listCompositeResources/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0"
}
Sample response
{
"tree": "/services/data/v54.0/composite/tree",
"batch": "/services/data/v54.0/composite/batch",
"sobjects": "/services/data/v54.0/composite/sobjects",
"graph": "/services/data/v54.0/composite/graph"
}
sendMultipleRequestsUsingComposite
To execute a series of REST API requests in a single call, use salesforcerest.sendMultipleRequestsUsingComposite. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/composite
Parameter Name | Description | Required | Sample Value | fieldAndValue | The .json format property used to send multiple requests using composite. | Yes | { "allOrNone" : true, "collateSubrequests": true, "compositeRequest" : [{ Composite Subrequest },{ Composite Subrequest },{ Composite Subrequest }] } |
---|
Sample configuration
<salesforcerest.sendMultipleRequestsUsingComposite>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.sendMultipleRequestsUsingComposite>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"fieldAndValue": {
"allOrNone" : true,
"collateSubrequests": true,
"compositeRequest" : [{
Composite Subrequest
},{
Composite Subrequest
},{
Composite Subrequest
}]
}
}
Sample response
{
"compositeResponse" : [{
Composite Subrequest Result
},{
Composite Subrequest Result
},{
Composite Subrequest Result
}]
}
compositeBatch
To execute up to 25 subrequests in a single request, use salesforcerest.compositeBatch. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/composite/batch
Parameter Name | Description | Required | Sample Value | fieldAndValue | The .json format property used to submit bacth requests. | Yes | { "batchRequests" : [ { "method" : "PATCH", "url" : "v59.0/sobjects/account/001D000000K0fXOIAZ", "richInput" : {"Name" : "NewName"} },{ "method" : "GET", "url" : "v59.0/sobjects/account/001D000000K0fXOIAZ?fields=Name,BillingPostalCode" }] } |
---|
Sample configuration
<salesforcerest.compositeBatch>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.compositeBatch>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"fieldAndValue": {
"batchRequests" : [
{
"method" : "PATCH",
"url" : "v59.0/sobjects/account/001D000000K0fXOIAZ",
"richInput" : {"Name" : "NewName"}
},{
"method" : "GET",
"url" : "v59.0/sobjects/account/001D000000K0fXOIAZ?fields=Name,BillingPostalCode"
}
]
}
}
Sample response
{
"hasErrors" : false,
"results" : [{
"statusCode" : 204,
"result" : null
},{
"statusCode" : 200,
"result": {
"attributes" : {
"type" : "Account",
"url" : "/services/data/v59.0/sobjects/Account/001D000000K0fXOIAZ"
},
"Name" : "NewName",
"BillingPostalCode" : "94105",
"Id" : "001D000000K0fXOIAZ"
}
}]
}
compositeGraph
To submit composite graph operations, use salesforcerest.compositeGraph. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/composite/graph
Parameter Name | Description | Required | Sample Value | fieldAndValue | The .json format property used to submit composite graph operations. | Yes | { "graphId" : "graphId", "compositeRequest" : [ compositeSubrequest, compositeSubrequest, ... ] } |
---|
Sample configuration
<salesforcerest.compositeGraph>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.compositeGraph>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"fieldAndValue": {
"graphId" : "graphId",
"compositeRequest" : [
compositeSubrequest,
compositeSubrequest,
...
]
}
}
Sample response
{
"graphs" : [
{
"graphId" : "graphId",
"graphResponse" : {
"compositeResponse" : [
compositeSubrequestResult,
compositeSubrequestResult,
compositeSubrequestResult,
...
]
},
"isSuccessful" : flag
},
...
]
}
Consent¶
consentDetailsOnSingleAction
To retrieve consent details based on a single action, like email or track, across specific consent management objects when the records have a lookup relationship, use salesforcerest.consentDetailsOnSingleAction. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/consent/action/{action}?ids={listOfIds}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
action | The proposed action. Ex: email, fax, geotrack, mail, phone, portability, process, profile, shouldforget, social, solicit, storepiielsewhere, track, web | Yes | |
listOfIds | Comma-separated list of IDs. The ID can be the record ID or the email address listed on the record. | Yes | [email protected],[email protected] |
aggregatedConsent | Whether to enable or disable aggregated consent. true or false. | No | true |
datetime | The timestamp for which consent is determined. | No | 2018-12-12T00:00:00Z |
policy | The policy. | No | requireExplicitConsent |
purpose | The reason for contacting a customer. | No | billing |
verbose | Whether to allow verbose non-verbose responses. true or false | No | true |
Sample configuration
<salesforcerest.consentDetailsOnSingleAction>
<action>{$ctx:action}</action>
<listOfIds>{$ctx:listOfIds}</listOfIds>
<aggregatedConsent>{$ctx:aggregatedConsent}</aggregatedConsent> <!-- optional -->
<datetime>{$ctx:datetime}</datetime> <!-- optional -->
<policy>{$ctx:policy}</policy> <!-- optional -->
<purpose>{$ctx:purpose}</purpose> <!-- optional -->
<verbose>{$ctx:verbose}</verbose> <!-- optional -->
</salesforcerest.consentDetailsOnSingleAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"action":"email",
"listOfIds": "[email protected],[email protected]",
"datetime": "2018-12-12T00:00:00Z"
}
Sample Response
{
"[email protected]" : {
"result" : "Success",
"proceed" : {
"email" : "true"
"emailResult" : "Success"
},
"explanation" : [ {
"objectConsulted" : "ContactTypePointConsent",
"status" : "opt_in",
"purpose" : "billing",
"recordId" : "003xx000004TxyY",
"value" : "true"
},{
"objectConsulted" : "Contact",
"field" : "HasOptedOutOfTracking",
"recordId" : "1",
"value" : "true"
}]
},
"[email protected]" : {
"result" : "Success",
"proceed" : {
"email" : "false"
"emailResult" : "Success"
},
"explanation" : [ {
"objectConsulted" : "Contact",
"field" : "HasOptedOutOfEmail",
"recordId" : "00Qxx00000skwO",
"value" : "true"
} ]
}
}
consentDetailsOnMultipleAction
To retrieve consent details based on multiple actions, like email and track, across specific consent management objects when the records have a lookup relationship, use salesforcerest.consentDetailsOnMultipleAction. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/consent/multiaction?actions={listOfActions}&ids={listOfIds}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
listOfActions | Comma-separated list of proposed actions. Ex: email, fax, geotrack, mail, phone, portability, process, profile, shouldforget, social, solicit, storepiielsewhere, track, web | Yes | email,track,fax |
listOfIds | Comma-separated list of IDs. The ID can be the record ID or the email address listed on the record. | Yes | [email protected],[email protected] |
aggregatedConsent | Whether to enable or disable aggregated consent. true or false. | No | true |
datetime | The timestamp for which consent is determined. | No | 2018-12-12T00:00:00Z |
policy | The policy. | No | requireExplicitConsent |
purpose | The reason for contacting a customer. | No | billing |
verbose | Whether to allow verbose non-verbose responses. true or false | No | true |
Sample configuration
<salesforcerest.consentDetailsOnMultipleAction>
<listOfActions>{$ctx:listOfActions}</listOfActions>
<listOfIds>{$ctx:listOfIds}</listOfIds>
<aggregatedConsent>{$ctx:aggregatedConsent}</aggregatedConsent> <!-- optional -->
<datetime>{$ctx:datetime}</datetime> <!-- optional -->
<policy>{$ctx:policy}</policy> <!-- optional -->
<purpose>{$ctx:purpose}</purpose> <!-- optional -->
<verbose>{$ctx:verbose}</verbose> <!-- optional -->
</salesforcerest.consentDetailsOnMultipleAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"action":"track,geotrack,email",
"listOfIds": "[email protected],[email protected]",
"datetime": "2018-12-12T00:00:00Z",
"verbose": "true",
"purpose": "billing"
}
Sample Response
{
"[email protected]" : {
"result" : "Success",
"proceed" : {
"email" : "false"
"emailResult" : "Success"
"track" : "false"
"trackResult" : "Success"
"solicit" : "false"
"solicitResult" : "Success"
},
"explanation" : [ {
"objectConsulted" : "ContactTypePointConsent",
"status" : "opt_in",
"purpose" : "billing",
"recordId" : "003xx000004TxyY",
"value" : "true"
},{
"objectConsulted" : "Individual",
"field" : "HasOptedOutOfTracking",
"recordId" : "0PKx000006JkyZ",
"value" : "true"
}]
},
"[email protected]" : {
"result" : "Success",
"proceed" : {
"email" : "false"
"emailResult" : "Success"
"track" : "false"
"trackResult" : "Success"
"solicit" : "true"
"solicitResult" : "Success"
},
"explanation" : [ {
"objectConsulted" : "Contact",
"field" : "HasOptedOutOfEmail",
"recordId" : "00Qxx00000skwO",
"value" : "true"
},{
"objectConsulted" : "Individual",
"field" : "HasOptedOutOfSolicit",
"recordId" : "0PKx000003JcpK",
"value" : "false"
}]
}
}
Embedded Service¶
embeddedServiceConfig
To retrieve the values for your Embedded Service deployment configuration, including the branding colors, font, and site URL, use salesforcerest.embeddedServiceConfig. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/support/embeddedservice/configuration/{embeddedServiceConfigDeveloperName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
embeddedServiceConfigDeveloperName | The name of the embedded service config developer. | Yes | TestOne |
Sample configuration
<salesforcerest.embeddedServiceConfig>
<embeddedServiceConfigDeveloperName>{$ctx:embeddedServiceConfigDeveloperName}</embeddedServiceConfigDeveloperName>
</salesforcerest.embeddedServiceConfig>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"embeddedServiceConfigDeveloperName":"TestOne"
}
Sample Response
{
"embeddedServiceConfig" : {
"areGuestUsersAllowed" : false,
"authMethod" : "CustomLogin",
"embeddedServiceBranding" : {
"contrastInvertedColor" : "#ffffff",
"contrastPrimaryColor" : "#333333",
"font" : "Salesforce Sans",
"height" : 498,
"navBarColor" : "#222222",
"primaryColor" : "#222222",
"secondaryColor" : "#005290",
"width" : 320
},
"embeddedServiceLiveAgent" : {
...
}
}
returnHeadersForEmbeddedServiceConfig
To retrieve only the headers that are returned by the embeddedServiceConfig operation, use salesforcerest.returnHeadersForEmbeddedServiceConfig. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/support/embeddedservice/configuration/{embeddedServiceConfigDeveloperName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
embeddedServiceConfigDeveloperName | The name of the embedded service config developer. | Yes | TestOne |
Sample configuration
<salesforcerest.returnHeadersForEmbeddedServiceConfig>
<embeddedServiceConfigDeveloperName>{$ctx:embeddedServiceConfigDeveloperName}</embeddedServiceConfigDeveloperName>
</salesforcerest.returnHeadersForEmbeddedServiceConfig>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"embeddedServiceConfigDeveloperName":"TestOne"
}
Event Monitoring¶
describeEventMonitoring
To retrieve the description of the event monitoring log, use salesforcerest.describeEventMonitoring. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/EventLogFile/describe
Sample configuration
<salesforcerest.describeEventMonitoring/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample response
{
"actionOverrides" : [ ],
"activateable" : false,
"childRelationships" : [ ],
"compactLayoutable" : false,
"createable" : false,
"custom" : false,
"customSetting" : false,
"deletable" : false,
"deprecatedAndHidden" : false,
"feedEnabled" : false,
"fields" : [ {
"autoNumber" : false,
"byteLength" : 18,
"calculated" : false,
"calculatedFormula" : null,
"cascadeDelete" : false,
"caseSensitive" : false,
"controllerName" : null,
"createable" : false,
...
}
queryEventMonitoringData
To retrieve the field values from a record, use salesforcerest.queryEventMonitoringData and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/query?q={queryStringForEventMonitoringData}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
queryStringForEventMonitoringData | The query string to use to get the field values from the log. | Yes | SELECT+Id+,+EventType+,+LogFile+,+LogDate+,+LogFileLength+FROM+EventLogFile+WHERE+LogDate+>+Yesterday+AND+EventType+=+'API' |
Sample configuration
<salesforcerest.queryEventMonitoringData>
<queryStringForEventMonitoringData>{$ctx:queryStringForEventMonitoringData}</queryStringForEventMonitoringData>
</salesforcerest.queryEventMonitoringData>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v34.0",
"queryStringForEventMonitoringData": "SELECT+Id+,+EventType+,+LogFile+,+LogDate+,+LogFileLength+FROM+EventLogFile+WHERE+LogDate+>+Yesterday+AND+EventType+=+'API'",
}
Sample response
{
"totalSize" : 4,
"done" : true,
"records" : [ {
"attributes" : {
"type" : "EventLogFile",
"url" : "/services/data/v59.0/sobjects/EventLogFile/0ATD000000001bROAQ" }
"Id" : "0ATD000000001bROAQ",
"EventType" : "API",
"LogFile" : "/services/data/v59.0/sobjects/EventLogFile/0ATD000000001bROAQ/LogFile",
"LogDate" : "2014-03-14T00:00:00.000+0000",
"LogFileLength" : 2692.0
},
.
]
}
getEventMonitoringContentFromRecord
To retrieve event monitoring content in binary format, use salesforcerest.getEventMonitoringContentFromRecord. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/EventLogFile/{eventLogFileId}/LogFilee
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
eventLogFileId | The ID of the event log file. | Yes | 0ATD000000000pyOAA |
Sample configuration
<salesforcerest.getEventMonitoringContentFromRecord>
<eventLogFileId>{$ctx:eventLogFileId}</eventLogFileId>
</salesforcerest.getEventMonitoringContentFromRecord>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"eventLogFileId": "0ATD000000000pyOAA"
}
Sample response
Event monitoring content is returned in binary form. Note that the response content type won’t be JSON or XML because the returned data is binary.
HTTP/1.1 200 OK
Date: Tue, 06 Aug 2013 16:46:10 GMT
Sforce-Limit-Info: api-usage=135/5000
Content-Type: application/octetstream
Transfer-Encoding: chunked
"EVENT_TYPE", "ORGANIZATION_ID", "TIMESTAMP","USER_ID", "CLIENT_IP",
"URI", "REFERRER_URI", "RUN_TIME"
"URI", "00DD0000000K5xD", "20130728185606.020", "005D0000001REDy",
"10.0.62.141", "/secur/contentDoor", "https-//login-salesforce-com/",
"11"
"URI", "00DD0000000K5xD", "20130728185556.930", "005D0000001REI0",
"10.0.62.141", "/secur/logout.jsp", "https-//MyDomainName-my-salesforce-com/00O/o",
"54"
"URI", "00DD0000000K5xD", "20130728185536.725", "005D0000001REI0",
"10.0.62.141", "/00OD0000001ckx3",
"https-//MyDomainName-my-salesforce-com/00OD0000001ckx3", "93"
Invocable Actions¶
getListOfAction
To retrieve the list of general action types for the current organization, use salesforcerest.getListOfAction and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/actions
Sample configuration
<salesforcerest.getListOfAction/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample response
{
"standard":"/services/data/v59.0/actions/standard",
"custom":"/services/data/v59.0/actions/custom"
}
returnHTTPHeadersForListOfAction
To retrieve only the headers that are returned by the getListOfAction operation, use salesforcerest.returnHTTPHeadersForListOfAction and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/actions
Sample configuration
<salesforcerest.returnHTTPHeadersForListOfAction/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
getSpecificListOfAction
To retrieve an attribute of a single action, use salesforcerest.getSpecificListOfAction and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/actions/{actionType}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
actionType | The type of the invocable action. Valid values: custom, standard. | Yes | standard |
Sample configuration
<salesforcerest.getSpecificListOfAction>
<actionType>{$ctx:actionType}</actionType>
</salesforcerest.getSpecificListOfAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"actionType": "custom",
}
Sample response
{
"quickAction" : "/services/data/v59.0/actions/custom/quickAction",
"apex" : "/services/data/v59.0/actions/custom/apex",
"emailAlert" : "/services/data/v59.0/actions/custom/emailAlert",
"flow" : "/services/data/v59.0/actions/custom/flow",
"sendNotification" : "/services/data/v59.0/actions/custom/sendNotification"
}
returnHTTPHeadersForSpecificListOfAction
To retrieve only the headers that are returned by the getSpecificListOfAction operation, use salesforcerest.returnHTTPHeadersForSpecificListOfAction and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/actions/{actionType}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
actionType | The type of the invocable action. Valid values: custom, standard. | Yes | standard |
Sample configuration
<salesforcerest.returnHTTPHeadersForSpecificListOfAction>
<actionType>{$ctx:actionType}</actionType>
</salesforcerest.returnHTTPHeadersForSpecificListOfAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"actionType": "standard",
}
getAttributeOfSpecificAction
To retrieve an attribute of a single action, use salesforcerest.getAttributeOfSpecificAction and specify the following properties. See the related API documentation for more information.
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
actionType | The type of the invocable action. | Yes | standard |
attribute | The attribute whose details you want to retrieve. | Yes | emailSimple |
Sample configuration
<salesforcerest.getAttributeOfSpecificAction>
<actionType>{$ctx:actionType}</actionType>
<attribute>{$ctx:attribute}</attribute>
</salesforcerest.getAttributeOfSpecificAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"actionType": "standard",
"attribute": "emailSimple",
}
Sample response
{
"actions":[
{
"name":"chatterPost",
"label":"Post to Chatter",
"type":"CHATTERPOST"
},
{
"name":"emailSimple",
"label":"Send Email",
"type":"EMAILSIMPLE"
}
...
]
}
Knowledge Support¶
listKnowledgeRESTApis
To retrieve knowledge support REST APIs that allow both authorized and guest users to retrieve the user’s visible data categories and their associated articles, use salesforcerest.listKnowledgeRESTApis. See the related API documentation for more information.
Equivalent to REST API GET /services/data/vXX.X/support
Sample configuration
<salesforcerest.listKnowledgeRESTApis/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0"
}
Sample Response
{
"dataCategoryGroups" : "/services/data/vXX.X/support/dataCategoryGroups",
"knowledgeArticles" : "/services/data/vXX.X/support/knowledgeArticles"
:
}
listDataCategoryGroups
To retrieve data category groups that are visible to the current user, use salesforcerest.listDataCategoryGroups. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/support/dataCategoryGroups?sObjectName={sObjectName}&topCategoriesOnly={topCategoriesOnly}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of sObject. Support 'KnowledgeArticleVersion' only. | Yes | KnowledgeArticleVersion |
topCategoriesOnly | A boolean value where the true returns only the top level categories and false returns the entire tree. Defaults to true. | No | true |
Sample configuration
<salesforcerest.listDataCategoryGroups>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<topCategoriesOnly>{$ctx:topCategoriesOnly}</topCategoriesOnly> <!-- optional -->
</salesforcerest.listDataCategoryGroups>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "KnowledgeArticleVersion",
"topCategoriesOnly": "true"
}
Sample Response
{
"categoryGroups" : [ {
"label" : "Doc",
"name" : "Doc",
"objectUsage" : "KnowledgeArticleVersion",
"topCategories" : [ {
"childCategories" : null,
"label" : "All",
"name" : "All",
"url" : "/services/data/v59.0/support/dataCategoryGroups/Doc/dataCategories/All?sObjectName=KnowledgeArticleVersion"
} ]
}, {
"label" : "Manual",
"name" : "Manual",
"objectUsage" : "KnowledgeArticleVersion",
"topCategories" : [ {
"childCategories" : null,
"label" : "All",
"name" : "All",
"url" : "/services/data/v59.0/support/dataCategoryGroups/Manual/dataCategories/All?sObjectName=KnowledgeArticleVersion"
} ]
} ]
}
getDataCategoryDetails
To retrieve data category details and the child categories by a given category, use salesforcerest.getDataCategoryDetails. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/support/dataCategoryGroups/{group}/dataCategories/{category}?sObjectName={sObjectName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
group | The data category group. | Yes | Doc |
category | The data category. | Yes | All |
sObjectName | The type of sObject. Support 'KnowledgeArticleVersion' only. | Yes | KnowledgeArticleVersion |
Sample configuration
<salesforcerest.getDataCategoryDetails>
<group>{$ctx:group}</group>
<category>{$ctx:category}</category>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.getDataCategoryDetails>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "KnowledgeArticleVersion",
"group": "Doc",
"category": "All"
}
Sample Response
{
"childCategories" : [ {
"childCategories" : null,
"label" : "Help",
"name" : "Help",
"url" : "/services/data/v59.0/support/dataCategoryGroups/Doc/dataCategories/Help?sObjectName=KnowledgeArticleVersion"
}, {
"childCategories" : null,
"label" : "QA",
"name" : "QA",
"url" : "/services/data/v59.0/support/dataCategoryGroups/Doc/dataCategories/QA?sObjectName=KnowledgeArticleVersion"
} ],
"label" : "All",
"name" : "All",
"url" : "/services/data/v59.0/support/dataCategoryGroups/Doc/dataCategories/All?sObjectName=KnowledgeArticleVersion"
}
listArticles
To retrieve a page of online articles for the given language and category through either search or query, use salesforcerest.listArticles. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/support/knowledgeArticles
or with optional parameters GET /services/data/vXX.X/support/knowledgeArticles?queryString={queryString}&channel={channel}&categories={categories}&queryMethod={queryMethod}&sort={sort}&order={order}&pageSize={pageSize}&pageNumber={pageNumber}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
queryString | The query string to perform an SOSL search. | No | FIND {MyProspect OR MyCompany} |
channel | The name of the embedded service config developer. Valid channel values are App, Pkb, Csp, Prm | No | App |
categories | The data categories in map json format with a limit of three data category conditions. Ex: {"group1":"category1","group2":"category2",...}. Defaults to None. | No | {"group1":"category1","group2":"category2"} |
queryMethod | AT, BELOW, ABOVE, ABOVE_OR_BELOW. Only valid when categories are specified. Defaults to ABOVE_OR_BELOW. | No | ABOVE_OR_BELOW |
sort | A sortable field name LastPublishedDate, CreatedDate, Title, ViewScore. Defaults to LastPublishedDate for query and relevance for search. | No | ViewScore |
order | Either ASC or DESC, defaults to DESC. Valid only when sort is valid. | No | ASC |
pageSize | Defaults to 20. Valid range 1 to 100. | No | 10 |
pageNumber | The page number. Defaults to 1. | No | 1 |
Sample configuration
<salesforcerest.listArticles>
<queryString>{$ctx:queryString}</queryString> <!-- optional -->
<channel>{$ctx:channel}</channel> <!-- optional -->
<categories>{$ctx:categories}</categories> <!-- optional -->
<queryMethod>{$ctx:queryMethod}</queryMethod> <!-- optional -->
<sort>{$ctx:sort}</sort> <!-- optional -->
<order>{$ctx:order}</order> <!-- optional -->
<pageSize>{$ctx:pageSize}</pageSize> <!-- optional -->
<pageNumber>{$ctx:pageNumber}</pageNumber> <!-- optional -->
</salesforcerest.listArticles>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sort": "ViewScore",
"channel": "Pkb",
"pageSize": 2
}
Sample Response
{
"articles" : [ {
"articleNumber" : "000001002",
"categoryGroups" : [ ],
"downVoteCount" : 0,
"id" : "kA0xx000000000BCAQ",
"lastPublishedDate" : "2015-02-25T02:07:18Z",
"summary" : "With this online Chinese input tool, you can type Chinese characters through your web browser without installing any Chinese input software in your system. The Chinese online input tool uses the popular Pin Yin input method. It is a fast and convenient tool to input Chinese on English OS environments.",
"title" : "Long text test",
"upVoteCount" : 0,
"url" : "/services/data/v59.0/support/knowledgeArticles/kA0xx000000000BCAQ",
"viewCount" : 4,
"viewScore" : 100.0
}, {
"articleNumber" : "000001004",
"categoryGroups" : [ ],
"downVoteCount" : 0,
"id" : "kA0xx000000000LCAQ",
"lastPublishedDate" : "2016-06-21T21:11:02Z",
"summary" : "The number of characters required for complete coverage of all these languages' needs cannot fit in the 256-character code space of 8-bit character encodings, requiring at least a 16-bit fixed width encoding or multi-byte variable-length encodings. \r\n\r\nAlthough CJK encodings have common character sets, the encodings often used to represent them have been developed separately by different East Asian governments and software companies, and are mutually incompatible. Unicode has attempted, with some controversy, to unify the character sets in a process known as Han unification.\r\n\r\nCJK character encodings should consist minimally of Han characters p",
"title" : "Test Images",
"upVoteCount" : 0,
"url" : "/services/data/v59.0/support/knowledgeArticles/kA0xx000000000LCAQ",
"viewCount" : 0,
"viewScore" : 0.0
}],
"currentPageUrl" : "/services/data/v59.0/support/knowledgeArticles?channel=Pkb&pageSize=3&sort=ViewScore",
"nextPageUrl" : null,
"pageNumber" : 1
}
getArticleDetails
To retrieve all online article fields, accessible to the user, use salesforcerest.getArticleDetails. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/support/knowledgeArticles/{articleId_or_articleUrlName}?channel={channel}&updateViewStat={updateViewStat}&isUrlName={isUrlName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
articleId_or_articleUrlName | The Id or the URL name of the article. | Yes | kA0xx000000000LCAQ |
channel | The value of the channel. Defaults to user’s context. Valid channel values are App, Pkb, Csp, Prm | No | App |
updateViewStat | A boolean value. If true, API updates the view count in the given channel as well as the total view count. Defaults to true. | No | true |
isUrlName | A boolean value. If true, indicates that the last portion of the endpoint is a URL name instead of an article ID. Defaults to false. | No | true |
Sample configuration
<salesforcerest.getArticleDetails>
<articleId_or_articleUrlName>{$ctx:articleId_or_articleUrlName}</articleId_or_articleUrlName>
<channel>{$ctx:channel}</channel> <!-- optional -->
<updateViewStat>{$ctx:updateViewStat}</updateViewStat> <!-- optional -->
<isUrlName>{$ctx:isUrlName}</isUrlName> <!-- optional -->
</salesforcerest.getArticleDetails>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"articleId_or_articleUrlName": "kA0xx000000000LCAQ",
"updateViewStat": "true"
}
Sample Response
{
"allViewCount" : 17,
"allViewScore" : 100.0,
"appDownVoteCount" : 0,
"appUpVoteCount" : 0,
"appViewCount" : 17,
"appViewScore" : 100.0,
"articleNumber" : "000001004",
"categoryGroups" : [ ],
"createdBy" : {
"email" : "[email protected]",
"firstName" : "Test",
"id" : "005xx000001SvoMAAS",
"isActive" : true,
"lastName" : "User",
...
}
getKnowledgeLanguageSettings
To retrieve the existing Knowledge language settings, including the default knowledge language and a list of supported Knowledge language information, use salesforcerest.getKnowledgeLanguageSettings. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/knowledgeManagement/settings
Sample configuration
<salesforcerest.getKnowledgeLanguageSettings/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0"
}
Sample Response
{
"defaultLanguage" : "en_US",
"knowledgeEnabled" : true,
"languages" : [ {
"active" : true,
"name" : "en_US"
}, {
"active" : true,
"name" : "it"
}, {
"active" : true,
"name" : "zh_CN"
}, {
"active" : true,
"name" : "fr"
} ]
}
Layouts¶
sObjectLayouts
To retrieve a list of layouts and descriptions (including for actions) for a specific object, use salesforcerest.sObjectLayouts and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/describe/approvalLayouts/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose layouts and descriptions you want to retrieve. | Yes | Account |
Sample configuration
<salesforcerest.sObjectLayouts>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.sObjectLayouts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
}
Sample Response
"layouts":[
{
"detailLayoutSections":[
{
"heading":"Account Information",
"columns":2,
"tabOrder":"TopToBottom",
"useCollapsibleSection":false,
"rows":8,
"useHeading":false,
"layoutRows":[
{
"layoutItems":[
{
"editableForUpdate":false,
"editableForNew":false,
"layoutComponents":[
{
"tabOrder":1,
"details":{
"defaultValue":null,
"precision":0,
"nameField":false,
"type":"reference",
"restrictedDelete":false,
"relationshipName":"Owner",
"calculatedFormula":null,
"controllerName":null,
"namePointing":false,
"defaultValueFormula":null,
"calculated":false,
"writeRequiresMasterRead":false,
"inlineHelpText":null,
"picklistValues":[
]
}
}
]
}
.
}
returnHeadersForSObjectLayouts
To retrieve only the headers that are returned by the sObjectLayouts operation, use salesforcerest.returnHeadersForSObjectLayouts and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/{sObjectName}/describe/approvalLayouts/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose layouts and descriptions you want to retrieve. | Yes | Account |
Sample configuration
<salesforcerest.sObjectLayouts>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.sObjectLayouts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
}
globalSObjectLayouts
To retrieve descriptions of global publisher layouts, use salesforcerest.globalSObjectLayouts. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/Global/describe/layouts/
Sample configuration
<salesforcerest.globalSObjectLayouts/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample Response
{
"layouts":[
{
"detailLayoutSections":[
],
"relatedContent":null,
"editLayoutSections":[
],
"relatedLists":[
],
"buttonLayoutSection":null,
"id":"00h28000001hExeAAE",
"offlineLinks":[
],
.
.
}
}
returnHeadersForGlobalSObjectLayouts
To retrieve only the headers that are returned by the globalSObjectLayouts operation, use salesforcerest.returnHeadersForGlobalSObjectLayouts. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/Global/describe/layouts/
Sample configuration
<salesforcerest.globalSObjectLayouts/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
compactLayouts
To retrieve a list of compact layouts for multiple objects, use salesforcerest.compactLayouts and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/compactLayouts?q={sObjectNameList}
Parameter Name | Description | Required |
---|---|---|
sObjectNameList | A comma-separated list of the objects whose compact layouts you want to retrieve. | Yes |
Sample configuration
<salesforcerest.compactLayouts/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectNameList":"Account,User",
}
Sample Response
{
"Account":{
"name":"SYSTEM",
"id":null,
"label":"System Default",
"actions":[
{
"showsStatus":false,
"custom":false,
"label":"Call",
"overridden":false,
"encoding":null,
"icons":[
{
"width":0,
"theme":"theme4",
"contentType":"image/svg+xml",
"url":"https://kesavan-dev-ed.my.salesforce.com/img/icon/t4v59/action/call.svg",
"height":0
},
],
"windowPosition":null,
"colors":[
{
"color":"F2CF5B",
"context":"primary",
"theme":"theme4"
}
],
.
.
],
"objectType":"User"
}
}
sObjectApprovalLayouts
To retrieve a list of approval layouts for a specified object, use salesforcerest.sObjectApprovalLayouts and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/describe/approvalLayouts/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose layouts you want to retrieve. | Yes | Account |
Sample configuration
<salesforcerest.sObjectApprovalLayouts>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.sObjectApprovalLayouts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
}
Sample Response
{
"approvalLayouts" : [ {
"id" : "04aD00000008Py9IAE",
"label" : "MyApprovalProcessName",
"layoutItems" : [...],
"name" : "MyApprovalProcessName"
}, {
"id" : "04aD00000008Q0KIAU",
"label" : "Process1",
"layoutItems" : [...],
"name" : "Process1"
} ]
}
returnHeadersForSObjectApprovalLayouts
To retrieve only the headers that are returned by the sObjectApprovalLayouts operation, use salesforcerest.returnHeadersForSObjectApprovalLayouts and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/{sObjectName}/describe/approvalLayouts/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose layouts you want to retrieve. | Yes | Account |
Sample configuration
<salesforcerest.sObjectApprovalLayouts>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.sObjectApprovalLayouts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
}
sObjectCompactLayouts
To retrieve a list of compact layouts for a specific object, use salesforcerest.sObjectCompactLayouts and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/describe/compactLayouts/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose layouts you want to retrieve. | Yes | Account |
Sample configuration
<salesforcerest.sObjectCompactLayouts>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.sObjectCompactLayouts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
}
Sample Response
{
"compactLayouts":[
{
"name":"SYSTEM",
"id":null,
"label":"System Default",
"actions":[
{
"showsStatus":false,
"custom":false,
"label":"Call",
"overridden":false,
"encoding":null,
"icons":[
{
"width":0,
"theme":"theme4",
"contentType":"image/svg+xml",
"url":"https://kesavan-dev-ed.my.salesforce.com/img/icon/t4v59/action/call.svg",
"height":0
}
],
"defaultCompactLayoutId":null
.
]
}
returnHeadersForSObjectCompactLayouts
To retrieve only the headers that are returned by the sObjectCompactLayouts operation, use salesforcerest.returnHeadersForSObjectCompactLayouts and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/{sObjectName}/describe/compactLayouts/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose layouts you want to retrieve. | Yes | Account |
Sample configuration
<salesforcerest.sObjectCompactLayouts>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.sObjectCompactLayouts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
}
sObjectNamedLayouts
To retrieve information about alternative named layouts for a specific object, use salesforcerest.sObjectNamedLayouts and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/describe/namedLayouts/{layoutName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose layouts you want to retrieve. | Yes | Account |
layoutName | The type of layout. | Yes | UserAlt |
Sample configuration
<salesforcerest.sObjectNamedLayouts>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<layoutName>{$ctx:layoutName}</layoutName>
</salesforcerest.sObjectNamedLayouts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"layoutName": "UserAlt",
}
Sample Response
{
"layouts":[
{
"detailLayoutSections":[
{
"heading":"About",
"columns":2,
"tabOrder":"LeftToRight",
"useCollapsibleSection":false,
"rows":2,
"useHeading":false,
"layoutRows":[
{
"layoutItems":[
{
"editableForUpdate":false,
"editableForNew":false,
"layoutComponents":[
{
"components":[
{
"tabOrder":2,
"details":{
"defaultValue":null,
"precision":0,
"nameField":false,
"type":"string",
"restrictedDelete":false,
"relationshipName":null,
"calculatedFormula":null,
"controllerName":null,
"namePointing":false,
"defaultValueFormula":null,
"calculated":false,
"writeRequiresMasterRead":false,
"inlineHelpText":null,
"picklistValues":[
]
}
}
]
}
.
}
sObjectLayoutsForObjectWithMultipleRecordTypes
To retrieve lists of page layouts and their descriptions for objects that have more than one record type defined, use salesforcerest.sObjectLayoutsForObjectWithMultipleRecordTypes and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/describe/layouts/{recordTypeId}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose layouts you want to retrieve. | Yes | Account |
recordTypeId | The id of the record type. | Yes | 0125c000000oIN9AAM |
Sample configuration
<salesforcerest.sObjectNamedLayouts>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<recordTypeId>{$ctx:recordTypeId}</recordTypeId>
</salesforcerest.sObjectNamedLayouts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"recordTypeId": "0125c000000oIN9AAM",
}
Sample Response
{
"buttonLayoutSection" : {
"detailButtons" : [
...
]
},
"detailLayoutSections" : [
...
],
"editLayoutSections" : [
...
],
"feedView" : null,
"highlightsPanelLayoutSection" : null,
"id" : "00ho000000CUJWIAA5",
"multirowEditLayoutSections" : [ ],
"offlineLinks" : [ ],
"quickActionList" : {
"quickActionListItems" : [
...
]
},
"relatedContent" : null,
"relatedLists" : [
...
],
"saveOptions" : [ ]
}
returnHeadersForSObjectLayoutsForObjectWithMultipleRecordTypes
To retrieve only the headers that are returned by the sObjectLayoutsForObjectWithMultipleRecordTypes operation, use salesforcerest.returnHeadersForSObjectLayoutsForObjectWithMultipleRecordTypes and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/{sObjectName}/describe/layouts/{recordTypeId}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose layouts you want to retrieve. | Yes | Account |
recordTypeId | The id of the record type. | Yes | 0125c000000oIN9AAM |
Sample configuration
<salesforcerest.sObjectNamedLayouts>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<recordTypeId>{$ctx:recordTypeId}</recordTypeId>
</salesforcerest.sObjectNamedLayouts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"recordTypeId": "0125c000000oIN9AAM",
}
sObjectApprovalLayoutsForSpecifiedApprovalProcess
To retrieve an approval layout for a named approval process on a specified object, use salesforcerest.sObjectApprovalLayoutsForSpecifiedApprovalProcess and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/describe/approvalLayouts/{approvalProcessName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose layouts you want to retrieve. | Yes | Account |
approvalProcessName | The Name of the approval process. | Yes | ExampleApprovalProcessName |
Sample configuration
<salesforcerest.sObjectNamedLayouts>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<approvalProcessName>{$ctx:approvalProcessName}</approvalProcessName>
</salesforcerest.sObjectNamedLayouts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"approvalProcessName": "ExampleApprovalProcessName",
}
Sample Response
{
"approvalLayouts" : [ {
"id" : "04aD00000008Py9IAE",
"label" : "ExampleApprovalProcessName",
"layoutItems" : [...],
"name" : "ExampleApprovalProcessName"
} ]
}
returnHeadersForSObjectApprovalLayoutsForSpecifiedApprovalProcess
To retrieve only the headers that are returned by the sObjectApprovalLayoutsForSpecifiedApprovalProcess operation, use salesforcerest.returnHeadersForSObjectApprovalLayoutsForSpecifiedApprovalProcess and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/{sObject}/describe/approvalLayouts/{approvalProcessName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose layouts you want to retrieve. | Yes | Account |
approvalProcessName | The Name of the approval process. | Yes | ExampleApprovalProcessName |
Sample configuration
<salesforcerest.sObjectNamedLayouts>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<approvalProcessName>{$ctx:approvalProcessName}</approvalProcessName>
</salesforcerest.sObjectNamedLayouts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"approvalProcessName": "ExampleApprovalProcessName",
}
List Views¶
listViews
To retrieve a list of list views for the specific sObject, use salesforcerest.listViews and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/listviews
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose list views you want to retrieve. | Yes | Account |
Sample configuration
<salesforcerest.listViews>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.listViews>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
}
Sample Response
{
"nextRecordsUrl":null,
"size":7,
"listviews":[
{
"resultsUrl":"/services/data/v59.0/sobjects/Account/listviews/00B280000032AihEAE/results",
"soqlCompatible":true,
"id":"00B280000032AihEAE",
"label":"New This Week",
"describeUrl":"/services/data/v59.0/sobjects/Account/listviews/00B280000032AihEAE/describe",
"developerName":"NewThisWeek",
"url":"/services/data/v59.0/sobjects/Account/listviews/00B280000032AihEAE"
},
.
.
],
"done":true,
"sobjectType":"Account"
}
listViewById
To retrieve the basic information about one list view for the specific sObject, use salesforcerest.listViewById and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/listviews/{listViewID}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose list of list views you want to retrieve. | Yes | Account |
listViewId | The ID of the specific list view whose information you want to return. This can be obtained by listViews operation |
Yes | 00B28000002yqeVEAQ |
Sample configuration
<salesforcerest.listViewById>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<listViewID>{$ctx:listViewID}</listViewID>
</salesforcerest.listViewById>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
"listViewID":"00B28000002yqeVEAQ",
}
Sample Response
{
"resultsUrl":"/services/data/v59.0/sobjects/Account/listviews/00B280000032AihEAE/results",
"soqlCompatible":true,
"id":"00B280000032AihEAE",
"label":"New This Week",
"describeUrl":"/services/data/v59.0/sobjects/Account/listviews/00B280000032AihEAE/describe",
"developerName":"NewThisWeek",
"url":"/services/data/v59.0/sobjects/Account/listviews/00B280000032AihEAE"
}
recentListViews
To retrieve the list of recently used list views for the given sObject type, use salesforcerest.recentListViews and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/listviews/recent
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object whose recently used list views you want to return. | Yes | Account |
Sample configuration
<salesforcerest.recentListViews>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.recentListViews>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
}
Sample Response
{
"nextRecordsUrl":null,
"size":2,
"listviews":[
{
"resultsUrl":"/services/data/v59.0/sobjects/Account/listviews/00B280000032AihEAE/results",
"soqlCompatible":true,
"id":"00B280000032AihEAE",
"label":"New This Week",
"describeUrl":"/services/data/v59.0/sobjects/Account/listviews/00B280000032AihEAE/describe",
"developerName":"NewThisWeek",
"url":"/services/data/v59.0/sobjects/Account/listviews/00B280000032AihEAE"
}
.
.
],
"done":true,
"sobjectType":"Account"
}
describeListViewById
To retrieve detailed information (ID, columns, and SOQL query) about a specific list view for the given sObject type, use salesforcerest.describeListViewById and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/listviews/{listViewID}/describe
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object to which the list view applies. | Yes | Account |
listViewID | The ID of the list view. | Yes | 00B28000002yqeVEAQ (obtained by listViews operation) |
Sample configuration
<salesforcerest.describeListViewById>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<listViewID>{$ctx:listViewID}</listViewID>
</salesforcerest.describeListViewById>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
"listViewID":"00B28000002yqeVEAQ",
}
Sample Response
{
"whereCondition":{
"field":"CreatedDate",
"values":[
"THIS_WEEK"
],
"operator":"equals"
},
"columns":[
{
"fieldNameOrPath":"Name",
"sortDirection":"ascending",
"hidden":false,
"sortIndex":0,
"ascendingLabel":"Z-A",
"label":"Account Name",
"sortable":true,
"type":"string",
"descendingLabel":"A-Z",
"selectListItem":"Name"
},
.
.
],
"query":"SELECT Name, Site, BillingState, Phone, toLabel(Type), Owner.Alias, Id, CreatedDate, LastModifiedDate, SystemModstamp FROM Account WHERE CreatedDate = THIS_WEEK ORDER BY Name ASC NULLS FIRST, Id ASC NULLS FIRST",
"scope":null,
"orderBy":[
{
"fieldNameOrPath":"Name",
"sortDirection":"ascending",
"nullsPosition":"first"
},
{
"fieldNameOrPath":"Id",
"sortDirection":"ascending",
"nullsPosition":"first"
}
],
"id":"00B280000032Aih",
"sobjectType":"Account"
}
listViewResults
To execute the SOQL query for the list view and return the resulting data and presentation information, use salesforcerest.listViewResults and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/listviews/{listViewID}/results
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object to which the list view applies. | Yes | Account |
listViewID | The ID of the list view (obtained by listViews operation). |
Yes | 00B28000002yqeVEAQ |
Sample configuration
<salesforcerest.listViewResults>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<listViewID>{$ctx:listViewID}</listViewID>
</salesforcerest.listViewResults>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
"listViewID":"00B28000002yqeVEAQ",
}
Sample Response
{
"size":0,
"records":[
],
"columns":[
{
"fieldNameOrPath":"Name",
"sortDirection":"ascending",
"hidden":false,
"sortIndex":0,
"ascendingLabel":"Z-A",
"label":"Account Name",
"sortable":true,
"type":"string",
"descendingLabel":"A-Z",
"selectListItem":"Name"
},
.
.
],
"id":"00B280000032Aih",
"label":"New This Week",
"developerName":"NewThisWeek",
"done":true
}
Platform Event¶
platformEventSchemaByEventName
To retrieve the definition of a platform event for an event name, use salesforcerest.platformEventSchemaByEventName and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{eventName}/eventSchema
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
eventName | The name of the event. | Yes | Low_Ink__e |
Sample configuration
<salesforcerest.platformEventSchemaByEventName>
<eventName>{$ctx:sObjectName}</eventName>
</salesforcerest.platformEventSchemaByEventName>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"eventName": "Low_Ink__e"
}
Sample Response
{
"name": "Low_Ink__e",
"namespace": "com.sforce.eventbus",
"type": "expanded-record",
"fields": [
{
"name": "data",
"type": {
"type": "record",
"name": "Data",
"namespace": "",
"fields": [
{
"name": "schema",
"type": "string"
},
,...
]
}
},
{
"name": "channel",
"type": "string"
}
]
}
platformEventSchemaByEventNameAndSpecifiedPayloadFormat
To retrieve the definition of a platform event for an event name in specified payload format, use salesforcerest.platformEventSchemaByEventNameAndSpecifiedPayloadFormat and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{eventName}/eventSchema?payloadFormat={payloadFormat}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
eventName | The name of the event. | Yes | Low_Ink__e |
payloadFormat | The format of the returned event schema. This parameter can either be EXPANDED or COMPACT. | Yes | COMPACT |
Sample configuration
<salesforcerest.platformEventSchemaByEventNameAndSpecifiedPayloadFormat>
<eventName>{$ctx:sObjectName}</eventName>
<payloadFormat>{$ctx:payloadFormat}</payloadFormat>
</salesforcerest.platformEventSchemaByEventNameAndSpecifiedPayloadFormat>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"eventName": "Low_Ink__e",
"payloadFormat": "COMPACT"
}
Sample Response
{
"name": "Low_Ink__e",
"namespace": "com.sforce.eventbus",
"type": "record",
"fields": [
{
"name": "CreatedDate",
"type": "long",
"doc": "CreatedDate:DateTime"
},
{
"name": "CreatedById",
"type": "string",
"doc": "CreatedBy:EntityId"
},
{
"name": "Printer_Model__c",
"type": [
"null",
"string"
],
"doc": "Data:Text:00NRM000001krnv",
"default": null
},...
],
"uuid": "5E5OtZj5_Gm6Vax9XMXH9A"
}
platformEventSchemaBySchemaId
To retrieve the definition of a platform event for a schema ID, use salesforcerest.platformEventSchemaBySchemaId and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/event/eventSchema/{schemaId}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
schemaId | The Id of the schema. | Yes | 5E5OtZj5_Gm6Vax9XMXH9A |
Sample configuration
<salesforcerest.platformEventSchemaBySchemaId>
<schemaId>{$ctx:schemaId}</schemaId>
</salesforcerest.platformEventSchemaBySchemaId>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"schemaId": "5E5OtZj5_Gm6Vax9XMXH9A"
}
Sample Response
{
"name": "Low_Ink__e",
"namespace": "com.sforce.eventbus",
"type": "expanded-record",
"fields": [
{
"name": "data",
"type": {
"type": "record",
"name": "Data",
"namespace": "",
"fields": [
{
"name": "schema",
"type": "string"
},
]
}
},
{
"name": "channel",
"type": "string"
}
]
}
platformEventSchemaBySchemaIdAndSpecifiedPayloadFormat
To retrieve the definition of a platform event for a schema ID in specified payload format, use salesforcerest.platformEventSchemaBySchemaIdAndSpecifiedPayloadFormat and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/event/eventSchema/{schemaId}?payloadFormat={payloadFormat}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
schemaId | The Id of the schema. | Yes | 5E5OtZj5_Gm6Vax9XMXH9A |
payloadFormat | The format of the returned event schema. This parameter can either be EXPANDED or COMPACT. | Yes | COMPACT |
Sample configuration
<salesforcerest.platformEventSchemaBySchemaIdAndSpecifiedPayloadFormat>
<schemaId>{$ctx:schemaId}</schemaId>
<payloadFormat>{$ctx:payloadFormat}</payloadFormat>
</salesforcerest.platformEventSchemaBySchemaIdAndSpecifiedPayloadFormat>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"schemaId": "5E5OtZj5_Gm6Vax9XMXH9A",
"payloadFormat": "COMPACT"
}
Sample Response
{
"name": "Low_Ink__e",
"namespace": "com.sforce.eventbus",
"type": "record",
"fields": [
{
"name": "CreatedDate",
"type": "long",
"doc": "CreatedDate:DateTime"
},
{
"name": "CreatedById",
"type": "string",
"doc": "CreatedBy:EntityId"
},...
],
"uuid": "5E5OtZj5_Gm6Vax9XMXH9A"
}
Process Rules¶
listProcessRules
To retrieve the list of process rules in the organization, use salesforcerest.listProcessRules. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/process/rules/
Sample configuration
<salesforcerest.listProcessRules/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample Response
{
"rules":{
}
}
returnHeadersForProcessRules
To retrieve only the headers that are returned by the listProcessRules operation, use salesforcerest.returnHeadersForProcessRules. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/process/rules/
Sample configuration
<salesforcerest.returnHeadersForProcessRules/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
getSpecificProcessRule
To retrieve the metadata for a specific sObject process rule, use salesforcerest.getSpecificProcessRule and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/process/rules/{sObjectName}/{workflowRuleId}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object whose process rule you want to retrieve. | Yes | Account |
workflowRuleId | The ID of the process rule. You can get IDs using operation listProcessRules . |
Yes | 01QD0000000APli |
Sample configuration
<salesforcerest.getSpecificProcessRule>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<workflowRuleId>{$ctx:workflowRuleId}</workflowRuleId>
</salesforcerest.getSpecificProcessRule>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
"workflowRuleId": "01QD0000000APli",
}
Sample Response
{
"actions" : [ {
"id" : "01VD0000000D2w7",
"name" : "ApprovalProcessTask",
"type" : "Task"
} ],
"description" : null,
"id" : "01QD0000000APli",
"name" : "My Rule",
"namespacePrefix" : null,
"object" : "Account"
}
returnHeadersForSpecificProcessRule
To retrieve only the headers that are returned by the getSpecificProcessRule operation, use salesforcerest.returnHeadersForSpecificProcessRule and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/process/rules/{sObjectName}/{workflowRuleId}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object whose process rule you want to retrieve. | Yes | Account |
workflowRuleId | The ID of the process rule. You can get IDs using operation listProcessRules . |
Yes | 01QD0000000APli |
Sample configuration
<salesforcerest.returnHeadersForSpecificProcessRule>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<workflowRuleId>{$ctx:workflowRuleId}</workflowRuleId>
</salesforcerest.returnHeadersForSpecificProcessRule>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
"workflowRuleId": "01QD0000000APli",
}
getSpecificProcessRuleList
To retrieve all active workflow rules for an sObject, use salesforcerest.getSpecificProcessRuleList and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/process/rules/{sObjectName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object whose process rule list you want to retrieve. | Yes | Account |
Sample configuration
<salesforcerest.getSpecificProcessRuleList>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.getSpecificProcessRuleList>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
}
Sample Response
{
"rules" : {
"Account" : [ {
"actions" : [ {
"id" : "01VD0000000D2w7",
"name" : "ApprovalProcessTask",
"type" : "Task"
} ],
"description" : null,
"id" : "01QD0000000APli",
"name" : "My Rule",
"namespacePrefix" : null,
"object" : "Account"
} ]
}
}
returnHeadersForSpecificProcessRuleList
To retrieve all active workflow rules for an sObject, use salesforcerest.returnHeadersForSpecificProcessRuleList and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/process/rules/{sObjectName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object whose process rule list you want to retrieve. | Yes | Account |
Sample configuration
<salesforcerest.returnHeadersForSpecificProcessRuleList>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.returnHeadersForSpecificProcessRuleList>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
}
triggerProcessRules
To trigger all active workflow rules, use salesforcerest.triggerProcessRules and specify the following properties. All rules associated with the specified ID are evaluated, regardless of the evaluation criteria. All IDs must be for records on the same object. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/process/rules/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
fieldAndValue | An array of context IDs. | Yes | Account |
Sample configuration
<salesforcerest.triggerProcessRules>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.triggerProcessRules>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"fieldAndValue": {
"contextIds" : [
"001D000000JRWBd",
"001D000000I8mIm",
"001D000000I8aaf"
]
}
}
Sample Response
{
"errors" : null,
"success" : true
}
Product Schedules¶
getProductSchedules
To retrieve revenue and quantity schedules for opportunity products, use salesforcerest.getProductSchedules and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/OpportunityLineItem/{OpportunityLineItemId}/OpportunityLineItemSchedules
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
OpportunityLineItemId | The Id of the opportunity line item. | Yes | 00kR0000001WJJAIA4 |
Sample configuration
<salesforcerest.getProductSchedules>
<OpportunityLineItemId>{$ctx:OpportunityLineItemId}</OpportunityLineItemId>
</salesforcerest.getProductSchedules>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"OpportunityLineItemId":"00kR0000001WJJAIA4"
}
createProductSchedules
To establish or reestablish a product schedule with multiple installments for an opportunity product, use salesforcerest.createProductSchedules and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API PUT /services/data/vXX.X/sobjects/OpportunityLineItem/{OpportunityLineItemId}/OpportunityLineItemSchedules
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
OpportunityLineItemId | The Id of the opportunity line item. | Yes | 00kR0000001WJJAIA4 |
fieldAndValue | The .json format property used to create product schedules. | Yes | { "type": "Both", "quantity": 100, "quantityScheduleType": "Repeat", "quantityScheduleInstallmentPeriod": "Monthly", "quantityScheduleInstallmentsNumber": 12, "quantityScheduleStartDate": "2018-09-15", "revenue": 100, "revenueScheduleType": "Repeat", "revenueScheduleInstallmentPeriod": "Monthly", "revenueScheduleInstallmentsNumber": 12, "revenueScheduleStartDate": "2018-09-15" } |
Sample configuration
<salesforcerest.createProductSchedules>
<OpportunityLineItemId>{$ctx:OpportunityLineItemId}</OpportunityLineItemId>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.createProductSchedules>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"OpportunityLineItemId":"00kR0000001WJJAIA4",
"fieldAndValue": {
"type": "Both",
"quantity": 100,
"quantityScheduleType": "Repeat",
"quantityScheduleInstallmentPeriod": "Monthly",
"quantityScheduleInstallmentsNumber": 12,
"quantityScheduleStartDate": "2018-09-15",
"revenue": 100,
"revenueScheduleType": "Repeat",
"revenueScheduleInstallmentPeriod": "Monthly",
"revenueScheduleInstallmentsNumber": 12,
"revenueScheduleStartDate": "2018-09-15"
}
}
deleteProductSchedules
To delete all installments in a revenue or quantity schedule for opportunity products, use salesforcerest.deleteProductSchedules and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API DELETE /services/data/vXX.X/sobjects/OpportunityLineItem/{OpportunityLineItemId}/OpportunityLineItemSchedules
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
OpportunityLineItemId | The Id of the opportunity line item. | Yes | 00kR0000001WJJAIA4 |
Sample configuration
<salesforcerest.deleteProductSchedules>
<OpportunityLineItemId>{$ctx:OpportunityLineItemId}</OpportunityLineItemId>
</salesforcerest.deleteProductSchedules>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"OpportunityLineItemId":"00kR0000001WJJAIA4"
}
Queries¶
query
To retrieve data from an object, use salesforcerest.query and specify the following properties. If you want your results to include deleted records in the Recycle Bin, use salesforcerest.queryAll in place of salesforcerest.query. See the related API documentation for query and queryAll for more information.
Parameter Name | Description | Required | Sample Value | |
---|---|---|---|---|
queryString | The SQL query to use to search for records. | Yes | select id, name from Account |
Sample configuration
query:
Equivalent to Salesforce REST API GET /services/data/vXX.X/query?q={queryString}
<salesforcerest.query>
<queryString>{$ctx:queryString}</queryString>
</salesforcerest.query>
queryAll:
Equivalent to Salesforce REST API GET /services/data/vXX.X/queryAll?q={queryString}
<salesforcerest.queryAll>
<queryString>{$ctx:queryString}</queryString>
</salesforcerest.queryAll>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"queryString": "select id, name from Account",
}
Sample Response
{
"done" : false,
"totalSize" : 2014,
"nextRecordsUrl" : "/services/data/v20.0/query/01gD0000002HU6KIAW-2000",
"records" :
[
{
"attributes" :
{
"type" : "Account",
"url" : "/services/data/v20.0/sobjects/Account/001D000000IRFmaIAH"
},
"Name" : "Test 1"
},
{
"attributes" :
{
"type" : "Account",
"url" : "/services/data/v20.0/sobjects/Account/001D000000IomazIAB"
},
"Name" : "Test 2"
},
...
]
}
queryMore
If the results from the query or queryAll operations are too large, the first batch of results is returned along with an ID that you can use with salesforcerest.queryMore to get additional results. If you want your results to include deleted records in the Recycle Bin, use salesforcerest.queryAllMore in place of salesforcerest.queryMore. See the related API documentation for queryMore and queryAllMore for more information.
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
nextRecordsUrl | The query identifier for retrieving additional results. | Yes | QWE45HUJ39D9UISD00 |
Sample configuration
queryMore:
Equivalent to Salesforce REST API GET /services/data/vXX.X/query/{nextRecordsUrl}
<salesforcerest.queryMore>
<nextRecordsUrl>{$ctx:nextRecordsUrl}</nextRecordsUrl>
</salesforcerest.queryMore>
queryAllMore:
Equivalent to Salesforce REST API GET /services/data/vXX.X/queryAll/{nextRecordsUrl}
<salesforcerest.queryAllMore>
<nextRecordsUrl>{$ctx:nextRecordsUrl}</nextRecordsUrl>
</salesforcerest.queryAllMore>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"nextRecordsUrl": "QWE45HUJ39D9UISD00",
}
Sample Response
{
"done" : true,
"totalSize" : 3214,
"records" : [...]
}
queryPerformanceFeedback
To get feedback on how Salesforce will execute your query, use the salesforcerest.queryPerformanceFeedback operation. It uses the Query resource along with the explain parameter to get feedback. Salesforce analyzes each query to find the optimal approach to obtain the query results. Depending on the query and query filters, an index or internal optimization might be used. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/query?explain={queryString}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
queryString | The SQL query to use to get feedback for a query. | Yes | select id, name from Account |
Sample configuration
<salesforcerest.queryPerformanceFeedback>
<queryString>{$ctx:queryString}</queryString>
</salesforcerest.queryPerformanceFeedback>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"queryString": "select id, name from Account",
}
Sample Response
{
"plans":[
{
"leadingOperationType":"TableScan",
"relativeCost":2.8324836601307193,
"sobjectCardinality":2549,
"fields":[
],
"cardinality":2549,
"sobjectType":"Account"
}
]
}
listviewQueryPerformanceFeedback
To retrieve query performance feedback on a report or list view, use salesforcerest.listviewQueryPerformanceFeedback and specify the following properties. See the related API documentation for more information.
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
listViewID | The ID of the report or list view to get feedback for a query. | Yes | 00B28000002yqeVEAQ |
Sample configuration
<salesforcerest.listviewQueryPerformanceFeedback>
<listViewID>{$ctx:listViewID}</listViewID>
</salesforcerest.listviewQueryPerformanceFeedback>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"listViewID":"00B28000002yqeVEAQ",
}
Sample Response
{
"plans":[
{
"leadingOperationType":"Index",
"relativeCost":0,
"sobjectCardinality":2549,
"fields":[
"CreatedDate"
],
"cardinality":0,
"sobjectType":"Account"
},
.
.
]
}
Quick Actions¶
quickActions
To retrieve a list of global actions, use salesforcerest.quickActions. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/quickActions/
Sample configuration
<salesforcerest.quickActions/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample Response
{
"output":"[
{
\"actorIds\" : [ \"005D00000015rY9IAI\" ],
\"entityId\" : \"001D000000I8mImIAJ\",
\"errors\" : null,
\"instanceId\" : \"04gD0000000Cvm5IAC\",
\"instanceStatus\" : \"Pending\",
\"newWorkitemIds\" : [ \"04iD0000000Cw6SIAS\" ],
\"success\" : true
}
]"
}
returnHeadersForQuickAction
To retrieve only the headers that are returned by the quickActions operation, use salesforcerest.returnHeadersForQuickAction. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/quickActions/
Sample configuration
<salesforcerest.returnHeadersForQuickAction/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
sObjectAction
To retrieve a list of object-specific actions, use salesforcerest.sObjectAction and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/quickActions/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you want to retrieve a list of quick actions. | Yes | Account |
Sample configuration
<salesforcerest.sObjectAction>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.sObjectAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
}
Sample Response
{
"output":"[
{\"label\":\"Log a Call\",
\"name\":\"LogACall\",\"type\":\"LogACall\",
\"urls\":{\"defaultValues\":\"/services/data/v59.0/quickActions/LogACall/defaultValues\",
\"quickAction\":\"/services/data/v59.0/quickActions/LogACall\",
\"describe\":\"/services/data/v59.0/quickActions/LogACall/describe\",
\"defaultValuesTemplate\":\"/services/data/v59.0/quickActions/LogACall/defaultValues/{ID}\"}},
.
.
]"
}
returnHeadersForSObjectAction
To retrieve only the headers that are returned by the sObjectAction operation, use salesforcerest.returnHeadersForSObjectAction and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/{sObjectName}/quickActions/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you want to retrieve a list of quick actions. | Yes | Account |
Sample configuration
<salesforcerest.returnHeadersForSObjectAction>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.returnHeadersForSObjectAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
}
getSpecificAction
To retrieve a specific action, use salesforcerest.getSpecificAction and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/quickActions/{actionName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you want to retrieve the specific quick action. | Yes | Account |
actionName | The name of action to return. | Yes | hariprasath__LogACall |
Sample configuration
<salesforcerest.getSpecificAction>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<actionName>{$ctx:actionName}</actionName>
</salesforcerest.getSpecificAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
"actionName":"hariprasath__LogACall"
}
Sample Response
{
"iconName":null,
"targetRecordTypeId":null,
"targetSobjectType":"Task",
"canvasApplicationName":null,
"label":"Log a Call",
"accessLevelRequired":null,
"icons":[
{
"width":0,
"theme":"theme4",
"contentType":"image/svg+xml",
"url":"https://kesavan-dev-ed.my.salesforce.com/img/icon/t4v59/action/log_a_call.svg",
"height":0
},
.
.
],
"targetParentField":null,
"iconUrl":"https://kesavan-dev-ed.my.salesforce.com/img/icon/log_a_call_32.png",
"height":null
}
returnHeadersForSpecificQuickAction
To retrieve only the headers that are returned by the getSpecificAction operation, use salesforcerest.returnHeadersForSpecificQuickAction and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/{sObjectName}/quickActions/{actionName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you want to retrieve the specific quick action. | Yes | Account |
actionName | The name of action to return. | Yes | hariprasath__LogACall |
Sample configuration
<salesforcerest.returnHeadersForSpecificQuickAction>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<actionName>{$ctx:actionName}</actionName>
</salesforcerest.returnHeadersForSpecificQuickAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
"actionName":"hariprasath__LogACall"
}
getDescribeSpecificAction
To retrieve the description of a specific action, use salesforcerest.getDescribeSpecificAction and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/quickActions/{actionName}/describe/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you want to retrieve the specific quick action. | Yes | Account |
actionName | The action whose description you want to return. | Yes | hariprasath__LogACall |
Sample configuration
<salesforcerest.getDescribeSpecificAction>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<actionName>{$ctx:actionName}</actionName>
</salesforcerest.getDescribeSpecificAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"actionName":"hariprasath__LogACall"
}
Sample Response
{
"iconName":null,
"targetRecordTypeId":null,
"targetSobjectType":"Task",
"canvasApplicationName":null,
"label":"Log a Call",
"accessLevelRequired":null,
"icons":[
{
"width":0,
"theme":"theme4",
"contentType":"image/svg+xml",
"url":"https://kesavan-dev-ed.my.salesforce.com/img/icon/t4v59/action/log_a_call.svg",
"height":0
}
],
.
.
"targetParentField":null,
"iconUrl":"https://kesavan-dev-ed.my.salesforce.com/img/icon/log_a_call_32.png",
"height":null
}
returnHeadersForDescribeSpecificAction
To retrieve only the headers that are returned by the getDescribeSpecificAction operation, use salesforcerest.returnHeadersForDescribeSpecificAction and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/{sObjectName}/quickActions/{actionName}/describe/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you want to retrieve the specific quick action. | Yes | Account |
actionName | The action whose description you want to return. | Yes | hariprasath__LogACall |
Sample configuration
<salesforcerest.returnHeadersForDescribeSpecificAction>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<actionName>{$ctx:actionName}</actionName>
</salesforcerest.returnHeadersForDescribeSpecificAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"actionName":"hariprasath__LogACall"
}
getDefaultValueOfAction
To return a specific action’s default values, including default field values, use salesforcerest.getDefaultValueOfAction and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/quickActions/{actionName}/defaultValues/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you want to retrieve a specific action’s default values. | Yes | Account |
actionName | The specific action. | Yes | hariprasath__LogACall |
Sample configuration
<salesforcerest.getDefaultValueOfAction>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<actionName>{$ctx:actionName}</actionName>
</salesforcerest.getDefaultValueOfAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"actionName":"hariprasath__LogACall",
}
Sample Response
{
"WhoId":null,
"Description":null,
"WhatId":null,
"attributes":{
"type":"Task"
},
"Subject":"Call"
}
returnHeadersForDefaultValueOfAction
To return only the headers that are returned by the getDefaultValueOfAction operation, use salesforcerest.returnHeadersForDefaultValueOfAction and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/{sObjectName}/quickActions/{actionName}/defaultValues/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you want to retrieve a specific action’s default values. | Yes | Account |
actionName | The specific action. | Yes | hariprasath__LogACall |
Sample configuration
<salesforcerest.returnHeadersForDefaultValueOfAction>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<actionName>{$ctx:actionName}</actionName>
</salesforcerest.returnHeadersForDefaultValueOfAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"actionName":"hariprasath__LogACall",
}
getDefaultValueOfActionById
To return the default values for an action specific to the context_id object, use salesforcerest.getDefaultValueOfActionById and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/quickActions/{actionName}/defaultValues/{contextId}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you want to retrieve a specific action’s default values. | Yes | Account |
contextId | The specific context id to retrieve the default values of an action. | Yes | Account |
actionName | The specific action. | Yes | hariprasath__LogACall |
Sample configuration
<salesforcerest.getDefaultValueOfActionById>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<actionName>{$ctx:actionName}</actionName>
<contextId>{$ctx:contextId}</contextId>
</salesforcerest.getDefaultValueOfActionById>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"actionName":"CreateContact",
"contextId":"001D000000JRWBd"
}
Sample Response
{
"WhoId":null,
"Description":null,
"WhatId":null,
"attributes":{
"type":"Task"
},
"Subject":"Call"
}
returnHeadersForDefaultValueOfActionById
To return only the headers that are returned by the getDefaultValueOfActionById operation, use salesforcerest.returnHeadersForDefaultValueOfActionById and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/{sObjectName}/quickActions/{actionName}/defaultValues/{contextId}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you want to retrieve a specific action’s default values. | Yes | Account |
contextId | The specific context id to retrieve the default values of an action. | Yes | Account |
actionName | The specific action. | Yes | hariprasath__LogACall |
Sample configuration
<salesforcerest.returnHeadersForDefaultValueOfActionById>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<actionName>{$ctx:actionName}</actionName>
<contextId>{$ctx:contextId}</contextId>
</salesforcerest.returnHeadersForDefaultValueOfActionById>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"actionName":"CreateContact",
"contextId":"001D000000JRWBd"
}
create
To create a record, use salesforcerest.create and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/sobjects/{sObjectName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you will create a record. | Yes | Account |
fieldAndValue | The .json format property used to create the record. Include all mandatory fields according to the requirements for the specified sObject. | Yes | { "name": "wso2", "description":"This Account belongs to WSO2" } |
Note: For example, if you are creating a record for the Account sObject, "name" is a mandatory parameter, and you might want to include the optional description, so the fieldAndValue property would look like this:
{ "name":"wso2", "description":"This account belongs to WSO2" }
Sample configuration
<salesforcerest.create>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.create>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",,
"fieldAndValue": {
"name": "wso2",
"description":"This Account belongs to WSO2"
}
}
Sample Response
{
"success":true,
"id":"0010K00001uiAn8QAE",
"errors":[
]
}
createMultipleRecords
To create multiple records of the same sObject type, use salesforcerest.createMultipleRecords and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/composite/tree/{sObjectName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you will create multiple records. | Yes | Account |
fieldAndValue | The .json format property, which specifies each record as an entry within the records array. Include all mandatory fields according to the requirements for the specified sObject. | Yes | { "records": [ { "attributes": {"type": "Account", "referenceId": "ref1"}, "name": "wso2", "phone": "1111111", "website": "www.salesforce1.com" }, { "attributes": {"type": "Account", "referenceId": "ref2"}, "name": "slwso2", "phone": "22222222", "website": "www.salesforce2.com" }] } |
Note: For example, if you are creating a record for the Account sObject, "name" is a mandatory parameter, and you might want to include the optional description, so the fieldAndValue property would look like this:
{ "records": [ { "attributes": {"type": "Account", "referenceId": "ref1"}, "name": "wso2", "phone": "1111111", "website": "www.salesforce1.com" }, { "attributes": {"type": "Account", "referenceId": "ref2"}, "name": "slwso2", "phone": "22222222", "website": "www.salesforce2.com" }] }
Sample configuration
<salesforcerest.createMultipleRecords>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.createMultipleRecords>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"fieldAndValue": {
"records": [
{
"attributes": {"type": "Account", "referenceId": "ref1"},
"name": "wso2",
"phone": "1111111",
"website": "www.salesforce1.com"
},
{
"attributes": {"type": "Account", "referenceId": "ref2"},
"name": "slwso2",
"phone": "22222222",
"website": "www.salesforce2.com"
}]
}
}
Sample Response
{
"hasErrors" : false,
"results" : [{
"referenceId" : "ref1",
"id" : "001D000000K1YFjIAN"
},{
"referenceId" : "ref2",
"id" : "001D000000K1YFkIAN"
},{
"referenceId" : "ref3",
"id" : "001D000000K1YFlIAN"
},{
"referenceId" : "ref4",
"id" : "001D000000K1YFmIAN"
}]
}
createNestedRecords
To create nested records for a specific sObject, use salesforcerest.createNestedRecords and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/composite/tree/{sObjectName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you will create nested records. | Yes | |
fieldAndValue | The .json format property, which specifies each record as an entry within the records array. Include all mandatory fields according to the requirements for the specified sobject. | Yes | { "records" :[{ "attributes" : {"type" : "Account", "referenceId" : "ref1"}, "name" : "SampleAccount1", "phone" : "1234567890", "website" : "www.salesforce.com", "numberOfEmployees" : "100", "type" : "Analyst", "industry" : "Banking", "Contacts" : { "records" : [{ "attributes" : {"type" : "Contact", "referenceId" : "ref2"}, "lastname" : "Smith", "Title" : "President", "email" : "[email protected]" },{ "attributes" : {"type" : "Account", "referenceId" : "ref3"}, "lastname" : "Evans", "title" : "Vice President", "email" : "[email protected]" }] } },{ "attributes" : {"type" : "Account", "referenceId" : "ref4"}, "name" : "SampleAccount2", "phone" : "1234567890", "website" : "www.salesforce.com", "numberOfEmployees" : "52000", "type" : "Analyst", "industry" : "Banking", "childAccounts" : { "records" : [{ "attributes" : {"type" : "Account", "referenceId" : "ref5"}, "name" : "SampleChildAccount1", "phone" : "1234567890", "website" : "www.salesforce.com", "numberOfEmployees" : "100", "type" : "Analyst", "industry" : "Banking" }] }, "Contacts" : { "records" : [{ "attributes" : {"type" : "Contact", "referenceId" : "ref6"}, "lastname" : "Jones", "title" : "President", "email" : "[email protected]" }] } }] } |
Note: For example, if you are creating records for the Account sObject, "name" is a mandatory parameter, and you might want to include additional optional values for each record, so the fieldAndValue property might look like this:
{ "records" :[{ "attributes" : {"type" : "Account", "referenceId" : "ref1"}, "name" : "SampleAccount1", "phone" : "1234567890", "website" : "www.salesforce.com", "numberOfEmployees" : "100", "type" : "Analyst", "industry" : "Banking", "Contacts" : { "records" : [{ "attributes" : {"type" : "Contact", "referenceId" : "ref2"}, "lastname" : "Smith", "Title" : "President", "email" : "[email protected]" },{ "attributes" : {"type" : "Contact", "referenceId" : "ref3"}, "lastname" : "Evans", "title" : "Vice President", "email" : "[email protected]" }] } },{ "attributes" : {"type" : "Account", "referenceId" : "ref4"}, "name" : "SampleAccount2", "phone" : "1234567890", "website" : "www.salesforce.com", "numberOfEmployees" : "52000", "type" : "Analyst", "industry" : "Banking", "childAccounts" : { "records" : [{ "attributes" : {"type" : "Account", "referenceId" : "ref5"}, "name" : "SampleChildAccount1", "phone" : "1234567890", "website" : "www.salesforce.com", "numberOfEmployees" : "100", "type" : "Analyst", "industry" : "Banking" }] }, "Contacts" : { "records" : [{ "attributes" : {"type" : "Contact", "referenceId" : "ref6"}, "lastname" : "Jones", "title" : "President", "email" : "[email protected]" }] } }] }
Sample configuration
<salesforcerest.createNestedRecords>
<sObjectName>{$ctx:sObjectName}</sobject>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.createNestedRecords>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",,
"fieldAndValue":{
"records" :[{
"attributes" : {"type" : "Account", "referenceId" : "ref1"},
"name" : "SampleAccount1",
"phone" : "1234567890",
"website" : "www.salesforce.com",
"numberOfEmployees" : "100",
"type" : "Analyst",
"industry" : "Banking",
"Contacts" : {
"records" : [{
"attributes" : {"type" : "Contact", "referenceId" : "ref2"},
"lastname" : "Smith",
"Title" : "President",
"email" : "[email protected]"
},{
"attributes" : {"type" : "Account", "referenceId" : "ref3"},
"lastname" : "Evans",
"title" : "Vice President",
"email" : "[email protected]"
}]
}
},...
]
}
}
Sample Response
{
"hasErrors" : false,
"results" : [{
"referenceId" : "ref1",
"id" : "001D000000K0fXOIAZ"
},{
"referenceId" : "ref4",
"id" : "001D000000K0fXPIAZ"
},{
"referenceId" : "ref2",
"id" : "003D000000QV9n2IAD"
},{
"referenceId" : "ref3",
"id" : "003D000000QV9n3IAD"
},{
"referenceId" : "ref5",
"id" : "001D000000K0fXQIAZ"
},{
"referenceId" : "ref6",
"id" : "003D000000QV9n4IAD"
}]
}
createUsingExternalId
To create a new record based on the field values included in the request body, use salesforcerest.createUsingExternalId and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/sobjects/{sObjectName}/Id
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you will create a record. | Yes | |
fieldAndValue | The .json format property used to create the record. Include all mandatory fields according to the requirements for the specified sObject. | Yes | { "Name" : "California Wheat Corporation", "Type" : "New Customer" } |
Sample configuration
<salesforcerest.createUsingExternalId>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.createUsingExternalId>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"fieldAndValue": {
"records": {
"Name" : "California Wheat Corporation",
"Type" : "New Customer"
}
}
}
Sample Response
{
"id" : "001D000000Kv3g5IAB",
"success" : true,
"errors" : [ ],
"created": true
}
createUsingQuickAction
To create a record via a quick action, use salesforcerest.createUsingQuickAction and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/quickActions/{actionName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
actionName | The specific action name to create the record. | Yes | |
fieldAndValue | The .json format property used to create the record using a quick action. Include all mandatory fields according to the requirements for the specified sObject. | Yes | { "record" : { "LastName" : "Smith" } } |
Sample configuration
<salesforcerest.createUsingQuickAction>
<actionName>{$ctx:actionName}</actionName>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.createUsingQuickAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"actionName":"CreateContact",
"fieldAndValue": {
"record" : { "LastName" : "Smith" }
}
}
createUsingSpecificSObjectQuickAction
To create a record via the specified quick action based on the field values included in the request body, use salesforcerest.createUsingSpecificSObjectQuickAction and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/sobjects/{sObjectName}/quickActions/{actionName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you will create a record. | Yes | |
actionName | The specific action name to create the record. | Yes | |
fieldAndValue | The .json format property used to create the record using a quick action. Include all mandatory fields according to the requirements for the specified sObject. | Yes | { "contextId" : "001D000000JRSGf", "record" : { "LastName" : "Smith" } } |
Sample configuration
<salesforcerest.createUsingSpecificSObjectQuickAction>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<actionName>{$ctx:actionName}</actionName>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.createUsingSpecificSObjectQuickAction>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"actionName":"CreateContact",
"fieldAndValue": {
"contextId" : "001D000000JRSGf",
"record" : { "LastName" : "Smith" }
}
}
createUsingSObjectCollections
To create records using sObject collections, use salesforcerest.createUsingSObjectCollections and specify the following properties. Can add up to 200 records. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/composite/sobjects
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
fieldAndValue | The .json format property used to create the record using sObject collections. Include all mandatory fields according to the requirements for the specified sObject. | Yes | { "allOrNone" : false, "records" : [{ "attributes" : {"type" : "Account"}, "Name" : "example.com", "BillingCity" : "San Francisco" }, { "attributes" : {"type" : "Contact"}, "LastName" : "Johnson", "FirstName" : "Erica" }] } |
Sample configuration
<salesforcerest.createUsingSObjectCollections>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.createUsingSObjectCollections>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"actionName":"CreateContact",
"fieldAndValue": {
"allOrNone" : false,
"records" : [{
"attributes" : {"type" : "Account"},
"Name" : "example.com",
"BillingCity" : "San Francisco"
}, {
"attributes" : {"type" : "Contact"},
"LastName" : "Johnson",
"FirstName" : "Erica"
}]
}
}
Sample Response
[
{
"id" : "001RM000003oLnnYAE",
"success" : true,
"errors" : [ ]
},
{
"id" : "003RM0000068xV6YAI",
"success" : true,
"errors" : [ ]
}
]
getRecordsUsingRelationships
To retrieve a record based on the specified object, record ID, and relationship field, use salesforcerest.getRecordsUsingRelationships and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/{id}/{relationshipFieldName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you will create a record. | Yes | Account |
id | The identifier of the record. | Yes | 001R0000005hDFYIA2 |
relationshipFieldName | The name of the field that contains the relationship. | Yes | Opportunities |
fields | A comma-delimited list of fields in the associated relationship record returned in the response body. | No | field1,field2 |
Sample configuration
<salesforcerest.getRecordsUsingRelationships>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<id>{$ctx:id}</id>
<relationshipFieldName>{$ctx:relationshipFieldName}</relationshipFieldName>
<fields>{$ctx:fields}</fields>
</salesforcerest.getRecordsUsingRelationships>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"id":"001R0000005hDFYIA2",
"relationshipFieldName":"Opportunities",
"fields":"field1,field2"
}
Sample Response
{
"attributes" :
{
"type" : "Distributor__c",
"url" : "/services/data/v59.0/sobjects/Distributor__c/a03D0000003DUhcIAG"
},
"Id" : "a03D0000003DUhcIAG",
"OwnerId" : "005D0000001KyEIIA0",
"IsDeleted" : false,
"Name" : "Distributor1",
"CreatedDate" : "2011-12-16T17:43:01.000+0000",
"CreatedById" : "005D0000001KyEIIA0",
"LastModifiedDate" : "2011-12-16T17:43:01.000+0000",
"LastModifiedById" : "005D0000001KyEIIA0",
"SystemModstamp" : "2011-12-16T17:43:01.000+0000",
"Location__c" : "San Francisco"
}
getRecordsUsingSObjectCollections
To retrieve one or more records of the same object type using sObject collections, use salesforcerest.getRecordsUsingSObjectCollections and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/composite/sobjects/{sObjectName}?ids={ids}&fields={fields}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you will create a record. | Yes | Account |
ids | A list of one or more IDs of the objects to return. All IDs must belong to the same object type. | Yes | 001xx000003DGb1AAG,001xx000003DGb0AAG,001xx000003DGb9AAG |
fields | A list of fields to include in the response. The field names you specify must be valid, and you must have read-level permissions to each field. | Yes | id,name |
Sample configuration
<salesforcerest.getRecordsUsingSObjectCollections>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<ids>{$ctx:ids}</ids>
<fields>{$ctx:fields}</fields>
</salesforcerest.getRecordsUsingSObjectCollections>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"ids":"001xx000003DGb1AAG,001xx000003DGb0AAG,001xx000003DGb9AAG",
"fields":"id,name"
}
Sample Response
[
{
"attributes" : {
"type" : "Account",
"url" : "/services/data/v59.0/sobjects/Account/001xx000003DGb1AAG"
},
"Id" : "001xx000003DGb1AAG",
"Name" : "Acme"
},
{
"attributes" : {
"type" : "Account",
"url" : "/services/data/v59.0/sobjects/Account/001xx000003DGb0AAG"
},
"Id" : "001xx000003DGb0AAG",
"Name" : "Global Media"
},
null
]
getRecordsWithARequestBodyUsingSObjectCollections
To retrieve one or more records of the same object type using sObject collections with a request body, use salesforcerest.getRecordsWithARequestBodyUsingSObjectCollections and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/composite/sobjects/{sObjectName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you will retrieve the record. | Yes | Account |
fieldAndValue | The json format property with the new definition for the record. | Yes | { "ids" : ["001xx000003DGb1AAG", "001xx000003DGb0AAG", "001xx000003DGb9AAG"], "fields" : ["id", "name"] } |
Sample configuration
<salesforcerest.getRecordsWithARequestBodyUsingSObjectCollections>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.getRecordsWithARequestBodyUsingSObjectCollections>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"fieldAndValue": {
"ids" : ["001xx000003DGb1AAG", "001xx000003DGb0AAG", "001xx000003DGb9AAG"],
"fields" : ["id", "name"]
},
}
Sample Response
[
{
"attributes" : {
"type" : "Account",
"url" : "/services/data/v59.0/sobjects/Account/001xx000003DGb1AAG"
},
"Id" : "001xx000003DGb1AAG",
"Name" : "Acme"
},
{
"attributes" : {
"type" : "Account",
"url" : "/services/data/v59.0/sobjects/Account/001xx000003DGb0AAG"
},
"Id" : "001xx000003DGb0AAG",
"Name" : "Global Media"
},
null
]
getObjectRecordCounts
To list information about object record counts in your organization, use salesforcerest.getObjectRecordCounts and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/limits/recordCount?sObjects={sObjects}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjects | A comma-delimited list of object names. If a listed object is not found in the org, it is ignored and not returned in the response. | No | Account,Contact |
Sample configuration
<salesforcerest.getObjectRecordCounts>
<sObjects>{$ctx:sObjects}</sObjects>
</salesforcerest.getObjectRecordCounts>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjects":"Account,Contact"
}
Sample Response
{
"sObjects" : [ {
"count" : 3,
"name" : "Account"
}, {
"count" : 10,
"name" : "Contact"
} ]
}
update
To update a record, use salesforcerest.update and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API PATCH /services/data/vXX.X/sobjects/{sObjectName}/{Id}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you will create a record. | Yes | Account |
Id | The ID of the record you are updating. | Yes | 00128000002OOhD |
fieldAndValue | The json format property with the new definition for the record. | Yes | { "name": "wso2", "description":"This Account belongs to WSO2" } |
Sample configuration
<salesforcerest.update>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<Id>{$ctx:Id}</Id>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.update>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"Id":"00128000002OOhD",
"fieldAndValue": {
"name": "wso2",
"description":"This Account belongs to WSO2"
}
}
updateUsingRelationships
To updatea parent record based on the specified object, record ID, and relationship field name, use salesforcerest.updateUsingRelationships and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API PATCH /services/data/vXX.X/sobjects/{sObjectName}/{id}/{relationshipFieldName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The type of object for which you will update the record. | Yes | Contact |
id | The ID of the record you are updating. | Yes | 003R0000005hDFYIA2 |
relationshipFieldName | The name of the field that contains the relationship. | Yes | Account |
fieldAndValue | The json format property with the new definition for the record. | Yes | { "BillingCity" : "San Francisco" } |
Sample configuration
<salesforcerest.updateUsingRelationships>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<id>{$ctx:Id}</id>
<relationshipFieldName>{$ctx:relationshipFieldName}</relationshipFieldName>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.updateUsingRelationships>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Contact",
"id":"003R0000005hDFYIA2",
"relationshipFieldName": "Account",
"fieldAndValue": {
"BillingCity" : "San Francisco"
}
}
updateRecordsUsingSObjectCollections
To updatea records using sObject collections, use salesforcerest.updateRecordsUsingSObjectCollections and specify the following properties. This operation can update up to 200 records. See the related API documentation for more information.
Equivalent to Salesforce REST API PATCH /services/data/vXX.X/composite/sobjects/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
fieldAndValue | The json format property with the new definition for the record. | Yes | { "allOrNone" : false, "records" : [{ "attributes" : {"type" : "Account"}, "id" : "001xx000003DGb2AAG", "NumberOfEmployees" : 27000 },{ "attributes" : {"type" : "Contact"}, "id" : "003xx000004TmiQAAS", "Title" : "Lead Engineer" }] } |
Sample configuration
<salesforcerest.updateRecordsUsingSObjectCollections>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.updateRecordsUsingSObjectCollections>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"fieldAndValue": {
"allOrNone" : false,
"records" : [{
"attributes" : {"type" : "Account"},
"id" : "001xx000003DGb2AAG",
"NumberOfEmployees" : 27000
},{
"attributes" : {"type" : "Contact"},
"id" : "003xx000004TmiQAAS",
"Title" : "Lead Engineer"
}]
}
}
Sample Response
[
{
"id" : "001RM000003oCprYAE",
"success" : true,
"errors" : [ ]
},
{
"id" : "003RM0000068og4YAA",
"success" : true,
"errors" : [ ]
}
]
delete
To delete a record, use salesforcerest.delete and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API DELETE /services/data/vXX.X/sobjects/{sObjectName}/{idToDelete}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object type of the record. | Yes | Account |
idToDelete | The ID of the record you are deleting. | Yes | 00128000002OOhD |
Sample configuration
<salesforcerest.delete>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<idToDelete>{$ctx:idToDelete}</idToDelete>
</salesforcerest.delete>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"idToDelete":"00128000002OOhD",
}
deleteUsingExternalId
To delete a record based on the value of the specified external ID field, use salesforcerest.deleteUsingExternalId and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API DELETE /services/data/vXX.X/sobjects/{customObject}/{externalIdField}/{externalIdFieldValue}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
customObject | The type of object for which you will create a record. | Yes | Account |
externalIdField | Specific object field to access the record. | Yes | sample__c |
externalIdFieldValue | The value of the ExternalIdField. | Yes | 15222 |
Sample configuration
<salesforcerest.deleteUsingExternalId>
<customObject>{$ctx:customObject}</customObject>
<externalIdField>{$ctx:externalIdField}</externalIdField>
<externalIdFieldValue>{$ctx:externalIdFieldValue}</externalIdFieldValue>
</salesforcerest.deleteUsingExternalId>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"customObject": "Account",
"externalIdField": "sample__c",
"externalIdFieldValue": "15222"
}
deleteUsingRelationships
To delete a parent record based on the specified object, record ID, and relationship field name, use salesforcerest.deleteUsingRelationships and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API DELETE /services/data/vXX.X/sobjects/{sObjectName}/{id}/{relationshipFieldName}
Parameter Name | Description | Required | Sample Value | sObjectName | The type of object for which you will delete the record. | Yes | Contact |
---|---|---|---|
id | The ID of the record you are updating. | Yes | 003R0000005hDFYIA2 |
relationshipFieldName | The name of the field that contains the relationship. | Yes | Account |
Sample configuration
<salesforcerest.deleteUsingRelationships>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<id>{$ctx:id}</id>
<relationshipFieldName>{$ctx:relationshipFieldName}</relationshipFieldName>
</salesforcerest.deleteUsingRelationships>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Contact",
"id": "003R0000005hDFYIA2",
"relationshipFieldName": "Account"
}
deleteRecordsUsingSObjectCollections
To delete records using sObject collections, use salesforcerest.deleteRecordsUsingSObjectCollections and specify the following properties. Can delete up to 200 records. See the related API documentation for more information.
Equivalent to Salesforce REST API DELETE /services/data/vXX.X/composite/sobjects?ids={ids}&allOrNone={allOrNone}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
ids | A list of up to 200 IDs of objects to be deleted. The IDs can belong to different object types, including custom objects. | Yes | 001xx000003DGb2AAG,003xx000004TmiQAAS |
allOrNone | Indicates whether to roll back the entire request when the deletion of any object fails (true) or to continue with the independent deletion of other objects in the request. The default is false. | No | false |
Sample configuration
<salesforcerest.deleteRecordsUsingSObjectCollections>
<ids>{$ctx:ids}</ids>
<allOrNone>{$ctx:allOrNone}</allOrNone>
</salesforcerest.deleteRecordsUsingSObjectCollections>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"ids": "001xx000003DGb2AAG,003xx000004TmiQAAS",
"allOrNone": "false"
}
Sample response
[
{
"id" : "001RM000003oLrHYAU",
"success" : true,
"errors" : [ ]
},
{
"id" : "001RM000003oLraYAE",
"success" : true,
"errors" : [ ]
}
]
recentlyViewedItem
To retrieve the recently viewed items, use salesforcerest.recentlyViewedItem and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/recent/?limit={limit}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
limit | The maximum number of records to be returned. | Yes | 2 |
Sample configuration
<salesforcerest.recentlyViewedItem>
<limit>{$ctx:limit}</limit>
</salesforcerest.recentlyViewedItem>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"limit":"2",
}
Sample Response
{
"attributes" :
{
"type" : "Account",
"url" : "/services/data/v59.0/sobjects/Account/a06U000000CelH0IAJ"
},
"Id" : "a06U000000CelH0IAJ",
"Name" : "Acme"
},
{
"attributes" :
{
"type" : "Opportunity",
"url" : "/services/data/v59.0/sobjects/Opportunity/a06U000000CelGvIAJ"
},
"Id" : "a06U000000CelGvIAJ",
"Name" : "Acme - 600 Widgets"
}
retrieveFieldValues
To retrieve specific field values for a specific sObject, use salesforcerest.retrieveFieldValues and specify the following properties. See the related API documentation for more information.
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object type whose metadata you want to retrieve. | Yes | Account |
rowId | The ID of the record whose values you want to retrieve. | Yes | 00128000005YjDnAAK |
fields | A comma-separated list of fields whose values you want to retrieve. | Yes | AccountNumber,BillingPostalCode |
Sample configuration
<salesforcerest.retrieveFieldValues>
<limit>{$ctx:limit}</limit>
</salesforcerest.retrieveFieldValues>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
"rowId":"00128000005YjDnAAK",
"fields":"AccountNumber,BillingPostalCode",
}
Sample Response
{
"AccountNumber" : "CD656092",
"BillingPostalCode" : "27215",
}
retrieveFieldValuesFromExternalObject
To retrieve specific field values from an External Object, use salesforcerest.retrieveFieldValuesFromExternalObject and specify the following properties. See the related API documentation for more information.
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
externalObject | The External object of the organization. | Yes | Customer__x |
salesforceId | The row Id of the object. | Yes | x01D0000000002RIAQ |
externalFields | The comma separated field values. | Yes | Country__c,Country__a |
Sample configuration
<salesforcerest.retrieveFieldValuesFromExternalObject>
<externalObject>{$ctx:externalObject}</externalObject>
<salesforceId>{$ctx:salesforceId}</salesforceId>
<externalFields>{$ctx:externalFields}</externalFields>
</salesforcerest.retrieveFieldValuesFromExternalObject>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"externalObject": "Customer__x",
"salesforceId":"x01D0000000002RIAQ",
"externalFields":"Country__c,Country__a",
}
Sample Response
{
"attributes" : {
"type" : "Customer__x",
"url" : "/services/data/v59.0/sobjects/Customer__x/x01D0000000002RIAQ"
},
"Country__c" : "Argentina",
"Id" : "x01D0000000002RIAQ"
}
retrieveStandardFieldValuesFromExternalObjectWithExternalId
To retrieve specific field values from an External Object, use salesforcerest.retrieveStandardFieldValuesFromExternalObjectWithExternalId and specify the following properties. See the related API documentation for more information.
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
externalObject | The External object of the organization. | Yes | Customer__x |
externalId | The row Id of the object. | Yes | CACTU |
externalFields | The comma separated field values. | Yes | Country__c,Country__a |
Sample configuration
<salesforcerest.retrieveStandardFieldValuesFromExternalObjectWithExternalId>
<externalObject>{$ctx:externalObject}</externalObject>
<externalId>{$ctx:externalId}</externalId>
<externalFields>{$ctx:externalFields}</externalFields>
</salesforcerest.retrieveStandardFieldValuesFromExternalObjectWithExternalId>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"externalObject": "Customer__x",
"externalId":"CACTU",
"externalFields":"Country__c,Country__a",
}
Sample Response
{
"attributes" : {
"type" : "Customer__x",
"url" : "/services/data/v59.0/sobjects/Customer__x/CACTU"
},
"Country__c" : "Argentina",
"ExternalId" : "CACTU"
}
upsert
To create or update (upsert) a record using an external ID, use salesforcerest.upsert and specify the following properties. This method is used to create records or update existing records based on the value of a specified external ID field. See the related API documentation for more information.
* If the specified value does not exist, a new record is created.
* If a record does exist with that value, the field values specified in the request body are updated.
Equivalent to Salesforce REST API PATCH /services/data/vXX.X/sobjects/{sObjectName}/{externalIDField}/{Id}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object type whose value you want to upsert. | Yes | Account |
externalIDField | The external Id Field of the subject. | Yes | sample__c |
Id | The value of the customExtIdField. | Yes | 15222 |
fieldAndValue | The json format property/payload used to create the record. | Yes | { "Name":"john" } |
Sample configuration
<salesforcerest.upsert>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<externalIDField>{$ctx:externalIDField}</externalIDField>
<Id>{$ctx:Id}</Id>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.upsert>
Sample request
{
"accessToken":"00D280000017q6q!AQoAQMMZWoN9MQZcXLW475YYoIdJFUICTjbGh67jEfAeV7Q57Ac2Ov.0ZuM_2Zx6SnrOmwpml8Qf.XclstTQiXtCYSGRBcEv",
"apiUrl":"https://(your_instance).salesforce.com",
"clientId": "3MVG9ZL0ppGP5UrBrnsanGUZRgHqc8gTV4t_6tfuef8Zz4LhFPipmlooU6GBszpplbTzVXXWjqkGHubhRip1s",
"refreshToken": "5Aep861TSESvWeug_ztpnAk6BGQxRdovMLhHso81iyYKO6hTm68KfebpK7UYtEzF0ku8JCz7CNto8b3YMRmZrhy",
"clientSecret": "9104967092887676680",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",,
"intervalTime" : "2400000",
"externalIDField":"sample__c",
"Id":"15222",
"fieldAndValue":
{
"Name":"john"
}
}
Sample Response
{
"id" : "00190000001pPvHAAU",
"errors" : [ ],
"success" : true
}
upsertRecordsUsingSObjectCollections
To either create or update (upsert) up to 200 records based on an external ID field using sObject collections, use salesforcerest.upsertRecordsUsingSObjectCollections and specify the following properties. This method is used to create records or update existing records based on the value of a specified external ID field. See the related API documentation for more information.
* If the specified value does not exist, a new record is created.
* If a record does exist with that value, the field values specified in the request body are updated.
Equivalent to Salesforce REST API PATCH /services/data/vXX.X/composite/sobjects/{sObjectName}/{externalIdFieldName}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object type whose value you want to upsert. | Yes | Account |
externalIdFieldName | The name of the external id field. | Yes | MyExtId__c |
fieldAndValue | The json format property/payload used to create the record. | Yes | { "allOrNone" : false, "records" : [{ "attributes" : {"type" : "Account"}, "Name" : "Company One", "MyExtId__c" : "AAA" }, { "attributes" : {"type" : "Account"}, "Name" : "Company Two", "MyExtId__c" : "BBB" }] } |
Sample configuration
<salesforcerest.upsertRecordsUsingSObjectCollections>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<externalIdFieldName>{$ctx:externalIdFieldName}</externalIdFieldName>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.upsertRecordsUsingSObjectCollections>
Sample request
{
"accessToken":"00D280000017q6q!AQoAQMMZWoN9MQZcXLW475YYoIdJFUICTjbGh67jEfAeV7Q57Ac2Ov.0ZuM_2Zx6SnrOmwpml8Qf.XclstTQiXtCYSGRBcEv",
"apiUrl":"https://(your_instance).salesforce.com",
"clientId": "3MVG9ZL0ppGP5UrBrnsanGUZRgHqc8gTV4t_6tfuef8Zz4LhFPipmlooU6GBszpplbTzVXXWjqkGHubhRip1s",
"refreshToken": "5Aep861TSESvWeug_ztpnAk6BGQxRdovMLhHso81iyYKO6hTm68KfebpK7UYtEzF0ku8JCz7CNto8b3YMRmZrhy",
"clientSecret": "9104967092887676680",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"externalIdFieldName" : "MyExtId__c",
"fieldAndValue":
{
"allOrNone" : false,
"records" : [{
"attributes" : {"type" : "Account"},
"Name" : "Company One",
"MyExtId__c" : "AAA"
}, {
"attributes" : {"type" : "Account"},
"Name" : "Company Two",
"MyExtId__c" : "BBB"
}]
}
}
Sample Response
[
{
"id": "001xx0000004GxDAAU",
"success": true,
"errors": [],
"created": true
},
{
"id": "001xx0000004GxEAAU",
"success": true,
"errors": [],
"created": false
}
]
getDeleted
To retrieve a list of individual records that have been deleted within the given timespan for the specified object, use salesforcerest.getDeleted. The date and time should be provided in ISO 8601 format:YYYY-MM-DDThh:mm:ss+hh:mm. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/deleted/?start={startTime}&end={endTime}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object where you want to look for deleted records | Yes | Account |
startTime | Starting date/time (Coordinated Universal Time (UTC)—not local—timezone) of the timespan for which to retrieve the data. | Yes | 2015-10-05T12:30:30+05:30 |
endTime | Ending date/time (Coordinated Universal Time (UTC)—not local—timezone) of the timespan for which to retrieve the data. | Yes | 2015-10-10T20:30:30+05:30 |
Sample configuration
<salesforcerest.getDeleted>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<startTime>{$ctx:startTime}</startTime>
<endTime>{$ctx:endTime}</endTime>
</salesforcerest.getDeleted>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"startTime":"2015-10-05T12:30:30+05:30",
"endTime":"2015-10-10T20:30:30+05:30"
}
Sample Response
{
"earliestDateAvailable":"2018-09-20T07:52:00.000+0000",
"deletedRecords":[
],
"latestDateCovered":"2018-10-27T15:00:00.000+0000"
}
getUpdated
To retrieve a list of individual records that have been updated within the given timespan for the specified object, use salesforcerest.getUpdated. The date and time should be provided in ISO 8601 format:YYYY-MM-DDThh:mm:ss+hh:mm. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/updated?start={startTime}&end={endTime}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object where you want to look for updated records | Yes | Account |
startTime | Starting date/time (Coordinated Universal Time (UTC)—not local—timezone) of the timespan for which to retrieve the data. | Yes | 2015-10-05T12:30:30+05:30 |
endTime | Ending date/time (Coordinated Universal Time (UTC)—not local—timezone) of the timespan for which to retrieve the data. | Yes | 2015-10-10T20:30:30+05:30 |
Sample configuration
<salesforcerest.getUpdated>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<startTime>{$ctx:startTime}</startTime>
<endTime>{$ctx:endTime}</endTime>
</salesforcerest.getUpdated>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"startTime":"2015-10-05T12:30:30+05:30",
"endTime":"2015-10-10T20:30:30+05:30"
}
Sample Response
{
"ids":[
],
"latestDateCovered":"2018-10-27T15:00:00.000+0000"
}
Scheduling¶
listSchedulerRESTResourcesAndURIs
To retrieve a list of available Salesforce Scheduler REST resources and corresponding URIs, use salesforcerest.listSchedulerRESTResourcesAndURIs and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/scheduling/
Sample configuration
<salesforcerest.listSchedulerRESTResourcesAndURIs/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0"
}
Sample response
{
"getAppointmentCandidates" : "/services/data/v59.0/scheduling/getAppointmentCandidates",
"getAppointmentSlots" : "/services/data/v59.0/scheduling/getAppointmentSlots"
}
listAppointmentCandidates
To retrieve a list of service resources (appointment candidates) based on work type group or work type and service territories, use salesforcerest.listAppointmentCandidates and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/scheduling/getAppointmentCandidates
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
fieldAndValue | The .json format property used to list appointment candidates. | Yes | { "startTime": "2019-01-23T00:00:00.000Z", "endTime": "2019-02-30T00:00:00.000Z", "workTypeGroupId": "0VSB0000000KyjBOAS", "accountId": "001B000000qAUAWIA4", "territoryIds": [ "0HhB0000000TO9WKAW" ], "schedulingPolicyId": "0VrB0000000KyjB", "engagementChannelTypeIds": [ "0eFRM00000000Bv2AI" ] } |
Sample configuration
<salesforcerest.listAppointmentCandidates>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.listAppointmentCandidates>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"fieldAndValue": {
"startTime": "2019-01-23T00:00:00.000Z",
"endTime": "2019-02-30T00:00:00.000Z",
"workTypeGroupId": "0VSB0000000KyjBOAS",
"accountId": "001B000000qAUAWIA4",
"territoryIds": [
"0HhB0000000TO9WKAW"
],
"schedulingPolicyId": "0VrB0000000KyjB",
"engagementChannelTypeIds": [
"0eFRM00000000Bv2AI"
]
}
}
Sample response
{
"candidates": [
{
"endTime": "2019-01-23T19:15:00.000+0000",
"resources": [
"0HnB0000000D2DsKAK"
],
"startTime": "2019-01-23T16:15:00.000+0000",
"territoryId": "0HhB0000000TO9WKAW",
"engagementChannelTypeIds": [
"0eFRM00000000Bv2AI"
]
},
{
"endTime": "2019-01-23T19:30:00.000+0000",
"resources": [
"0HnB0000000D2DsKAK"
],
"startTime": "2019-01-23T16:30:00.000+0000",
"territoryId": "0HhB0000000TO9WKAW",
"engagementChannelTypeIds": [
"0eFRM00000000Bv2AI"
]
}
]
}
listAppointmentSlots
To retrieve a list of available appointment time slots for a resource based on given work type group or work type and service territories, use salesforcerest.listAppointmentSlots and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/scheduling/getAppointmentSlots
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
fieldAndValue | The .json format property used to list appointment slots. | Yes | { "startTime": "2019-01-23T00:00:00.000Z", "endTime": "2019-02-30T00:00:00.000Z", "workTypeGroupId": "0VSB0000000KyjBOAS", "accountId": "001B000000qAUAWIA4", "territoryIds": [ "0HhB0000000TO9WKAW" ], "schedulingPolicyId": "0VrB0000000KyjB", "engagementChannelTypeIds": [ "0eFRM00000000Bv2AI" ] } |
Sample configuration
<salesforcerest.listAppointmentSlots>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.listAppointmentSlots>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"fieldAndValue": {
"startTime": "2019-01-23T00:00:00.000Z",
"endTime": "2019-02-30T00:00:00.000Z",
"workTypeGroupId": "0VSB0000000KyjBOAS",
"accountId": "001B000000qAUAWIA4",
"territoryIds": [
"0HhB0000000TO9WKAW"
],
"schedulingPolicyId": "0VrB0000000KyjB",
"engagementChannelTypeIds": [
"0eFRM00000000Bv2AI"
]
}
}
Sample response
{
"timeSlots": [
{
"endTime": "2019-01-21T19:15:00.000+0000",
"startTime": "2019-01-21T16:15:00.000+0000",
"territoryId": "0HhB0000000TO9WKAW"
},
{
"endTime": "2019-01-21T19:30:00.000+0000",
"startTime": "2019-01-21T16:30:00.000+0000",
"territoryId": "0HhB0000000TO9WKAW"
},
{
"endTime": "2019-01-21T19:45:00.000+0000",
"startTime": "2019-01-21T16:45:00.000+0000",
"territoryId": "0HhB0000000TO9WKAW"
}
]
}
sObjects¶
describeGlobal
To retrieve a list of the objects that are available in the system, use salesforcerest.describeGlobal. You can then get metadata for an object or objects as described in the next sections. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/
Sample configuration
<salesforcerest.describeGlobal/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample Response
{
"maxBatchSize":200,
"sobjects":[
{
"updateable":false,
"activateable":false,
"deprecatedAndHidden":false,
"layoutable":false,
"custom":false,
"deletable":false,
"replicateable":false,
"undeletable":false,
"label":"Accepted Event Relation",
"keyPrefix":null,
"searchable":false,
"queryable":true,
"mergeable":false,
"urls":{
"rowTemplate":"/services/data/v59.0/sobjects/AcceptedEventRelation/{ID}",
"describe":"/services/data/v59.0/sobjects/AcceptedEventRelation/describe",
"sobject":"/services/data/v59.0/sobjects/AcceptedEventRelation"
},
"createable":false,
"feedEnabled":false,
"retrieveable":true,
"name":"AcceptedEventRelation",
"customSetting":false,
"labelPlural":"Accepted Event Relations",
"triggerable":false
},
.
.
],
"encoding":"UTF-8"
}
describeSObject
To get metadata (such as name, label, and fields, including the field properties) for a specific object type, use salesforcerest.describeSObject and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/describe/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object type whose metadata you want to retrieve. | Yes | Account |
Sample configuration
<salesforcerest.describeSObject>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.describeSObject>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
}
Sample Response
{
"updateable":true,
"activateable":false,
"childRelationships":[
{
"relationshipName":"ChildAccounts",
"field":"ParentId",
"deprecatedAndHidden":false,
"childSObject":"Account",
"cascadeDelete":false,
"restrictedDelete":false
},
{
"relationshipName":"AccountCleanInfos",
"field":"AccountId",
"deprecatedAndHidden":false,
"childSObject":"AccountCleanInfo",
"cascadeDelete":true,
"restrictedDelete":false
},
.
]
}
listAvailableApiVersion
To retrieve a list of summary information about each REST API version that is currently available, use salesforcerest.listAvailableApiVersion. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/
Sample configuration
<salesforcerest.listAvailableApiVersion/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample Response
{
"output":"[
{\"label\":\"Winter '11\",\"url\":\"/services/data/v20.0\",\"version\":\"20.0\"},
.
.
]"
}
listOrganizationLimits
To retrieve the limit information for your organization, use salesforcerest.listOrganizationLimits. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/limits/
Sample configuration
<salesforcerest.listOrganizationLimits/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample Response
{
"ActiveScratchOrgs": {
"Max": 3,
"Remaining": 3
},
"AnalyticsExternalDataSizeMB": {
"Max": 40960,
"Remaining": 40960
},
"ConcurrentAsyncGetReportInstances": {
"Max": 200,
"Remaining": 200
},
.
.
}
listResourcesByApiVersion
To retrieve the resources that are available in the specified API version, use salesforcerest.listResourcesByApiVersion. You can then get the details of those resources. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/
Sample configuration
<salesforcerest.listResourcesByApiVersion/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample Response
{
"tooling":"/services/data/v59.0/tooling",
"folders":"/services/data/v59.0/folders",
"eclair":"/services/data/v59.0/eclair",
"prechatForms":"/services/data/v59.0/prechatForms",
"chatter":"/services/data/v59.0/chatter",
"tabs":"/services/data/v59.0/tabs",
"appMenu":"/services/data/v59.0/appMenu",
"quickActions":"/services/data/v59.0/quickActions",
"queryAll":"/services/data/v59.0/queryAll",
"commerce":"/services/data/v59.0/commerce",
.
}
sObjectBasicInfo
To retrieve the individual metadata for the specified object, use salesforcerest.sObjectBasicInfo. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object type whose metadata you want to retrieve. | Yes | Account |
Sample configuration
<salesforcerest.sObjectBasicInfo>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.sObjectBasicInfo>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
}
Sample Response
{
"objectDescribe":{
"updateable":true,
"activateable":false,
"deprecatedAndHidden":false,
"layoutable":true,
"custom":false,
"deletable":true,
"replicateable":true,
"undeletable":true,
"label":"Account",
"keyPrefix":"001",
"searchable":true,
"queryable":true,
"mergeable":true,
"urls":{
"compactLayouts":"/services/data/v59.0/sobjects/Account/describe/compactLayouts",
"rowTemplate":"/services/data/v59.0/sobjects/Account/{ID}"
},
"createable":true,
"feedEnabled":true,
"retrieveable":true,
"name":"Account",
"customSetting":false,
"labelPlural":"Accounts",
"triggerable":true
},
.
}
sObjectPlatformAction
To retrieve the description of the PlatformAction, use salesforcerest.sObjectPlatformAction. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/PlatformAction
Sample configuration
<salesforcerest.sObjectPlatformAction/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample Response
{
"objectDescribe":{
"updateable":false,
"activateable":false,
"deprecatedAndHidden":false,
"layoutable":false,
"custom":false,
"deletable":false,
"replicateable":false,
"undeletable":false,
"label":"Platform Action",
"keyPrefix":"0JV",
"searchable":false,
"queryable":true,
"mergeable":false,
"urls":{
"rowTemplate":"/services/data/v59.0/sobjects/PlatformAction/{ID}",
"describe":"/services/data/v59.0/sobjects/PlatformAction/describe",
"sobject":"/services/data/v59.0/sobjects/PlatformAction"
},
"createable":false,
"feedEnabled":false,
"retrieveable":false,
"name":"PlatformAction",
"customSetting":false,
"labelPlural":"Platform Actions",
"triggerable":false
},
"recentItems":[
]
}
sObjectRows
To retrieve details of a specific record, use salesforcerest.sObjectRows. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{sObjectName}/{rowId}/
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectName | The object type of the record. | Yes | Account |
rowId | The ID of the record whose details you want to retrieve. | Yes | 00128000005YjDnAAK |
Sample configuration
<salesforcerest.sObjectRows>
<sObjectName>{$ctx:sObjectName}</sObjectName>
<rowId>{$ctx:rowId}</rowId>
</salesforcerest.sObjectRows>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName":"Account",
"rowId":"00128000005YjDnAAK",
}
Sample Response
{
"AccountNumber" : "CD656092",
"BillingPostalCode" : "27215"
}
sObjectRowsByExternalId
To retrieve records with a specific external ID, use salesforcerest.sObjectRowsByExternalId. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/{customObject}/{externalIdField}/{externalIdFieldValue}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
customObject | The type of the custom object. | Yes | Merchandise__c |
externalIdField | Specific object ID to access the record. | Yes | MerchandiseExtID__c |
externalIdFieldValue | The value of the ExternalIdField. | Yes | 123 |
Sample configuration
<salesforcerest.sObjectRowsByExternalId>
<customObject>{$ctx:customObject}</customObject>
<externalIdField>{$ctx:externalIdField}</externalIdField>
<externalIdFieldValue>{$ctx:externalIdFieldValue}</externalIdFieldValue>
</salesforcerest.sObjectRowsByExternalId>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"customObject":"Merchandise__c",
"externalIdField":"MerchandiseExtID__c",
"externalIdFieldValue": "123"
}
Sample Response
{
"attributes" : {
"type" : "Merchandise__c",
"url" : "/services/data/v59.0/sobjects/Merchandise__c/a00D0000008oWP8IAM"
},
"Id" : "a00D0000008oWP8IAM",
"OwnerId" : "005D0000001KyEIIA0",
"IsDeleted" : false,
"Name" : "Example Merchandise",
"CreatedDate" : "2012-07-12T17:49:01.000+0000",
"CreatedById" : "005D0000001KyEIIA0",
"LastModifiedDate" : "2012-07-12T17:49:01.000+0000",
"LastModifiedById" : "005D0000001KyEIIA0",
"SystemModstamp" : "2012-07-12T17:49:01.000+0000",
"Description__c" : "Merch with external ID",
"Price__c" : 10.0,
"Total_Inventory__c" : 100.0,
"Distributor__c" : null,
"MerchandiseExtID__c" : 123.0
}
returnHeadersOfSObjectRowsByExternalId
To retrieve headers that are returned by sending a request to the sObjectRowsByExternalId operation, use salesforcerest.returnHeadersOfSObjectRowsByExternalId. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/{customObject}/{externalIdField}/{externalIdFieldValue}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
customObject | The type of the custom object. | Yes | Merchandise__c |
externalIdField | Specific object ID to access the record. | Yes | MerchandiseExtID__c |
externalIdFieldValue | The value of the ExternalIdField. | Yes | 123 |
Sample configuration
<salesforcerest.returnHeadersOfSObjectRowsByExternalId>
<customObject>{$ctx:customObject}</customObject>
<externalIdField>{$ctx:externalIdField}</externalIdField>
<externalIdFieldValue>{$ctx:externalIdFieldValue}</externalIdFieldValue>
</salesforcerest.returnHeadersOfSObjectRowsByExternalId>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"customObject":"Merchandise__c",
"externalIdField":"MerchandiseExtID__c",
"externalIdFieldValue": "123"
}
viewRelevantItems
To retrieve the current user’s most relevant items that include up to 50 of the most recently viewed or updated records for each object in the user’s global search scope, use salesforcerest.viewRelevantItems. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/relevantItems?lastUpdatedId={lastUpdatedId}&sobjects={sobjects}&{nameOfLastUpdatedIdParamPerSObject}.lastUpdatedId={valueOfLastUpdatedIdParamPerSObject}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
lastUpdatedId | The last updated Id. It compares the entire current list of relevant items to a previous version, if available. | No | 102959935 |
sobjects | The name for one or more sObjects to scope the results to a particular object or set of objects. | No | Account,User |
nameOfLastUpdatedIdParamPerSObject | The parameter name of the last updated id for a particular object in the format of sobject.lastUpdatedId. Ex: Account.lastUpdatedId. | No | Account |
valueOfLastUpdatedIdParamPerSObject | The value of the last updated id for a particular object parameter. | No | 102959935 |
Sample configuration
<salesforcerest.viewRelevantItems>
<lastUpdatedId>{$ctx:lastUpdatedId}</lastUpdatedId>
<sobjects>{$ctx:sobjects}</sobjects>
<nameOfLastUpdatedIdParamPerSObject>{$ctx:nameOfLastUpdatedIdParamPerSObject}</nameOfLastUpdatedIdParamPerSObject>
<valueOfLastUpdatedIdParamPerSObject>{$ctx:valueOfLastUpdatedIdParamPerSObject}</valueOfLastUpdatedIdParamPerSObject>
</salesforcerest.viewRelevantItems>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sobjects":"Account,User",
"nameOfLastUpdatedIdParamPerSObject": "Account",
"valueOfLastUpdatedIdParamPerSObject": "102959935"
}
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/relevantItems?sobjects=Account,User&Account.lastUpdatedId=102959935
Sample Response
[ {
"apiName" : "Account",
"key" : "001",
"label" : "Accounts",
"lastUpdatedId" : "193640553",
"recordIds" : [ "001xx000003DWsT" ]
} ]
Search¶
search
To search for records, use salesforcerest.search and specify the search string. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/search/?q={searchString}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
searchString | The SQL query to use to search for records. | Yes | sample string |
Sample configuration
<salesforcerest.search>
<searchString>{$ctx:searchString}</searchString>
</salesforcerest.search>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"searchString": "FIND {map*} IN ALL FIELDS RETURNING Account (Id, Name), Contact, Opportunity, Lead",
}
Sample Response
{
{"output":"[{\"attributes\":{\"type\":\"Account\",\"url\":\"/services/data/v59.0/sobjects/Account/00128000005dMcSAAU\"},\"Id\":\"00128000005dMcSAAU\",\"Name\":\"GenePoint\"}]"}
}
searchScopeAndOrder
To retrieve the search scope and order for the currently logged-in user, use salesforcerest.searchScopeAndOrder. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/search/scopeOrder
Sample configuration
<salesforcerest.searchScopeAndOrder/>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
}
Sample Response
{
"output":"[]"
}
searchResultLayout
To retrieve the search result layouts for one or more sObjects, use salesforcerest.searchResultLayout and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/search/layout/?q={sObjectNameList}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
sObjectNameList | A comma-delimited list of the objects whose search result layouts you want to retrieve. | Yes | Account,User |
Sample configuration
<salesforcerest.searchResultLayout>
<sObjectNameList>{$ctx:sObjectNameList}</sObjectNameList>
</salesforcerest.searchResultLayout>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectNameList": "Account,User",
}
Sample Response
{
"output":"[{\"errorMsg\":null,\"label\":\"Search Results\",\"limitRows\":25,\"objectType\":\"Account\",\"searchColumns\":[{\"field\":\"Account.Name\",\"format\":null,\"label\":\"Account Name\",\"name\":\"Name\"},{\"field\":\"Account.Site\",\"format\":null,\"label\":\"Account Site\",\"name\":\"Site\"},.]"
}
searchSuggestedRecords
To return a list of suggested records whose names match the user’s search string, use salesforcerest.searchSuggestedRecords and specify the following properties. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/search/?q={searchString}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
stringForSearch | The object type that the search is scoped to. | Yes | hari |
sObjectName | The SOQL query to execute the search. | Yes | Account |
Sample configuration
<salesforcerest.searchSuggestedRecords>
<stringForSearch>{$ctx:stringForSearch}</stringForSearch>
<sObjectName>{$ctx:sObjectName}</sObjectName>
</salesforcerest.searchSuggestedRecords>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"sObjectName": "Account",
"stringForSearch": "hari",
}
Sample Response
{
{"autoSuggestResults":[],"hasMoreResults":false}
}
Survey¶
addOrChangeTranslationOfSurveyField
To add or change the translated value of the survey field if a survey field can be translated or is already translated into a particular language, use salesforcerest.addOrChangeTranslationOfSurveyField and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/localizedvalue/record/{developerName}/{language}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
developerName | The developer name of the flow field. | Yes | Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel |
language | The translated language of the flow field. | Yes | zh_CN |
fieldAndValue | The .json format property used to add or change the translation of survey field. | Yes | { "value": "China" } |
Sample configuration
<salesforcerest.addOrChangeTranslationOfSurveyField>
<developerName>{$ctx:developerName}</developerName>
<language>{$ctx:language}</language>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.addOrChangeTranslationOfSurveyField>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel",
"language": "zh_CN",
"fieldAndValue": {
"value": "China"
}
}
Sample response
{
"createdBy": "005xxx",
"createdDate": "2018-09-14T00:10:30Z",
"developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel",
"language": "zh_CN",
"value": "中國",
"isOutOfDate": true
}
addOrUpdateTranslatedValueOfMultipleSurveyFieldsInOneOrMoreLanguages
If one or more survey fields can be translated or are already translated, to add or update the translated values of the survey fields in the languages into which survey fields can be translated, use salesforcerest.addOrUpdateTranslatedValueOfMultipleSurveyFieldsInOneOrMoreLanguages and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/localizedvalue/records/upsert
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
fieldAndValue | The .json format property used to add or update the translated value of multiple survey fields in one or more languages. | Yes | [ { "developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel", "language": "en_US", "value": "China" }, { "developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel", "language": "zh_CN", "value": "中國" } ] |
Sample configuration
<salesforcerest.addOrUpdateTranslatedValueOfMultipleSurveyFieldsInOneOrMoreLanguages>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.addOrUpdateTranslatedValueOfMultipleSurveyFieldsInOneOrMoreLanguages>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"fieldAndValue": [
{
"developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel",
"language": "en_US",
"value": "China"
},
{
"developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel",
"language": "zh_CN",
"value": "中國"
}
]
}
Sample response
{
"output":
"[
{
\"createdBy\": \"005xxx\",
\"createdDate\": \"2018-09-14T00:10:30Z\",
\"developerName\": \"Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel\",
\"language\": \"en_US\",
\"value\": \"China\",
\"isOutOfDate\": false
},
...
]"
}
getTranslatedValueOfSurveyField
To retrieve the translated value of the survey field after a survey field is translated into a particular language, use salesforcerest.getTranslatedValueOfSurveyField and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/localizedvalue/record/{developerName}/{language}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
developerName | The developer name of the flow field. | Yes | Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel |
language | Language of the translated field. Possible values are da, nl_NL, fi, fr, de. | Yes | zh_CN |
Sample configuration
<salesforcerest.getTranslatedValueOfSurveyField>
<developerName>{$ctx:developerName}</developerName>
<language>{$ctx:language}</language>
</salesforcerest.getTranslatedValueOfSurveyField>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel",
"language": "zh_CN"
}
Sample response
{
"createdBy": "005xxx",
"createdDate": "2018-09-14T00:10:30Z",
"developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel",
"language": "zh_CN",
"value": "中國",
"isOutOfDate": true
}
getTranslatedValuesOfMultipleSurveyFieldsInOneOrMoreLanguages
To retrieve the translated values of multiple survey fields in the translated languages after survey fields are translated into one or more languages, use salesforcerest.getTranslatedValuesOfMultipleSurveyFieldsInOneOrMoreLanguages and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/localizedvalue/records/get
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
fieldAndValue | The .json format property used to get the translated value of multiple survey fields in one or more languages. | Yes | [ { "developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel", "language": "en_US" }, { "developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel", "language": "zh_CN" } ] |
Sample configuration
<salesforcerest.getTranslatedValuesOfMultipleSurveyFieldsInOneOrMoreLanguages>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.getTranslatedValuesOfMultipleSurveyFieldsInOneOrMoreLanguages>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"fieldAndValue": [
{
"developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel",
"language": "en_US"
},
{
"developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel",
"language": "zh_CN"
}
]
}
Sample response
{
"output":
"[
{
\"createdBy\": \"005xxx\",
\"createdDate\": \"2018-09-14T00:10:30Z\",
\"developerName\": \"Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel\",
\"language\": \"en_US\",
\"value\": \"China\",
\"isOutOfDate\": false
},
...
]"
}
deleteTheTranslatedValueOfSurveyField
To delete the translated value of the survey field after a survey field is translated into a particular language, use salesforcerest.deleteTheTranslatedValueOfSurveyField and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API DELETE /services/data/vXX.X/localizedvalue/record/{developerName}/{language}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
developerName | The developer name of the flow field. | Yes | Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel |
language | Language of the translated field. Possible values are da, nl_NL, fi, fr, de. | Yes | zh_CN |
Sample configuration
<salesforcerest.deleteTheTranslatedValueOfSurveyField>
<developerName>{$ctx:developerName}</developerName>
<language>{$ctx:language}</language>
</salesforcerest.deleteTheTranslatedValueOfSurveyField>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel",
"language": "zh_CN"
}
deleteTranslatedValueOfMultipleSurveyFieldsInOneOrMoreLanguages
To delete the translated values of multiple survey fields after survey fields are translated into one or more languages, use salesforcerest.deleteTranslatedValueOfMultipleSurveyFieldsInOneOrMoreLanguages and specify the following properties. This resource does not require the use of an external ID field. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/localizedvalue/records/delete
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
fieldAndValue | The .json format property used to get the translated value of multiple survey fields in one or more languages. | Yes | [ { "developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel", "language": "en_US" }, { "developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel", "language": "zh_CN" } ] |
Sample configuration
<salesforcerest.deleteTranslatedValueOfMultipleSurveyFieldsInOneOrMoreLanguages>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.deleteTranslatedValueOfMultipleSurveyFieldsInOneOrMoreLanguages>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"fieldAndValue": [
{
"developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel",
"language": "en_US"
},
{
"developerName": "Flow.Flow.MyFlow.1.Choice.Choice_1_Master.InputLabel",
"language": "zh_CN"
}
]
}
Users¶
getUserInformation
To retrieve information about a specific user, use salesforcerest.getUserInformation and specify the following property.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/User/{userId}
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
userId | The ID of the user whose information you want to retrieve. | Yes | 00528000000yl7j |
Sample configuration
<salesforcerest.getUserInformation>
<userId>{$ctx:userId}</userId>
</salesforcerest.getUserInformation>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"userId": "00528000000yl7j",
}
Sample Response
{
"ProfileId":"00e28000000xIEQAA2",
"LastModifiedDate":"2016-11-29T05:40:45.000+0000",
"Address":{
"country":"LK",
"city":null,
"street":null,
"latitude":null,
"postalCode":null,
"geocodeAccuracy":null,
"state":null,
"longitude":null
},
"LanguageLocaleKey":"en_US",
"EmailPreferencesAutoBccStayInTouch":false
.
.
}
getUserPasswordExpirationStatus
To retrieve information about a specific user, use salesforcerest.getUserPasswordExpirationStatus and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/User/{userId}/password
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
userId | The ID of the user whose information you want to retrieve. | Yes | 00528000000yl7j |
Sample configuration
<salesforcerest.getUserPasswordExpirationStatus>
<userId>{$ctx:userId}</userId>
</salesforcerest.getUserPasswordExpirationStatus>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"userId": "00528000000yl7j",
}
Sample Response
{
"isExpired" : false
}
Example error response if session has insufficient privileges
{
"message" : "You do not have permission to view this record.",
"errorCode" : "INSUFFICIENT_ACCESS"
}
setPassword
To set new password for Salesforce account for a specific User, use salesforcerest.setPassword and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/sobjects/User/{userId}/password
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
userId | The ID of the user whose information you want to retrieve. | Yes | 00528000000yl7j | fieldAndValue | The .json format property used to submit, approve, or reject the approvals. | Yes | { "NewPassword" : "myNewPassword1234" } |
Sample configuration
<salesforcerest.setPassword>
<userId>{$ctx:userId}</userId>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.setPassword>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"userId": "00528000000yl7j",
"fieldAndValue": {
"NewPassword" : "myNewPassword1234"
}
}
Sample Response
No response body on successful password change, HTTP status code 204 returned.
Example error response if new password does not meet organization password requirements
{
"message" : "Your password must have a mix of letters and numbers.",
"errorCode" : "INVALID_NEW_PASSWORD"
}
resetPassword
To reset the password of a specific user, use salesforcerest.resetPassword and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API DELETE /services/data/vXX.X/sobjects/User/{userId}/password
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
userId | The ID of the user whose information you want to retrieve. | Yes | 00528000000yl7j |
Sample configuration
<salesforcerest.getUserInformation>
<userId>{$ctx:userId}</userId>
</salesforcerest.getUserInformation>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"userId": "00528000000yl7j",
}
Sample Response
{
"NewPassword" : "myNewPassword1234"
}
returnHeadersForUserPassword
To retrieve only the headers that are returned by sending a GET request to the sObject User Password resource, use salesforcerest.returnHeadersForUserPassword and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/User/{userId}/password
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
userId | The ID of the user whose information you want to retrieve. | Yes | 00528000000yl7j |
Sample configuration
<salesforcerest.returnHeadersForUserPassword>
<userId>{$ctx:userId}</userId>
</salesforcerest.returnHeadersForUserPassword>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"userId": "00528000000yl7j",
}
getSelfServiceUserPasswordExpirationStatus
To retrieve a self-service user’s password expiration status based on the specified user ID, use salesforcerest.getSelfServiceUserPasswordExpirationStatus and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API GET /services/data/vXX.X/sobjects/SelfServiceUser/{selfServiceUserId}/password
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
selfServiceUserId | The Id of the self-service user. | Yes | 00528000000yl7j |
Sample configuration
<salesforcerest.getSelfServiceUserPasswordExpirationStatus>
<selfServiceUserId>{$ctx:selfServiceUserId}</selfServiceUserId>
</salesforcerest.getSelfServiceUserPasswordExpirationStatus>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"selfServiceUserId": "00528000000yl7j",
}
Sample Response
{
"isExpired" : false
}
Example error response if session has insufficient privileges
{
"message" : "You do not have permission to view this record.",
"errorCode" : "INSUFFICIENT_ACCESS"
}
setSelfServiceUserPassword
To set a self-service user’s password based on the specified user ID, use salesforcerest.setSelfServiceUserPassword and specify the following property. The password provided in the request body replaces the user’s existing password. See the related API documentation for more information.
Equivalent to Salesforce REST API POST /services/data/vXX.X/sobjects/SelfServiceUser/{selfServiceUserId}/password
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
selfServiceUserId | The ID of the self service user whose password needs to be set. | Yes | 00528000000yl7j | fieldAndValue | The .json format property used to submit, approve, or reject the approvals. | Yes | { "NewPassword" : "myNewPassword1234" } |
Sample configuration
<salesforcerest.setSelfServiceUserPassword>
<selfServiceUserId>{$ctx:selfServiceUserId}</selfServiceUserId>
<fieldAndValue>{$ctx:fieldAndValue}</fieldAndValue>
</salesforcerest.setSelfServiceUserPassword>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"selfServiceUserId": "00528000000yl7j",
"fieldAndValue": {
"NewPassword" : "myNewPassword1234"
}
}
Sample Response
No response body on successful password change, HTTP status code 204 returned.
Example error response if new password does not meet organization password requirements
{
"message" : "Your password must have a mix of letters and numbers.",
"errorCode" : "INVALID_NEW_PASSWORD"
}
resetSelfServiceUserPassword
To reset password for Salesforce account for a specific self-service, use salesforcerest.resetSelfServiceUserPassword and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API DELETE /services/data/vXX.X/sobjects/SelfServiceUser/{selfServiceUserId}/password
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
selfServiceUserId | The ID of the self service user whose password needs to be reset. | Yes | 00528000000yl7j |
Sample configuration
<salesforcerest.resetSelfServiceUserPassword>
<selfServiceUserId>{$ctx:selfServiceUserId}</selfServiceUserId>
</salesforcerest.resetSelfServiceUserPassword>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"selfServiceUserId": "00528000000yl7j",
}
Sample Response
{
"NewPassword" : "myNewPassword1234"
}
returnHeadersForSelfServiceUserPassword
To retrieve only the headers that are returned by sending a GET request to the sObject Self-Service User Password resource, use salesforcerest.returnHeadersForSelfServiceUserPassword" and specify the following property. See the related API documentation for more information.
Equivalent to Salesforce REST API HEAD /services/data/vXX.X/sobjects/SelfServiceUser/{selfServiceUserId}/password
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
selfServiceUserId | The Id of the self-service user. | Yes | 00528000000yl7j |
Sample configuration
<salesforcerest.returnHeadersForSelfServiceUserPassword>
<selfServiceUserId>{$ctx:selfServiceUserId}</selfServiceUserId>
</salesforcerest.returnHeadersForSelfServiceUserPassword>
Sample request
{
"accessToken":"XXXXXXXXXXXX (Replace with your access token)",
"apiUrl":"https://(your_instance).salesforce.com",
"hostName": "https://login.salesforce.com",
"apiVersion": "v59.0",
"selfServiceUserId": "00528000000yl7j",
}
Reports¶
getReport
To retrieve information about a report, use salesforcerest.getReport and specify the following property. See the related API documentation for more information.
Parameter Name | Description | Required | Sample Value |
---|---|---|---|
reportId | The ID of the report that you want to retrieve. | Yes | 00O8d000004MWaGEAW |
Sample configuration
<salesforcerest.getReport>
<reportId>{$ctx:reportId}</reportId>
</salesforcerest.getReport>
Sample request
{
"reportId": "00O8d000004MWaGEAW",
}
Sample Response
{
"attributes": {
"describeUrl": "/services/data/v55.0/analytics/reports/00O8d000004MWaGEAW/describe",
"instancesUrl": "/services/data/v55.0/analytics/reports/00O8d000004MWaGEAW/instances",
"reportId": "00O8d000004MWaGEAW",
"reportName": "SampleReport",
"type": "Report"
},
"allData": true,
"factMap": {
"T!T": {
"aggregates": [
{
"label": "13",
"value": 13
}
],
"rows": [
{
"dataCells": [
{
"label": "Customer - Direct",
"recordId": "0018d00000FgQblAAF",
"value": "Customer - Direct"
},
{
"label": "Warm",
"recordId": "0018d00000FgQblAAF",
"value": "Warm"
},
{
"label": "-",
"recordId": "0018d00000FgQblAAF",
"value": null
},
{
"label": "16/08/2022",
"value": "2022-08-15"
},
.
.
.
]
}
]
}
}
}