Forest is the back office for operations teams in regulated companies. Ops teams review, decide and act on your data from one interface, or let AI agents do it through MCP, within the roles, permissions and audit logs you define.
This repository is the Node.js agent: the part of Forest that runs on your servers, connects to your databases and services, and exposes them to the Forest interface and to AI agents. Your business data never goes through Forest.
Note
Forest v2. This is the current Node.js SDK. Using forest-express-sequelize or forest-express-mongoose? You are on v1: see the migration guide.
npm install @forestadmin/agent @forestadmin/datasource-sqlimport { createAgent } from '@forestadmin/agent';
import { createSqlDataSource } from '@forestadmin/datasource-sql';
const agent = createAgent({
authSecret: process.env.FOREST_AUTH_SECRET,
envSecret: process.env.FOREST_ENV_SECRET,
isProduction: process.env.NODE_ENV === 'production',
});
agent.addDataSource(createSqlDataSource(process.env.DATABASE_URL));
await agent.start();Required environment variables: FOREST_ENV_SECRET, FOREST_AUTH_SECRET, DATABASE_URL.
Full guide: docs.forest.app/get-started/quickstart
| Node.js | Developed and tested on Node.js 24 (see .nvmrc) |
| Framework | None required: standalone server, or mounted on Express, Koa, Fastify or NestJS |
| Data | Connect your databases and services through data sources: SQL, Sequelize, Mongoose, MongoDB, Zendesk, replicas, RPC. |
| Customization | Computed fields, actions, segments, hooks and validations in TypeScript, with autocompletion generated from your schema. |
| Workflows | Runs your Forest business processes on your side (@forestadmin/workflow-executor). |
| MCP server | Exposes your collections and actions to AI agents through the Model Context Protocol (@forestadmin/mcp-server). |
| Permissions and audit | Roles, scopes and activity logs defined in Forest, enforced on every request, from the UI or from an AI agent. |
The agent runs on your infrastructure. The Forest interface calls your agent, and your agent queries your sources: Forest does not store your business data. You control what is exposed, to whom, and the logic applied to it.
| Get started | https://docs.forest.app/get-started/quickstart |
| Connect a data source | https://docs.forest.app/get-started/connect/data-sources/overview |
| Node.js API reference | https://docs.forest.app/reference/agent-api/nodejs |
| MCP server | https://docs.forest.app/product/embed/mcp-server |
| Migrating from v1 | https://docs.forest.app/guides/migration/from-v1/overview |
Packages in this monorepo
@forestadmin/agent 路 datasource-sql 路 datasource-sequelize 路 datasource-mongoose 路 datasource-mongo 路 datasource-zendesk 路 datasource-replica 路 datasource-customizer 路 mcp-server 路 workflow-executor 路 agent-testing 路 plugin-aws-s3 路 plugin-flattener 路 plugin-export-advanced 路 forest-cloud
Experimental plugins and data sources: forestadmin-experimental.
Bug reports and pull requests are welcome. See CONTRIBUTING.md for setup, tests and commit conventions.
yarn install && yarn build && yarn testApache 2.0. See LICENSE.