Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, 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.

Composite Response Body

Describes the result of a /composite request.

Composite Results

Properties

Name Type Description
compositeResponse Composite Subrequest Result[] Collection of subrequest results

JSON Example

1{
2   "compositeResponse" : [{
3      Composite Subrequest Result
4      },{
5      Composite Subrequest Result
6      },{
7      Composite Subrequest Result
8   }]
9}

Composite Subrequest Result

Properties

Name Type Description
body The type depends on the response type of the subrequest. The response body of this subrequest. If the subrequest returns an error, the body includes the error code and message.
httpHeaders Map<String, String> Response headers and their values for this subrequest. The /composite resource doesn’t support the Content-Length header, so subrequest responses don’t include this header and neither does the top-level response.
httpStatusCode Integer An HTTP status code for this subrequest. If allOrNone is set to true in the composite request and a subrequest returns an error, all other subrequests return the 400 HTTP status code.
referenceID String The reference ID specified in the subrequest. Use this property to associate subrequests with their results.

JSON Example

1{
2   "body" : {
3      "id" : "001R00000033I6AIAU",
4      "success" : true,
5      "errors" : [ ]
6   },
7   "httpHeaders" : {
8      "Location" : "/services/data/v40.0/tooling/sobjects/apexclassmember/001R00000033I6AIAU"
9   },
10   "httpStatusCode" : 201,
11   "referenceId" : "apexclassmember_reference_id"
12}