Questions tagged [google-sheets-api]

The Google Sheets API lets developers write third-party applications that read and modify any aspect of spreadsheets. Not to be confused with [google-apps-script]

The Google Sheets REST API enables developers to create applications that read and modify the data in Google Sheets.

This API is useful for:

  • Managing the worksheets in a Google Sheets file
  • Consuming the rows of a worksheet
  • Managing cells in a worksheet by position
  • Performing complex formatting of cell text

Example quickstarts are available for most popular languages, along with Google-provided client libraries.

References

6071 questions
1
vote
0 answers

Inserted image by Google Apps Script isn't exported

My script inserts a PNG image in the spreadsheet by insertImage() function. const Sheet = SpreadsheetApp.getActiveSpreadsheet().getSheetByName("Sheet1"); const File = DriveApp.getFileById("**********"); // PNG file in Google Drive const…
fujimu
  • 11
  • 1
1
vote
1 answer

Google sheet: Error on copy sheet to other spreadsheet

I am trying to copy a sheet into other spreadsheet by using this code. However, there is error: [Exception: Specified sheet must be part of the spreadsheet] function copy_to_A() { var source = SpreadsheetApp.getActiveSpreadsheet(); var…
1
vote
1 answer

gspread - get specific columns by column name

I have a sheet with the struct below. COLUMN1 | COLUMN2 | COLUMN3 0 | 3 | 1 1 | 3 | 2 | 5 | 4 4 | 2 | 2 How can I return just the column 1 and 2 by its column name? Not by the index. Using the…
1
vote
1 answer

Sorting the sheets in a google sheets worksheet

I am reading data from google sheets, writing data to google sheets, and want to rearrange the sheets inside the worksheet: CLIENT_SECRET_GOOGLE_SHEETS = r"client_secret_google_sheets.json" creds =…
Jonas Palačionis
  • 4,591
  • 4
  • 22
  • 55
1
vote
1 answer

I want to write spread sheet with service account

I use Ruby. I want to access a Google Spread Sheet. However, in the document, the access method is not listed depending on the service account. I referred to the following articles. https://developers.google.com/sheets/api/quickstart/ruby Please…
せんば
  • 11
  • 1
1
vote
1 answer

How do I use the google sheets api v4?

I am trying to switch to the new google spreadsheets API v4 in my android studio app. I am trying to load the data from the URL but the program doesn't find the credentials JSON and I do not know where to put it so the program will see it. I used…
1
vote
1 answer

Google script (.gs) returns duplicate rows

I have created a CRUD webApp based on Googlesheet. I'm getting duplicate search results when I try to search through multiple rows and columns of the html datatable in the web App. This happens when search test matches data in the multiple columns…
1
vote
1 answer

Problem with updating a script for the sheets v4 API version

I am trying to update this script for the Sheets v4 API version but I am not successful... jQuery(document).ready(function() { setTimeout(function() { jQuery.getJSON( …
Luke
  • 11
  • 4
1
vote
1 answer

Google OAuth: Only revoke authorization to selected scopes (not all)

I'm using Google OAuth to access users' Google Sheets and Drive. However, I want to give users an option to revoke the access but if a user decides to keep Google Sheets and revoke Drive, they will unintentionally revoke all the access. How to allow…
1
vote
2 answers

Uncaught Reference Error: gapi is not defined

So I'm trying to experiment with accessing my google spreadsheet using JS, and I'm a beginner, and probably way in over my head, but I need help So I have this script Google Sheets API Quickstart
1
vote
2 answers

How to set up Google sheets API for personal use

I'm trying to follow the instructions here which tell me to create credentials via the instructions here, which as step 6 tells me 'Click the user type for your app. If you're running a Quickstart, select Internal.' On the page in question,…
Arepo
  • 825
  • 1
  • 9
  • 23
1
vote
1 answer

I can't properly adjust the google spreadsheet body using python

I am able to make a new blank google spreadsheet using python. Everything works fine except the fact that i can't figure out how to properly adjust the spreadsheet body to my needs. What i really wanna do is to pass values in the cells of the first…
Orestis D
  • 45
  • 3
1
vote
2 answers

Importing API data via importJSON

Having a bit of trouble using importJSON for the first time in Google Sheets. My data is importing as truncated and I can't find any way to really filter things the way I'd like. API source: https://prices.runescape.wiki/api/v1/osrs/1h I'm using the…
1
vote
1 answer

Is there a way to mass edit user permissions / interact with hundreds of Google Sheets via Python?

I have around 600 google sheets that are all very similar where I need to get values from one specific column. I've authenticated an app in the Google Developer console so I have access to one sheet. However to do so I had to give access to the…
purpletube
  • 21
  • 4
1
vote
1 answer

Increment a cell value in a dataframe by the amount written in another dataframe cell

Given source and target dataframes in Pandas, I need to update a column in the target dataframe by an amount specified in a column of the source dataframe, for every match on a key column. In the example below, the source and target dataframes are…
1 2 3
99
100