@camstack/types 0.1.18 → 0.1.20

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.
@@ -7263,11 +7263,17 @@ const ScopedTokenSummarySchema = zod.z.object({
7263
7263
  name: zod.z.string(),
7264
7264
  tokenPrefix: zod.z.string(),
7265
7265
  scopes: zod.z.array(TokenScopeSchema$1),
7266
- expiresAt: zod.z.number().optional(),
7267
- lastUsedAt: zod.z.number().optional(),
7266
+ // Mirror the storage schema: `.nullish()` accepts the SQLite-native
7267
+ // `null` for absent timestamps as well as in-memory `undefined`.
7268
+ expiresAt: zod.z.number().nullish(),
7269
+ lastUsedAt: zod.z.number().nullish(),
7268
7270
  createdAt: zod.z.number()
7269
7271
  });
7270
7272
  const CreateScopedTokenInputSchema = zod.z.object({
7273
+ // The owner the token is issued on behalf of. `adminProcedure` gates
7274
+ // this call so an admin can mint tokens for any user; the CLI passes
7275
+ // its own logged-in `user.id` here.
7276
+ userId: zod.z.string(),
7271
7277
  name: zod.z.string(),
7272
7278
  scopes: zod.z.array(TokenScopeSchema$1),
7273
7279
  expiresAt: zod.z.number().optional()
@@ -7959,8 +7965,10 @@ const ScopedTokenSchema = zod.z.object({
7959
7965
  tokenHash: zod.z.string(),
7960
7966
  tokenPrefix: zod.z.string(),
7961
7967
  scopes: zod.z.array(TokenScopeSchema),
7962
- expiresAt: zod.z.number().optional(),
7963
- lastUsedAt: zod.z.number().optional(),
7968
+ // SQLite/JSON storage round-trips undefined → null. Use `nullish` so the
7969
+ // schema accepts both `null` (read from disk) and `undefined` (in-memory).
7970
+ expiresAt: zod.z.number().nullish(),
7971
+ lastUsedAt: zod.z.number().nullish(),
7964
7972
  createdAt: zod.z.number()
7965
7973
  });
7966
7974
  exports.ACCESSORY_LABEL = ACCESSORY_LABEL;
@@ -8301,4 +8309,4 @@ exports.webrtcSessionCapability = webrtcSessionCapability;
8301
8309
  exports.zoneAnalyticsCapability = zoneAnalyticsCapability;
8302
8310
  exports.zoneRulesCapability = zoneRulesCapability;
8303
8311
  exports.zonesCapability = zonesCapability;
8304
- //# sourceMappingURL=auth-records-dZTcJ-2e.js.map
8312
+ //# sourceMappingURL=auth-records-BS1ylE_b.js.map