We were using the http package inside a custom function and noticed that the function was throwing errors we could not reproduce locally.
After some investigation we saw that the “createServer” function of the http package is not working.
It should be supported inside the node version mongo is using: HTTP | Node.js v10.24.1 Documentation
Also it is stated as fully supported inside the MongoDB documentation: https://docs.mongodb.com/realm/functions/built-in-module-support/
So there seems to be a bug here.