Skip to Content
0
Jan 23, 2023 at 11:08 AM

Issue with uploading file in API

72 Views Last edit Jan 23, 2023 at 11:14 AM 2 rev

Hi,

I am working on converting PDF files into images thanks to an Adobe API.

The conversion consists of 6 consecutive requests :

  1. POST : Exchange JWT for Access token ;
  2. POST : Get upload pre-signed URI ;
  3. PUT : Upload asset to cloud provider ;
  4. POST : Create job (convert into image) ;
  5. GET : Fetch status ;
  6. GET : Download asset.

All of the above API’s are working perfectly fine in Postman. But now that I have built the corresponding automation in SAP Cloud Factory, I’m getting the following error at step 5 (Fetch status) :

image.png

The overall automation looks like this :

image.png

After a couple of tests, I have reasons to believe the issue might come from step 3 (Upload asset), which I have built using the following code :

image.png

image.png

I think the body is what is causing trouble, and even though it’s a pretty straightforward piece of code, there’s something my low level of coding stops me from doing correctly. Note that in Postman I upload the file using the binary option.

Thanks for your assistance on this.

Kind regards,

LM.

Attachments

image.png (34.4 kB)
image.png (136.6 kB)
image.png (160.1 kB)
image.png (104.1 kB)