Documentation
Gateway
Deployment
Node.js Frameworks
Introduction

Node.js Frameworks

We highly recommend to use Hive Gateway with the CLI in Node.js as described in Node.js guide. But if you want to use Hive Gateway with a Node.js framework, you can use the createGatewayRuntime function from @graphql-hive/gateway package.

In this case, you have to pass your serve configuration inside createGatewayRuntime instead of exporting it gatewayConfig from gateway.config.ts file.

It handles Node.js request and response types which are IncomingMessage and ServerResponse.

If your framework has middlewares and so on, you can handle the response by yourself as in Fastify example.

Choose your framework from the list on the left to see an example.