@farthershore/product 0.4.0 → 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -25,11 +25,8 @@ product/
25
25
  package.json
26
26
  product.config.ts
27
27
  meters.ts
28
- plans/
29
- free.ts
30
- pro.ts
31
- routes/
32
- api.ts
28
+ features.ts
29
+ plans.ts
33
30
  frontend/
34
31
  ...
35
32
  ```
@@ -45,8 +42,8 @@ Farther Shore stores them in Core.
45
42
  ```ts
46
43
  import { fs } from "@farthershore/product";
47
44
  import { configureMeters } from "./meters.js";
48
- import { configureCronRoutes } from "./routes/cron.js";
49
- import { configurePlans } from "./plans/index.js";
45
+ import { configureCronRoutes } from "./features.js";
46
+ import { configurePlans } from "./plans.js";
50
47
 
51
48
  const product = fs.product("croncloud", {
52
49
  origin: "https://app.example.com",
@@ -173,12 +170,10 @@ accepts; Core, not the user repo, remains the lifecycle authority.
173
170
  - `product.use(...modules)` — compose Product SDK modules from any files under
174
171
  `product/`.
175
172
  - `product.surface(...)` — declare the product surfaces customers interact with
176
- (`frontend`, `api`, `docs`, `widget`, `webhook`, `worker`, or `agent`).
173
+ (`frontend`, `api`, `docs`, `widget`, `webhook`, `worker`, `agent`, or
174
+ `dashboard`).
177
175
  - `product.entitlement(...)` — group capabilities, feature gates, limits, and
178
176
  meters into reusable access metadata.
179
- - `product.offering.plan(...)` — declare a subscription plan through the
180
- generalized offering namespace. `product.plan(...)` remains the direct plan
181
- helper.
182
177
  - `product.meter(...)` — declare billable or enforceable dimensions.
183
178
  - `product.requests()` — declare and inherit the platform-managed successful
184
179
  request meter.
@@ -188,7 +183,7 @@ accepts; Core, not the user repo, remains the lifecycle authority.
188
183
  - `product.capability(...)` — declare capability bundles and plan grants.
189
184
  - `product.feature(...)` / `product.api.route(...)` — declare gateway routes,
190
185
  static costs, dynamic reports, estimates, and action metadata.
191
- - `product.policy(...)` — declare policy files in code.
186
+ - `product.policy(...)` — declare policy layers in code.
192
187
  - `product.plan(...)` — declare plan pricing, limits, grants, and lifecycle
193
188
  behavior.
194
189
  - `product.lifecycle.*` — declare migrations.