A worker to turn Google Sheet API into a REST API

I want to submit my static form data to a google sheet. But I can’t just simply do it as google doesn’t provide a REST API. I have been using (github[dot]com/dtinth/sheet.spacet.me) by hosting it on Vercel. And it’s working really well.

But to my knowledge, Vercel have some uptime problem. Also, I find Cloudflare more reliable than Vercel. So, I want to use Cloudflare Worker as my REST API backend. :sweat_smile:

I tried to find a Cloudflare Worker script to create Google Sheet REST API , but couldn’t find one. :cry:
Google Sheet API Link: (developers.google[dot]com/sheets/api/guides/values)

It would be really helpful if someone could find or provide a Cloudflare Worker script for this purpose. As it’s not only going to help me but anyone who is trying to submit static form data to google sheets. :blush:

I don’t believe that there is an existing worker.
That code looks to be easy to convert over, it would be good learning as well!

1 Like

(post deleted by author)

I gave it a quick try and there are issues with importing the googleapis library. The requests are going to have to be made via the fetch API.

1 Like

(post deleted by author)