file upload from Command Line Interface(CLI) node.js
I am creating custom command line interface(CLI) for our application. Now, I need to upload a file from CLI. Can we upload a file from CLI? Let say I'm in project folder location abc in terminal and it contains a .js file. I want to get that file and upload into server.
I used multer with express framework for uploading files from browser with html form. But I don't know how to do this from command line interface. Any help or suggestion would be much appreciated.
I have a REST api server end point with POST method for uploading file. So HTTP method is needed. I want to send headers with HTTP POST request such as session token and app key