Skip to content

Commit 297515c

Browse files
committed
feat: update import path for ManifestSchema and add PluginVersionSchema with version history
1 parent c71c233 commit 297515c

2 files changed

Lines changed: 24 additions & 1 deletion

File tree

packages/spec/src/hub/composer.zod.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { z } from 'zod';
2-
import { ManifestSchema } from '../system/manifest.zod';
2+
import { ManifestSchema } from '../kernel/manifest.zod';
33

44
/**
55
* # Cloud Composer Protocol

packages/spec/src/hub/marketplace.zod.ts

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,23 @@ export const PluginPricingSchema = z.object({
2727
trialDays: z.number().int().optional(),
2828
});
2929

30+
/**
31+
* Plugin Version Schema
32+
* Specific release version details
33+
*/
34+
export const PluginVersionSchema = z.object({
35+
version: z.string().describe('SemVer string (e.g. 1.0.0)'),
36+
publishedAt: z.string().datetime().describe('Publication date'),
37+
downloadUrl: z.string().url().describe('Archive download URL'),
38+
checksum: z.string().optional().describe('Integrity checksum (shasum)'),
39+
engine: z.object({
40+
node: z.string().optional(),
41+
objectstack: z.string().describe('Required ObjectStack kernel version range'),
42+
}).optional().describe('Engine compatibility'),
43+
dependencies: z.record(z.string(), z.string()).optional().describe('Runtime plugin dependencies'),
44+
changeLog: z.string().optional().describe('Release notes'),
45+
});
46+
3047
/**
3148
* Plugin Registry Entry Schema
3249
* Represents a listing in the Marketplace.
@@ -38,6 +55,12 @@ export const MarketplacePluginSchema = z.object({
3855
*/
3956
id: z.string(),
4057

58+
/**
59+
* Version History
60+
* Registry of all available versions
61+
*/
62+
versions: z.record(z.string(), PluginVersionSchema).optional().describe('Map of versions (1.0.0) -> Details'),
63+
4164
/**
4265
* Display Name
4366
*/

0 commit comments

Comments
 (0)