Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for updateOnly option for data loads using Batch upserts #941

Open
paustint opened this issue Jun 15, 2024 · 0 comments
Open
Labels
enhancement New feature or request

Comments

@paustint
Copy link
Contributor

Describe the problem you are trying to solve

With API version 61.0, UPSERT requests using REST API can opt to fail instead of creating a new record. This would be a nice option to expose to users when using the Batch API.

https://developer.salesforce.com/docs/atlas.en-us.250.0.api_rest.meta/api_rest/resources_sobject_upsert_patch.htm
https://developer.salesforce.com/docs/atlas.en-us.250.0.api_rest.meta/api_rest/resources_composite_sobjects_collections_upsert.htm

https://help.salesforce.com/s/articleView?id=release-notes.rn_api_new_updateonly_param.htm&release=250&type=5

Update Records Using External IDs in REST API

You can now update a record using the value of its external ID with the new updateOnly parameter in REST API. Previously, you could only upsert a record using its external ID.

Where: This change affects API version 61.0 and later.

How: To prevent creating a new record if the target record can’t be found or doesn’t exist, add the updateOnly parameter to a URL that executes an upsert operation. You can also use URLs with the updateOnly parameter in composite REST API and composite graph REST API.

@paustint paustint added the enhancement New feature or request label Jun 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant