Hi, quite new here to Palantir Foundry. just a few questions regarding ontology objects with attachments. I am using this function createAttachmentUpload to upload attachments. What function in the OSDK can I use to retrieve the attachment based on rid? Do we have documents on how to manipulate attachments from the OSDK?
I also have an edit function that accepts an attachment parameter. How can I change the attachment without reuploading? For example, I want to change the attachment property of an object from attachment A to attachment B, where attachment B has already been uploaded before.
alright, thanks! is there a function in the osdk to read back the uploaded attachment given its rid? another API will be reading it, is there a function like readAttachment?
If you search the API documentation on our public web site you can find this method Get Attachment Property Content By Rid
Which I think is what you are looking for.
You can write a fetch function to call this API and use the token you are granted in the SDK by calling auth.getTokenOrNothing()