Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Vision API quota/budget limit and API key help

frp22
New Member

Hello, I have never used Vision API before but I recently found it very powerful for a project of mine. However I have two concerns regarding its budget limiting, in order to not get an unexpected bill:

  1. Is it possible to set a monthly cost limit? I have been used to Compute Engine which gives me an almost exact cost of the month but this seems not possible here. Since I will be using the API for labelling I have set the label detections requests per minute and per user to a specific amount, also to be sure I have set the global request per minute and per user to the same amount, all the other quotas to 0. If I have understood correctly, setting the max calls quota per minute to 4, for example, should provide a maximum of 178560 calls per month, right? Should this limit my budget? Am I safe?

  2. The API will be used as an API key in a mobile app. I have followed the code examples for iOS & Android and I have seen the key is written in the code. Is this safe? For a better security I have restricted the key to iOS/Android apps bundle and to Cloud Vision API only. Would it be a safe enough option?

Thanks everyone for any help!

0 1 1,099
1 REPLY 1

Hi 

You can set a cap of api usage or a billing budget might help you on this issue. Does it meet your needs?

About your security question about "hard code the key in Android/iOS", I recommend you to discuss on Stack Overflow for better help.