metrics

Query Railway service CPU, memory, disk, and network metrics by environment and time range.

Updated Feb 1, 2026
One-click install
npx skills add https://github.com/habrahgithub/node-backend-starter --skill metrics-habrahgithub
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: metrics
Source: https://github.com/habrahgithub/node-backend-starter/tree/main/.codex/skills/railway-metrics
Command: npx skills add https://github.com/habrahgithub/node-backend-starter --skill metrics-habrahgithub

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires jq, curl, railway, and includes scripts (resource) and references (resource) components.

What problem does it solve?

Quickly surface time-series resource usage and performance data for Railway services so engineers can diagnose slow services, verify capacity, and confirm health status.

Core Features & Use Cases

  • Query CPU, memory, network, and disk metrics for a single service or all services in an environment.
  • Support time-range queries with configurable sample rates and averaging windows, and group results by deployment, instance, region, or service.
  • Use cases include investigating a service regression causing high CPU, validating memory limits during a spike, and producing charts for capacity planning.

Quick Start

Use the metrics skill to fetch CPU and memory time-series for an environment by specifying environmentId, optional serviceId, and a startDate range.

Frequently Asked Questions about metrics

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I check CPU and memory usage for a Railway service?

To check Railway CPU and memory usage, query resource metrics by providing an environmentId, optional serviceId, and ISO8601 startDate. The skill returns timestamped CPU_USAGE and MEMORY_USAGE_GB values.

How do I retrieve historical Railway performance metrics for a specific time range?

Retrieve historical Railway performance metrics by specifying an ISO8601 startDate and an optional endDate. You can apply configurable sample rates and averaging windows to group results by deployment, instance, region, or service.

Can I monitor disk and network usage across all services in a Railway environment?

Yes, you can monitor disk and network usage across all services in a Railway environment. By omitting the optional serviceId, the query targets the entire environment and returns grouped resource usage data.

Do I need curl and jq installed to query Railway service metrics?

Yes, you need curl and jq installed locally. The skill depends on curl to execute API requests and jq to parse the returned JSON time-series data into timestamped values suitable for plotting.

What is the best way to debug high CPU usage on a Railway deployment?

To debug high Railway CPU usage, query the CPU_USAGE metric for your environment and group results by deployment. This surfaces time-series data to identify regressions and verify capacity limits during performance spikes.

Why does my Railway memory usage query return empty results?

Empty Railway memory usage results occur when the provided ISO8601 startDate or optional endDate falls outside the retention window, or when the specified environmentId and serviceId combination lacks active deployments.