Any way to upload files from MID Server to Amazon S3 without S3 spoke?

Aki18
Tera Contributor

We have some files in a folder in MID Server. The files are sent from ServiceNow regularly.

What we would like to do is to upload the files to Amazon S3 triggered by Flow Designer. Is there any way to achieve this?
*We understand that ServiceNow offers "Amazon S3 Spoke", but it's not an option for us since it needs IntegrationHub Enterprise subscription which we don't have.

Best Regards,

Aki

7 REPLIES 7

Community Alums
Not applicable

Amit Verma
Kilo Patron
Kilo Patron

Hi @Aki18 

 

You can make use of a PowerShell script to do the upload for you. The PowerShell script can run on the mid server and can make use of AWS CLI. Refer https://gist.github.com/dpo007/f7e7fab2d7f44f2a94eaae9ad5980c0a to get a reference script.

 

You can call the PowerShell script via Flow Designer PowerShell step if you have Integration Hub Professional subscription else you need to call the mid server script file via ecc queue. Refer https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0858504

 

Thanks and Regards

Amit Verma


Please mark this response as correct and helpful if it assisted you with your question.

Aki18
Tera Contributor

Hi @Amit Verma ,

Thank you for your comment!

We do not have IntegrationHub Professional subscription, so we need to call the mid server script file via ecc queue. To achieve that, can you check if my understandings below are correct?

 

1. Create Batch (Windows) or Shell (Linux) in "MID Server Script File" that contains AWS CLI commands for uploading files to S3.

2. Set Flow Designer Action with "Script step" that creates ECC queue so that the Flow can execute the Batch/Shell for the uploading.

3. Check if the upload has been successful or not in Flow Designer.

 

By the way, will the Batch / Shell be automatically executed just after creating the ECC queue?

Also, can you let me know how to define the Script step in Flow Designer Action for creating the queue?

 

Best Regards,

Aki

 

@Aki18 

 

You are going in the right direction. You can refer below link and setup your action :

https://www.servicenow.com/community/developer-articles/execute-powershell-script-from-servicenow/ta...

 


Please mark this response as correct and helpful if it assisted you with your question.