defmodule SyntropyWeb.MetricsController do use SyntropyWeb, :controller @doc """ Prometheus scrape endpoint (text exposition format). """ @spec index(Plug.Conn.t(), map()) :: Plug.Conn.t() def index(conn, _params) do conn |> put_resp_content_type("text/plain") |> send_resp(200, SyntropyWeb.Telemetry.scrape()) end end