We are currently experiencing intermittent login issues on Community.  The team is actively working on a fix.

How to attach file same as OOB table api in postman from scripted web services ?

Thej1
Tera Expert

Hi,

 

Can we able to attach a file from the postman same as OOB table api from the scripted web services ?

The below screenshot is of the sending attachment by using the OOB table api.

image (7).png

 

But for the custom scripted web services, we are send request in JSON body as below but not in multipart/form-data.

{
  "incidentNumber""INC0010002",
  "fileName""Testtt.png",
    "contentType""image/png",
  "fileData": "Base64 code"
}
Is there a way to do it to send request in form-data same as of the OOB table api for the custom scripted web service ?
 
Thanks
1 ACCEPTED SOLUTION

@Thej1 

it's not able to read the file data hence went inside No file uploaded

You can check the links I shared above, some solution might be present there

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

14 REPLIES 14

@Thej1 

it's not able to read the file data hence went inside No file uploaded

You can check the links I shared above, some solution might be present there

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@Thej1 

Would you mind closing your earlier questions by marking appropriate response as correct?

Members have invested their time and efforts in helping you.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@Thej1 

Hope you are doing good.

Did my reply answer your question?

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@Thej1 

Hope you are doing good.

Did my reply answer your question?

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Hi @Ankur Bawiskar ,

 

Sure. Thanks.