Can I have a single Google Maps API key for all my apps without registering their package names?

后端 未结 4 1704
太阳男子
太阳男子 2020-12-09 09:59

I have written an android library project that includes custom MapFragments, based on Google Maps for Android v2 API. In the Google APIs console, I have registered the libra

相关标签:
4条回答
  • 2020-12-09 10:07

    There is no way to do that. Registering takes like 15 seconds per app if you use the same key for all of them.

    0 讨论(0)
  • 2020-12-09 10:13

    No... you have to specify package name. It identify your application registered with Map key

    0 讨论(0)
  • 2020-12-09 10:20

    Here's how to accomplish what you're trying to do when creating a new API key:

    • Click create new Android key button
    • Don't enter anything into the package names list
    • Click create

    Then you should see AndroidApps: Any app allowed, and be able to use that maps API key in all of your apps without any configuration on the APIs console.

    Since you have probably already have entered the certificate fingerprints for each of your applications, just click Edit allowed Android apps, delete them all from the list, click update, and it should say any app is allowed to use that API key.

    0 讨论(0)
  • 2020-12-09 10:32

    It can answer for 2 ways

    Can I have a single Google Maps API key for all my apps?

    Yes, you can by register API Key with multiple lines by using enter, like this: enter image description here

    but for this question Can I have a single Google Maps API key for all my apps without registering their package names?

    No, you can't

    *edit image for easier to read

    0 讨论(0)
提交回复
热议问题