Storage: Bucket.go doesn't export projectNumber available in the REST API #4804
Labels
api: storage
Issues related to the Cloud Storage API.
type: feature request
‘Nice-to-have’ improvement, new feature or different behavior or design.
Is your feature request related to a problem? Please describe.
I intend to verify the project where bucket exists, in my 'CheckIfBucketExists' functionality.
For me to do this check, it would be great if bucket.go would export the projectNumber field available in the REST API:
https://cloud.google.com/storage/docs/json_api/v1/buckets/get
Describe the solution you'd like
bucket.attrs would give me the projectNumber associated with the project as well.
Describe alternatives you've considered
Other alternatives would for checking the existence of a bucket in a project is : to list all the buckets in the project check whether the bucket is one of them. (I dont intend to do this as it adds latency).
Additional context
https://cloud.google.com/storage/docs/json_api/v1/buckets#resource-representations --> projectNumber
The text was updated successfully, but these errors were encountered: