NocoDB

Lightweight, dependency-free in-memory NocoDB REST fake for testing axios-based application code with zero external side effects.

Default port: 4612

Quick Start

import axios from "axios";
import { NocodbServer } from "./services/nocodb/src/server.js";

const server = new NocodbServer(4612);
await server.start();

const client = axios.create({ baseURL: "http://127.0.0.1:4612" });
const base = await client.post("/api/v2/meta/bases", { title: "CRM" });
const table = await client.post(`/api/v2/meta/bases/${base.data.id}/tables`, {
  title: "Contacts",
  columns: [{ title: "Name", uidt: "SingleLineText" }],
});
const record = await client.post(`/api/v2/tables/${table.data.id}/records`, { Name: "Ada" });

await server.stop();

Implemented Operations

Server

MethodEndpointDescription
GET/Service metadata.
GET/healthHealth check, returns { "status": "ok" }.
HEAD/healthHeader-only health check for axios head.
OPTIONS/*CORS preflight for axios browser-style calls.
POST/__resetClears all in-memory bases, tables, columns, views, and records.

Auth

MethodEndpointDescription
POST/api/v1/auth/user/signinReturns a fake token and user object.
POST/api/v1/auth/user/signupReturns a fake token and user object.
GET/api/v1/auth/user/meReturns the fake current user.
POST/api/v1/auth/password/forgotReturns a password reset acknowledgement.

Meta: Bases and Projects

MethodEndpointDescription
GET/api/v2/meta/basesList bases.
POST/api/v2/meta/basesCreate a base.
GET/api/v2/meta/bases/:baseIdRead a base.
PATCH/api/v2/meta/bases/:baseIdUpdate a base title.
PUT/api/v2/meta/bases/:baseIdUpdate a base title.
DELETE/api/v2/meta/bases/:baseIdDelete a base and its tables.
GET/api/v1/db/meta/projectsv1 alias for listing bases.
POST/api/v1/db/meta/projectsv1 alias for creating bases.
GET/api/v1/db/meta/projects/:baseIdv1 alias for reading a base.
PATCH/api/v1/db/meta/projects/:baseIdv1 alias for updating a base.
PUT/api/v1/db/meta/projects/:baseIdv1 alias for updating a base.
DELETE/api/v1/db/meta/projects/:baseIdv1 alias for deleting a base.

Meta: Tables

MethodEndpointDescription
GET/api/v2/meta/bases/:baseId/tablesList tables in a base.
POST/api/v2/meta/bases/:baseId/tablesCreate a table. System fields and a grid view are added automatically.
GET/api/v2/meta/tables/:tableIdRead a table, including columns and views.
PATCH/api/v2/meta/tables/:tableIdUpdate a table title.
PUT/api/v2/meta/tables/:tableIdUpdate a table title.
DELETE/api/v2/meta/tables/:tableIdDelete a table and its columns, views, and records.
GET/api/v1/db/meta/projects/:baseId/tablesv1 alias for listing tables.
POST/api/v1/db/meta/projects/:baseId/tablesv1 alias for creating tables.
GET/api/v1/db/meta/tables/:tableIdv1 alias for reading a table.
PATCH/api/v1/db/meta/tables/:tableIdv1 alias for updating a table.
PUT/api/v1/db/meta/tables/:tableIdv1 alias for updating a table.
DELETE/api/v1/db/meta/tables/:tableIdv1 alias for deleting a table.

Meta: Columns

MethodEndpointDescription
GET/api/v2/meta/tables/:tableId/columnsList columns in a table.
POST/api/v2/meta/tables/:tableId/columnsCreate a column.
GET/api/v2/meta/columns/:columnIdRead a column.
PATCH/api/v2/meta/columns/:columnIdUpdate a column title or uidt.
PUT/api/v2/meta/columns/:columnIdUpdate a column title or uidt.
DELETE/api/v2/meta/columns/:columnIdDelete a column.
GET/api/v1/db/meta/tables/:tableId/columnsv1 alias for listing columns.
POST/api/v1/db/meta/tables/:tableId/columnsv1 alias for creating columns.
GET/api/v1/db/meta/columns/:columnIdv1 alias for reading a column.
PATCH/api/v1/db/meta/columns/:columnIdv1 alias for updating a column.
PUT/api/v1/db/meta/columns/:columnIdv1 alias for updating a column.
DELETE/api/v1/db/meta/columns/:columnIdv1 alias for deleting a column.

Meta: Views

MethodEndpointDescription
GET/api/v2/meta/tables/:tableId/viewsList views in a table.
POST/api/v2/meta/tables/:tableId/viewsCreate a view.
GET/api/v2/meta/views/:viewIdRead a view.
PATCH/api/v2/meta/views/:viewIdUpdate a view title.
PUT/api/v2/meta/views/:viewIdUpdate a view title.
DELETE/api/v2/meta/views/:viewIdDelete a view.
GET/api/v1/db/meta/tables/:tableId/viewsv1 alias for listing views.
POST/api/v1/db/meta/tables/:tableId/viewsv1 alias for creating views.
GET/api/v1/db/meta/views/:viewIdv1 alias for reading a view.
PATCH/api/v1/db/meta/views/:viewIdv1 alias for updating a view.
PUT/api/v1/db/meta/views/:viewIdv1 alias for updating a view.
DELETE/api/v1/db/meta/views/:viewIdv1 alias for deleting a view.

Records

MethodEndpointDescription
GET/api/v2/tables/:tableId/recordsList records. Supports where, sort, limit, page, pageSize, offset, and fields.
POST/api/v2/tables/:tableId/recordsCreate one record or an array of records.
PATCH/api/v2/tables/:tableId/recordsBulk update records by Id or id.
PUT/api/v2/tables/:tableId/recordsBulk update records by Id or id.
DELETE/api/v2/tables/:tableId/recordsBulk delete records with { "ids": [...] }, { "records": [...] }, or an array.
GET/api/v2/tables/:tableId/records/countCount records after optional where filtering.
GET/api/v2/tables/:tableId/records/:recordIdRead one record.
PATCH/api/v2/tables/:tableId/records/:recordIdUpdate one record.
PUT/api/v2/tables/:tableId/records/:recordIdUpdate one record.
DELETE/api/v2/tables/:tableId/records/:recordIdDelete one record.
GET/api/v1/db/data/:baseTitleOrId/:tableTitleOrNamev1 alias for listing records.
POST/api/v1/db/data/:baseTitleOrId/:tableTitleOrNamev1 alias for creating records.
PATCH/api/v1/db/data/:baseTitleOrId/:tableTitleOrNamev1 alias for bulk updating records.
PUT/api/v1/db/data/:baseTitleOrId/:tableTitleOrNamev1 alias for bulk updating records.
DELETE/api/v1/db/data/:baseTitleOrId/:tableTitleOrNamev1 alias for bulk deleting records.
GET/api/v1/db/data/:baseTitleOrId/:tableTitleOrName/countv1 alias for counting records.
GET/api/v1/db/data/:baseTitleOrId/:tableTitleOrName/:recordIdv1 alias for reading one record.
PATCH/api/v1/db/data/:baseTitleOrId/:tableTitleOrName/:recordIdv1 alias for updating one record.
PUT/api/v1/db/data/:baseTitleOrId/:tableTitleOrName/:recordIdv1 alias for updating one record.
DELETE/api/v1/db/data/:baseTitleOrId/:tableTitleOrName/:recordIdv1 alias for deleting one record.

Supported Features

FeatureStatusNotes
In-memory bases, tables, columns, views, recordsSupportedState is ephemeral and reset with POST /__reset or server.reset().
axios HTTP methodsSupportedget, post, put, patch, delete, head, options, and generic request map to supported HTTP verbs.
v2 meta APISupportedBases, tables, columns, and views.
v1 project/data aliasesSupportedCommon older NocoDB paths are accepted.
Record paginationSupportedlimit, page, pageSize, and offset.
Record projectionSupportedfields=Name,Age.
Record sortingSupportedsort=Name and sort=-Name.
Record filteringSupportedSimple NocoDB-style where=(Field,eq,value) with eq, neq, gt, gte, lt, lte, and like.
PersistenceIntentionally unsupportedData is not written to disk.
SQL/database adaptersIntentionally unsupportedThis fake only implements the HTTP REST wire protocol.
Webhooks, automations, plugins, ACLsIntentionally unsupportedCalls return 404 unless listed above.
Real password validationIntentionally unsupportedAuth endpoints return deterministic fake users/tokens.

Error Shapes

Errors use the NocoDB-style JSON body:

{
  "msg": "Table not found",
  "error": "Not Found",
  "statusCode": 404
}

Returned statuses include:

StatusShapeWhen
401{ "msg": "Unauthorized", "error": "Unauthorized", "statusCode": 401 }Protected routes when requireAuth: true and no valid token is supplied.
404{ "msg": "Not found", "error": "Not Found", "statusCode": 404 }Unknown routes.
404{ "msg": "Base not found", "error": "Not Found", "statusCode": 404 }Missing base.
404{ "msg": "Table not found", "error": "Not Found", "statusCode": 404 }Missing table.
404{ "msg": "Column not found", "error": "Not Found", "statusCode": 404 }Missing column.
404{ "msg": "View not found", "error": "Not Found", "statusCode": 404 }Missing view.
404{ "msg": "Record not found", "error": "Not Found", "statusCode": 404 }Missing record.
405{ "msg": "Method not allowed", "error": "Method Not Allowed", "statusCode": 405 }Known endpoint with unsupported HTTP method.
<!-- parlel:testenv:start -->

Configuration — test.env

Copy these into your test.env (used by the bridge sidecar flow). Tokens are Parlel's seeded test credentials — any non-empty value is accepted by the emulator, so you rarely need to change them. Swap in real credentials only when pointing at the live service in prod.env.

NC_AUTH_JWT_SECRET=parlel
NOCODB_API_TOKEN=parlel
NOCODB_BASE_URL=http://parlel-bridge:4612
NOCODB_BASE_ID=base_parlel
<!-- parlel:testenv:end -->