Integrates GraphQL-Tools with Sequelize ORM to auto-generate GraphQL schema definitions and resolvers for CRUD operations on entities and their relationships. Version 2.3.0 is the latest stable release, with a low update cadence (last update 2022). Unlike manual schema building, it maps Sequelize models to GraphQL types automatically, including associations and optional full-text search via ElasticLunr. Requires graphql >=0.13, graphql-tools >=3.0, graphql-tools-types >=1.1, and sequelize >=4.0 as peer dependencies. Provides hooks for validation, authorization, and tracing. ESM-only with Node >=8.
npm install graphql-tools-sequelizeNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Initializes Sequelize, defines a model, creates GraphQLToolsSequelize instance, boots it, and generates a sample schema definition string.
Upgrade to v2 and instantiate with `new GraphQLToolsSequelize(db)` then `await gts.boot()`.
Consider alternatives like graphql-sequelize or manual schema building for long-term projects.
Define all Sequelize models before creating GraphQLToolsSequelize instance and calling boot().
Use import syntax or enable esModuleInterop in tsconfig.json / use babel for CJS compatibility.
Use `import GraphQLToolsSequelize from 'graphql-tools-sequelize'` or `const GraphQLToolsSequelize = require('graphql-tools-sequelize').default`.Ensure `await gts.boot()` executes before accessing gts methods.
Pass a valid Sequelize instance to the constructor: `new GraphQLToolsSequelize(sequelizeInstance)`.