The Query API described in the first part of this document was introduced with Google Desktop 3. We cover how to use it with both native plug-ins and script-based plug-ins, and assume that you are familiar with the general principles of how to write Desktop plug-ins. The latter part of this document describes methods for issuing Desktop search queries using HTTP and XML. This XML-based API is supported by both the Windows and Mac OS X versions of Google Desktop. Mac OS X support was added in Google Desktop Mac 1.0.3.

You can only use the Query API if you have registered with it and thus obtained a Query API registration cookie. Note that this is in addition to the general registration of your plug-in with Google Desktop.

There are two types of Query API registration cookies, read-only and read-write. Usually, you’ll only need a read-only cookie. The read-write cookie is only needed when you remove an item from the Google Desktop index. We recommend that your plug-in encrypt the registration cookie when it saves it, and, of course, be able to decrypt it when you pass it to the various Query API methods and objects.
You’ll need a global identifier (GUID) for your plug-in to pass to the registration method. You can use a tool such as guidgen.exe to generate.

Download pdf Google Desktop Query API Developer Guide