The questions below are specifically targeted for the Google Spreadsheets Data API. There are, however, many questions that are applicable to all of the Google Data APIs. Visit the Google Data APIs FAQ if you do not find the question you are looking for below.
The Google Spreadsheets data API is an extension of the Google Data API protocol, which you can use to create programs that interact with Google Spreadsheets. The API allows you to query for a list of spreadsheets owned by the currently authenticated user, query for a list of worksheets visible to the authenticated user in a given spreadsheet, and query, insert, update, and delete data in a spreadsheet by either cell or row.
The Google Spreadsheets data API is designed for developers who would like to integrate their applications with Google Spreadsheets. To get started:
The API is designed to help anyone interested in publishing their Google Spreadsheets' data with other users through mash-ups and developers wishing to integrate their applications with Google Spreadsheets.
If you're a new or casual user of Google Spreadsheets, we suggest you start or continue using Google Spreadsheets through the online editor. To get started, go to http://spreadsheets.google.com/.
If you need to develop a more sophisticated application, you might want to consider the Google Spreadsheets data API. This method will allow you to programmatically manage spreadsheets in Google Spreadsheets. Developers should be familiar with the HTTP protocol. You can start here:
To query a published Google Spreadsheets spreadsheet using the API, no.
To insert, update, delete, or query data in a spreadsheet or to query for a list of your spreadsheets, you'll need to authenticate using a Google Spreadsheets account. You can authenticate using an AuthSub (authentication for web applications) token or the username and password for a Google Spreadsheets account. You can register for a Google Spreadsheets account at docs.google.com.
An authenticated Google Spreadsheets user can query the list of spreadsheets for which they have edit or view permissions.
Worksheets in a published Google Spreadsheets spreadsheet can be queried by just about anyone. Unpublished workheets, however, can be queried only by those that were granted view or edit permissions.
A published spreadsheet can be queried at the list and cell levels by just about anyone.
For unpublished spreadsheets, an authenticated Google Spreadsheets user can view or edit (insert, update, delete) spreadsheet data only if given specific permission to do so.
In a list-based feed, each feed entry contains the data of a row, while in a cells-based feed, each entry represents an individual cell. You can learn more about the available feeds in the Google Spreadsheets Data API Developer's Guide.
When inserting, updating or deleting an entry in a cells or list feed, be sure to remember the appropriate XML namespaces.
The gs:cell
element in a cells entry is in the XML namespace:
xmlns:gs='http://schemas.google.com/spreadsheets/2006'
The gsx:{column_name}
elements in a list entry is in the XML namespace:
xmlns:gsx='http://schemas.google.com/spreadsheets/2006/extended'
Functions can only be inserted through the cells feed. To insert a function, update the cell from the cells feed with the desired formula as a string. You can see an example in the Change contents of a cell section of the Developer's Guide.
When editing a cells feed you should use PUT
for adding data to a blank cell and clearing data from a blank cell in addition to updating the contents of a cell. The POST
and DELETE
methods on the cells feed are deprecated.
You can find more information in the Getting Started article for .NET:
http://code.google.com/apis/gdata/articles/dotnet_client_lib.html
The Google Documents List data API is an extension of the Google data API protocol, which you can use to create programs that interact with Google Documents. The API allows you to query for a list of word processor documents and/or spreadsheets that contain a given search term or have titles matching a search term. It also allows you to upload existing word processor documents or spreadsheets to Google Documents.
The Google Documents List data API is designed for developers who would like to integrate their applications with Google Documents. Visit here to get started:
The Developer Guide for Spreadsheets can be found at: http://code.google.com/apis/spreadsheets/developers_guide_protocol.html
The Developer Guide for Documents List can be found at: http://code.google.com/apis/documents/developers_guide_protocol.html
File extension | MIME type |
---|---|
CSV | text/csv |
TSV | text/tab-separated-values |
TAB | text/tab-separated-values |
HTML | text/html |
HTM | text/html |
DOC | application/msword |
ODS | application/x-vnd.oasis.opendocument.spreadsheet |
ODT | application/vnd.oasis.opendocument.text |
RTF | application/rtf |
SXW | application/vnd.sun.xml.writer |
TXT | text/plain |
XLS | application/vnd.ms-excel |
PPT | application/vnd.ms-powerpoint |
PPS | application/vnd.ms-powerpoint |
Yes, in order to retrieve a list of documents or upload documents to the Google Documents service, you will need to sign up for an account at http://docs.google.com.
The API is designed to help anyone interested in uploading their existing documents to their Google Documents account programmatically and for developers wishing to integrate their applications with Google Documents.
If you have not created a Google Documents account please visit http://docs.google.com.
If you wish to create an application which can programmatically upload to or access your list of documents, then the Google Documents List API can enable you to do so. Developers should be familiar with XML and the HTTP protocol. Further information on how to begin can be found here:
An authenticated Google Documents user can query the list of documents that belong to them.
Java, .NET, Python and Objective-C client libraries are officially supported by Google. Using these libraries, you can construct Google Data requests, send them to a service, and process server responses.
If you write a client library in a language other than Java, .Net, Python or Objective-C, and would like to share with the Google Data developer community, please post in the Google Data discussion group. We would love to hear from you!
In addition, our partner Zend has written a Google Data PHP client library.
Post a detailed description on the Google Docs Data APIs discussion group: