Hello!
I have an API which is returning an array of documents through an integration call with the response looking something like this:
{ documents: [ { documentName: "document1.pdf", documentContent: "[BASE64ENCODEDCONTENT]" }, { documentName: "document2.pdf", documentContent: "[BASE64ENCODEDCONTENT]" } ] }
The issue I'm having is that here in the integration where you can make appian to automatically convert the binary data to Document type, appian will recognise multiple files (content of them) through the fv! domain, but there is no way to set the document name for each document through the fv! domain.
What I want to be able to do is to set the document names similarly like I do here in the screenshot for the documentContent, which then correctly goes through the response and converts the data to document type..
What is the expected way to do this in appian?
Discussion posts and replies are publicly visible
AFAIK Appian does not support multiple files in a single call.
Thanks for the answer but I think that is a bit incorrect since appian can tell that i have returned two different files, and saves them both (i've also checked the contents on the saved files and they are in fact different and correct). The only issue here is I somehow can't set the document names (it saves them under the same name) - see attached screenshot.
You are right, I did not see that the files are inside a JSON string.
I need to guess ... did you try to just add another file using "+ Add Document"?
I did. But that only adds a predetermined document. The response can return between 2-5 documents dynamically and I was wondering why there's no option to access the fv! domain in the documentName expression since the fv! domain is already available in the documentContent. I think appian should be able to support this I'm just not getting how to make it work currently..