# Invalid request error in Google Flash

**URL:** https://meta.discourse.org/t/invalid-request-error-in-google-flash/360095
**Category:** Support
**Tags:** ai
**Created:** [April 2, 2025, 8:49pm UTC](https://meta.discourse.org/t/invalid-request-error-in-google-flash/360095 "2025-04-02T20:49:49Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![BrianC](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/brianc/32/487568_2.png) [@BrianC](https://meta.discourse.org/u/BrianC)
#### Post date: [April 2, 2025, 8:49pm UTC](https://meta.discourse.org/t/invalid-request-error-in-google-flash/360095/1 "2025-04-02T20:49:49Z")

</div>

Hi all,

I’m currently using Google Flash 2.0 (Gemini 2.0 Flash) with a direct API key from Google and have configured the system to use the Google Tokenizer. The chat functionality is working perfectly; however, when I try to enable image support, I encounter the following error:

> `{ "error": { "message": "'$.input' is invalid. Please check the API reference: https://platform.openai.com/docs/api-reference.", "type": "invalid_request_error", "param": null, "code": null } } `

Has anyone else seen this? Is this error due to Gemini 2.0 not yet supporting vision features in Discourse AI? Any insights or workarounds would be appreciated.

Thanks!

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [April 2, 2025, 11:43pm UTC](https://meta.discourse.org/t/invalid-request-error-in-google-flash/360095/3 "2025-04-02T23:43:41Z")

</div>

Yes I think I do 🙂

You are trying to use the Open AI compatible endpoint Google provide instead of the Gemini native endpoint.

Try using:

`https://generativelanguage.googleapis.com/v1beta/models/gemini-2.0-flash`

And use the Gemini provider.

The OpenAI compatibility layer has some limitations.

---

<div class="post-metadata">

### Author: ![BrianC](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/brianc/32/487568_2.png) [@BrianC](https://meta.discourse.org/u/BrianC)
#### Post date: [April 3, 2025, 12:44am UTC](https://meta.discourse.org/t/invalid-request-error-in-google-flash/360095/4 "2025-04-03T00:44:27Z")

</div>

Thanks Sam, that is the URL for the setting. The error message occurs when using a persona with that LLM and also set for Vision Enabled and you upload a picture. It fails after hitting upload for jpg. I try to validate as best possible because there are so many settings it’s easy to miss something.

 ![The image shows a settings page for an AI model called Gemini-2.0-flash, provided by Google with an API key input, a "Run test" and "Submit" button. (Captioned by AI)](https://global.discourse-cdn.com/meta/original/4X/f/d/9/fd9e36f5feeb7b0690ba3239bb542fae65103073.png)

 ![The image shows a message indicating an error occurred while trying to reply, with detailed error information that explains the input is invalid. (Captioned by AI)](https://global.discourse-cdn.com/meta/original/4X/2/a/8/2a842e36edfb3c960dab5627c6e2465b7c92e4e3.png)

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [April 3, 2025, 1:38am UTC](https://meta.discourse.org/t/invalid-request-error-in-google-flash/360095/5 "2025-04-03T01:38:01Z")

</div>

It is working here, something feels a bit odd.

 ![The image shows a configuration screen for a Google AI tool named "Gemini 2.0 Flash," detailing its model ID, service URL, API key, and settings. (Captioned by AI)](https://global.discourse-cdn.com/meta/original/4X/0/f/c/0fc5fd4cdabb108c2fc46552d201ae82fae8b65d.png)

Can you share the output of copy request and response on a [gist](https://gist.github.com/)?

 ![The image displays a configuration screen for a Google AI tool, outlining its service settings, key, model ID "genmin-2.0-flash," service URL, and enabled features like GeminiToKenizer and Vision. (Captioned by AI)](https://global.discourse-cdn.com/meta/original/4X/5/a/a/5aa4149ba1a8f36a35338de14049853bbf905531.png)

---

<div class="post-metadata">

### Author: ![BrianC](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/brianc/32/487568_2.png) [@BrianC](https://meta.discourse.org/u/BrianC)
#### Post date: [April 3, 2025, 2:53am UTC](https://meta.discourse.org/t/invalid-request-error-in-google-flash/360095/6 "2025-04-03T02:53:58Z")

</div>

Where do I see that screen?

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [April 3, 2025, 2:54am UTC](https://meta.discourse.org/t/invalid-request-error-in-google-flash/360095/7 "2025-04-03T02:54:45Z")

</div>

That is the i button you have enabled at the bottom.
