cancel
Showing results for 
Search instead for 
Did you mean: 

How to set HTTP Request Multipart

arjunraj
Level 4

Hi Everyone,

I am trying to upload a pdf file using HTTP Request Multipart and I have tried putting the variables in both Headers and FieldMetadata collection separately but I'm getting the 400 error every time.

Can anyone please help me on how I can set it up?

Thanks

arjunraj_0-1739902639250.png

 

1 BEST ANSWER

Helpful Answers

@arjunraj  i was not able to go on this website https://pwdevwsg.cmsenergy.com/ConsumersEnergyPWWebAPI/api/FileUploadUrn maybe i need access. BTW try this please and let me know : 

Mohamad_747_0-1740400867826.png

 

 

View answer in original post

28 REPLIES 28

Hi @arjunraj 

To answer you, i need more details 

First are you using the last version of this VBO 

https://digitalexchange.blueprism.com/cardDetails?id=115162

Second can you try to execute your api on postman then send us a screen shot and we can reproduce the same template of postman on Blue prism 

 

Waiting tour answer regards 

arjunraj_1-1739915390752.pngarjunraj_2-1739915523318.png

This is a successful execution on the WebAPI

plnarayana777
Level 7

Hi @arjunraj 

Please try with fieldmetadata as empty collection, provide contentType in Filemetadata collection

Regards

Regards

@arjunraj 

Try this please. With last version that i have mentionned, provide this inputs : 

Mohamad_747_0-1739945289112.png

Mohamad_747_1-1739945439515.png

 

Generat output 

Mohamad_747_2-1739945525730.png

 

try it and let me know.

if its fail remove DocumentAttributesJsonString from FieldMetaData and run it again.

if its still failong remove from the inputs parameters the collection FieldMetaData.

 

Let me know

 

arjunraj_0-1739949121241.png

FieldMetadata is throwing this error for both the columns. So, I removed FieldMetadata and added those columns to Headers collection but I'm still getting another error shown below -

arjunraj_1-1739949296145.png

 

arjunraj
Level 4

Hi @Athiban_Mahamathi ,

the article suggests using either Web Services REST (which I'm unable to download from the exchange) or utility http request multipart which I'm already trying but unable to execute.

I have the screenshots attached of a successful call to the web API which shows the parameters being used in the call, which I did try to replicate as suggested by @Mohamad_747 but still I'm getting errors which are also attached above. 

Not sure how to resolve it, please help

@arjunraj hi,

 

 

I acknowledge that the ideal approach would be to replicate your request in Postman. I'm more accustomed to using Postman templates rather than Swagger.

 

 

 

 

 

 

 

Am pretty sure that with the utility http - action multipart request we can execute your api.

I think we miss a little parameters and then it will be done 

 

@arjunraj