修复无法查询的BUG

This commit is contained in:
CN-JS-HuiBai
2026-04-05 23:46:29 +08:00
parent 322621a97b
commit 90c7bd80b1
2 changed files with 3 additions and 3 deletions

View File

@@ -805,7 +805,7 @@ module.exports = {
if (!blackboxUrl || !target) return null;
try {
const normalized = blackboxUrl.trim().replace(/\/+$/, '');
const params = new URLSearchParams({ query: `probe_duration_seconds{instance="${target}"}` });
const params = new URLSearchParams({ query: `probe_duration_seconds{instance_name="${target}"}` });
const res = await fetch(`${normalized}/api/v1/query?${params.toString()}`);
if (!res.ok) return null;
const data = await res.json();