Skip to main content
Glama

liara_get_metrics

Retrieve application performance metrics and summary data from the Liara cloud platform to monitor resource usage and track operational health.

Instructions

Get app metrics summary

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
appNameYesThe name of the app
periodNoTime period for metrics (optional)

Implementation Reference

  • The main handler function for the liara_get_metrics tool. It validates the app name, optionally adds a period parameter, and fetches the metrics summary from the Liara API endpoint /v1/projects/{appName}/metrics/summary.
    /** * Get app metrics summary */ export async function getAppMetrics( client: LiaraClient, appName: string, period?: string ): Promise<MetricsSummary> { validateAppName(appName); const params: Record<string, string | number | boolean> | undefined = period ? { period } : undefined; return await client.get<MetricsSummary>( `/v1/projects/${appName}/metrics/summary`, params ); }
  • Type definitions for the metrics data structures used by the liara_get_metrics tool. AppMetrics defines the metric fields, and MetricsSummary wraps it with the period.
    // Metrics types export interface AppMetrics { cpu: number; memory: number; disk: number; network: { in: number; out: number; }; requests?: number; } export interface MetricsSummary { period: string; metrics: AppMetrics; }
  • The core API call that retrieves the metrics data from Liara's observability endpoint.
    return await client.get<MetricsSummary>( `/v1/projects/${appName}/metrics/summary`, params );

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/razavioo/liara-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server