# use AI (API Gemini) with varest in project

**URL:** <https://forums.unrealengine.com/t/use-ai-api-gemini-with-varest-in-project/2551271>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine, api, json, question\
**Created:** [June 11, 2025, 11:03am UTC](https://forums.unrealengine.com/t/use-ai-api-gemini-with-varest-in-project/2551271 "2025-06-11T11:03:14Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Michelangelo\_AI](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Michelangelo\_AI](https://forums.unrealengine.com/u/Michelangelo_AI)\
**Post date:** [June 11, 2025, 11:03am UTC](https://forums.unrealengine.com/t/use-ai-api-gemini-with-varest-in-project/2551271/1 "2025-06-11T11:03:14Z")

</div>

i want use ai in my project.  
use api gemini.  
but when click on button show error 400.

 ![Screenshot 2025-06-11 143055](https://d3kjluh73b9h9o.cloudfront.net/original/4X/d/9/1/d91d776cccc5de203ff66237c250ef636618ef21.png)

---

<div class="post-metadata">

**Author:** ![Jimbohalo10](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/jimbohalo10/32/961440_2.png) [@Jimbohalo10](https://forums.unrealengine.com/u/Jimbohalo10)\
**Post date:** [June 11, 2025, 12:02pm UTC](https://forums.unrealengine.com/t/use-ai-api-gemini-with-varest-in-project/2551271/2 "2025-06-11T12:02:02Z")

</div>

This is a web error code see [400 Bad Request - HTTP | MDN](https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Status/400)

---

<div class="post-metadata">

**Author:** ![Michelangelo\_AI](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Michelangelo\_AI](https://forums.unrealengine.com/u/Michelangelo_AI)\
**Post date:** [June 11, 2025, 12:34pm UTC](https://forums.unrealengine.com/t/use-ai-api-gemini-with-varest-in-project/2551271/3 "2025-06-11T12:34:11Z")

</div>

The blueprint structure is correct?  
Do you know how to solve it?

---

<div class="post-metadata">

**Author:** ![Michelangelo\_AI](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Michelangelo\_AI](https://forums.unrealengine.com/u/Michelangelo_AI)\
**Post date:** [June 11, 2025, 12:35pm UTC](https://forums.unrealengine.com/t/use-ai-api-gemini-with-varest-in-project/2551271/4 "2025-06-11T12:35:03Z")

</div>

i got api from google ai studio.

---

<div class="post-metadata">

**Author:** ![Jimbohalo10](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/jimbohalo10/32/961440_2.png) [@Jimbohalo10](https://forums.unrealengine.com/u/Jimbohalo10)\
**Post date:** [June 11, 2025, 2:44pm UTC](https://forums.unrealengine.com/t/use-ai-api-gemini-with-varest-in-project/2551271/5 "2025-06-11T14:44:10Z")

</div>

Hi @Michelangelo_AI ,  
Google now requires everything to have a passkey individual to them and this must be sent with the transaction. Just logging in is no longer the way.

Microsoft AI requires two passkeys to work.

GitHub AI needs multiple credentials to be registered with them.  
Is your Digital Certificates up to date?

Please read

[Authenticate to AI Applications | Google Cloud](https://cloud.google.com/generative-ai-app-builder/docs/authentication)

[Authentication methods at Google for AI| Google Cloud](https://cloud.google.com/docs/authentication)

Looking at the Blueprint there is not anything adding credentials

---

<div class="post-metadata">

**Author:** ![Michelangelo\_AI](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Michelangelo\_AI](https://forums.unrealengine.com/u/Michelangelo_AI)\
**Post date:** [June 12, 2025, 8:50am UTC](https://forums.unrealengine.com/t/use-ai-api-gemini-with-varest-in-project/2551271/6 "2025-06-12T08:50:58Z")

</div>

![Screenshot 2025-06-12 122004](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/3/a/23a6c9a0dbbb716725cfc64e0b36de463c0350bf.png)  
 ![Screenshot 2025-06-12 122653](https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/8/a/88a289ada68f6410a5987f7d983e4b56ed079499.png)  
i check api in this website and it is ok.

---

<div class="post-metadata">

**Author:** ![Michelangelo\_AI](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Michelangelo\_AI](https://forums.unrealengine.com/u/Michelangelo_AI)\
**Post date:** [June 13, 2025, 1:49pm UTC](https://forums.unrealengine.com/t/use-ai-api-gemini-with-varest-in-project/2551271/7 "2025-06-13T13:49:45Z")

</div>

i create two , blueprint to do this. but still error remained.

first design:

 ![Screenshot 2025-06-13 171053](https://d3kjluh73b9h9o.cloudfront.net/original/4X/6/6/a/66a5a1c804b26016a5f7be33c8e35a74e441b8d7.png)

 ![Screenshot 2025-06-13 171427](https://d3kjluh73b9h9o.cloudfront.net/original/4X/e/a/9/ea909aa9593ba2fc3f86b75dd5fe754162db1d7f.png)

and second design:

 ![Screenshot 2025-06-13 172115](https://d3kjluh73b9h9o.cloudfront.net/original/4X/f/a/9/fa9585d986d82922cdaef6635d00d47f4f1ed200.png)

---

<div class="post-metadata">

**Author:** ![Jimbohalo10](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/jimbohalo10/32/961440_2.png) [@Jimbohalo10](https://forums.unrealengine.com/u/Jimbohalo10)\
**Post date:** [June 13, 2025, 5:20pm UTC](https://forums.unrealengine.com/t/use-ai-api-gemini-with-varest-in-project/2551271/8 "2025-06-13T17:20:23Z")

</div>

Hi, Sorry no idea, most of the time its authentication.  
You need to retrieve the output message from Blueprint, check it, and then submit it manually. Next, check the response text, which is a response page with details on why the server did not like your request.  
All AI servers use same protocol its called Open AI
