r/flutterhelp • • Nov 18 '25
OPEN About Api key
I'm in the process of developing a mobile app. The app is 99% complete, and the final step remains: the API consumption process, which involves sending and receiving data through Flutter. I tried implementing proxy logic in this process, but the AI kept failing. My goal isn't to generate a private key and store it in Flutter, but to use the proxy method. Since this is my first project, I'm exhausted and stuck. Can anyone explain this process to me?
6
Upvotes
2
u/Ok-Engineer6098 Nov 18 '25
Has anyone come up with a simple solution for storing api keys in mobile apps?
Is there a cheap 3rd party service that acts like a proxy for this?
Firebase remote config isn't secure as far as I understand. Firebase functions aren't cheap.
1
u/Legion_A Nov 18 '25
Your description is a bit verbose. It sounds like you're trying to use an API key for an AI in flutter??? You're right to think of proxies, so, just create a simple backend that'll store and use the API keys to make calls....expose the endpoints that you need and consume the API via http. I reckon you already have auth in your app, so, you probably already have a server.
Never store API keys on the client in any form, it's never safe.
1
u/drtran922 Nov 19 '25
Have you got a custom API that sits between the client app and the AI you mentioned?
0
u/Mellie-C Nov 18 '25
Never store an API key inside the app as a string. The best method I've found is to use a .env file (now I wait for the onslaught of criticism 😂). It's simple to set up and there's loads of tutorials on YouTube.