Conversation
…avity, Gemini CLI)
Adds the Cloud Code internal route used by Antigravity and Gemini CLI. The body is a { model, project, request } envelope; the inner generateContent request is transformed and the envelope is preserved. Forwards to cloudcode-pa.googleapis.com by default (GOOGLE_UPSTREAM / googleUpstream override), forwards the client bearer, never injects the Anthropic key, skips the upstream countTokens probe.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Support native Google inference requests rerouted through pxpipe from clients and providers using the Google wire format:
/v1/models/{model}:generateContentand/v1beta/models/{model}:streamGenerateContent(both methods on both versions), alongside existing Google AI Studio gateway paths./v1internal:generateContentand:streamGenerateContent, includingrequestandgenerateContentRequestenvelopes.GOOGLE_UPSTREAMoverrides the shared upstream for Google inference; retain explicit Cloudflare gateway routing and daily Cloud Code host detection.This routes Google-format requests; it does not translate OpenAI Responses or Chat Completions payloads into Google payloads.
Validation