/** * `weft.system.metrics` operation + REST binding. * * Returns JSON-shaped metrics. This is distinct from the Prometheus text * exposition at `GET /v1/metrics` (which remains a direct handler and is * REST-only). This operation exposes the same underlying data as a * structured JSON object for consumers that need machine-readable metrics * rather than Prometheus text format. * * Access is scoped to `system:read` — the same privilege class as any * internal-observability endpoint. * * The metrics snapshot comes from server-owned state captured when the * operation is registered. Callers cannot supply a snapshot through REST * or JSON-RPC input. * * @module server/operations/get-system-metrics */ import { z } from 'zod'; import type { MetricsCollector, MetricsSnapshot } from '../../observability/metrics.ts'; import type { UnknownRestBinding } from '../rest-bindings.ts'; declare const getSystemMetricsInput: z.ZodObject<{}, z.core.$strip>; export type GetSystemMetricsInput = z.infer; export type GetSystemMetricsOutput = MetricsSnapshot; /** * Create the `weft.system.metrics` operation bound to a server-owned * metrics collector. */ export declare function createGetSystemMetricsOperation(options?: { metricsCollector?: MetricsCollector | undefined; }): import("../operation-catalog.ts").OperationDefinition, MetricsSnapshot, unknown>; export declare const getSystemMetricsOperation: import("../operation-catalog.ts").OperationDefinition, MetricsSnapshot, unknown>; /** * Factory for the `weft.system.metrics` REST binding. * * Takes no arguments — the metrics snapshot is sourced through * `createGetSystemMetricsOperation`'s closure over the server-owned * collector, not through the binding. The binding only declares the * REST shape (path, method, response shaping). */ export declare function createGetSystemMetricsRestBinding(): UnknownRestBinding; export {};