import * as prom from 'prom-client' ; import { WebSocket } from 'uWebSockets.js' ; export interface MetricsInterface { /**
     * The Metrics driver.
     */ driver ? : MetricsInterface ; /**
     * Handle a new connection.
     */ markNewConnection ( ws ) : void ; /**
     * Handle a disconnection.
     */ markDisconnection ( ws ) : void ; /**
     * Handle a new API message event being received and sent out.
     */ markApiMessage ( appId , incomingMessage , sentMessage ) : void ; /**
     * Handle a new WS client message event being sent.
     */ markWsMessageSent ( appId , sentMessage ) : void ; /**
     * Handle a new WS client message being received.
     */ markWsMessageReceived ( appId , message ) : void ; /**
     * Get the stored metrics as plain text, if possible.
     */ getMetricsAsPlaintext ( ) : Promise < string > ; /**
     * Get the stored metrics as JSON.
     */ getMetricsAsJson ( ) : Promise < prom . metric [ ] | void > ; /**
     * Reset the metrics at the server level.
     */ clear ( ) : Promise < void > ; }