Registry / devops / centric

centric

JSON →
library0.13.1jsnpmunverified

A programmable automation server (v0.13.1) for defining and scheduling tasks via JavaScript modules. Services export shared logic (e.g., DB connections), tasks define runnable workflows with cron scheduling. Peer dependency on graphql ^14.5.8. Minimal configuration: drop files into services/ and tasks/ folders. No alternative automation server with this exact file-based, GraphQL-backed approach.

npm install centric
INSTALL
IMPORT
SIG · CENTRIC
C
centric
devopsjavascriptv0.13.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

centric
npm install -g centric
npm install centric --save-dev
CLI tool installed globally via npm. Not a library to import.
Service
module.exports = async function ({ config }) { ... }
export default async function ({ config }) { ... }
Services use CommonJS module.exports, not ES module syntax.
Task
module.exports = { description, locks, defaultData, run }
export default { ... }
Tasks also use CommonJS module.exports. The run method receives an object with config, services, opData, etc.

Global install, scaffold a project, then start the server. Demonstrates minimal setup.

npm install -g centric mkdir my-automation cd my-automation centric scaffold # Then edit generated tasks and services # Start the server centric start
Debug
Known issues
gotchaTasks and services must use CommonJS module.exports, not ES module export default. The server does not support ESM.
fix
Use module.exports = ... for tasks and services.
affects: <=0.13.1
breakingGraphQL peer dependency required: graphql ^14.5.8. If missing, server may fail to start.
fix
npm install graphql@^14.5.8
affects: >=0.13.0
gotchaThe run method's first argument is a single object with destructured members, not multiple arguments.
fix
async function run({ config, services, opData, saveOpData, taskData, saveTaskData, logInfo, logWarning, logError, isCancelled })
affects: all
deprecatedThe centric CLI was originally named 'centric-cli' on npm but now is the main package 'centric'. Old references may break.
fix
Use 'npm uninstall -g centric-cli && npm install -g centric'
affects: <0.10.0
Errors
Common errors & fixes
Error: Cannot find module 'graphql'
Missing peer dependency graphql.
fix
npm install graphql@^14.5.8
centric: command not found
Centric not installed globally or not in PATH.
fix
npm install -g centric
TypeError: services[serviceName] is not a function
Service file did not export a function (e.g., exported an object instead).
fix
Ensure service files use module.exports = async function({ config }) { ... }
Upgrade
Version history
0.13.1latest on npm
Audit
Dependencies
graphqlrequiredpeer dependency (^14.5.8) required for GraphQL runtime
Agent activity
4 hits · last 30 days
node
4
Resources
centric — npm install centric · libregistry