Re:Show HN: Using Google Sheets as the back end/APIs of your...
by nbbaier on Saturday April 13, 2024 @02:04AM
(#40020882)
Wow this is really cool, thanks for linking!
Re:Show HN: Using Google Sheets as the back end/APIs of your...
by johtso on Saturday April 13, 2024 @06:14AM
(#40021940)
Looks neat! Seems very limited though.. like you can't even insert multiple lines in one request?
Re:Show HN: Using Google Sheets as the back end/APIs of your...
by altbdoor on Monday April 15, 2024 @11:08PM
(#40047999)
Just tried it out. The script is able to handle multiple commands (GET, POST, etc) in one go, but you will have to package the payload as an array.
See https://github.com/ziolko/spreadapi/blob/master/spread-api.j...
As an example:
curl -L \
--data '[{ "method": "POST", "sheet": "Sheet1", "payload": { "username": "John", "age": 25 } }, { "method": "GET", "sheet": "Sheet1" }]' \
"https://script.google.com/macros/s/$APP_ID/exec"
A single curl request, that POSTs a user, and then GETs the data. So you can do multiple POSTs to add multiple rows too.
Re:Show HN: Using Google Sheets as the back end/APIs of your...
by _sidewalkchalk_ on Saturday April 13, 2024 @09:36AM
(#40023044)
what are the Spread API rate limits? Wasn't able to find info about this on the site
Re:Show HN: Using Google Sheets as the back end/APIs of your...
by ziolko on Saturday April 13, 2024 @11:20AM
(#40023671)
So glad that people find my little project useful!
Please keep in mind that you can always post your improvement ideas or PR's here https://github.com/ziolko/spreadapi.
It's a free Google Sheets / Apps Script you just paste to your sheet, and it turns the sheet into a full CRUD. It's kind of rate limited though but completely free!
Edit: I've thought about creating a company around Sheets before, and the problem is that once you get to the "willing to pay" stage, you also kind of outgrow Sheets. I'd rather migrate to Turso, Cloudflare D1, or Pocketbase instead of staying with Sheets or SpreadAPI, because of the limitations.