title: How do I set up an App Engine backend for a Chrome Extension?
body: <p>I would like to be able to send a small push message from a Python Google App Engine server to a Chrome Extension. From searching the web, my best bet seems to be Google Cloud Messaging. (<a href="https://developer.chrome.com/apps/cloudMessaging" rel="nofollow">https://developer.chrome.com/apps/cloudMessaging</a>)</p>
  
  <p>However, the documentation for the Chrome extension side of GCM (as opposed to the Android side of GCM) is very poor. I cannot figure out what Python code to include in my App Engine server in order to communicate with the Chrome Extension. </p>
  
  <p>The only info I can find is on the page linked to above, which has the following description of sending messages from a server to an extension:</p>
  
  <blockquote>
    <ol>
    <li>Your app or extension client should register a handler to receive the gcm.onMessage event.</li>
    <li>When your server sends a message to the user, it specifies all of the registration IDs that are related to that user and passes the message to the GCM service.</li>
    <li>GCM servers route the message to all instances of Chrome running apps or extensions with one of the registration IDs.</li>
    <li>When the message arrives on the client, Chrome starts the app or extension, if it is not already running, and calls the registered handler to process the message.</li>
    </ol>
  </blockquote>
  
  <p>The documentation makes no mention of how exactly the server can pass the message to the GCM service. </p>
  
  <p>I'm hoping someone out there has figured out how to send push messages from an App Engine server to a Chrome Extension.</p>
  
  <p>Thank you for your time!</p>