@owlmeans/api-config 0.1.18-rc.11 → 0.1.18-rc.12

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
@@ -12,7 +12,7 @@ Shared entrypoint for advertising safe config values from server to client via a
12
12
  ## Installation
13
13
 
14
14
  ```bash
15
- bun add @owlmeans/api-config
15
+ bun add @owlmeans/api-config@^0.1.18-rc.11
16
16
  ```
17
17
 
18
18
  ## Usage
@@ -51,7 +51,7 @@ This package ships embedded agent skills under `agent-meta/`. After installing y
51
51
  your project's skill store (`.agents/skills/`):
52
52
 
53
53
  ```sh
54
- npx @owlmeans/agent-skills
54
+ npx @owlmeans/agent-skills@^0.1.18-rc.12
55
55
  ```
56
56
 
57
57
  The embedded files are version-matched to this package release. Do not edit them
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "schemaVersion": 2,
3
3
  "package": "@owlmeans/api-config",
4
- "version": "0.1.18-rc.11",
5
- "generatedAt": "2026-09-01T17:39:40.767Z",
4
+ "version": "0.1.18-rc.12",
5
+ "generatedAt": "2026-09-04T22:43:25.452Z",
6
6
  "canonicalRepo": "https://github.com/owlmeans/common",
7
7
  "entries": [
8
8
  {
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: api-config
3
- description: How to use @owlmeans/api-config — module declarations for fetching API/service configuration at runtime. Auto-invoked when importing api-config types or modules.
3
+ description: How to use @owlmeans/api-config — the shared entrypoint declaration and redaction lists behind the runtime config document a backend advertises and a frontend merges into its own config at boot. Auto-invoked when importing api-config, or when wiring runtime API config between a server and a client.
4
4
  user-invocable: false
5
5
  ---
6
6
  <!-- AUTO-GENERATED — do not edit. Regenerate via sync-agent-meta. -->
@@ -8,25 +8,44 @@ user-invocable: false
8
8
  # @owlmeans/api-config
9
9
 
10
10
  **Layer:** Core
11
- **Install:** `"@owlmeans/api-config": "^0.1.18-rc.11"` in `dependencies`
11
+ **Install:** `"@owlmeans/api-config": "^0.1.18-rc.12"` in `dependencies`
12
+
13
+ The contract package of a three-package flow: this one declares the endpoint and what may cross it,
14
+ `@owlmeans/api-config-server` answers it, `@owlmeans/api-config-client` fetches it and merges the
15
+ answer into the client config. Nothing here runs — it is the shared declaration all three agree on.
12
16
 
13
17
  ## Key Exports
14
18
 
15
19
  | Export | Description |
16
20
  |--------|-------------|
17
- | `ApiConfig` types | Shape of remotely-served API config |
18
- | Modules | Module declarations for the config endpoint |
19
- | Constants | Module aliases, route paths |
21
+ | `entrypoints` | The single declaration — alias `API_CONFIG`, route `/assets/config.json`, `sticky: true` so a router attaches it unconditionally |
22
+ | `API_CONFIG` | The alias (`api-config:advertise`) both sides elevate |
23
+ | `notAdvertizedConfigKeys` | Config keys the server strips before answering — `dbs`, `trusted`, `ready`, `service`, `type`, `records`, `webService`, `oidc`, `storageBuckets`, `secrets` |
24
+ | `allowedConfigRecords` | The only `recordType` values a config record may carry to be advertised — `plan`, `product`, `l10n` |
25
+ | `ApiConfig` | The advertised document — `CommonConfig` minus `dbs`, `trusted`, `ready`, `service` and `type` |
20
26
 
21
27
  ## Usage
22
28
 
23
- Pair with `@owlmeans/api-config-client` (browser) or `@owlmeans/api-config-server` (Fastify) for the runtime side. The `api-config` package itself defines the shared module/route shape.
29
+ The declaration is elevated on both sides, so neither imports the other's package — they only share
30
+ this one. Add it to the entrypoint list the way any other entrypoint set is added:
24
31
 
25
32
  ```typescript
26
- import { modules as apiConfigModules } from '@owlmeans/api-config'
27
- const appModules = [...apiConfigModules, ...myModules]
33
+ import { entrypoints as apiConfigEntrypoints } from '@owlmeans/api-config'
34
+ export const appEntrypoints = [...apiConfigEntrypoints, ...myEntrypoints]
28
35
  ```
29
36
 
37
+ Most apps never do this directly: a backend built on `@owlmeans/server-app` already carries the
38
+ server side in its built-in `entrypoints`, and a client panel package already carries the client
39
+ side.
40
+
41
+ ## What may cross
42
+
43
+ The advertised document is the server's own config with the secrets taken out, so anything added to
44
+ a backend config is public by default. A new config key holding a credential, a connection string or
45
+ an internal address belongs in `notAdvertizedConfigKeys`; a new config-record type is invisible to
46
+ clients until it is listed in `allowedConfigRecords`. Both lists live here rather than in the server
47
+ so the client's type (`ApiConfig`) and the server's redaction cannot drift apart.
48
+
30
49
  ## Depends On
31
50
 
32
51
  - `@owlmeans/entrypoint`, `@owlmeans/route`, `@owlmeans/config`
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@owlmeans/api-config",
3
- "version": "0.1.18-rc.11",
3
+ "version": "0.1.18-rc.12",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "scripts": {
@@ -21,9 +21,9 @@
21
21
  }
22
22
  },
23
23
  "dependencies": {
24
- "@owlmeans/config": "^0.1.18-rc.11",
25
- "@owlmeans/entrypoint": "^0.1.18-rc.10",
26
- "@owlmeans/route": "^0.1.18-rc.8"
24
+ "@owlmeans/config": "^0.1.18-rc.12",
25
+ "@owlmeans/entrypoint": "^0.1.18-rc.11",
26
+ "@owlmeans/route": "^0.1.18-rc.9"
27
27
  },
28
28
  "devDependencies": {
29
29
  "@owlmeans/dep-config": "workspace:*",