Yes, that was using the API directly. If you've set up the Google Sheets resource in Retool, you should be able to accomplish it with the Update a spreadsheet option, clicking "Use A1 notation" and setting that to the value of your sheet. Keep in mind, if your new data isn't the same size/smaller, you might need to first clear your data by updating it with an empty array.
You can achieve that by doing something like this:

Which would empty the first 20 rows x 10 columns. The code in the values box is
{{ Array.from({ length: 20 }, () => Array(10).fill("")) }}