Inserting Lists of Objects, Across the APIs, Salesforce REST API Composite Tree (in English)
Updated 2026-11-07
What's changed since the video
Each change is dated and checked against Salesforce's own documentation.
- The tree fails as a whole. The video says you can choose all or none for a tree. Salesforce's guide says it always works that way: "If an error occurs while creating a record, the entire request fails" (same page). The all-or-none choice belongs to collections and composite (video 1.14).
- Sign in without a password in the request. The demo signs in to Postman with the OAuth username-password flow. Salesforce blocks that flow in orgs created in Summer '26 and later, and stops supporting it for connected apps on February 20, 2027 (Retirement of OAuth 2.0 Username-Password Flow for Connected Apps (Release Update), Salesforce Help, checked 2026-11-07). On your own bench, sign in with the client credentials flow or the web server flow with PKCE, through an External Client App (chapter 13, module 8).
- A newer API version. The video calls version 59 the latest. Today's is 68.0 (Winter '27), and the oldest versions are closing: 31.0 to 40.0 are deprecated in Summer '27 and retired in Summer '28, when a REST call to them returns 410 GONE (Salesforce Platform API Versions 31.0 through 40.0 Retirement, Salesforce Help, checked 2026-11-07).
Still right
- A parent and its children in one call, linked by reference IDs.
- The tree's limits hold: "Up to a total of 200 records across all trees" (sObject Tree, checked 2026-11-07).
- A duplicate rule stopped the demo, and that's a real lesson: the org's rules still apply to every record a call creates.
All videos in this series: 整合架構
只有在你點選時,影片才會從 YouTube 載入。