How to run a Module as a Web API?

I’m working on a Slack integration and want a co-workers bot to talk to my PowerShell module. I’ve found a HttpListener module written that’ll use .Net but I can only get it to run locally. My co-worker says great things about Node.JS so I’m curious about going that route. Basically I don’t know what the best solution would be.


Well, PowerShell isn’t a Web scripting language. Nor is it a Web server. You’re going to need to have a Web server for your code to live on, and I’d suggest using something that works well under a Web server. Node.js, sure. ASP.NET. Whatever floats yer boat. But probably not PowerShell.