Burning money for no reason - with firebase studio and gemini api

Got to say I’m loosing the will to live with Firebase studio.

It has so much potential but there are so many problems.

I go a week without any problems then suddenly it just starts messing things up.

I’m prototyping an app - none of the images or clips i generate is used for anything.

I have a api key that allows my app to generate gemini images and video but… and here’s the but

I’m getting charged a lot of money for lots of mistakes that the app makes.
Last month I got charged over £250 and what do i have to show for it - still a half built app that breaks every other week.

I deleted the api key - to try and stop and figure it out - created a new api key and again tried resolving the issues.
Last night i got charged over £50 and tonight - i got charged almost £20 - and I only managed to get 1 video generated - the rest of the time just error upon error.

There are fundamental flaws and who’s paying for all of this…. I am.

Really starting to think that this is a waste of my time - and I’m really not getting anywhere with google cloud support on the matter.

I would really like it if someone - an actual person can give me a ring and discuss all this.

1 Like

Is there a way of checking and printing out all the errors that I’ve had on my firebase app.
The video gen keeps failing and i never recieve the clips but yet I’m getting charged for it by google cloud. Need help to figure out how I prove that there is a fundamental problem with my app.

I understand your frustration with Firebase and the unexpected charges you’re incurring. It’s incredibly disheartening to spend time and effort on development only to be met with errors and a hefty bill. While I can’t directly connect you with Google Cloud support over the phone, I can offer some general advice and potential avenues to explore to mitigate these issues.

First, let’s address the charges. It sounds like you’re being charged for failed API calls, which is definitely something that needs to be investigated. Here are some steps you can take:

Review your Billing Reports: Go into your Google Cloud console and meticulously review your billing reports. Try to identify specific services or API calls that are racking up the costs. Look for spikes in usage that correlate with the times you experienced errors.

Set up Budget Alerts: If you haven’t already, set up budget alerts in Google Cloud. This will notify you when your spending approaches a certain threshold, allowing you to react more quickly to unexpected charges.

Understand API Quotas and Limits: Each Google Cloud API has quotas and limits. Ensure your application is respecting these. Frequent errors could be a sign of hitting these limits, leading to retries that consume more resources and incur more costs.

Error Handling in Your App: Even though you mentioned your current generation is for prototyping, robust error handling in your application is crucial. If your app is making repeated, failed calls to an API, that’s where a lot of the cost can come from. Implement mechanisms to prevent continuous retries on persistent errors.

Specific API Usage: Since you mentioned generating Gemini images and videos, focus on the specific usage metrics for the Gemini API in your billing reports. Are you making an unusually high number of requests? Are the requests for complex generations that might be more expensive?

Contact Google Cloud Billing Support: While you’ve expressed frustration with general support, there’s usually a dedicated billing support team. They might be able to offer more specific insights into your charges and potentially even credits if the charges are due to service issues on Google’s end.

Regarding the “fundamental flaws” and recurrent breaking of your app, it’s hard to pinpoint the exact cause without more details. However, here are some common areas to investigate:

Dependency Management: Are your Firebase and other Google Cloud SDKs up to date? Sometimes, issues arise from outdated dependencies or conflicts between different library versions.

API Key Security and Usage: Ensure your API key is properly secured and only used where necessary. If your API key is exposed, it could lead to unauthorized usage and unexpected charges. Also, confirm you’re using the correct API key for the correct project.

Logging and Monitoring: Implement comprehensive logging in your application to capture detailed error messages from the Gemini API or any other Firebase services you’re using. This will provide valuable clues about what’s failing. Google Cloud’s Operations (formerly Stackdriver) can be very helpful here.

Rate Limiting: If your app is making a large number of requests in a short period, you might be hitting rate limits imposed by the APIs, leading to errors.

Test Environment: If possible, consider setting up a separate, limited test environment with strict budget controls or even a free tier where possible, to prototype and test new features without incurring significant charges on your main project.

I know this is a lot to digest, and it doesn’t directly solve your immediate frustration of wanting to speak to a person. However, systematically going through these points might help you uncover the root cause of your problems and get your development back on track without the financial burden.

As a visual aid, here’s an image representing the common feeling of dealing with complex cloud billing and development issues: