Accessing Public Spreadsheets via API Key (Without Any Configuration)
This documentation provides an overview of how to access public view spreadsheets using an API Key, without the need for any configuration on the dashboard. All GET
endpoints can be used using this approach.
Prerequisites
- Ensure you have a valid API Key. You can find your API Key on the Account page of your dashboard.
Authentication
Instead of passing a <connection-id>
, you will use your API Key for your requests. The API request should also include __id
query parameter which is the Spreadsheet ID.
Example
Let's say we want to access https://docs.google.com/spreadsheets/d/1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgvE2upms/edit#gid=0
which is a public spreadsheet.
We can read data for this spreadsheet using following CURL command
curl -XGET 'https://api.sheet2db.com/v1/{apiKey}?__id=1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgvE2upms&format=records&limit=10'