import type { components, operations } from '../generated/api.js';
import { WorkspaceScopedResource } from './base.js';
export type MetricCatalogEntry = components['schemas']['MetricCatalogEntry'];
export type MetricCatalogResponse = components['schemas']['MetricCatalogResponse'];
export type MetricListResponse = components['schemas']['MetricListResponse'];
export type NumericalMetricValue = components['schemas']['NumericalMetricValueResponse'];
export type CategoricalMetricValue = components['schemas']['CategoricalMetricValueResponse'];
export type BooleanMetricValue = components['schemas']['BooleanMetricValueResponse'];
export type MetricValue = NumericalMetricValue | CategoricalMetricValue | BooleanMetricValue;
/** @deprecated Use `MetricValue` instead. */
export type MetricValueResponse = MetricValue;
export type MetricValuesParams = NonNullable<operations['get-metric-values']['parameters']['query']>;
export type MetricTrendParams = NonNullable<operations['get-metric-trend']['parameters']['query']>;
/**
 * Metrics — computed metric catalog and typed metric values.
 */
export declare class MetricsResource extends WorkspaceScopedResource {
    /** List the latest value for each metric in the workspace */
    listLatest(): Promise<{
        metrics: ({
            avg_confidence?: number | null | undefined;
            computed_at?: string | null | undefined;
            entity_id?: string | null | undefined;
            entity_type?: string | null | undefined;
            event_count: number;
            metric_key: string;
            metric_type: "boolean";
            period_end: string;
            period_start: string;
            run_id?: string | null | undefined;
            service_id?: string | null | undefined;
            session_id?: string | null | undefined;
            source?: string | undefined;
            unit?: string | null | undefined;
            value: boolean | null;
        } | {
            avg_confidence?: number | null | undefined;
            computed_at?: string | null | undefined;
            entity_id?: string | null | undefined;
            entity_type?: string | null | undefined;
            event_count: number;
            metric_key: string;
            metric_type: "categorical";
            period_end: string;
            period_start: string;
            run_id?: string | null | undefined;
            service_id?: string | null | undefined;
            session_id?: string | null | undefined;
            source?: string | undefined;
            unit?: string | null | undefined;
            value: string | null;
        } | {
            avg_confidence?: number | null | undefined;
            computed_at?: string | null | undefined;
            entity_id?: string | null | undefined;
            entity_type?: string | null | undefined;
            event_count: number;
            metric_key: string;
            metric_type: "numerical";
            period_end: string;
            period_start: string;
            run_id?: string | null | undefined;
            service_id?: string | null | undefined;
            session_id?: string | null | undefined;
            source?: string | undefined;
            unit?: string | null | undefined;
            value: number | null;
        })[];
    } & import("../index.js").ResponseMetadata>;
    /** List available built-in and custom metric definitions */
    getCatalog(): Promise<{
        metrics: {
            builtin: boolean;
            custom_source_key?: string | null | undefined;
            description?: (components["schemas"]["DescriptionString"] | null) | undefined;
            extraction_mode?: "static" | "ai_classify" | "ai_extract" | "ai_query" | "sql_expr" | undefined;
            granularity?: "aggregate" | "per_entity" | undefined;
            has_prompt?: boolean | undefined;
            key: string;
            latency_tier?: "streaming" | "near_realtime" | "batch" | undefined;
            metric_type: "numerical" | "categorical" | "boolean";
            model_tier?: "free" | "fast" | "balanced" | "max" | "custom" | undefined;
            name: components["schemas"]["NameString"];
            period_granularity?: "hourly" | "daily" | undefined;
            source: "call_intelligence" | "world_events" | "surface_events" | "emotion_events" | "connector_events" | "zerobus_events" | "voice_judge_results" | "custom";
            unit?: string | null | undefined;
        }[];
    } & import("../index.js").ResponseMetadata>;
    /** Get stored values for one metric key, optionally bounded by time range */
    getValues(metricKey: string, params?: MetricValuesParams): Promise<{
        metrics: ({
            avg_confidence?: number | null | undefined;
            computed_at?: string | null | undefined;
            entity_id?: string | null | undefined;
            entity_type?: string | null | undefined;
            event_count: number;
            metric_key: string;
            metric_type: "boolean";
            period_end: string;
            period_start: string;
            run_id?: string | null | undefined;
            service_id?: string | null | undefined;
            session_id?: string | null | undefined;
            source?: string | undefined;
            unit?: string | null | undefined;
            value: boolean | null;
        } | {
            avg_confidence?: number | null | undefined;
            computed_at?: string | null | undefined;
            entity_id?: string | null | undefined;
            entity_type?: string | null | undefined;
            event_count: number;
            metric_key: string;
            metric_type: "categorical";
            period_end: string;
            period_start: string;
            run_id?: string | null | undefined;
            service_id?: string | null | undefined;
            session_id?: string | null | undefined;
            source?: string | undefined;
            unit?: string | null | undefined;
            value: string | null;
        } | {
            avg_confidence?: number | null | undefined;
            computed_at?: string | null | undefined;
            entity_id?: string | null | undefined;
            entity_type?: string | null | undefined;
            event_count: number;
            metric_key: string;
            metric_type: "numerical";
            period_end: string;
            period_start: string;
            run_id?: string | null | undefined;
            service_id?: string | null | undefined;
            session_id?: string | null | undefined;
            source?: string | undefined;
            unit?: string | null | undefined;
            value: number | null;
        })[];
    } & import("../index.js").ResponseMetadata>;
    /** Get a recent time-series trend for one metric key */
    getTrend(metricKey: string, params?: MetricTrendParams): Promise<{
        metrics: ({
            avg_confidence?: number | null | undefined;
            computed_at?: string | null | undefined;
            entity_id?: string | null | undefined;
            entity_type?: string | null | undefined;
            event_count: number;
            metric_key: string;
            metric_type: "boolean";
            period_end: string;
            period_start: string;
            run_id?: string | null | undefined;
            service_id?: string | null | undefined;
            session_id?: string | null | undefined;
            source?: string | undefined;
            unit?: string | null | undefined;
            value: boolean | null;
        } | {
            avg_confidence?: number | null | undefined;
            computed_at?: string | null | undefined;
            entity_id?: string | null | undefined;
            entity_type?: string | null | undefined;
            event_count: number;
            metric_key: string;
            metric_type: "categorical";
            period_end: string;
            period_start: string;
            run_id?: string | null | undefined;
            service_id?: string | null | undefined;
            session_id?: string | null | undefined;
            source?: string | undefined;
            unit?: string | null | undefined;
            value: string | null;
        } | {
            avg_confidence?: number | null | undefined;
            computed_at?: string | null | undefined;
            entity_id?: string | null | undefined;
            entity_type?: string | null | undefined;
            event_count: number;
            metric_key: string;
            metric_type: "numerical";
            period_end: string;
            period_start: string;
            run_id?: string | null | undefined;
            service_id?: string | null | undefined;
            session_id?: string | null | undefined;
            source?: string | undefined;
            unit?: string | null | undefined;
            value: number | null;
        })[];
    } & import("../index.js").ResponseMetadata>;
}
//# sourceMappingURL=metrics.d.ts.map