Google Drive Push Notifications Playground
Google Drive Push Notifications Playground is a web app that helps you to try out the features of the Google Drive Push Notifications.
This sample will take you through the steps required to subscribe and unsubscribe to push notifications for changes in a specific file or any files in your Drive account.
You can try out the Google Drive Push Notifications Playground on its live demo instance.
Installation and Configuration
Create a Google APIs project and Activate the Drive API
First, you need to activate the Drive API for your app. You can do it by configuring your API project in the Google APIs Console.
- Create an API project in the Google APIs Console.
- Select the "Services" tab and enable the Drive API.
- Select the "API Access" tab in your API project, and click "Create an OAuth 2.0 client ID".
- In the Branding Information section, provide a name for your application (e.g. "CollabCube 3D"), and click Next. Providing a product logo is optional.
- In the Client ID Settings section, do the following:
- Select Web application for the Application type
- Click the more options link next to the heading, Your site or hostname.
- Click Create Client ID.
- On the same page, click on Download JSON to download the 'client_secrets.json' file.
- Save 'client_secrets.json' file to the root folder of this application.
Download and extract 'google-api-python-client' library
Download the 'google-api-python-client' Google App Engine package and extract it to the root folder of this application.
Set up Google App Engine application
- Create an App Engine application in the Google App Engine Console and note the application identifier.
- Update application setting in app.yaml file of this project with your application identifier.
- Set up Google App Engine development environment on your local machine.
- Upload and deploy your project with the following command
appcfg.py --oauth2 update .
Before creating a pull request, please fill out either the individual or corporate Contributor License Agreement.
- If you are an individual writing original source code and you're sure you own the intellectual property, then you'll need to sign an individual CLA.
- If you work for a company that wants to allow you to contribute your work to this client library, then you'll need to sign a corporate CLA.
Follow either of the two links above to access the appropriate CLA and instructions for how to sign and return it. Once we receive it, we'll add you to the official list of contributors and be able to accept your patches.