Use Google Cloud Platform Bucket with React.js

Hi all,

I am working on a project where I need to make CRUD operations with the GCP bucket. The app doesn’t have a backend, everything is on the client. Is there a way to make a POST request to the bucket with Axios library for example?

Thank you very much!

Hello, I work with GCP at work. I’m not an expert, but I do have some experience.

I don’t think there is an easy way to manage GCP bucket data without a back-end unless you use something like Firebase.

The reason for this is because GCP’s cloud storage doesn’t really provide any interfaces out of the box to authenticated/authorized any CRUD actions on the bucket itself. It needs some security/abstraction otherwise any user can do anything within the bucket, making it impractical. For example there’s nothing stopping a user from uploading endless amounts of data, then deleting it and running up your costs. So even if it’s possible to do this using some workaround from the client-side I wouldn’t take this route.

You can perform some actions directly to a bucket that is made public, such as getting the data, but full CRUD support is probably a non-starter. I’m sure there is some wonky work-around involving one of GCP’s client-side api’s, and using some other form of authentication to “get access” to the bucket’s apis to perform actions, but I’ve never ran into any clear paths for that route.

The Firebase option works because Firebase is a set of API’s that you can manage as that abstraction layer, with built in authentication and other features. It might work for your use-case better, or just create a back-end so you can manage uploads from a secure environment.


Thanks a lot for the explanation. I will try firebase for this particular task!

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.