<aside> 💡 Most of the time, a file will be associated with a patient. This is done by setting the enduserId field. If you need to match an existing enduser, check out the following page
</aside>
Uploading a file currently takes two steps
Use the Prepare File Upload endpoint and set the set the name, size, and type (mime type) to match the file you’re uploading. Set the enduserId to associate with a specific enduser. Set publicRead to true only if you want the file to be publicly accessible by a single URL (strongly discouraged for any file which may contain PHI or other sensitive information).
This returns the file, which has a unique id that you can use later to generate download links, update the name, and more. It also includes a JSON object called presignedUpload which includes the information you’ll need to upload the file itself
Taking the presignedUpload JSON in the response to Prepare File Upload, POST to the .url value with the following details: