spaps-types 1.0.15 → 1.0.18
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.
@@ -9,8 +9,8 @@ exports.secureMessageMetadataSchema = defaultMetadataSchema;
|
|
9
9
|
* Consumers can pass a custom metadata schema to get typed inference.
|
10
10
|
*/
|
11
11
|
const createSecureMessageRequestSchema = (metadataSchema = defaultMetadataSchema) => zod_1.z.object({
|
12
|
-
patientId: zod_1.z.string().
|
13
|
-
practitionerId: zod_1.z.string().
|
12
|
+
patientId: zod_1.z.string().uuid('patientId must be a valid UUID'),
|
13
|
+
practitionerId: zod_1.z.string().uuid('practitionerId must be a valid UUID'),
|
14
14
|
content: zod_1.z.string().min(1, 'content is required'),
|
15
15
|
metadata: metadataSchema.optional()
|
16
16
|
});
|
package/package.json
CHANGED
@@ -10,8 +10,8 @@ export const createSecureMessageRequestSchema = <MetadataSchema extends z.ZodTyp
|
|
10
10
|
metadataSchema: MetadataSchema = defaultMetadataSchema as unknown as MetadataSchema
|
11
11
|
) =>
|
12
12
|
z.object({
|
13
|
-
patientId: z.string().
|
14
|
-
practitionerId: z.string().
|
13
|
+
patientId: z.string().uuid('patientId must be a valid UUID'),
|
14
|
+
practitionerId: z.string().uuid('practitionerId must be a valid UUID'),
|
15
15
|
content: z.string().min(1, 'content is required'),
|
16
16
|
metadata: metadataSchema.optional()
|
17
17
|
});
|