phpray

Ask an agent why a PHP site is slow: every request with its SQL, HTTP calls, errors and N+1.

我該用這個嗎

品質與安全性

A
說明品質
97%
結構描述完整度
86%
命名品質
80%
汙染風險
100%
權限相符程度
100%
協定合規性
100%

發現項目(1)

  • LOWTool 'phpray_components' description lacks action verb在 phpray_components 中

根據工具定義與協定合規性的自動化分析。

上下文成本

~1,077Token(工具定義)
~767 B典型回應大小
中等的注意力影響(128k 上下文的 0.84%)

這是每次將伺服器的工具載入模型上下文時所消耗的約略 token 數量。數量越高,可用於其他工作的注意力就越少。

安裝

一鍵安裝

將以下內容加入你的 `claude_desktop_config.json` 檔案:

{
  "mcpServers": {
    "phpray": {
      "url": "https://phpray.dev/mcp"
    }
  }
}

遠端端點

https://phpray.dev/mcpstreamable-http

它能做什麼

工具清單

工具(10)

🟢 唯讀🟡 寫入🔴 刪除⚪ 未知
🟢phpray_sites

List the PHP sites this token can see, with requests, p95 latency and error rate. Start here: every other tool needs a site_id from this list.

輸入結構描述

{
  "type": "object",
  "properties": {}
}
⚪phpray_overview(site_id, window_minutes)

Headline numbers for one site over a time window: requests, errors, p50/p95/p99 latency, database share and N+1 count. Use this before digging into anything else.

輸入結構描述

{
  "type": "object",
  "properties": {
    "site_id": {
      "description": "Site id from phpray_sites.",
      "type": "string"
    },
    "window_minutes": {
      "description": "How far back to look, in minutes. Default 60.",
      "type": "integer"
    }
  },
  "required": [
    "site_id"
  ]
}
⚪phpray_slow_pages(limit, site_id, window_minutes)

The slowest URLs on a site, with request counts and p95, from the request timeseries. Answers "which page is slow".

輸入結構描述

{
  "type": "object",
  "properties": {
    "limit": {
      "description": "How many URLs to return. Default 25.",
      "type": "integer"
    },
    "site_id": {
      "description": "Site id from phpray_sites.",
      "type": "string"
    },
    "window_minutes": {
      "description": "How far back to look. Default 1440.",
      "type": "integer"
    }
  },
  "required": [
    "site_id"
  ]
}
🟢phpray_slow_queries(limit, site_id, window_minutes)

SQL fingerprints ordered by time spent, with call counts and the caller when known. Literals are already masked. Answers "which query is slow".

輸入結構描述

{
  "type": "object",
  "properties": {
    "limit": {
      "description": "How many queries to return. Default 20.",
      "type": "integer"
    },
    "site_id": {
      "description": "Site id from phpray_sites.",
      "type": "string"
    },
    "window_minutes": {
      "description": "How far back to look. Default 1440.",
      "type": "integer"
    }
  },
  "required": [
    "site_id"
  ]
}
⚪phpray_components(limit, site_id, window_minutes)

Time attributed to each plugin, theme or vendor package on profiled requests. Answers "which plugin is slowing the site down". Empty when function profiling is off.

輸入結構描述

{
  "type": "object",
  "properties": {
    "limit": {
      "description": "How many components to return. Default 20.",
      "type": "integer"
    },
    "site_id": {
      "description": "Site id from phpray_sites.",
      "type": "string"
    },
    "window_minutes": {
      "description": "How far back to look. Default 1440.",
      "type": "integer"
    }
  },
  "required": [
    "site_id"
  ]
}
⚪phpray_errors(limit, site_id, window_minutes)

Requests that failed on a site: PHP errors and warnings with file and line where PHP raised one, plus 5xx responses that carry no PHP error. Pass an id to phpray_trace to see what one of them did.

輸入結構描述

{
  "type": "object",
  "properties": {
    "limit": {
      "description": "How many to return. Default 20.",
      "type": "integer"
    },
    "site_id": {
      "description": "Site id from phpray_sites.",
      "type": "string"
    },
    "window_minutes": {
      "description": "How far back to look. Default 1440.",
      "type": "integer"
    }
  },
  "required": [
    "site_id"
  ]
}
🟢phpray_traces(limit, min_ms, site_id, status, window_minutes)

Recent requests for a site. Filter with min_ms and status to find the bad ones, then pass an id to phpray_trace.

輸入結構描述

{
  "type": "object",
  "properties": {
    "limit": {
      "description": "How many to return. Default 50.",
      "type": "integer"
    },
    "min_ms": {
      "description": "Only requests slower than this.",
      "type": "integer"
    },
    "site_id": {
      "description": "Site id from phpray_sites.",
      "type": "string"
    },
    "status": {
      "description": "Only this HTTP status, e.g. 500.",
      "type": "integer"
    },
    "window_minutes": {
      "description": "How far back to look. Default 1440.",
      "type": "integer"
    }
  },
  "required": [
    "site_id"
  ]
}
⚪phpray_trace(trace_id)

One request in full: wall time split into PHP, database and outbound HTTP, every query, every external call, errors, and the component breakdown when the request was profiled.

輸入結構描述

{
  "type": "object",
  "properties": {
    "trace_id": {
      "description": "Trace id from phpray_traces.",
      "type": "string"
    }
  },
  "required": [
    "trace_id"
  ]
}
🟡phpray_compare(from_a, from_b, site_id, to_a, to_b)

Two time ranges for one site side by side. Use it to check whether a deployment, a plugin update or a configuration change made things better or worse.

輸入結構描述

{
  "type": "object",
  "properties": {
    "from_a": {
      "description": "Start of range A (the earlier one), unix seconds. Without any range: the day before yesterday's 24 h against the last 24 h.",
      "type": "integer"
    },
    "from_b": {
      "description": "Start of range B, unix seconds.",
      "type": "integer"
    },
    "site_id": {
      "description": "Site id from phpray_sites.",
      "type": "string"
    },
    "to_a": {
      "description": "End of range A, unix seconds.",
      "type": "integer"
    },
    "to_b": {
      "description": "End of range B, unix seconds.",
      "type": "integer"
    }
  },
  "required": [
    "site_id"
  ]
}
⚪phpray_alerts

Alerts currently firing across every site this token can see, worst overrun first.

輸入結構描述

{
  "type": "object",
  "properties": {}
}

社群

為此伺服器評分

證據

近期觀測

已驗證未記錄版本10 個工具
已驗證未記錄版本10 個工具