opencode-usage 0.4.3 → 0.4.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/codex-client.d.ts +2 -1
- package/dist/index.js +12375 -11613
- package/dist/index.js.map +11 -11
- package/dist/quota-loader.d.ts +2 -5
- package/dist/types.d.ts +16 -0
- package/package.json +1 -1
package/dist/quota-loader.d.ts
CHANGED
|
@@ -1,9 +1,6 @@
|
|
|
1
|
-
import type { QuotaSnapshot } from "./types.js";
|
|
2
|
-
/**
|
|
3
|
-
* Load quota from anthropic-multi-account state file
|
|
4
|
-
* Path: ~/.local/share/opencode/multi-account-state.json
|
|
5
|
-
*/
|
|
1
|
+
import type { QuotaSnapshot, MultiAccountThresholds } from "./types.js";
|
|
6
2
|
export declare function loadMultiAccountQuota(): Promise<QuotaSnapshot[]>;
|
|
3
|
+
export declare function loadMultiAccountThresholds(): Promise<MultiAccountThresholds | null>;
|
|
7
4
|
/**
|
|
8
5
|
* Load quota from antigravity accounts file
|
|
9
6
|
* Path: ~/.config/opencode/antigravity-accounts.json
|
package/dist/types.d.ts
CHANGED
|
@@ -70,6 +70,13 @@ export type CursorState = {
|
|
|
70
70
|
export type MultiAccountState = {
|
|
71
71
|
currentAccount?: string;
|
|
72
72
|
requestCount?: number;
|
|
73
|
+
config?: {
|
|
74
|
+
threshold?: number | {
|
|
75
|
+
session5h?: number;
|
|
76
|
+
weekly7d?: number;
|
|
77
|
+
weekly7dSonnet?: number;
|
|
78
|
+
};
|
|
79
|
+
};
|
|
73
80
|
usage?: Record<string, {
|
|
74
81
|
session5h?: {
|
|
75
82
|
utilization: number;
|
|
@@ -89,6 +96,15 @@ export type MultiAccountState = {
|
|
|
89
96
|
timestamp?: string;
|
|
90
97
|
}>;
|
|
91
98
|
};
|
|
99
|
+
export type MultiAccountThresholds = {
|
|
100
|
+
session5h: number;
|
|
101
|
+
weekly7d: number;
|
|
102
|
+
weekly7dSonnet: number;
|
|
103
|
+
};
|
|
104
|
+
export type CodexThresholds = {
|
|
105
|
+
fiveHour: number;
|
|
106
|
+
weekly: number;
|
|
107
|
+
};
|
|
92
108
|
/** Antigravity quota group */
|
|
93
109
|
export type AntigravityQuotaGroup = {
|
|
94
110
|
remainingFraction: number;
|