import type { SubscriptionQuota } from "@opengeni/subscriptions"; import type { SubscriptionCoreConnectionRow } from "./administration.js"; /** A cached observation, not a fresh usage check or an account eligibility decision. */ export type SubscriptionCoreAccountUsage = { /** Snapshot-level time only: retained windows have no individual observation timestamps. */ observedAt: string | null; source: SubscriptionQuota["source"]; windows: Array<{ id: string; usedPercent: number | null; resetsAt: string | null; status: SubscriptionQuota["windows"][number]["status"]; }>; exhaustedUntil: string | null; exhaustedKind: SubscriptionQuota["exhaustedKind"]; }; type UsageRow = Pick; /** * Project only a row already authorized by the account-list reader. Null means * this visible account has no decodable stored observation, never that a hidden * account was inspected. No I/O, credential metadata, raw provider payloads or * new authorization path belongs here. * * Keep partial/unknown windows and past resets as observed; neither elapsed time * nor an absent window proves replenishment. A snapshot can combine observations, * so its source/time does not assert per-window freshness or completeness. Token * refreshes do not erase historical readings: the existing decoder requires the * stored generation marker, not equality with a current credential version. * Routing/allocator decisions and model cooldowns remain on their existing paths. */ export declare function projectSubscriptionCoreAccountUsage(row: UsageRow): SubscriptionCoreAccountUsage | null; export {};