diff --git a/README.md b/README.md index cbeec15..4206091 100644 --- a/README.md +++ b/README.md @@ -69,7 +69,7 @@ Since Cursor 3.27, Cursor encrypts its session in `state.vscdb` with a key it ke - Reuses, **read-only**, the sessions that already exist in Claude Code, Codex CLI, Cursor and Antigravity (including T3 Code's Antigravity token files under `~/.t3/userdata/providers/antigravity/` and Antigravity's local service files under `~/.gemini/antigravity/daemon/hub_*.json` and `~/.gemini/antigravity-insiders/daemon/hub_*.json`). It never asks for passwords, signs in, refreshes tokens or writes credentials. Cursor's encrypted session is read only after you allow it (see above). - Turning a provider off drops everything Uzzy held of its session (its token, account and figures) at once; turning it on reads the session again from the official app. -- Only connects to `api.anthropic.com`, `chatgpt.com`, `api2.cursor.sh` and `daily-cloudcode-pa.sandbox.googleapis.com` to read usage limits, plans and credit balances, to `127.0.0.1` to ask a running Antigravity app on your Mac when no fresh token is available, and to `api.github.com` once a day to ask for the latest version. That check sends no token and nothing about you or your usage, and you can turn it off in Settings. No telemetry and no server of its own. +- Only connects to `api.anthropic.com`, `chatgpt.com`, `api2.cursor.sh` and `daily-cloudcode-pa.googleapis.com` to read usage limits, plans and credit balances, to `127.0.0.1` to ask a running Antigravity app on your Mac when no fresh token is available, and to `api.github.com` once a day to ask for the latest version. That check sends no token and nothing about you or your usage, and you can turn it off in Settings. No telemetry and no server of its own. - Usage data lives only in memory; nothing is written to disk. - Display magnitude, countdown style, whether to show resets available, which providers are turned on, provider order, background refresh and usage limit alert preferences, whether to check for updates and whether you allowed access to Cursor's key are stored in local `UserDefaults`; they contain no usage data, token, email or account identifier. diff --git a/app/UzzyCore/Antigravity.swift b/app/UzzyCore/Antigravity.swift index 3e3fc74..868bf4d 100644 --- a/app/UzzyCore/Antigravity.swift +++ b/app/UzzyCore/Antigravity.swift @@ -170,7 +170,7 @@ enum Antigravity: ProviderAdapter { /// Antigravity tracks usage on Cloud Code's daily host; `cloudcode-pa.googleapis.com` /// answers with 200 and unused (`remainingFraction: 1`) buckets. private static func cloudCodeRequest(_ method: String, session: Session, body: Data) -> URLRequest { - var request = URLRequest(url: URL(string: "https://daily-cloudcode-pa.sandbox.googleapis.com/v1internal:\(method)")!) + var request = URLRequest(url: URL(string: "https://daily-cloudcode-pa.googleapis.com/v1internal:\(method)")!) request.httpMethod = "POST" request.setValue("Bearer \(session.accessToken)", forHTTPHeaderField: "Authorization") request.setValue("application/json", forHTTPHeaderField: "Content-Type") diff --git a/app/UzzyCore/Fakes.swift b/app/UzzyCore/Fakes.swift index d7f8caf..53194f0 100644 --- a/app/UzzyCore/Fakes.swift +++ b/app/UzzyCore/Fakes.swift @@ -41,7 +41,7 @@ public actor SampleTransport: HTTPTransport { let body = switch request.url?.host { case "chatgpt.com": codexResponse case "api2.cursor.sh": request.url?.lastPathComponent == "GetPlanInfo" ? Samples.cursorPlanResponse : cursorResponse - case "daily-cloudcode-pa.sandbox.googleapis.com": request.url?.lastPathComponent == "v1internal:loadCodeAssist" + case "daily-cloudcode-pa.googleapis.com": request.url?.lastPathComponent == "v1internal:loadCodeAssist" ? Samples.antigravityAccountResponse : Samples.antigravityQuotaResponse case "127.0.0.1": request.url?.lastPathComponent == "GetUserStatus" ? Samples.antigravityDaemonStatusResponse : Samples.antigravityDaemonQuotaResponse @@ -332,7 +332,7 @@ extension Provider { case "api.anthropic.com": self = .claude case "chatgpt.com": self = .codex case "api2.cursor.sh": self = .cursor - case "daily-cloudcode-pa.sandbox.googleapis.com", "127.0.0.1": self = .antigravity + case "daily-cloudcode-pa.googleapis.com", "127.0.0.1": self = .antigravity default: return nil } } diff --git a/app/UzzyCoreTests/AntigravityPanelTests.swift b/app/UzzyCoreTests/AntigravityPanelTests.swift index 24d452c..f0e9dc0 100644 --- a/app/UzzyCoreTests/AntigravityPanelTests.swift +++ b/app/UzzyCoreTests/AntigravityPanelTests.swift @@ -59,8 +59,8 @@ struct AntigravityPanelTests { let requests = await transport.quotaRequests(to: .antigravity) #expect(requests.map(\.url) == [ - URL(string: "https://daily-cloudcode-pa.sandbox.googleapis.com/v1internal:loadCodeAssist"), - URL(string: "https://daily-cloudcode-pa.sandbox.googleapis.com/v1internal:retrieveUserQuotaSummary"), + URL(string: "https://daily-cloudcode-pa.googleapis.com/v1internal:loadCodeAssist"), + URL(string: "https://daily-cloudcode-pa.googleapis.com/v1internal:retrieveUserQuotaSummary"), ]) #expect(requests.allSatisfy { $0.httpMethod == "POST" }) #expect(requests.allSatisfy { $0.value(forHTTPHeaderField: "Authorization") == "Bearer sample-token" }) diff --git a/app/UzzyCoreTests/AntigravitySessionTests.swift b/app/UzzyCoreTests/AntigravitySessionTests.swift index 75a9d96..2fc790f 100644 --- a/app/UzzyCoreTests/AntigravitySessionTests.swift +++ b/app/UzzyCoreTests/AntigravitySessionTests.swift @@ -140,7 +140,7 @@ struct AntigravitySessionTests { let requests = await transport.quotaRequests(to: .antigravity) #expect(requests.count == 2) - #expect(requests.allSatisfy { $0.url?.host == "daily-cloudcode-pa.sandbox.googleapis.com" }) + #expect(requests.allSatisfy { $0.url?.host == "daily-cloudcode-pa.googleapis.com" }) #expect(requests.allSatisfy { $0.value(forHTTPHeaderField: "Authorization") == "Bearer sample-token" }) } @@ -320,7 +320,7 @@ struct AntigravitySessionTests { let requests = await transport.quotaRequests(to: .antigravity) #expect(requests.count == 2) - #expect(requests.allSatisfy { $0.url?.host == "daily-cloudcode-pa.sandbox.googleapis.com" }) + #expect(requests.allSatisfy { $0.url?.host == "daily-cloudcode-pa.googleapis.com" }) #expect(requests.allSatisfy { $0.value(forHTTPHeaderField: "Authorization") == "Bearer t3-fresh-token" }) #expect(requests.allSatisfy { $0.url?.host != "127.0.0.1" }) } diff --git a/site/src/content.ts b/site/src/content.ts index cfacd6f..5c74879 100644 --- a/site/src/content.ts +++ b/site/src/content.ts @@ -54,7 +54,7 @@ export const providers = [ { name: "Claude", hosts: ["api.anthropic.com"] }, { name: "Codex", hosts: ["chatgpt.com"] }, { name: "Cursor", hosts: ["api2.cursor.sh"] }, - { name: "Antigravity", hosts: ["daily-cloudcode-pa.sandbox.googleapis.com", "127.0.0.1"] }, + { name: "Antigravity", hosts: ["daily-cloudcode-pa.googleapis.com", "127.0.0.1"] }, ]; export type SettingsTabId = "general" | "providers" | "notifications";