REST API

REST API includes changed resources and a generally available resource for making several requests at once.

Make Several Requests at Once with the Composite Resource (Generally Available)

Imagine you’re writing a mobile app. To cut down on the number of round trips between your client and Salesforce, you want to make several REST API requests in a single call. You consider the Batch resource, but Batch doesn’t let you pass information between subrequests. Are you out of luck? Not anymore! The Composite resource lets you make several requests in a single call and provides a way to reference the results of one subrequest in later subrequests.
Composite is supported for the following resources.
  • All sObject resources (vXX.X/sobjects/)
  • The Query resource (vXX.X/query/?q=soql)
  • The QueryAll resource (vXX.X/queryAll/?q=soql)

You can have up to 25 subrequests in a single call. Up to 10 of these subrequests can be query operations, including Query, QueryAll, and “Query More” requests to obtain the next batch of query results.

Composite
/vXX.X/composite

New Resources: Flows and Flow Interviews (Pilot)

Have you ever wanted to build your own runtime experience for Visual Workflow? Here’s your chance. We’re providing two resources to describe flows and three resources to describe and manipulate interviews. If you’re an existing pilot customer, nothing has changed since the last release.
Note

Note

We provide Flow Runtime REST API to selected customers through a pilot program that requires agreement to specific terms and conditions. To be nominated to participate in the program, contact Salesforce. Pilot programs are subject to change, and we can’t guarantee acceptance. Flow Runtime REST API isn’t generally available unless or until Salesforce announces its general availability in documentation or in press releases or public statements. We can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features. You can provide feedback and suggestions for Flow Runtime REST API in the IdeaExchange.

Flows
Lists active flow definitions in your org.
/vXX.X/process/flows
Specific Flow
Lists summary information about a specific flow.
/vXX.X/process/flows/FlowName
Paused Interviews
Lists paused interviews that the running user can resume.
/vXX.X/process/interviews
New Interview
Starts a flow interview.
/vXX.X/process/interviews/FlowName
Specific Interview
Continues, pauses, or finishes an in-progress interview, or resumes a paused interview.
/vXX.X/process/interviews/FlowName/guid

Changed Resource: Search Suggested Records

The where clause now supports specifying multiple objects. Any object-specific where clause overrides the global where clause.

Here’s the new example with a global and object-specific where clause.

...search/suggestions?q=Smith 
&sobject=Account,Contact,KnowledgeArticleVersion,CollaborationGroup,Topic,FeedItem 
// Specifies a global where clause (to filter Account and Contact)
&where=name%20LIKE%20%27Smith%25%27 
// Overrides the global where clause for Knowledge Article (filtering by PublishStatus and Language is required for KnowledgeArticle)
&knowledgearticleversion.where=PublishStatus='online'+and+language='en_US'
// Overrides the global where clause for Topic
&topic.where=networkid=<1234567891> 
// Overrides the global where clause for CollaborationGroup
&collaborationgroup.where=networkid=<1234567891> 
// FeedItem-Question doesn't support where clauses, but we can filter the type and networkId
&type=question 
&networkId==<1234567891>

Removed Resource: FlexiPage

The FlexiPage resource has been deprecated in API version 39.0 and has been removed from all previous API versions as well.

The FlexiPage resource returned a list of Lightning Pages and their details.

The /vXX.X/flexiPage/ REST endpoint has been removed as part of this deprecation.

You can still get FlexiPage metadata via the Metadata and Tooling APIs, however.