Skip to main content

Google Sheets Component

Create, read, and modify Google Spreadsheets

Component key: google-sheets

Description#

Google Sheets is Google's spreadsheet service. This component allows you to create, read, and modify spreadsheets stored in a Google Drive Account.

Documentation for the Node.js client used in this component can be found at https://googleapis.dev/nodejs/storage/latest.

Pair this with the Google Drive component to list the available Google Sheets attached to your account.

A common integration pattern involves listing files in a file store, and performing a series of actions on the array of files that are returned. See our looping over files quickstart for information about how to create a loop over an array of files.

Authorization Notes#

The Google Sheets component requires authentication through Google's OAuth service. To create a Google Sheets developer account and authenticate using Google OAuth, follow directions on https://developers.google.com/sheets/api/quickstart/quickstarts-overview?hl=en.

Actions#

Append To Spreadsheet#

Append values to a Google Sheet | key: appendToSheet

InputKeyNotesExample

Insert Data Option

string
/ Required
insertDataOptionDetermines how existing data is changed when new data is input.

Major Dimension

string
/ Required
majorDimensionThe major dimension that results should use. For example, if the spreadsheet data is: A1=1,B1=2,A2=3,B2=4, then a request that selects that range and sets majorDimension=ROWS returns [[1,2],[3,4]], whereas a request that sets majorDimension=COLUMNS returns [[1,3],[2,4]].

Range

string
rangeGoogle Sheets allows for 2 different formats of cell ranges: A1 Notation and R1C1 Notation.A1:A25

Date Time Render Option

string
/ Required
responseDateTimeRenderOptionDetermines how dates should be rendered in the output.

Value Render Option

string
/ Required
responseValueRenderOptionDetermines how values should be rendered in the output.

Spreadsheet ID

string
sheetIdEvery spreadsheet is represented by a Spreadsheet resource and has a unique spreadsheetId value, containing letters, numbers, hyphens, or underscores. You can find the spreadsheet ID in a Google Sheets URL. my-example-sheet

Value Input Option

string
/ Required
valueInputOptionDetermines how input data should be interpreted.

Values

string
/ Required
valuesThe data that was read or to be written. This is an array of arrays, the outer array representing all the data and each inner array representing a major dimension. Each item in the inner array corresponds with one cell.[1,2,3,4,5,6]

Authorization#

Authorization is required for this action.
Auth TypeKeyDescriptionFields
OAuth 2.0 - Authorization Codeoauth2OAuth 2.0 authorization using the authorization code grant type

Client ID |  client_id

Client Secret |  client_secret

Scopes |  scopes

Authorization URL |  auth_uri

Access Token URL |  token_uri


Create Spreadsheet#

Create a new Google Sheet | key: createSheet

InputKeyNotesExample

Spreadsheet Title

string
/ Required
sheetTitleProvide a string for the name of the new spreadsheet.MySpreadSheet

Authorization#

Authorization is required for this action.
Auth TypeKeyDescriptionFields
OAuth 2.0 - Authorization Codeoauth2OAuth 2.0 authorization using the authorization code grant type

Client ID |  client_id

Client Secret |  client_secret

Scopes |  scopes

Authorization URL |  auth_uri

Access Token URL |  token_uri


Get Spreadsheet#

Read the contents of a Google Sheet | key: getSheet

InputKeyNotesExample

Major Dimension

string
/ Required
majorDimensionThe major dimension that results should use. For example, if the spreadsheet data is: A1=1,B1=2,A2=3,B2=4, then a request that selects that range and sets majorDimension=ROWS returns [[1,2],[3,4]], whereas a request that sets majorDimension=COLUMNS returns [[1,3],[2,4]].

Cell Ranges

string
rangesGoogle Sheets allows for 2 different formats of cell ranges: A1 Notation and R1C1 NotationA1:A25

Date Time Render Option

string
/ Required
responseDateTimeRenderOptionDetermines how dates should be rendered in the output.

Value Render Option

string
/ Required
responseValueRenderOptionDetermines how values should be rendered in the output.

Spreadsheet ID

string
sheetIdEvery spreadsheet is represented by a Spreadsheet resource and has a unique spreadsheetId value, containing letters, numbers, hyphens, or underscores. You can find the spreadsheet ID in a Google Sheets URL. my-example-sheet

Authorization#

Authorization is required for this action.
Auth TypeKeyDescriptionFields
OAuth 2.0 - Authorization Codeoauth2OAuth 2.0 authorization using the authorization code grant type

Client ID |  client_id

Client Secret |  client_secret

Scopes |  scopes

Authorization URL |  auth_uri

Access Token URL |  token_uri


Read Spreadsheet Properties#

Read the contents and metadata of a Google Sheet | key: readSheet

InputKeyNotesExample

Cell Ranges

string
rangesGoogle Sheets allows for 2 different formats of cell ranges: A1 Notation and R1C1 NotationA1:A25

Spreadsheet ID

string
sheetIdEvery spreadsheet is represented by a Spreadsheet resource and has a unique spreadsheetId value, containing letters, numbers, hyphens, or underscores. You can find the spreadsheet ID in a Google Sheets URL. my-example-sheet

Authorization#

Authorization is required for this action.
Auth TypeKeyDescriptionFields
OAuth 2.0 - Authorization Codeoauth2OAuth 2.0 authorization using the authorization code grant type

Client ID |  client_id

Client Secret |  client_secret

Scopes |  scopes

Authorization URL |  auth_uri

Access Token URL |  token_uri


Update Spreadsheet#

Update the contents of an existing Google Sheet | key: updateSheet

InputKeyNotesExample

Major Dimension

string
/ Required
majorDimensionThe major dimension that results should use. For example, if the spreadsheet data is: A1=1,B1=2,A2=3,B2=4, then a request that selects that range and sets majorDimension=ROWS returns [[1,2],[3,4]], whereas a request that sets majorDimension=COLUMNS returns [[1,3],[2,4]].

Range

string
rangeGoogle Sheets allows for 2 different formats of cell ranges: A1 Notation and R1C1 Notation.A1:A25

Spreadsheet ID

string
sheetIdEvery spreadsheet is represented by a Spreadsheet resource and has a unique spreadsheetId value, containing letters, numbers, hyphens, or underscores. You can find the spreadsheet ID in a Google Sheets URL. my-example-sheet

Value Input Option

string
/ Required
valueInputOptionDetermines how input data should be interpreted.

Values

string
/ Required
valuesThe data that was read or to be written. This is an array of arrays, the outer array representing all the data and each inner array representing a major dimension. Each item in the inner array corresponds with one cell.[1,2,3,4,5,6]

Authorization#

Authorization is required for this action.
Auth TypeKeyDescriptionFields
OAuth 2.0 - Authorization Codeoauth2OAuth 2.0 authorization using the authorization code grant type

Client ID |  client_id

Client Secret |  client_secret

Scopes |  scopes

Authorization URL |  auth_uri

Access Token URL |  token_uri