This message has oneof_ fields (mutually exclusive fields).
For each oneof, at most one member field can be set at the same time.
Setting any member of the oneof automatically clears all other
members.
str
Required. User-provided name for the Cloud Storage bucket.
The bucket must be created by the user. The bucket name must
be without any prefix like "gs://". See the [bucket naming
requirements]
(https://cloud.google.com/storage/docs/buckets#naming).
filename_prefix
:noindex:
str
Optional. User-provided prefix for Cloud Storage filename.
See the `object naming
requirements
filename_suffix
:noindex:
str
Optional. User-provided suffix for Cloud Storage filename.
See the `object naming
requirements
filename_datetime_format
:noindex:
str
Optional. User-provided format string specifying how to
represent datetimes in Cloud Storage filenames. See the
`datetime format
guidance
text_config
:noindex:
google.pubsub_v1.types.CloudStorageConfig.TextConfig
Optional. If set, message data will be
written to Cloud Storage in text format.
This field is a member of oneof_ output_format.
avro_config
:noindex:
google.pubsub_v1.types.CloudStorageConfig.AvroConfig
Optional. If set, message data will be
written to Cloud Storage in Avro format.
This field is a member of oneof_ output_format.
max_duration
:noindex:
google.protobuf.duration_pb2.Duration
Optional. The maximum duration that can
elapse before a new Cloud Storage file is
created. Min 1 minute, max 10 minutes, default 5
minutes. May not exceed the subscription's
acknowledgment deadline.
max_bytes
:noindex:
int
Optional. The maximum bytes that can be written to a Cloud
Storage file before a new file is created. Min 1 KB, max 10
GiB. The max_bytes limit may be exceeded in cases where
messages are larger than the limit.
max_messages
:noindex:
int
Optional. The maximum number of messages that
can be written to a Cloud Storage file before a
new file is created. Min 1000 messages.
state
:noindex:
google.pubsub_v1.types.CloudStorageConfig.State
Output only. An output-only field that
indicates whether or not the subscription can
receive messages.
service_account_email
:noindex:
str
Optional. The service account to use to write to Cloud
Storage. The subscription creator or updater that specifies
this field must have iam.serviceAccounts.actAs
permission on the service account. If not specified, the
Pub/Sub `service
agent
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-28 UTC."],[],[],null,["# Class CloudStorageConfig (2.31.0)\n\nVersion latestkeyboard_arrow_down\n\n- [2.31.0 (latest)](/python/docs/reference/pubsub/latest/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.30.0](/python/docs/reference/pubsub/2.30.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.29.1](/python/docs/reference/pubsub/2.29.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.28.0](/python/docs/reference/pubsub/2.28.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.27.3](/python/docs/reference/pubsub/2.27.3/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.26.1](/python/docs/reference/pubsub/2.26.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.25.2](/python/docs/reference/pubsub/2.25.2/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.23.1](/python/docs/reference/pubsub/2.23.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.22.0](/python/docs/reference/pubsub/2.22.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.21.5](/python/docs/reference/pubsub/2.21.5/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.20.3](/python/docs/reference/pubsub/2.20.3/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.19.8](/python/docs/reference/pubsub/2.19.8/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.18.4](/python/docs/reference/pubsub/2.18.4/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.17.1](/python/docs/reference/pubsub/2.17.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.16.1](/python/docs/reference/pubsub/2.16.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.15.2](/python/docs/reference/pubsub/2.15.2/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.14.1](/python/docs/reference/pubsub/2.14.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.13.12](/python/docs/reference/pubsub/2.13.12/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.12.1](/python/docs/reference/pubsub/2.12.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.11.1](/python/docs/reference/pubsub/2.11.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.10.0](/python/docs/reference/pubsub/2.10.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.9.0](/python/docs/reference/pubsub/2.9.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.8.0](/python/docs/reference/pubsub/2.8.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.7.1](/python/docs/reference/pubsub/2.7.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.6.1](/python/docs/reference/pubsub/2.6.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.5.0](/python/docs/reference/pubsub/2.5.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.4.2](/python/docs/reference/pubsub/2.4.2/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.3.0](/python/docs/reference/pubsub/2.3.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.2.0](/python/docs/reference/pubsub/2.2.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.1.0](/python/docs/reference/pubsub/2.1.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [2.0.0](/python/docs/reference/pubsub/2.0.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [1.7.2](/python/docs/reference/pubsub/1.7.2/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [1.6.1](/python/docs/reference/pubsub/1.6.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [1.5.0](/python/docs/reference/pubsub/1.5.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [1.4.3](/python/docs/reference/pubsub/1.4.3/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [1.3.1](/python/docs/reference/pubsub/1.3.1/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [1.2.0](/python/docs/reference/pubsub/1.2.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [1.1.0](/python/docs/reference/pubsub/1.1.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [1.0.2](/python/docs/reference/pubsub/1.0.2/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [0.45.0](/python/docs/reference/pubsub/0.45.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [0.44.0](/python/docs/reference/pubsub/0.44.0/google.cloud.pubsub_v1.types.CloudStorageConfig)\n- [0.43.0](/python/docs/reference/pubsub/0.43.0/google.cloud.pubsub_v1.types.CloudStorageConfig) \n\n CloudStorageConfig(mapping=None, *, ignore_unknown_fields=False, **kwargs)\n\nConfiguration for a Cloud Storage subscription.\n\nThis message has `oneof`_ fields (mutually exclusive fields).\nFor each oneof, at most one member field can be set at the same time.\nSetting any member of the oneof automatically clears all other\nmembers.\n\n.. _oneof: \u003chttps://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields\u003e\n\nClasses\n-------\n\n### AvroConfig\n\n AvroConfig(mapping=None, *, ignore_unknown_fields=False, **kwargs)\n\nConfiguration for writing message data in Avro format.\nMessage payloads and metadata will be written to files as an\nAvro binary.\n\n### State\n\n State(value)\n\nPossible states for a Cloud Storage subscription.\n\n### TextConfig\n\n TextConfig(mapping=None, *, ignore_unknown_fields=False, **kwargs)\n\nConfiguration for writing message data in text format.\nMessage payloads will be written to files as raw text, separated\nby a newline."]]