fix(ai-sample-catalog): explain Firebase AI setup, billing, and blocked requests - #188
Open
saadkhalidkhan wants to merge 1 commit into
Open
saadkhalidkhan wants to merge 1 commit into
saadkhalidkhan wants to merge 1 commit into
Conversation
…ed requests Replace raw GenerateContent blocked errors with guidance for API key restrictions and Blaze billing, and document those requirements in the catalog.
saadkhalidkhan
requested review from
JolandaVerhoef,
calren and
ksemenova
as code owners
September 16, 2026 09:10
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
Improve Firebase AI Logic setup guidance and replace raw generate-content failures with actionable messages. Image generation samples now call out that billing is typically required.
Fixes #140
Motivation
Users running cloud samples, especially Nano Banana / Nano Banana Pro, often see opaque errors such as
GenerateContent are blocked. That usually means the Android API key does not allow the Firebase AI Logic API, or the model needs a Blaze plan. The catalog previously linked the Firebase dialog to outdated Vertex AI docs and did not explain those requirements.Changes
ui-componentand use it from cloud sample ViewModels.needsBillingand show a note on the sample cards.Testing
./gradlew :ui-component:testDebugUnitTest./gradlew spotlessApply./gradlew :ui-component:lintDebug :app:lintDebug:appand the updated sample modules (compileDebugKotlin)Screenshots / Video
N/A for functional behavior. Catalog cards for Nano Banana Pro, Nanobanana, and Magic Selfie now include a short billing note.
Additional Notes
GenerativeBackend.googleAI(). This does not switch backends.