Classes
Bucket
Create a Bucket object to interact with a Cloud Storage bucket.
Channel
Create a channel object to interact with a Cloud Storage channel.
CRC32C
File
A File object is created from your Bucket object using .
HashStreamValidator
HmacKey
An HmacKey object contains metadata of an HMAC key created from a service account through the Storage client using .
Iam
Get and set IAM policies for your Cloud Storage bucket.
See Cloud Storage IAM Management See Granting, Changing, and Revoking Access See IAM Roles
Iam
Notification
A Notification object is created from your Bucket object using . Use it to interact with Cloud Pub/Sub notifications.
Storage
ACLs
Cloud Storage uses access control lists (ACLs) to manage object and bucket access. ACLs are the mechanism you use to share files with other users and allow other users to access your buckets and files.To learn more about ACLs, read this overview on Access Control .
See Cloud Storage overview See Access Control
TransferManager
Create a TransferManager object to perform parallel transfer operations on a Cloud Storage bucket.
Interfaces
AccessControlObject
AclOptions
AddAclCallback
AddAclOptions
BucketCallback
BucketExistsOptions
BucketLockCallback
BucketOptions
CombineCallback
CombineOptions
CopyCallback
CopyOptions
CRC32CValidator
An interface for CRC32C hashing and validation
CRC32CValidatorGenerator
A function that generates a CRC32C Validator
CreateBucketQuery
CreateBucketRequest
CreateChannelCallback
CreateChannelConfig
CreateChannelOptions
CreateHmacKeyCallback
CreateHmacKeyOptions
CreateNotificationCallback
CreateNotificationOptions
CreateReadStreamOptions
CreateResumableUploadCallback
CreateResumableUploadOptions
CreateWriteStreamOptions
DeleteBucketCallback
DeleteBucketOptions
DeleteFileCallback
DeleteFileOptions
DeleteFilesCallback
DeleteFilesOptions
DeleteNotificationCallback
DeleteNotificationCallback
DeleteNotificationOptions
DisableRequesterPaysCallback
DownloadFileInChunksOptions
DownloadManyFilesOptions
DownloadOptions
EnableRequesterPaysCallback
EncryptionKeyOptions
FileExistsCallback
FileExistsOptions
FileOptions
GenerateSignedPostPolicyV2Callback
GenerateSignedPostPolicyV2Options
GenerateSignedPostPolicyV4Callback
GenerateSignedPostPolicyV4Options
GetAclCallback
GetAclOptions
GetBucketCallback
GetBucketMetadataCallback
GetBucketMetadataOptions
GetBucketOptions
GetBucketsCallback
GetBucketSignedUrlConfig
GetBucketsRequest
GetExpirationDateCallback
GetFileCallback
GetFileMetadataCallback
GetFileMetadataOptions
GetFileOptions
GetFilesCallback
GetFilesOptions
GetHmacKeysCallback
GetHmacKeysOptions
GetLabelsCallback
GetLabelsOptions
GetNotificationCallback
GetNotificationCallback
GetNotificationMetadataCallback
GetNotificationMetadataCallback
GetNotificationMetadataOptions
GetNotificationOptions
GetNotificationsCallback
GetNotificationsOptions
GetPolicyCallback
GetPolicyCallback
GetPolicyOptions
GetServiceAccountCallback
GetServiceAccountOptions
GetSignedUrlCallback
GetSignedUrlConfig
HashStreamValidatorOptions
HmacKeyMetadata
HmacKeyMetadataCallback
HmacKeyResourceResponse
Labels
MakeBucketPrivateCallback
MakeBucketPrivateOptions
MakeBucketPublicCallback
MakeBucketPublicOptions
MakeFilePrivateOptions
MakeFilePublicCallback
MoveCallback
MoveOptions
Policy
PolicyDocument
PolicyFields
PreconditionOptions
RemoveAclCallback
RemoveAclOptions
SaveCallback
SaveOptions
ServiceAccount
SetBucketMetadataCallback
SetBucketMetadataOptions
SetBucketStorageClassCallback
SetBucketStorageClassOptions
SetFileMetadataCallback
SetFileMetadataOptions
SetHmacKeyMetadata
SetHmacKeyMetadataOptions
SetLabelsCallback
SetLabelsOptions
SetPolicyCallback
SetPolicyCallback
SetPolicyOptions
{object} SetPolicyOptions
SetStorageClassCallback
SetStorageClassOptions
SignedPostPolicyV4Output
StopCallback
StorageOptions
TestIamPermissionsCallback
TestIamPermissionsCallback
TestIamPermissionsOptions
{object} TestIamPermissionsOptions Configuration options for Iam#testPermissions().
UpdateAclCallback
UpdateAclOptions
UploadCallback
UploadManyFilesOptions
UploadOptions
Enums
IdempotencyStrategy
Variables
CRC32C_DEFAULT_VALIDATOR_GENERATOR
CRC32C_DEFAULT_VALIDATOR_GENERATOR
:
CRC32CValidatorGenerator
CRC32C_EXCEPTION_MESSAGES
CRC32C_EXCEPTION_MESSAGES
:
{
readonly
INVALID_INIT_BASE64_RANGE
:
(
l
:
number
)
=
>
string
;
readonly
INVALID_INIT_BUFFER_LENGTH
:
(
l
:
number
)
=
>
string
;
readonly
INVALID_INIT_INTEGER
:
(
l
:
number
)
=
>
string
;
}
CRC32C_EXTENSION_TABLE
CRC32C_EXTENSION_TABLE
:
Int32Array
CRC32C_EXTENSIONS
CRC32C_EXTENSIONS
:
readonly
[
0
,
4067132163
,
3778769143
,
324072436
,
3348797215
,
904991772
,
648144872
,
3570033899
,
2329499855
,
2024987596
,
1809983544
,
2575936315
,
1296289744
,
3207089363
,
2893594407
,
1578318884
,
274646895
,
3795141740
,
4049975192
,
51262619
,
3619967088
,
632279923
,
922689671
,
3298075524
,
2592579488
,
1760304291
,
2075979607
,
2312596564
,
1562183871
,
2943781820
,
3156637768
,
1313733451
,
549293790
,
3537243613
,
3246849577
,
871202090
,
3878099393
,
357341890
,
102525238
,
4101499445
,
2858735121
,
1477399826
,
1264559846
,
3107202533
,
1845379342
,
2677391885
,
2361733625
,
2125378298
,
820201905
,
3263744690
,
3520608582
,
598981189
,
4151959214
,
85089709
,
373468761
,
3827903834
,
3124367742
,
1213305469
,
1526817161
,
2842354314
,
2107672161
,
2412447074
,
2627466902
,
1861252501
,
1098587580
,
3004210879
,
2688576843
,
1378610760
,
2262928035
,
1955203488
,
1742404180
,
2511436119
,
3416409459
,
969524848
,
714683780
,
3639785095
,
205050476
,
4266873199
,
3976438427
,
526918040
,
1361435347
,
2739821008
,
2954799652
,
1114974503
,
2529119692
,
1691668175
,
2005155131
,
2247081528
,
3690758684
,
697762079
,
986182379
,
3366744552
,
476452099
,
3993867776
,
4250756596
,
255256311
,
1640403810
,
2477592673
,
2164122517
,
1922457750
,
2791048317
,
1412925310
,
1197962378
,
3037525897
,
3944729517
,
427051182
,
170179418
,
4165941337
,
746937522
,
3740196785
,
3451792453
,
1070968646
,
1905808397
,
2213795598
,
2426610938
,
1657317369
,
3053634322
,
1147748369
,
1463399397
,
2773627110
,
4215344322
,
153784257
,
444234805
,
3893493558
,
1021025245
,
3467647198
,
3722505002
,
797665321
,
2197175160
,
1889384571
,
1674398607
,
2443626636
,
1164749927
,
3070701412
,
2757221520
,
1446797203
,
137323447
,
4198817972
,
3910406976
,
461344835
,
3484808360
,
1037989803
,
781091935
,
3705997148
,
2460548119
,
1623424788
,
1939049696
,
2180517859
,
1429367560
,
2807687179
,
3020495871
,
1180866812
,
410100952
,
3927582683
,
4182430767
,
186734380
,
3756733383
,
763408580
,
1053836080
,
3434856499
,
2722870694
,
1344288421
,
1131464017
,
2971354706
,
1708204729
,
2545590714
,
2229949006
,
1988219213
,
680717673
,
3673779818
,
3383336350
,
1002577565
,
4010310262
,
493091189
,
238226049
,
4233660802
,
2987750089
,
1082061258
,
1395524158
,
2705686845
,
1972364758
,
2279892693
,
2494862625
,
1725896226
,
952904198
,
3399985413
,
3656866545
,
731699698
,
4283874585
,
222117402
,
510512622
,
3959836397
,
3280807620
,
837199303
,
582374963
,
3504198960
,
68661723
,
4135334616
,
3844915500
,
390545967
,
1230274059
,
3141532936
,
2825850620
,
1510247935
,
2395924756
,
2091215383
,
1878366691
,
2644384480
,
3553878443
,
565732008
,
854102364
,
3229815391
,
340358836
,
3861050807
,
4117890627
,
119113024
,
1493875044
,
2875275879
,
3090270611
,
1247431312
,
2660249211
,
1828433272
,
2141937292
,
2378227087
,
3811616794
,
291187481
,
34330861
,
4032846830
,
615137029
,
3603020806
,
3314634738
,
939183345
,
1776939221
,
2609017814
,
2295496738
,
2058945313
,
2926798794
,
1545135305
,
1330124605
,
3173225534
,
4084100981
,
17165430
,
307568514
,
3762199681
,
888469610
,
3332340585
,
3587147933
,
665062302
,
2042050490
,
2346497209
,
2559330125
,
1793573966
,
3190661285
,
1279665062
,
1595330642
,
2910671697
]
Ported from
Type Aliases
AddAclResponse
export
type
AddAclResponse
=
[
AccessControlObject
,
Metadata
];
BucketExistsCallback
export
type
BucketExistsCallback
=
ExistsCallback
;
BucketExistsResponse
export
type
BucketExistsResponse
=
[
boolean
];
BucketLockResponse
export
type
BucketLockResponse
=
[
Metadata
];
CombineResponse
export
type
CombineResponse
=
[
File
,
Metadata
];
CopyResponse
export
type
CopyResponse
=
[
File
,
Metadata
];
CreateBucketResponse
export
type
CreateBucketResponse
=
[
Bucket
,
Metadata
];
CreateChannelResponse
export
type
CreateChannelResponse
=
[
Channel
,
Metadata
];
CreateHmacKeyResponse
export
type
CreateHmacKeyResponse
=
[
HmacKey
,
string
,
HmacKeyResourceResponse
];
CreateNotificationResponse
export
type
CreateNotificationResponse
=
[
Notification
,
Metadata
];
CreateResumableUploadResponse
export
type
CreateResumableUploadResponse
=
[
string
];
DeleteBucketResponse
export
type
DeleteBucketResponse
=
[
Metadata
];
DeleteFileResponse
export
type
DeleteFileResponse
=
[
Metadata
];
DeleteLabelsCallback
export
type
DeleteLabelsCallback
=
SetLabelsCallback
;
DeleteLabelsResponse
export
type
DeleteLabelsResponse
=
[
Metadata
];
DisableRequesterPaysResponse
export
type
DisableRequesterPaysResponse
=
[
Metadata
];
DownloadCallback
export
type
DownloadCallback
=
(
err
:
RequestError
|
null
,
contents
:
Buffer
)
=
>
void
;
DownloadResponse
export
type
DownloadResponse
=
[
Buffer
];
EnableRequesterPaysResponse
export
type
EnableRequesterPaysResponse
=
[
Metadata
];
FileExistsResponse
export
type
FileExistsResponse
=
[
boolean
];
GenerateSignedPostPolicyV2Response
export
type
GenerateSignedPostPolicyV2Response
=
[
PolicyDocument
];
GenerateSignedPostPolicyV4Response
export
type
GenerateSignedPostPolicyV4Response
=
[
SignedPostPolicyV4Output
];
GetAclResponse
export
type
GetAclResponse
=
[
AccessControlObject
|
AccessControlObject
[],
Metadata
];
GetBucketMetadataResponse
export
type
GetBucketMetadataResponse
=
[
Metadata
,
Metadata
];
GetBucketResponse
export
type
GetBucketResponse
=
[
Bucket
,
Metadata
];
GetBucketsResponse
export
type
GetBucketsResponse
=
[
Bucket
[],
{},
Metadata
];
GetExpirationDateResponse
export
type
GetExpirationDateResponse
=
[
Date
];
GetFileMetadataResponse
export
type
GetFileMetadataResponse
=
[
Metadata
,
Metadata
];
GetFileResponse
export
type
GetFileResponse
=
[
File
,
Metadata
];
GetFilesResponse
export
type
GetFilesResponse
=
[
File
[],
{},
Metadata
];
GetHmacKeysResponse
export
type
GetHmacKeysResponse
=
[
HmacKey
[]];
GetLabelsResponse
export
type
GetLabelsResponse
=
[
Metadata
];
GetNotificationMetadataResponse
export
type
GetNotificationMetadataResponse
=
[
ResponseBody
,
Metadata
];
{array} GetNotificationMetadataResponse {object} 0 The notification metadata. {object} 1 The full API response.
GetNotificationResponse
export
type
GetNotificationResponse
=
[
Notification
,
Metadata
];
{array} GetNotificationResponse {Notification} 0 The Notification {object} 1 The full API response.
GetNotificationsResponse
export
type
GetNotificationsResponse
=
[
Notification
[],
Metadata
];
GetPolicyResponse
export
type
GetPolicyResponse
=
[
Policy
,
Metadata
];
GetServiceAccountResponse
export
type
GetServiceAccountResponse
=
[
ServiceAccount
,
Metadata
];
GetSignedUrlResponse
export
type
GetSignedUrlResponse
=
[
SignerGetSignedUrlResponse
];
HmacKeyMetadataResponse
export
type
HmacKeyMetadataResponse
=
[
HmacKeyMetadata
,
Metadata
];
MakeBucketPrivateResponse
export
type
MakeBucketPrivateResponse
=
[
File
[]];
MakeBucketPublicResponse
export
type
MakeBucketPublicResponse
=
[
File
[]];
MakeFilePrivateCallback
export
type
MakeFilePrivateCallback
=
SetFileMetadataCallback
;
MakeFilePrivateResponse
export
type
MakeFilePrivateResponse
=
[
Metadata
];
MakeFilePublicResponse
export
type
MakeFilePublicResponse
=
[
Metadata
];
MoveResponse
export
type
MoveResponse
=
[
Metadata
];
PredefinedAcl
export
type
PredefinedAcl
=
'authenticatedRead'
|
'bucketOwnerFullControl'
|
'bucketOwnerRead'
|
'private'
|
'projectPrivate'
|
'publicRead'
;
RemoveAclResponse
export
type
RemoveAclResponse
=
[
Metadata
];
RotateEncryptionKeyCallback
export
type
RotateEncryptionKeyCallback
=
CopyCallback
;
RotateEncryptionKeyOptions
export
type
RotateEncryptionKeyOptions
=
string
|
Buffer
|
EncryptionKeyOptions
;
RotateEncryptionKeyResponse
export
type
RotateEncryptionKeyResponse
=
CopyResponse
;
SetBucketMetadataResponse
export
type
SetBucketMetadataResponse
=
[
Metadata
];
SetFileMetadataResponse
export
type
SetFileMetadataResponse
=
[
Metadata
];
SetLabelsResponse
export
type
SetLabelsResponse
=
[
Metadata
];
SetPolicyResponse
export
type
SetPolicyResponse
=
[
Policy
,
Metadata
];
{array} SetPolicyResponse {object} 0 The policy. {object} 1 The full API response.
SetStorageClassResponse
export
type
SetStorageClassResponse
=
[
Metadata
];
TestIamPermissionsResponse
export
type
TestIamPermissionsResponse
=
[{
[
key
:
string
]
:
boolean
;
},
Metadata
];
{array} TestIamPermissionsResponse {object} 0 A subset of permissions that the caller is allowed. {object} 1 The full API response.
UpdateAclResponse
export
type
UpdateAclResponse
=
[
AccessControlObject
,
Metadata
];
UploadResponse
export
type
UploadResponse
=
[
File
,
Metadata
];