cancel
Showing results for 
Search instead for 
Did you mean: 

How to send one csv file via REST POST Snap

vaidyarm
Contributor

Hi

I need to read the content of one large CSV file on s3 (more than 100 MB) and then do REST POST to send that CSV file (let say sample.csv) to another service

how this can be done? can you please share the snap setting that will be required for this
(note that I dont want to store files on snaplogic locally before sending, whole operation supposed to happen on the fly during pipeline execution)

Thanks

3 REPLIES 3

bojanvelevski
Valued Contributor

Hey @vaidyarm,

This should give you some pointers:

image

add the Content into HTTP Entity field of the REST Post snap, and also set the Content-Type in headers.

Can you please share REST Post snap properties?

bojanvelevski
Valued Contributor

I’m not sure how the uploading of a file will behave on the API you are using. The sample I sent above, will upload the file on Google Drive for example, but the filename will be “Untitled”, but the content will be correct. So far I’ve been uploading files on Google Drive via Google APIs, and the procedure requires more steps than just simple file upload. You need to send the metadata beside the content of the file. You can refer to the following link which is also a snaplogic community topic for a similar issue, where you can find all of the details:

REST Google Drive API - File is created as untitled

Regards,
Bojan