In this guide , I will show you how to process multipart form data via HttpTrigger in a NodeJS Azure Function.
Now lets create the function in the portal.
Once the function is created , go the plateform features and click (Advanced Tools) Kudu
Once in Kudu , Click Debug Console and Run CMD
Goto the Azurefunction folder in this case HttpTrigger1, create a package.json file by either running npm init and then copying the code below.
and then copying the code below to seperate files (function.js, index.js and package.json)
Run npm install and you are ready to test your function
Go to the Azure function and copy the URL
Click Get function URL
now you are ready to test it , download and open PostMan and paste the URL
Choose form-data and add file type , attach the test file
now you will receive the size of the file , file name and content type.
My name is Anass Kartit. I’m a cloud solutions architect and a programmer . I worked previously for various companies including Microsoft and Hewlett Packard, I like to solve problems , learn new technologies and code for fun.
I am on Linkedin, Stackoverflow, Github and MSDN forums.