feat(ai): added Synthetic usage provider
/usage and omp usage now report Synthetic (synthetic.new) quota state via GET /v2/quotas (free, does not consume quota): the rolling 5-hour request limit with per-tick regeneration rate, and the weekly credit quota in USD. Applies to API-key credentials for the synthetic provider; every payload section is parsed defensively since only subscription is documented.
This commit is contained in:
@@ -409,7 +409,7 @@ function formatLimitLine(limit: UsageLimit, labelWidth: number, nowMs: number):
|
||||
const details: string[] = [describeAmount(limit)];
|
||||
const resetsAt = limit.window?.resetsAt;
|
||||
if (resetsAt !== undefined && resetsAt > nowMs) {
|
||||
details.push(`resets in ${formatDuration(resetsAt - nowMs)}`);
|
||||
details.push(`${limit.window?.resetLabel ?? "resets"} in ${formatDuration(resetsAt - nowMs)}`);
|
||||
}
|
||||
const lines = [
|
||||
` ${STATUS_COLOR[status]("●")} ${padded} ${renderBar(limit)} ${chalk.dim(details.join(" · "))}`,
|
||||
|
||||
Reference in New Issue
Block a user