@opengeni/contracts 0.6.0 → 0.7.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opengeni/contracts",
3
- "version": "0.6.0",
3
+ "version": "0.7.0",
4
4
  "description": "Shared zod schemas and wire-contract types for the OpenGeni API.",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
package/src/index.ts CHANGED
@@ -429,20 +429,6 @@ export const ErrorEnvelope = z.object({
429
429
  });
430
430
  export type ErrorEnvelope = z.infer<typeof ErrorEnvelope>;
431
431
 
432
- export const PageInfo = z.object({
433
- limit: z.number().int().positive(),
434
- nextCursor: z.string().nullable(),
435
- hasMore: z.boolean(),
436
- });
437
- export type PageInfo = z.infer<typeof PageInfo>;
438
-
439
- export function paginated<T extends z.ZodTypeAny>(item: T) {
440
- return z.object({
441
- data: z.array(item),
442
- page: PageInfo,
443
- });
444
- }
445
-
446
432
  export const Permission = z.enum([
447
433
  "account:read",
448
434
  "account:admin",
@@ -3493,6 +3479,10 @@ export type ClientModel = z.infer<typeof ClientModel>;
3493
3479
 
3494
3480
  export const ClientConfig = z.object({
3495
3481
  deploymentRevision: z.string(),
3482
+ // Release-train version of the server (absent on dev/source builds). The
3483
+ // compatibility policy lives in docs/architecture.md — clients within the
3484
+ // same major are supported; evolution is additive within a major.
3485
+ serverVersion: z.string().optional(),
3496
3486
  defaultModel: z.string(),
3497
3487
  allowedModels: z.array(z.string()).min(1),
3498
3488
  // Richer model list (provider-grouped) for the picker. Defaults to [] for