chore: fix free tier query

This commit is contained in:
vimtor
2026-05-07 13:58:41 +02:00
parent d6e06c8950
commit 9c9bc09f52
+8 -13
View File
@@ -175,22 +175,17 @@ new honeycomb.Trigger("IncreasedFreeTierRequests", {
name: "Increased Free Tier Requests", name: "Increased Free Tier Requests",
description, description,
queryJson: honeycomb.getQuerySpecificationOutput({ queryJson: honeycomb.getQuerySpecificationOutput({
calculations: [ calculations: [{ op: "COUNT" }],
{ filters: [
op: "COUNT", { column: "event_type", op: "=", value: "completions" },
filterCombination: "AND", { column: "user_agent", op: "contains", value: "opencode" },
filters: [ { column: "isFreeTier", op: "=", value: "true" },
{ column: "event_type", op: "=", value: "completions" },
{ column: "user_agent", op: "contains", value: "opencode" },
{ column: "isFreeTier", op: "=", value: "true" },
],
},
], ],
timeRange: 14400, timeRange: 3600,
}).json, }).json,
alertType: "on_change", alertType: "on_change",
frequency: 3600, frequency: 900,
thresholds: [{ op: ">=", value: 50, exceededLimit: 2 }], thresholds: [{ op: ">=", value: 50, exceededLimit: 1 }],
baselineDetails: [{ type: "percentage", offsetMinutes: 1440 }], baselineDetails: [{ type: "percentage", offsetMinutes: 1440 }],
recipients: [ recipients: [
{ {