Skip to content

Commit c87c335

Browse files
authored
Merge pull request #1180 from objectstack-ai/copilot/update-package-docs
2 parents 0e7e932 + 7336af3 commit c87c335

60 files changed

Lines changed: 2219 additions & 145 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
### Added
11+
- **Release-readiness documentation pass (42 packages)** — Aligned every `@objectstack/*` package for the formal v4.x release:
12+
- Canonical README template and `package.json` publishing checklist committed at `docs/internal/PACKAGE_README_TEMPLATE.md`
13+
- New `packages/services/service-package/README.md` documenting the package registry service
14+
- All `package.json` files now carry `description`, at least 3 `keywords`, a full `repository` block with `directory`, `homepage`, `bugs`, `engines.node`, `publishConfig.access: public`, and a `files` whitelist
15+
- `@objectstack/service-tenant` (was `0.1.0`) and `@objectstack/service-package` (was `1.0.0`) bumped to `4.0.4` in lockstep with the release train
16+
- Rewrote thin READMEs for `core`, `rest`, `driver-memory`, `plugin-security`, and all seven framework adapters (`express`, `fastify`, `hono`, `nestjs`, `nextjs`, `nuxt`, `sveltekit`) to the canonical structure: overview, installation, quick start, key exports, configuration, when/when-not, related packages, and docs links
17+
- Updated `content/docs/guides/packages.mdx` and `content/docs/concepts/packages.mdx` to reflect the actual **42 package** inventory and to include `service-package` and `service-tenant`
18+
1019
### Fixed
1120
- **Cross-origin auth tokens stripped in `@objectstack/hono` adapter (follow-up to PR #1178)**`createHonoApp()` was not exposing `set-auth-token` via `Access-Control-Expose-Headers`, diverging from `plugin-hono-server`'s CORS wiring. On Vercel deployments (where all traffic flows through `createHonoApp()`), the browser stripped the header from every response, preventing the better-auth `bearer()` plugin from delivering rotated session tokens to cross-origin clients. Cross-origin sessions silently broke even after the wildcard fixes in #1177/#1178. The adapter now always includes `set-auth-token` in `exposeHeaders`, merged with any user-supplied values, mirroring the invariant established in commit `151dd19c`. (`packages/adapters/hono/src/index.ts`)
1221
- **CORS wildcard patterns in `@objectstack/hono` adapter (follow-up to PR #1177)**`createHonoApp()` was the third CORS code path that still treated wildcard origins (e.g. `https://*.objectui.org`) as literal strings when passing them to Hono's `cors()` middleware. Because `apps/server` routes all non-OPTIONS requests through this adapter on Vercel, the browser would see a successful preflight (handled by the Vercel short-circuit) followed by a POST/GET response with no `Access-Control-Allow-Origin` header, blocking every real request. The adapter now imports `hasWildcardPattern` / `createOriginMatcher` from `@objectstack/plugin-hono-server` and uses the same matcher-function branch as `plugin-hono-server`, so all three Hono-based CORS paths share a single source of truth. (`packages/adapters/hono/src/index.ts`)

README.md

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,7 @@ os doctor # Check environment health
136136
| Package | Description |
137137
| :--- | :--- |
138138
| [`@objectstack/plugin-hono-server`](packages/plugins/plugin-hono-server) | Hono-based HTTP server plugin |
139+
| [`@objectstack/plugin-mcp-server`](packages/plugins/plugin-mcp-server) | Model Context Protocol server — exposes ObjectStack to AI agents |
139140
| [`@objectstack/plugin-msw`](packages/plugins/plugin-msw) | Mock Service Worker plugin for browser testing |
140141
| [`@objectstack/plugin-auth`](packages/plugins/plugin-auth) | Authentication plugin (better-auth) |
141142
| [`@objectstack/plugin-security`](packages/plugins/plugin-security) | RBAC, Row-Level Security, Field-Level Security |
@@ -147,11 +148,18 @@ os doctor # Check environment health
147148

148149
| Package | Description |
149150
| :--- | :--- |
150-
| [`@objectstack/service-feed`](packages/services/service-feed) | Activity feed service |
151-
| [`@objectstack/service-automation`](packages/services/service-automation) | Automation engine — flows, triggers, DAG-based workflows |
152151
| [`@objectstack/service-ai`](packages/services/service-ai) | AI service — Agent, Tool, Skill, Vercel AI SDK integration |
153-
| [`@objectstack/service-realtime`](packages/services/service-realtime) | Real-time events and subscriptions |
152+
| [`@objectstack/service-analytics`](packages/services/service-analytics) | Analytics — aggregations, time series, funnels, dashboards |
153+
| [`@objectstack/service-automation`](packages/services/service-automation) | Automation engine — flows, triggers, DAG-based workflows |
154+
| [`@objectstack/service-cache`](packages/services/service-cache) | Cache — in-memory, Redis, multi-tier |
155+
| [`@objectstack/service-feed`](packages/services/service-feed) | Activity feed / chatter |
154156
| [`@objectstack/service-i18n`](packages/services/service-i18n) | Internationalization service |
157+
| [`@objectstack/service-job`](packages/services/service-job) | Cron & interval job scheduler |
158+
| [`@objectstack/service-package`](packages/services/service-package) | Package registry — publish, version, retrieve metadata packages |
159+
| [`@objectstack/service-queue`](packages/services/service-queue) | Background job queue (in-memory, BullMQ) |
160+
| [`@objectstack/service-realtime`](packages/services/service-realtime) | Real-time events and subscriptions |
161+
| [`@objectstack/service-storage`](packages/services/service-storage) | File storage (local, S3, R2, GCS) |
162+
| [`@objectstack/service-tenant`](packages/services/service-tenant) | Multi-tenant context and routing |
155163

156164
### Framework Adapters
157165

@@ -188,7 +196,7 @@ os doctor # Check environment health
188196

189197
| Metric | Value |
190198
| :--- | :--- |
191-
| Packages | 27 |
199+
| Packages | 42 |
192200
| Zod schema files | 200 |
193201
| Exported schemas | 1,600+ |
194202
| `.describe()` annotations | 8,750+ |

RELEASE_NOTES.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,50 @@
11
# Release Notes
22

3+
## v4.0.4 — Release Readiness: Documentation Alignment _(in progress)_
4+
5+
### 🎯 Purpose
6+
7+
Prepare all 42 packages under `@objectstack/*` for formal public release on npm by:
8+
9+
- Guaranteeing consistent, complete publishing metadata on every package.
10+
- Normalizing README structure so every package documents overview, installation, quick start, exports, configuration, when/when-not, related packages, and links to the docs site.
11+
- Bringing version numbers for previously experimental packages (`service-tenant`, `service-package`) in lockstep with the release train at `4.0.4`.
12+
- Correcting stale package counts and missing entries in the official documentation site.
13+
14+
### 📦 Package inventory (42)
15+
16+
| Category | Count | Packages |
17+
|:---|:---:|:---|
18+
| Core runtime | 7 | `spec`, `core`, `runtime`, `types`, `metadata`, `objectql`, `rest` |
19+
| Client / DX | 5 | `client`, `client-react`, `cli`, `create-objectstack`, `vscode-objectstack` |
20+
| Adapters | 7 | `express`, `fastify`, `hono`, `nestjs`, `nextjs`, `nuxt`, `sveltekit` |
21+
| Drivers | 3 | `driver-memory`, `driver-sql`, `driver-turso` |
22+
| Plugins | 8 | `plugin-auth`, `plugin-security`, `plugin-audit`, `plugin-hono-server`, `plugin-mcp-server`, `plugin-msw`, `plugin-dev`, `plugin-setup` |
23+
| Services | 12 | `service-ai`, `service-analytics`, `service-automation`, `service-cache`, `service-feed`, `service-i18n`, `service-job`, `service-package`, `service-queue`, `service-realtime`, `service-storage`, `service-tenant` |
24+
25+
### ✅ Release readiness checklist
26+
27+
- [x] Canonical README template and publishing checklist committed at `docs/internal/PACKAGE_README_TEMPLATE.md`.
28+
- [x] Every `package.json` has: `description`, `keywords` (≥ 3), `repository` (with `directory`), `homepage`, `bugs`, `license`, `publishConfig.access: public`, `files`, `engines.node`.
29+
- [x] `service-tenant` and `service-package` version-aligned to `4.0.4`.
30+
- [x] `packages/services/service-package/README.md` authored.
31+
- [x] Thin READMEs rewritten: `core`, `rest`, `driver-memory`, `plugin-security`, all 7 adapters.
32+
- [x] `content/docs/guides/packages.mdx` updated to 42-package inventory including `service-package` and `service-tenant`.
33+
- [x] `content/docs/concepts/packages.mdx` updated to 42-package inventory.
34+
- [x] `CHANGELOG.md` carries a release-prep entry.
35+
- [ ] `pnpm build` passes for every publishable package.
36+
- [ ] `pnpm test` passes.
37+
- [ ] `lychee` link check passes across all READMEs and `content/docs/**`.
38+
- [ ] `pnpm docs:build` succeeds.
39+
- [ ] `content/docs/references/` regenerated via `pnpm --filter @objectstack/spec gen:docs`.
40+
41+
### 📝 Known follow-ups
42+
43+
- Existing strong READMEs (e.g. `service-ai`, `service-storage`, `plugin-audit`, `runtime`, `spec`, `driver-sql`, `driver-turso`) are structurally sound and were not rewritten — they retain their individual voice and depth. A future pass may add standardized npm + license badges across them.
44+
- `content/docs/references/` regeneration is out of scope for this PR because it requires a full spec rebuild; it should run as part of the release pipeline.
45+
46+
---
47+
348
## v1.2.0 - Studio DX, REST Extraction, Dispatcher Plugin (2026-02-09)
449

550
### 📦 Released Packages

content/docs/concepts/packages.mdx

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,20 +5,22 @@ description: Complete reference of all ObjectStack packages in the monorepo
55

66
# Package Reference
77

8-
ObjectStack is distributed as a monorepo containing **25 packages** organized into core packages, adapters, and plugins.
8+
ObjectStack is distributed as a monorepo containing **42 packages** organized into core runtime, client SDKs, framework adapters, drivers, plugins, and platform services.
99

10-
> **Note for AI Agents**: Each package's `README.md` contains a specific "AI Development Context" section describing its architectural role and usage rules.
10+
> **Note for AI Agents**: Each package's `README.md` contains a specific architectural role and usage rules section.
1111
1212
## Package Overview
1313

1414
| Category | Count | Description |
1515
| :--- | :---: | :--- |
16-
| [Core Packages](#core-packages) | 9 | Essential runtime, protocols, client SDKs, and CLI |
17-
| [Framework Adapters](#framework-adapters) | 7 | Express, Fastify, Hono, NestJS, Next.js, Nuxt, SvelteKit |
18-
| [Plugin Packages](#plugin-packages) | 6 | Drivers, server, auth, security, dev, and MSW plugins |
19-
| [Tools](#tools) | 3 | Project scaffolder, VSCode extension, REST API server |
20-
21-
**Total: 25 packages**
16+
| Core runtime | 7 | `spec`, `core`, `runtime`, `types`, `metadata`, `objectql`, `rest` |
17+
| Client / DX | 5 | `client`, `client-react`, `cli`, `create-objectstack`, `vscode-objectstack` |
18+
| Framework adapters | 7 | Express, Fastify, Hono, NestJS, Next.js, Nuxt, SvelteKit |
19+
| Drivers | 3 | `driver-memory`, `driver-sql`, `driver-turso` |
20+
| Plugins | 8 | Auth, Security, Audit, Hono-Server, MCP-Server, MSW, Dev, Setup |
21+
| Platform services | 12 | AI, Analytics, Automation, Cache, Feed, I18n, Job, Package, Queue, Realtime, Storage, Tenant |
22+
23+
**Total: 42 packages**
2224

2325
---
2426

content/docs/guides/packages.mdx

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,19 @@ description: Complete guide to all ObjectStack packages, services, drivers, plug
55

66
# Package Overview
77

8-
ObjectStack is organized into **27 packages** across multiple categories. This guide provides a complete overview of each package, its purpose, and when to use it.
8+
ObjectStack is organized into **42 packages** across multiple categories. This guide provides a complete overview of each package, its purpose, and when to use it.
9+
10+
### Package categories at a glance
11+
12+
| Category | Count | Packages |
13+
|:---|:---:|:---|
14+
| **Core runtime** | 7 | `spec`, `core`, `runtime`, `types`, `metadata`, `objectql`, `rest` |
15+
| **Client / DX** | 5 | `client`, `client-react`, `cli`, `create-objectstack`, `vscode-objectstack` |
16+
| **Framework adapters** | 7 | `express`, `fastify`, `hono`, `nestjs`, `nextjs`, `nuxt`, `sveltekit` |
17+
| **Drivers** | 3 | `driver-memory`, `driver-sql`, `driver-turso` |
18+
| **Plugins** | 8 | `plugin-auth`, `plugin-security`, `plugin-audit`, `plugin-hono-server`, `plugin-mcp-server`, `plugin-msw`, `plugin-dev`, `plugin-setup` |
19+
| **Platform services** | 12 | `service-ai`, `service-analytics`, `service-automation`, `service-cache`, `service-feed`, `service-i18n`, `service-job`, `service-package`, `service-queue`, `service-realtime`, `service-storage`, `service-tenant` |
20+
921

1022
## Core Packages
1123

@@ -241,6 +253,22 @@ All services implement contracts from `@objectstack/spec/contracts` and are kern
241253
- **When to use**: File attachments, document management, media storage
242254
- **README**: [View README](/packages/services/service-storage/README.md)
243255

256+
### @objectstack/service-package
257+
258+
**Package Registry Service** — Publish, version, and retrieve ObjectStack metadata packages from the `sys_packages` table.
259+
260+
- **Features**: Upsert by `(id, version)`, SHA-256 integrity hash, `latest` resolution, bulk list/delete
261+
- **When to use**: Marketplace backends, internal tenant-facing registries, CI-driven metadata distribution
262+
- **README**: [View README](/packages/services/service-package/README.md)
263+
264+
### @objectstack/service-tenant
265+
266+
**Multi-Tenant Service** — Tenant context, routing, and isolation for SaaS deployments.
267+
268+
- **Features**: Tenant resolution from host/header/cookie, per-tenant metadata and data isolation
269+
- **When to use**: Any multi-tenant SaaS on ObjectStack
270+
- **README**: [View README](/packages/services/service-tenant/README.md)
271+
244272
---
245273

246274
## Official Plugins

0 commit comments

Comments
 (0)