I think that it would work with http2.createServer: HTTP/2 | Node.js v22.1.0 Documentation
http2.createServer