@ggui-ai/registry-core 0.2.0-alpha.4 → 0.4.0-rc.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
@@ -6,7 +6,7 @@ Pure-TypeScript registry operations + storage interfaces for the **ggui marketpl
6
6
 
7
7
  The registry's business logic — manifest validation, conformance gating, signature verification, version immutability — is identical regardless of where the registry runs. This package extracts that logic so:
8
8
 
9
- - The hosted registry's transport layer is a thin shell over these ops.
9
+ - A hosted registry's transport layer is a thin shell over these ops.
10
10
  - The OSS server is a [hono](https://hono.dev) + filesystem/memory adapter over the same ops.
11
11
  - A third-party operator can build their own transport (Express, Fastify, gRPC) by implementing two storage interfaces.
12
12
 
package/dist/index.d.ts CHANGED
@@ -11,7 +11,7 @@ export type { AuthnContext } from './interfaces/authn.js';
11
11
  export type { BundleStorage } from './interfaces/bundle-storage.js';
12
12
  export { AuthorKeyAlreadyExistsError, type PutAuthorKeyOptions, type RegistryStorage, } from './interfaces/registry-storage.js';
13
13
  export { ARTIFACTS_METADATA_SK, type ArtifactKind, type ArtifactScanFilter, type ArtifactVersionRow, type ArtifactsMetadataRow, type AuthorKeyRow, type CompiledBlobRow, type ErrorBody, LIST_VERSIONS_ERROR_CODES, type ListVersionsErrorBody, type ListVersionsErrorCode, type ListVersionsResponse, PUBLISH_ERROR_CODES, type PublishErrorBody, type PublishErrorCode, type PublishRequestBody, type PublishResponseBody, READ_ERROR_CODES, type ReadErrorBody, type ReadErrorCode, type ReadPkgResponse, REGISTER_AUTHOR_KEY_ERROR_CODES, type RegisterAuthorKeyErrorBody, type RegisterAuthorKeyErrorCode, type RegisterAuthorKeyRequestBody, type RegisterAuthorKeyResponseBody, SEARCH_ERROR_CODES, SEARCH_SORT_OPTIONS, type SearchErrorBody, type SearchErrorCode, type SearchResponse, type SearchResultEntry, type SearchSort, type VersionListEntry, type Visibility, } from './types.js';
14
- export { BLUEPRINT_EXTERNAL_MODULES, compileBlueprint, compiledDigestHex, type CompileBlueprintErr, type CompileBlueprintOk, type CompileBlueprintResult, } from './ops/compile.js';
14
+ export { compileBlueprint, type CompileBlueprintErr, type CompileBlueprintOk, type CompileBlueprintResult, } from './ops/compile.js';
15
15
  export { checkConformance, MAX_BLUEPRINT_SOURCE_BYTES, type BlueprintProbeRunner, type ConformanceError, type ConformanceErrorCode, type ConformanceFailureCode, type ConformanceRequestPayload, type ConformanceResponseBody, } from './ops/conformance.js';
16
16
  export { publishArtifact, MAX_BUNDLE_BYTES, type PublishArtifactDeps, type PublishArtifactInput, type PublishArtifactResult, } from './ops/publish.js';
17
17
  export { readArtifact, type ReadArtifactDeps, type ReadArtifactInput, type ReadArtifactResult, } from './ops/read.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,YAAY,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAC1D,YAAY,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AACpE,OAAO,EACL,2BAA2B,EAC3B,KAAK,mBAAmB,EACxB,KAAK,eAAe,GACrB,MAAM,kCAAkC,CAAC;AAG1C,OAAO,EACL,qBAAqB,EACrB,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,KAAK,YAAY,EACjB,KAAK,eAAe,EACpB,KAAK,SAAS,EACd,yBAAyB,EACzB,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,oBAAoB,EACzB,mBAAmB,EACnB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACvB,KAAK,mBAAmB,EACxB,gBAAgB,EAChB,KAAK,aAAa,EAClB,KAAK,aAAa,EAClB,KAAK,eAAe,EACpB,+BAA+B,EAC/B,KAAK,0BAA0B,EAC/B,KAAK,0BAA0B,EAC/B,KAAK,4BAA4B,EACjC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js';
11
11
  // Types — rows + wire shapes
12
12
  export { ARTIFACTS_METADATA_SK, LIST_VERSIONS_ERROR_CODES, PUBLISH_ERROR_CODES, READ_ERROR_CODES, REGISTER_AUTHOR_KEY_ERROR_CODES, SEARCH_ERROR_CODES, SEARCH_SORT_OPTIONS, } from './types.js';
13
13
  // Operations
14
- export { BLUEPRINT_EXTERNAL_MODULES, compileBlueprint, compiledDigestHex, } from './ops/compile.js';
14
+ export { compileBlueprint, } from './ops/compile.js';
15
15
  export { checkConformance, MAX_BLUEPRINT_SOURCE_BYTES, } from './ops/conformance.js';
16
16
  export { publishArtifact, MAX_BUNDLE_BYTES, } from './ops/publish.js';
17
17
  export { readArtifact, } from './ops/read.js';
@@ -3,9 +3,9 @@
3
3
  *
4
4
  * Vendor-neutral — registry-core's API never names a specific identity
5
5
  * provider (no JWT, no bearer, no cloud-vendor enum). Verification is
6
- * transport-specific: cloud handlers verify a JWT from the platform's
7
- * hosted auth surface and produce an `AuthnContext`; the OSS server
8
- * verifies a bearer token and produces an `AuthnContext`. Once
6
+ * transport-specific: a hosted deployment's handlers verify a JWT
7
+ * from its identity provider and produce an `AuthnContext`; the OSS
8
+ * server verifies a bearer token and produces an `AuthnContext`. Once
9
9
  * registry-core has the context, it only knows WHO is calling, not
10
10
  * HOW they proved it.
11
11
  *
@@ -16,8 +16,9 @@
16
16
  *
17
17
  * ## Protocol & Contract Bar
18
18
  *
19
- * **Parties:** the registry transport (cloud Lambda or OSS hono
20
- * server) is the producer; registry-core's ops are the consumer.
19
+ * **Parties:** the registry transport (a hosted deployment's handler
20
+ * or the OSS hono server) is the producer; registry-core's ops are
21
+ * the consumer.
21
22
  *
22
23
  * **Obligations:** the producer MUST verify the caller's credentials
23
24
  * (JWT signature, bearer-token constant-time compare, …) before
@@ -41,7 +42,7 @@
41
42
  */
42
43
  export interface AuthnContext {
43
44
  /**
44
- * Stable, opaque caller identity. Cloud transport: hosted-auth `sub`
45
+ * Stable, opaque caller identity. JWT transport: the token's `sub`
45
46
  * claim. OSS bearer: a configured user identifier the operator chose
46
47
  * to associate with the token (or a hash of the token itself when no
47
48
  * identifier is configured).
@@ -1 +1 @@
1
- {"version":3,"file":"authn.d.ts","sourceRoot":"","sources":["../../src/interfaces/authn.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AACH,MAAM,WAAW,YAAY;IAC3B;;;;;OAKG;IACH,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B"}
1
+ {"version":3,"file":"authn.d.ts","sourceRoot":"","sources":["../../src/interfaces/authn.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyCG;AACH,MAAM,WAAW,YAAY;IAC3B;;;;;OAKG;IACH,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B"}
@@ -1,21 +1,21 @@
1
1
  /**
2
- * `BundleStorage` — bundle + signature + manifest blob storage. The
3
- * hosted registry backs this with S3 behind a CDN; the open-source
4
- * server backs it with the filesystem under
2
+ * `BundleStorage` — bundle + signature + manifest blob storage. A
3
+ * hosted implementation may serve blobs from object storage behind a
4
+ * CDN; the open-source server backs it with the filesystem under
5
5
  * `<root>/bundles/<scope>/<name>/<version>/`. A memory impl is
6
6
  * provided for tests.
7
7
  *
8
8
  * Each `put*` method returns the fully-qualified URL the consumer
9
9
  * (iframe runtime, install CLI) can fetch. The URL prefix is
10
- * determined by the impl's constructor — a CDN alias for the hosted
11
- * registry, or `http://localhost:9001` (or whatever the server is
12
- * bound to) for the open-source server.
10
+ * determined by the impl's constructor — a CDN alias for a
11
+ * CDN-fronted implementation, or `http://localhost:9001` (or
12
+ * whatever the server is bound to) for the open-source server.
13
13
  *
14
14
  * Bundles are immutable post-publish. Responses MUST emit
15
15
  * `Cache-Control: public, max-age=31536000, immutable` — SRI integrity
16
16
  * depends on it. The OSS server's bundle route sets this header
17
- * explicitly; the cloud's CloudFront distribution sets it via its
18
- * cache policy.
17
+ * explicitly; a CDN-fronted implementation sets it via its cache
18
+ * policy.
19
19
  *
20
20
  * ## Protocol & Contract Bar
21
21
  *
@@ -1,9 +1,9 @@
1
1
  /**
2
2
  * `RegistryStorage` — the per-row persistence seam for the marketplace
3
- * registry. The interface mirrors a three-table DynamoDB shape
4
- * (artifacts + artifact-versions + author-keys) so a hosted DynamoDB
5
- * adapter can be a structural pass-through. Memory + filesystem impls
6
- * back the open-source server and unit tests.
3
+ * registry. The interface is a three-table key-value shape
4
+ * (artifacts + artifact-versions + author-keys) chosen so a hosted
5
+ * database adapter can be a structural pass-through. Memory +
6
+ * filesystem impls back the open-source server and unit tests.
7
7
  *
8
8
  * The shape follows a single-interface / multiple-impls / contract-test
9
9
  * pattern, with a Protocol & Contract Bar docstring.
@@ -23,19 +23,20 @@
23
23
  *
24
24
  * **Obligations:**
25
25
  * - {@link putArtifactVersionIfAbsent} MUST atomically reject when a row
26
- * exists for `(artifactId, version)`. Mirrors DDB's
27
- * `ConditionExpression: attribute_not_exists(...)`. Implementations
26
+ * exists for `(artifactId, version)` — a conditional put-if-absent
27
+ * at the storage layer. Implementations
28
28
  * MUST NOT overwrite on conflict — per-version immutability is a
29
29
  * load-bearing registry invariant.
30
30
  * - {@link getArtifactMetadata} / {@link getArtifactVersion} MUST return
31
31
  * exactly what was last written. `null` on miss; throw on transport
32
32
  * failure (caller decides retry).
33
- * - {@link scanArtifacts} returns rows in arbitrary order (cloud DDB
34
- * Scan order; memory insertion order; filesystem directory order).
33
+ * - {@link scanArtifacts} returns rows in arbitrary order
34
+ * (backing-store scan order; memory insertion order; filesystem
35
+ * directory order).
35
36
  * Consumers MUST treat ordering as non-deterministic.
36
37
  *
37
38
  * **Failure mode:**
38
- * - Transport-level failures (DDB throttle, disk full) throw.
39
+ * - Transport-level failures (store throttling, disk full) throw.
39
40
  * {@link publishArtifact} wraps and returns 500 with `internal`
40
41
  * error code.
41
42
  * - Missing rows return `null`; never throw.
@@ -63,8 +64,8 @@ export interface PutAuthorKeyOptions {
63
64
  /**
64
65
  * Thrown by {@link RegistryStorage.putAuthorKey} when the caller passed
65
66
  * `ifNotExists: true` AND a row already exists for `(subject, keyId)`.
66
- * Cloud DDB adapter surfaces `ConditionalCheckFailedException` as this
67
- * type; in-memory impl mirrors the contract synchronously.
67
+ * A hosted database adapter surfaces its conditional-write conflict
68
+ * as this type; the in-memory impl mirrors the contract synchronously.
68
69
  *
69
70
  * Callers re-read via {@link RegistryStorage.getAuthorKey} and dispatch
70
71
  * same-publicKey → 200, different-publicKey → 409.
@@ -91,16 +92,16 @@ export interface RegistryStorage {
91
92
  getArtifactVersion(artifactId: string, version: string): Promise<ArtifactVersionRow | null>;
92
93
  /**
93
94
  * List every version row for `artifactId`. Returns in arbitrary order
94
- * (DDB Query order by SK = version, lexicographic; memory map
95
+ * (backing-store query order; memory map
95
96
  * insertion order; filesystem directory order). Callers MUST sort
96
97
  * by semver themselves if they need ordering.
97
98
  *
98
99
  * Backs the `GET /pkg/:scope/:name` list-versions route.
99
100
  *
100
- * **Cost note.** A DynamoDB impl uses `Query` with `PK = artifactId`,
101
- * which is the cheapest possible per-artifact lookup (no Scan, no
102
- * GSI). Memory + filesystem impls do a full table walk filtered by
103
- * artifactId — adequate for bounded row counts.
101
+ * **Cost note.** A key-value impl can serve this as a single
102
+ * partition query keyed by artifactId — the cheapest possible
103
+ * per-artifact lookup. Memory + filesystem impls do a full table
104
+ * walk filtered by artifactId — adequate for bounded row counts.
104
105
  *
105
106
  * **Returns:** empty array when no versions exist (NOT null) — the
106
107
  * "metadata-row present but no version rows" state should never
@@ -158,8 +159,9 @@ export interface RegistryStorage {
158
159
  * - Version-row conflict — `(artifactId, version)` already exists.
159
160
  * NEITHER row mutates. Returns `{ ok: false, reason: 'version_exists' }`.
160
161
  * The publisher's idempotent-retry path.
161
- * - Transport-level failures (DDB throttle, disk full, transaction
162
- * conflict not attributable to either conditional) throw —
162
+ * - Transport-level failures (store throttling, disk full,
163
+ * transaction conflict not attributable to either conditional)
164
+ * throw —
163
165
  * {@link publishArtifact} wraps and returns 500.
164
166
  *
165
167
  * **Atomicity guarantee:**
@@ -167,10 +169,11 @@ export interface RegistryStorage {
167
169
  * - Memory + filesystem impls: single-threaded JS event loop —
168
170
  * the function awaits both writes before returning, no other
169
171
  * awaitable interleaves.
170
- * - Cloud DDB impl: `TransactWriteItems` is all-or-nothing at the
171
- * service level. The new-blob path issues one transaction; the
172
- * dedup path may retry once if the optimistic new-blob path
173
- * fails because the digest landed between read-and-write.
172
+ * - A hosted database impl uses its store's all-or-nothing
173
+ * multi-row transaction. The new-blob path issues one
174
+ * transaction; the dedup path may retry once if the optimistic
175
+ * new-blob path fails because the digest landed between
176
+ * read-and-write.
174
177
  *
175
178
  * **Why a single transaction matters (refCount double-increment on
176
179
  * retry)**: a sequenced write path could increment refCount, then
@@ -1 +1 @@
1
- {"version":3,"file":"registry-storage.d.ts","sourceRoot":"","sources":["../../src/interfaces/registry-storage.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+CG;AACH,OAAO,KAAK,EACV,kBAAkB,EAClB,kBAAkB,EAClB,oBAAoB,EACpB,YAAY,EACZ,eAAe,EAChB,MAAM,aAAa,CAAC;AAErB;;;;;;;;;GASG;AACH,MAAM,WAAW,mBAAmB;IAClC,QAAQ,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;CAChC;AAED;;;;;;;;GAQG;AACH,qBAAa,2BAA4B,SAAQ,KAAK;IACpD,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;gBACX,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM;CAQ3C;AAED,MAAM,WAAW,eAAe;IAE9B,mBAAmB,CAAC,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,oBAAoB,GAAG,IAAI,CAAC,CAAC;IAC9E,mBAAmB,CA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AC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,SAAS,YAAY,EAAE,CAAC,CAAC;CACnE"}
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * Thrown by {@link RegistryStorage.putAuthorKey} when the caller passed
3
3
  * `ifNotExists: true` AND a row already exists for `(subject, keyId)`.
4
- * Cloud DDB adapter surfaces `ConditionalCheckFailedException` as this
5
- * type; in-memory impl mirrors the contract synchronously.
4
+ * A hosted database adapter surfaces its conditional-write conflict
5
+ * as this type; the in-memory impl mirrors the contract synchronously.
6
6
  *
7
7
  * Callers re-read via {@link RegistryStorage.getAuthorKey} and dispatch
8
8
  * same-publicKey → 200, different-publicKey → 409.
@@ -17,21 +17,6 @@ export interface CompileBlueprintErr {
17
17
  }>;
18
18
  }
19
19
  export type CompileBlueprintResult = CompileBlueprintOk | CompileBlueprintErr;
20
- /**
21
- * Always-allowed imports on the SOURCE side. Mirrors the conformance
22
- * gate's `BLUEPRINT_ALLOWED_IMPORTS` to keep the wire-contract aligned;
23
- * any addition here MUST land in the conformance gate at the same
24
- * commit (and vice versa).
25
- */
26
- export declare const BLUEPRINT_EXTERNAL_MODULES: readonly string[];
27
- /**
28
- * Hex SHA-256 of `compiledBytes` (base64-decoded). Pure function; the
29
- * deterministic-compile contract is `compile(source) → sha256(bytes)`.
30
- *
31
- * Exported for callers that want to recompute the digest without
32
- * re-compiling (e.g. install-time defense-in-depth).
33
- */
34
- export declare function compiledDigestHex(compiledBytes: string): string;
35
20
  /**
36
21
  * Compile a blueprint's TSX `source` into canonical compiled JS bytes.
37
22
  *
@@ -1 +1 @@
1
- {"version":3,"file":"compile.d.ts","sourceRoot":"","sources":["../../src/ops/compile.ts"],"names":[],"mappings":"AAsDA,uEAAuE;AACvE,MAAM,WAAW,kBAAkB;IACjC,QAAQ,CAAC,EAAE,EAAE,IAAI,CAAC;IAClB,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;IAC/B,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;I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,IAAI,CAAC,EAAE,MAAM,CAAC;YAAC,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAA;SAAE,CAAC;KAC1E,CAAC,CAAC;CACJ;AAED,MAAM,MAAM,sBAAsB,GAAG,kBAAkB,GAAG,mBAAmB,CAAC;AAE9E;;;;;;;;;;;GAWG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,sBAAsB,CA4CvE"}
@@ -20,19 +20,17 @@
20
20
  * target: 'es2022' — pinned to the lowest engine the
21
21
  * protocol supports; rebumping is a
22
22
  * minor protocol version bump.
23
- * bundle: true — single-file output; the matcher writes
24
- * the bytes directly into componentCode.
25
23
  * minify: false — readability matters more than size at
26
24
  * this scale (~10s of KB per blueprint).
27
- * external: ['react', — host-provided modules at iframe-render
28
- * 'react-dom', time. The conformance gate enforces
29
- * 'react/jsx-runtime', the same allow-list on the SOURCE
30
- * '@ggui-ai/gadgets'] side so we never compile a blueprint
31
- * whose imports don't survive bundling.
32
- * loader.tsx: 'tsx' — input is JSX/TSX text.
25
+ * loader: 'tsx' — input is JSX/TSX text.
33
26
  * treeShaking: false — preserve all imports so the conformance
34
27
  * gate's import-walk matches what's in
35
- * the compiled output.
28
+ * the compiled output. Imports pass
29
+ * through verbatim (transformSync does
30
+ * no bundle resolution); consumers
31
+ * (iframe runtime, matcher) provide the
32
+ * conformance-gate allow-listed modules
33
+ * at module-load time.
36
34
  *
37
35
  * **esbuild version pin.** `packages/registry-core/package.json` pins
38
36
  * `esbuild` to a single minor — the digest is sensitive to esbuild's
@@ -51,28 +49,6 @@
51
49
  */
52
50
  import * as esbuild from 'esbuild';
53
51
  import { createHash } from 'node:crypto';
54
- /**
55
- * Always-allowed imports on the SOURCE side. Mirrors the conformance
56
- * gate's `BLUEPRINT_ALLOWED_IMPORTS` to keep the wire-contract aligned;
57
- * any addition here MUST land in the conformance gate at the same
58
- * commit (and vice versa).
59
- */
60
- export const BLUEPRINT_EXTERNAL_MODULES = Object.freeze([
61
- 'react',
62
- 'react-dom',
63
- 'react/jsx-runtime',
64
- '@ggui-ai/gadgets',
65
- ]);
66
- /**
67
- * Hex SHA-256 of `compiledBytes` (base64-decoded). Pure function; the
68
- * deterministic-compile contract is `compile(source) → sha256(bytes)`.
69
- *
70
- * Exported for callers that want to recompute the digest without
71
- * re-compiling (e.g. install-time defense-in-depth).
72
- */
73
- export function compiledDigestHex(compiledBytes) {
74
- return createHash('sha256').update(Buffer.from(compiledBytes, 'base64')).digest('hex');
75
- }
76
52
  /**
77
53
  * Compile a blueprint's TSX `source` into canonical compiled JS bytes.
78
54
  *
@@ -105,13 +81,12 @@ export function compileBlueprint(source) {
105
81
  // path strings into the output, breaking digest stability.
106
82
  sourcemap: false,
107
83
  });
108
- // Note on `BLUEPRINT_EXTERNAL_MODULES`: with `transformSync` (not
109
- // `buildSync`) imports are preserved verbatim in the output —
110
- // tree-shaking off + no bundle resolution means the import
111
- // statements pass through unmodified. The externals list is the
112
- // CONTRACT consumers (iframe runtime, matcher) honor at module-
113
- // load time. The conformance gate's import-walk enforces the
114
- // allow-list on the source side before publish.
84
+ // With `transformSync` (not `buildSync`) imports are preserved
85
+ // verbatim in the output — tree-shaking off + no bundle resolution
86
+ // means the import statements pass through unmodified. Consumers
87
+ // (iframe runtime, matcher) provide the allow-listed modules at
88
+ // module-load time; the conformance gate's import-walk enforces
89
+ // that allow-list on the source side before publish.
115
90
  const bytes = Buffer.from(result.code, 'utf-8');
116
91
  const compiledBytes = bytes.toString('base64');
117
92
  const compiledDigest = createHash('sha256').update(bytes).digest('hex');
@@ -1,7 +1,6 @@
1
1
  /**
2
- * Conformance check — a pure function shared by the registry server,
3
- * the hosted registry, and the publish op so they all enforce the
4
- * same gate.
2
+ * Conformance check — a pure function shared by every registry
3
+ * transport and the publish op so they all enforce the same gate.
5
4
  *
6
5
  * ## Gadget gates
7
6
  *
@@ -117,9 +116,9 @@ export interface ConformanceResponseBody {
117
116
  */
118
117
  export declare const MAX_BLUEPRINT_SOURCE_BYTES: number;
119
118
  /**
120
- * Run the conformance check synchronously. Pure function: no AWS, no
119
+ * Run the conformance check synchronously. Pure function: no
121
120
  * network, no env lookups. Returns the locked response body shape.
122
- * The OSS server, the cloud Lambda, and the publish op all call this.
121
+ * Every registry transport and the publish op call this.
123
122
  *
124
123
  * Static gates only — the optional runtime probe lives behind a
125
124
  * {@link BlueprintProbeRunner} seam so registry-core stays free of
@@ -1 +1 @@
1
- {"version":3,"file":"conformance.d.ts","sourceRoot":"","sources":["../../src/ops/conformance.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkEG;AACH,OAAO,EAEL,KAAK,gBAAgB,EACtB,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAGL,KAAK,YAAY,EACjB,KAAK,YAAY,EAClB,MAAM,YAAY,CAAC;AAGpB;;;;GAIG;AACH,MAAM,WAAW,yBAAyB;IACxC,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED;;;;;;;;;GASG;AACH,MAAM,MAAM,oBAAoB,GAC5B,kBAAkB,GAClB,oBAAoB,GACpB,mBAAmB,GACnB,wBAAwB,GACxB,4BAA4B,GAC5B,yBAAyB,GACzB,6BAA6B,GAC7B,kCAAkC,GAClC,8BAA8B,GAC9B,gCAAgC,CAAC;AAErC,MAAM,MAAM,sBAAsB,GAAG,oBAAoB,CAAC;AAE1D,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,IAAI,EAAE,oBAAoB,CAAC;IACpC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB;;;;OAIG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,SAAS,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,CAAC;IAC7C;;;OAGG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,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AAoB,CAAC;AAE1D,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,IAAI,EAAE,oBAAoB,CAAC;IACpC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB;;;;OAIG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,SAAS,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,CAAC;IAC7C;;;OAGG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC;CAC3B;AAED,MAAM,WAAW,uBAAuB;IACtC,QAAQ,CAAC,EAAE,EAAE,OAAO,CAAC;IACrB,QAAQ,CAAC,MAAM,EAAE,SAAS,gBAAgB,EAAE,CAAC;CAC9C;AAkBD;;;;;;;GAOG;AACH,eAAO,MAAM,0BAA0B,QAAkB,CAAC;AAE1D;;;;;;;;;GASG;AACH,wBAAgB,gBAAgB,CAC9B,OAAO,EAAE,yBAAyB,GACjC,uBAAuB,CAgBzB;AAmbD;;;;;;;;;;GAUG;AACH,MAAM,WAAW,oBAAoB;IACnC;;;;;;OAMG;IACH,KAAK,CACH,QAAQ,EAAE,OAAO,CAAC,gBAAgB,EAAE;QAAE,IAAI,EAAE,WAAW,CAAA;KAAE,CAAC,GACzD,OAAO,CAAC,uBAAuB,CAAC,CAAC;CACrC;AAED,YAAY,EAAE,YAAY,EAAE,YAAY,EAAE,CAAC"}
@@ -1,7 +1,6 @@
1
1
  /**
2
- * Conformance check — a pure function shared by the registry server,
3
- * the hosted registry, and the publish op so they all enforce the
4
- * same gate.
2
+ * Conformance check — a pure function shared by every registry
3
+ * transport and the publish op so they all enforce the same gate.
5
4
  *
6
5
  * ## Gadget gates
7
6
  *
@@ -92,9 +91,9 @@ const ALWAYS_ALLOWED_IMPORTS = new Set([
92
91
  */
93
92
  export const MAX_BLUEPRINT_SOURCE_BYTES = 5 * 1024 * 1024;
94
93
  /**
95
- * Run the conformance check synchronously. Pure function: no AWS, no
94
+ * Run the conformance check synchronously. Pure function: no
96
95
  * network, no env lookups. Returns the locked response body shape.
97
- * The OSS server, the cloud Lambda, and the publish op all call this.
96
+ * Every registry transport and the publish op call this.
98
97
  *
99
98
  * Static gates only — the optional runtime probe lives behind a
100
99
  * {@link BlueprintProbeRunner} seam so registry-core stays free of
@@ -29,9 +29,9 @@ import type { AuthnContext } from '../interfaces/authn.js';
29
29
  import type { RegistryStorage } from '../interfaces/registry-storage.js';
30
30
  export interface ListArtifactVersionsInput {
31
31
  /**
32
- * `<scope>/<name>` — the install identifier. Scope MUST start with `@`.
33
- * Cloud API Gateway path params drop the leading `@`; the cloud
34
- * Lambda shell re-prepends before calling this op.
32
+ * `<scope>/<name>` — the install identifier. Scope MUST start
33
+ * with `@`. Transports whose path params drop the leading `@`
34
+ * MUST re-prepend it before calling this op.
35
35
  */
36
36
  readonly artifactId: string;
37
37
  }
@@ -1 +1 @@
1
- {"version":3,"file":"publish.d.ts","sourceRoot":"","sources":["../../src/ops/publish.ts"],"names":[],"mappings":"AA2BA,OAAO,EAKL,KAAK,eAAe,EAErB,MAAM,yBAAyB,CAAC;AAGjC,OAAO,KAAK,EAIV,gBAAgB,EAEhB,mBAAmB,EACpB,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EACV,oBAAoB,EAErB,MAAM,kBAAkB,CAAC;AAE1B,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iCAAiC,CAAC;AACrE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AAMzE;;;;;;GAMG;AACH,eAAO,MAAM,gBAAgB,QAAkB,CAAC;AAEhD,MAAM,WAAW,oBAAoB;IACnC,4DAA4D;IAC5D,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,2EAA2E;IAC3E,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IACzB,8FAA8F;IAC9F,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAA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EAAE,oBAAoB,EAC3B,IAAI,EAAE,mBAAmB,GACxB,OAAO,CAAC,qBAAqB,CAAC,CAuXhC"}
@@ -22,7 +22,7 @@
22
22
  * 10. Return 201 with the wire-locked {@link PublishResponseBody}.
23
23
  */
24
24
  import { parseArtifactManifest, } from '@ggui-ai/artifact-manifest';
25
- import { canonicalJson, isGadgetSignature, verifyBundleEd25519, verifyBundleSigstore, } from '@ggui-ai/gadget-signing';
25
+ import { canonicalJson, extractSigstoreLeafCertPem, isGadgetSignature, verifyBundleEd25519, verifyBundleSigstore, } from '@ggui-ai/gadget-signing';
26
26
  import { bundleHostScheme } from '@ggui-ai/protocol';
27
27
  import { ZodError } from 'zod';
28
28
  import { ARTIFACTS_METADATA_SK } from '../types.js';
@@ -155,13 +155,10 @@ export async function publishArtifact(input, deps) {
155
155
  return error(400, 'signature_invalid', verifyResult.reason);
156
156
  }
157
157
  // Persist the leaf cert PEM on the version row so install
158
- // consumers can render the signer identity. Extracted inline from
159
- // the bundle's `verificationMaterial.x509CertificateChain.certificates[0]`
160
- // for now — TODO: replace with `extractSigstoreLeafCertPem(signature)`
161
- // from `@ggui-ai/gadget-signing` so the parsing logic lives next to
162
- // the bundle-format knowledge (single source of truth for the
163
- // cosign-bundle shape).
164
- const leafCertPem = extractSigstoreLeafCertPemInline(input.signature);
158
+ // consumers can render the signer identity. The cosign-bundle
159
+ // parsing lives in `@ggui-ai/gadget-signing` next to the verify
160
+ // impl (single source of truth for the bundle shape).
161
+ const leafCertPem = extractSigstoreLeafCertPem(input.signature);
165
162
  if (leafCertPem === undefined) {
166
163
  return error(400, 'signature_invalid', 'sigstore verify succeeded but bundle is missing `verificationMaterial.x509CertificateChain.certificates[0].rawBytes` — cannot pin author identity on the version row');
167
164
  }
@@ -348,46 +345,6 @@ function error(status, code, message, detail) {
348
345
  body: detail === undefined ? { error: code, message } : { error: code, message, detail },
349
346
  };
350
347
  }
351
- /**
352
- * Extract the Fulcio leaf cert's base64 raw bytes from a serialized
353
- * cosign bundle (per `@sigstore/bundle` v0.3 spec). Returns `undefined`
354
- * if the bundle is malformed or missing the cert chain.
355
- *
356
- * Inline today — TODO: pull this into `@ggui-ai/gadget-signing` as
357
- * `extractSigstoreLeafCertPem` so the bundle-format knowledge sits
358
- * next to the verify impl. The install CLI carries an identical
359
- * helper today; both should collapse to the single canonical export.
360
- */
361
- function extractSigstoreLeafCertPemInline(signature) {
362
- let parsed;
363
- try {
364
- parsed = JSON.parse(signature.bundle);
365
- }
366
- catch {
367
- return undefined;
368
- }
369
- if (parsed === null || typeof parsed !== 'object')
370
- return undefined;
371
- const verificationMaterial = parsed
372
- .verificationMaterial;
373
- if (verificationMaterial === null || typeof verificationMaterial !== 'object') {
374
- return undefined;
375
- }
376
- const chain = verificationMaterial
377
- .x509CertificateChain;
378
- if (chain === null || typeof chain !== 'object')
379
- return undefined;
380
- const certificates = chain.certificates;
381
- if (!Array.isArray(certificates) || certificates.length === 0)
382
- return undefined;
383
- const leaf = certificates[0];
384
- if (leaf === null || typeof leaf !== 'object')
385
- return undefined;
386
- const rawBytes = leaf.rawBytes;
387
- if (typeof rawBytes !== 'string' || rawBytes.length === 0)
388
- return undefined;
389
- return rawBytes;
390
- }
391
348
  /**
392
349
  * Translate a {@link ConformanceResponseBody} error list into a 400
393
350
  * `PublishArtifactResult`. Used by both the static-gate failure path
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * `readArtifact` — pure op for `GET /pkg/{scope}/{name}/{version}`.
3
- * A shared op that both this server and the hosted registry project
4
- * through their respective transport shells.
3
+ * A shared op that every registry deployment projects through its
4
+ * own transport shell.
5
5
  *
6
6
  * Flow:
7
7
  * 1. Point-read the version row via {@link RegistryStorage.getArtifactVersion}.
@@ -19,9 +19,9 @@ import type { AuthnContext } from '../interfaces/authn.js';
19
19
  import type { RegistryStorage } from '../interfaces/registry-storage.js';
20
20
  export interface ReadArtifactInput {
21
21
  /**
22
- * `<scope>/<name>` — the install identifier. Scope MUST start with `@`.
23
- * Cloud API Gateway path params drop the leading `@`; the cloud
24
- * Lambda shell re-prepends before calling this op.
22
+ * `<scope>/<name>` — the install identifier. Scope MUST start
23
+ * with `@`. Transports whose path params drop the leading `@`
24
+ * MUST re-prepend it before calling this op.
25
25
  */
26
26
  readonly artifactId: string;
27
27
  readonly version: string;
package/dist/types.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Row + wire shapes for the ggui marketplace registry. The same
3
- * shapes back both this open-source server and the hosted registry,
3
+ * shapes back this open-source server and any hosted implementation,
4
4
  * so they project against one definition.
5
5
  *
6
6
  * Rows are the storage-layer projection — what {@link RegistryStorage}
@@ -18,12 +18,12 @@ import type { ArtifactManifest } from '@ggui-ai/artifact-manifest';
18
18
  import type { GadgetSignature } from '@ggui-ai/gadget-signing';
19
19
  import type { ConformanceFailureCode } from './ops/conformance.js';
20
20
  /**
21
- * SK literal for the per-artifactId metadata row on the cloud's
22
- * Artifacts table. Pinned as a constant so cloud + OSS impls agree
23
- * on the SK.
21
+ * SK literal for the per-artifactId metadata row in a sort-keyed
22
+ * table layout. Pinned as a constant so every impl agrees on the SK.
24
23
  *
25
- * OSS impls (filesystem / memory) MAY ignore this — they have one row
26
- * per artifactId so no SK is needed. Cloud DDB impls MUST honor it.
24
+ * Filesystem / memory impls MAY ignore this — they have one row per
25
+ * artifactId so no SK is needed. Sort-keyed database impls MUST
26
+ * honor it.
27
27
  */
28
28
  export declare const ARTIFACTS_METADATA_SK: "metadata#";
29
29
  /**
@@ -118,17 +118,18 @@ export interface ArtifactVersionRow {
118
118
  * load-bearing: federation-ready, cross-app cache sharing, and
119
119
  * sigstore signing all key off `compiledDigest`.
120
120
  *
121
- * **Storage choice — inline base64 vs S3 pointer.** The compiled
121
+ * **Storage choice — inline base64 vs blob pointer.** The compiled
122
122
  * bytes are inlined as a base64-encoded string column. Rationale:
123
123
  * blueprints today ship raw TSX inline on `manifest.source` (capped
124
124
  * at 5 MiB by `MAX_BLUEPRINT_SOURCE_BYTES`); compiled JS is typically
125
- * 1.5–3× the TSX size. DynamoDB's 400-KiB item ceiling caps practical
126
- * inline storage around ~300 KiB compiled (~200 KiB TSX), which
127
- * accommodates every realistic blueprint observed so far. Larger
128
- * blueprints (and gadgets, which always exceed this) will need an
129
- * S3-pointer variant as a future enhancement. Inline storage keeps
130
- * the two-layer write/read contract simple, without the bucket-
131
- * lifecycle and IAM-grant overhead of S3.
125
+ * 1.5–3× the TSX size. Typical KV row-size ceilings (e.g. 400 KiB)
126
+ * cap practical inline storage around ~300 KiB compiled (~200 KiB
127
+ * TSX), which accommodates every realistic blueprint observed so
128
+ * far. Larger blueprints (and gadgets, which always exceed this)
129
+ * will need a blob-store pointer variant as a future enhancement.
130
+ * Inline storage keeps the two-layer write/read contract simple,
131
+ * without the lifecycle and access-grant overhead of a separate
132
+ * blob store.
132
133
  *
133
134
  * **GC.** `refCount` is maintained on publish (+1) and yank (no
134
135
  * decrement — yanked versions retain their pointer for audit;
@@ -139,8 +140,8 @@ export interface ArtifactVersionRow {
139
140
  *
140
141
  * **Signatures.** `manifestSig` is the publisher's signature
141
142
  * (Ed25519 for private artifacts, sigstore-cosign for public) over
142
- * the manifest's canonical-JSON projection — read by the hosted
143
- * install path for defense-in-depth re-verification. Stored as a
143
+ * the manifest's canonical-JSON projection — read by the install
144
+ * path for defense-in-depth re-verification. Stored as a
144
145
  * JSON-encoded `GadgetSignature` discriminated union. `compiledSig`
145
146
  * (a registry-rooted sigstore signature over `compiledBytes`) is
146
147
  * reserved for a future enhancement.
@@ -160,7 +161,7 @@ export interface CompiledBlobRow {
160
161
  /**
161
162
  * Publisher's signature envelope, JSON-encoded `GadgetSignature`
162
163
  * discriminated union (Ed25519 for private, sigstore-cosign for
163
- * public). Read by the hosted install path for defense-in-depth
164
+ * public). Read by the install path for defense-in-depth
164
165
  * re-verification before persisting an installed blueprint. May be
165
166
  * absent on rows published before signature persistence existed;
166
167
  * the install path hard-fails such rows with a clear error pointing
@@ -229,9 +230,9 @@ export interface SearchResultEntry {
229
230
  readonly publishedAt: string;
230
231
  }
231
232
  /**
232
- * `GET /search?…` body. `nextCursor` is opaque (impl-defined: cloud
233
- * uses base64-encoded DDB LastEvaluatedKey; OSS uses an offset). Clients
234
- * roundtrip it verbatim on the next call.
233
+ * `GET /search?…` body. `nextCursor` is opaque (impl-defined: a
234
+ * paged-database impl encodes its native page cursor; OSS uses an
235
+ * offset). Clients roundtrip it verbatim on the next call.
235
236
  */
236
237
  export interface SearchResponse {
237
238
  readonly results: readonly SearchResultEntry[];
@@ -243,18 +244,19 @@ export interface SearchResponse {
243
244
  *
244
245
  * - `recent` — order by {@link ArtifactsMetadataRow.publishedAt} DESC.
245
246
  *
246
- * Default (sort omitted) is impl-defined ordering: memory uses insertion
247
- * order, filesystem uses directory order, DDB uses Scan order. Callers
248
- * MUST opt in to a deterministic order via this field.
247
+ * Default (sort omitted) is impl-defined ordering: memory uses
248
+ * insertion order, filesystem uses directory order, a database impl
249
+ * uses its scan order. Callers MUST opt in to a deterministic order
250
+ * via this field.
249
251
  *
250
252
  * **Scale ceiling.** The `recent` sort is implemented as an in-memory
251
253
  * pass on the page returned by {@link RegistryStorage.scanArtifacts}.
252
254
  * For pre-launch row counts (< ~1k artifacts, single-page scans with
253
255
  * `limit=200`) this gives a globally-correct order. Once the artifact
254
- * table grows past one Scan page (~1 MiB of items), the order is only
256
+ * table grows past one scan page (~1 MiB of items), the order is only
255
257
  * page-local — clients paginating with `cursor` see per-page recency,
256
- * not global. A DDB GSI on `publishedAt` is the proper fix and is
257
- * planned as a follow-up.
258
+ * not global. A secondary index on `publishedAt` is the proper fix
259
+ * and is planned as a follow-up.
258
260
  */
259
261
  export declare const SEARCH_SORT_OPTIONS: readonly ["recent"];
260
262
  export type SearchSort = (typeof SEARCH_SORT_OPTIONS)[number];
@@ -292,10 +294,10 @@ export interface VersionListEntry {
292
294
  *
293
295
  * No pagination cursor — registry artifact version counts are
294
296
  * inherently bounded (typical: < 50 versions per artifact, hard ceiling
295
- * around ~1k for the lifetime of an artifact). If a single artifact ever
296
- * crosses the 1 MiB DDB Query page, we'll add a cursor — but for now the
297
- * round-trip cost of paginating versions is greater than the cost of
298
- * returning them all.
297
+ * around ~1k for the lifetime of an artifact). If a single artifact
298
+ * ever crosses a backing store's query-page size (~1 MiB), we'll add
299
+ * a cursor — but for now the round-trip cost of paginating versions
300
+ * is greater than the cost of returning them all.
299
301
  */
300
302
  export interface ListVersionsResponse {
301
303
  readonly artifactId: string;
@@ -445,8 +447,9 @@ export type ErrorBody = PublishErrorBody | ReadErrorBody | SearchErrorBody | Reg
445
447
  * Search filter shape. Passed to {@link RegistryStorage.scanArtifacts}.
446
448
  * `limit` is clamped to [1, 200] by {@link searchArtifacts}; impls
447
449
  * should respect it as a hard ceiling. `cursor` is opaque to consumers
448
- * — impls choose their own encoding (DDB LastEvaluatedKey base64;
449
- * memory uses an integer offset; filesystem uses a last-seen artifactId).
450
+ * — impls choose their own encoding (a database impl's native page
451
+ * cursor; memory uses an integer offset; filesystem uses a last-seen
452
+ * artifactId).
450
453
  */
451
454
  export interface ArtifactScanFilter {
452
455
  readonly q?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AACH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AACnE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAC/D,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AAEnE;;;;;;;GAOG;AACH,eAAO,MAAM,qBAAqB,EAAG,WAAoB,CAAC;AAE1D;;;;GAIG;AACH,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,SAAS,CAAC;AAE9C;;GAEG;AACH,MAAM,MAAM,YAAY,GAAG,QAAQ,GAAG,WAAW,CAAC;AAElD;;;;;;;;GAQG;AACH,MAAM,WAAW,oBAAoB;IACnC,QAA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CAAC,KAAK,EAAE,qBAAqB,CAAC;IACtC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC;CAC3B"}
package/dist/types.js CHANGED
@@ -1,10 +1,10 @@
1
1
  /**
2
- * SK literal for the per-artifactId metadata row on the cloud's
3
- * Artifacts table. Pinned as a constant so cloud + OSS impls agree
4
- * on the SK.
2
+ * SK literal for the per-artifactId metadata row in a sort-keyed
3
+ * table layout. Pinned as a constant so every impl agrees on the SK.
5
4
  *
6
- * OSS impls (filesystem / memory) MAY ignore this — they have one row
7
- * per artifactId so no SK is needed. Cloud DDB impls MUST honor it.
5
+ * Filesystem / memory impls MAY ignore this — they have one row per
6
+ * artifactId so no SK is needed. Sort-keyed database impls MUST
7
+ * honor it.
8
8
  */
9
9
  export const ARTIFACTS_METADATA_SK = 'metadata#';
10
10
  /**
@@ -13,18 +13,19 @@ export const ARTIFACTS_METADATA_SK = 'metadata#';
13
13
  *
14
14
  * - `recent` — order by {@link ArtifactsMetadataRow.publishedAt} DESC.
15
15
  *
16
- * Default (sort omitted) is impl-defined ordering: memory uses insertion
17
- * order, filesystem uses directory order, DDB uses Scan order. Callers
18
- * MUST opt in to a deterministic order via this field.
16
+ * Default (sort omitted) is impl-defined ordering: memory uses
17
+ * insertion order, filesystem uses directory order, a database impl
18
+ * uses its scan order. Callers MUST opt in to a deterministic order
19
+ * via this field.
19
20
  *
20
21
  * **Scale ceiling.** The `recent` sort is implemented as an in-memory
21
22
  * pass on the page returned by {@link RegistryStorage.scanArtifacts}.
22
23
  * For pre-launch row counts (< ~1k artifacts, single-page scans with
23
24
  * `limit=200`) this gives a globally-correct order. Once the artifact
24
- * table grows past one Scan page (~1 MiB of items), the order is only
25
+ * table grows past one scan page (~1 MiB of items), the order is only
25
26
  * page-local — clients paginating with `cursor` see per-page recency,
26
- * not global. A DDB GSI on `publishedAt` is the proper fix and is
27
- * planned as a follow-up.
27
+ * not global. A secondary index on `publishedAt` is the proper fix
28
+ * and is planned as a follow-up.
28
29
  */
29
30
  export const SEARCH_SORT_OPTIONS = ['recent'];
30
31
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ggui-ai/registry-core",
3
- "version": "0.2.0-alpha.4",
3
+ "version": "0.4.0-rc.0",
4
4
  "description": "Pure-TypeScript registry operations and storage interfaces for the ggui marketplace. No I/O, no HTTP — operations take typed inputs plus a storage deps bag and return discriminated-union results.",
5
5
  "keywords": [
6
6
  "ggui",
@@ -44,9 +44,9 @@
44
44
  "esbuild": "0.25.12",
45
45
  "oxc-parser": "^0.131.0",
46
46
  "zod": "^4.3.6",
47
- "@ggui-ai/artifact-manifest": "0.2.0-alpha.4",
48
- "@ggui-ai/gadget-signing": "0.2.0-alpha.4",
49
- "@ggui-ai/protocol": "0.2.0-alpha.4"
47
+ "@ggui-ai/artifact-manifest": "0.4.0-rc.0",
48
+ "@ggui-ai/gadget-signing": "0.4.0-rc.0",
49
+ "@ggui-ai/protocol": "0.4.0-rc.0"
50
50
  },
51
51
  "peerDependenciesMeta": {
52
52
  "vitest": {
@@ -56,7 +56,7 @@
56
56
  "devDependencies": {
57
57
  "@types/node": "^24.0.0",
58
58
  "typescript": "^5.0.0",
59
- "vitest": "^3.0.0"
59
+ "vitest": "^3.2.6"
60
60
  },
61
61
  "repository": {
62
62
  "type": "git",