I've tried to make at least js version run with ssr, but I had errors and eventually found this
https://youtrack.jetbrains.com/issue/KTOR-405
Seems Ktor client doesn't work with node without additional workarounds but I don't know how to apply the workaround from the comments to kilua app.