Express-Cassandra is a framework-independent Cassandra Object Models (ORM) for NodeJS that wraps the DataStax DSE driver (based on cassandra-driver). Version 1.9.3 supports Cassandra 3.x with features like CRUD operations, data type validations, materialized views, secondary/custom/SASI indexes, user-defined types, batch operations, hook functions, automatic migrations, and promise support via Async suffixed functions. It is compatible with Express, Restify, Hapi, Koa, and more. Note: legacy Cassandra 2.x users must use version 0.5.4. The ORM is built on a highly modified version of apollo-cassandra.
npm install tyb-express-cassandraNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Initializes the ORM, connects to a local Cassandra instance, defines a User model, saves a record using promises.
Migrate to dse-driver API or use express-cassandra@0.5.4 for Cassandra 2.x.
Replace .save() with .saveAsync() and handle with then/catch or async/await.
Use const models = require('express-cassandra')() or const models = require('express-cassandra').connect({...}).Set ormOptions.migration: 'safe' in the bind() call.
npm install express-cassandra (not tyb-express-cassandra).
npm install dse-driver
Correct usage: const models = require('express-cassandra'); models = models.bind({...}); then models.load('User', schema);Ensure Cassandra is started on 127.0.0.1:9042, or update contactPoints and port in clientOptions.