I am trying to send a csv file from snaplogic to an api endpoint using through a REST POST snap but it doesn't seem to actually send the file as the response says file not found
when I do the post through postman it just fine and use the same information I use in the snap
my settings in the POST snap are as follows:
Label*= REST Post Service URL*=http://(ip:port)/v1/innovazones HTTP
entity=(blank) Batch size=(blank) Show all headers(selected) Single
file upload: File=…/shared/TEMPcsv.csv Single file upload: File
key=file Single file upload: Filename to be used=innovaZones_csv_file
Upload transfer request type=calculate content length Upload body
type=Multipart form data Single file upload: Multipart Content-Type=text/csv
HTTP header:
Key=Content-Type;Value=application/x-www-form-urlencoded
key=Authorization Value="Bearer " + account.access_token
Trust all certificates*(checked) Follow redirects*(checked)
{
"status": "success",
"message": "Data transmitted successfully",
"payload": {}
}
but I get this in the response instead:
"error": "REST API service endpoint returned error result: status code = 400, reason phrase = Bad Request"
"error_entity": {
"status":"fail",
"message":"File not found",
"payload":{
"message":"File not found",
"statusCode":400,
"status":"fail"
}
}
"original": {filename:../shared/TEMPcsv.csv, result:overwritten, original:{, ...}}
"filename": "../shared/TEMPcsv.csv"
"result": "overwritten"