When calling APIs that do not access private user data, you can use simple API keys. These keys are used to authenticate your application for accounting purposes. The Google API Console documentation also describes API keys.
Acquiring API keys
- Open the Credentials page in the API Console.
- Click Create credentials > API key and select the appropriate key type.
To keep your API keys secure, follow the best practices for securely using API keys.
Using API keys
To use API keys, call the
setDeveloperKey() method of the
Google_Client object before making any API calls. For example:
A server key can be passed alongside an access token. This will not cause an error, unless the access token and the server key are from different projects.