feat(client): add customUpCodes to Monitor type and validation schema
This commit is contained in:
1 parent
158d976ccb
commit
603bd1d814
2 files changed
+5
No files matched your search
@@ -71,6 +71,7 @@ export interface Monitor {
|
|||||||
uptimePercentage?: number;
|
uptimePercentage?: number;
|
||||||
notifications: string[];
|
notifications: string[];
|
||||||
tags: string[];
|
tags: string[];
|
||||||
|
customUpCodes?: number[];
|
||||||
secret?: string;
|
secret?: string;
|
||||||
cpuAlertThreshold: number;
|
cpuAlertThreshold: number;
|
||||||
cpuAlertCounter: number;
|
cpuAlertCounter: number;
|
||||||
|
|||||||
@@ -64,6 +64,10 @@ const httpSchema = baseSchema.extend({
|
|||||||
.register(monitorStepRegistry, { step: 2 }),
|
.register(monitorStepRegistry, { step: 2 }),
|
||||||
expectedValue: z.string().optional().register(monitorStepRegistry, { step: 2 }),
|
expectedValue: z.string().optional().register(monitorStepRegistry, { step: 2 }),
|
||||||
jsonPath: z.string().optional().register(monitorStepRegistry, { step: 2 }),
|
jsonPath: z.string().optional().register(monitorStepRegistry, { step: 2 }),
|
||||||
|
customUpCodes: z
|
||||||
|
.array(z.number().min(100).max(599))
|
||||||
|
.optional()
|
||||||
|
.register(monitorStepRegistry, { step: 2 }),
|
||||||
...geoCheckFields,
|
...geoCheckFields,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user