Skip to main content

Interface: UseMonitorFieldsResult

Defined in: src/hooks/useMonitorFields.ts:63

Result interface for the useMonitorFields hook

Propertiesโ€‹

error?โ€‹

optional error?: string;

Defined in: src/hooks/useMonitorFields.ts:65

Error message if loading failed


getFieldsโ€‹

getFields: (monitorType:
| "cdn-edge-consistency"
| "dns"
| "http"
| "http-header"
| "http-json"
| "http-keyword"
| "http-latency"
| "http-status"
| "ping"
| "port"
| "replication"
| "server-heartbeat"
| "ssl"
| "websocket-keepalive") => MonitorFieldDefinition[];

Defined in: src/hooks/useMonitorFields.ts:67

Get field definitions for a specific monitor type

Parametersโ€‹

monitorTypeโ€‹

| "cdn-edge-consistency" | "dns" | "http" | "http-header" | "http-json" | "http-keyword" | "http-latency" | "http-status" | "ping" | "port" | "replication" | "server-heartbeat" | "ssl" | "websocket-keepalive"

Returnsโ€‹

MonitorFieldDefinition[]


getRequiredFieldsโ€‹

getRequiredFields: (monitorType:
| "cdn-edge-consistency"
| "dns"
| "http"
| "http-header"
| "http-json"
| "http-keyword"
| "http-latency"
| "http-status"
| "ping"
| "port"
| "replication"
| "server-heartbeat"
| "ssl"
| "websocket-keepalive") => string[];

Defined in: src/hooks/useMonitorFields.ts:69

Get required fields for a specific monitor type

Parametersโ€‹

monitorTypeโ€‹

| "cdn-edge-consistency" | "dns" | "http" | "http-header" | "http-json" | "http-keyword" | "http-latency" | "http-status" | "ping" | "port" | "replication" | "server-heartbeat" | "ssl" | "websocket-keepalive"

Returnsโ€‹

string[]


isFieldRequiredโ€‹

isFieldRequired: (
monitorType:
| "cdn-edge-consistency"
| "dns"
| "http"
| "http-header"
| "http-json"
| "http-keyword"
| "http-latency"
| "http-status"
| "ping"
| "port"
| "replication"
| "server-heartbeat"
| "ssl"
| "websocket-keepalive",
fieldName: string
) => boolean;

Defined in: src/hooks/useMonitorFields.ts:71

Check if a field is required for a monitor type

Parametersโ€‹

monitorTypeโ€‹

| "cdn-edge-consistency" | "dns" | "http" | "http-header" | "http-json" | "http-keyword" | "http-latency" | "http-status" | "ping" | "port" | "replication" | "server-heartbeat" | "ssl" | "websocket-keepalive"

fieldNameโ€‹

string

Returnsโ€‹

boolean


isLoadedโ€‹

isLoaded: boolean;

Defined in: src/hooks/useMonitorFields.ts:73

Whether field definitions are loaded