Look I’m not entirely sure if this works, or if it needs Mutipart datais the absolute best way to replace Attachments when data is coming in from the API, but it works for this simple image and it works for a 300kb docx file. I probably need to do way more extensive testing on it.
...
for the Composite API endpoint.
Creating the Case
Remember you can have 25 API calls within one Composite API call so that means you could create the case and 8 files (if that’s all you are doing in the call). NOTE: I don’t think you could do this with the new Composite Graph because that doesn’t allow GETs apparently and we need to GET the ContentDocumentId.
Code Block |
---|
{
"allOrNone" : true,
"compositeRequest" : [
{"method" : "POST",
"url" : "/services/data/v49.0/sobjects/Case",
"referenceId": "refCase",
"body":
{
"Subject": "A Case",
"Type": "Case",
"Status": "New Request"
}
},
{"method" : "POST",
"url" : "/services/data/v49.0/sobjects/ContentVersion",
"referenceId": "refCV",
"body":
{
"Title": "kitten.jpg",
"PathOnClient": "kitten.jpg",
"VersionData": "/9j/4AAQSkZJRgABAQAAAQABAAD//gA7Q1JFQVRPUjogZ2QtanBlZyB2MS4wICh1c2luZyBJSkcgSlBFRyB2NjIpLCBxdWFsaXR5ID0gODUK/9sAQwAFAwQEBAMFBAQEBQUFBgcMCAcHBwcPCwsJDBEPEhIRDxERExYcFxMUGhURERghGBodHR8fHxMXIiQiHiQcHh8e/9sAQwEFBQUHBgcOCAgOHhQRFB4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4e/8AAEQgBHwGYAwEiAAIRAQMRAf/EAB8AAAEFAQEBAQEBAAAAAAAAAAABAgMEBQYHCAkKC//EALUQAAIBAwMCBAMFBQQEAAABfQECAwAEEQUSITFBBhNRYQcicRQygZGhCCNCscEVUtHwJDNicoIJChYXGBkaJSYnKCkqNDU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6g4SFhoeIiYqSk5SVlpeYmZqio6Slpqeoqaqys7S1tre4ubrCw8TFxsfIycrS09TV1tfY2drh4uPk5ebn6Onq8fLz9PX29/j5+v/EAB8BAAMBAQEBAQEBAQEAAAA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V6+QTW4iAGT1Na+hxiOxVMDigDHluTZr5UijYR3qtp1uZrz7XDgovJG3kVL4zUGJtgwaveD0Eeih3+8epoAvHUUAUEc9DV5SGUMOhGawo5VmutgHIPpW6owoHoKAEJPmAY4xTqrwSs9wwxwKsUAGaKgt2ZpZN3QHim3chR1GetAC+QGufMPQVYqG1YsCTTrgkJkHHNAElI7BRk0KcqD7VV1EsFXb60AT7Q53n8KrXt0YVKtgVagOYlPtXMeKJ3WU4NAElqi3F7u45NbN2qQW4xXOaC7BtzZ5rU1O6zEFGaANDS5N8Rq5WZoOfJOe9adABRRSMwUZoAWgVCWZ+B0qYcCgAopsjbVzRExZMmgB1ISAcUtRBTvzQBLSMwUZNLWfqM5VSBxigBWm3y8etXkGFGaxdNYySZPrW3QBBcgD8arvGGX3NSXTZlCjtTk4XNAEQt1VMkVzPie6W3ibBxit/UrwRRNXlnj3V28t1BPegDmtc8UNHdMqycA+tZc/jFwn+sP51xGvXrvcsc8mufubuTpuNAHpg8YyM4xKfzorzO1kkPOT+dFAH/9k="
}
},
{"method" : "GET",
"url" :"/services/data/v49.0/query?q=Select+ContentDocumentId+from+ContentVersion+where+id+=+'@{refCV.id}'",
"referenceId" : "refCVInfo"
},
{"method" : "POST",
"url" : "/services/data/v49.0/sobjects/ContentDocumentLink",
"referenceId": "refCDL",
"body":
{"ContentDocumentId": "@{refCVInfo.records[0].ContentDocumentId}",
"LinkedEntityId": "@{refCase.id}",
"Visibility": "AllUsers"
}
}
]
} |
Data
What is PathOnClient you ask? Well from the docs
FileType
is defined by eitherContentUrl
for links orPathOnClient
for documents, but not both
So it’s just a way of determining the file type.
Other fields are in the documentation.
When you upload a document from your local drive using the Data Loader, you must specify the actual path in both
VersionData
andPathOnClient
.VersionData
identifies the location and extracts the format andPathOnClient
identifies the type of document being uploaded.
That doesn’t appear to be required with the API. But the API call did not work without PathOnClient, which is understandable.
This code is only referring to Files on records. Adding files to document libraries might be different. But it should just be changing the ID of the ContentVersionLink LinkedEntityId
For ContentVersionLink the record must be from an Object that has Feed Tracking enabled.
The Visibility as to be set to AllUsers because setting it to InternalUsers gives an error “Visibility InternalUsers is not permitted for this linked record”. This KB Article helps to understand it.
The Title can be anything you want, but we want it to still be the name of the uploaded file, so we will replicate the same data.
Sizes
The documentation seems pretty clear https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/dome_sobject_insert_update_blob.htm#inserting_a_contentversion
...
Cool. My client’s web restrictions are way below that. Let’s do this.
Visibility
Remember to take care of the sharing of the file and think about permissions when you upload files.
By default, users (including users with the “View All Data” permission) can only query files they have access to, including:
Salesforce Files in their personal library and in libraries they're a member of, regardless of library permissions (API version 17.0 and later).
Salesforce Files they own, shared directly with them, posted on their profile, or posted on groups they can see (API version 21.0 and later).
Enable the Query All Files permission to let your View All Data users bypass the restrictions on querying files.
Query All Files returns all files, including files in non-member libraries and files in unlisted groups.
Users can’t edit, upload new versions, or delete files they don’t have access to.
View All Data permission is required to enable Query All Files.
Amend Files
This is only for creating new Files, but of course the advantage of Files is that you can create new versions of documents also.
Viewing Files
Need a public link to the file just created?
Well I can’t test this because you have to have the Content Deliveries feature enabled and you have to submit a support request to do this? Bizarre! But it would be something like this….
Code Block |
---|
{"method" : "POST",
"url" : "/services/data/v49.0/sobjects/ContentDistribution",
"referenceId": "refCDist",
"body":
{
"Name" : "TEST",
"ContentVersionId": "@{refCV.id}",
"PreferencesAllowOriginalDownload": "true",
"PreferencesAllowViewInBrowser ": "true"
}
},
{"method" : "GET",
"url" :"/services/data/v49.0/query?q=SELECT+DistributionPublicUrl+FROM+ContentDistribution+WHERE+id+=+'@{refCDist.id}'",
"referenceId" : "refCDistInfo"
} |
From this Stack Exchange post.
Emailing Files
So the purpose of receiving these files into the Case is to then email them to a third party. So this bit becomes important. From the Help Docs.
If the total size of everything you’ve attached to the message is greater than 3 MB, all of the attachments appear as links, which the recipient can use to download the files. If the total attachment size is less than 3 MB, each file appears as an attachment.
Thanks
Thanks to this article https://www.appseconnect.com/how-to-upload-a-document-in-salesforce-files-using-rest-api/ and this video https://www.youtube.com/watch?v=KZB4Yhi9xv0 for help on how to do the API calls.
I don’t understand why the new Postman collection has nothing much in the way of Files API calls.