UNPKG

@google-cloud/pubsub

Version:

Cloud Pub/Sub Client Library for Node.js

1,279 lines 189 kB
{ "nested": { "google": { "nested": { "pubsub": { "nested": { "v1": { "options": { "csharp_namespace": "Google.Cloud.PubSub.V1", "go_package": "cloud.google.com/go/pubsub/v2/apiv1/pubsubpb;pubsubpb", "java_multiple_files": true, "java_outer_classname": "SchemaProto", "java_package": "com.google.pubsub.v1", "php_namespace": "Google\\Cloud\\PubSub\\V1", "ruby_package": "Google::Cloud::PubSub::V1" }, "nested": { "Publisher": { "options": { "(google.api.default_host)": "pubsub.googleapis.com", "(google.api.oauth_scopes)": "https://www.googleapis.com/auth/cloud-platform,https://www.googleapis.com/auth/pubsub" }, "methods": { "CreateTopic": { "requestType": "Topic", "responseType": "Topic", "options": { "(google.api.http).put": "/v1/{name=projects/*/topics/*}", "(google.api.http).body": "*", "(google.api.method_signature)": "name" }, "parsedOptions": [ { "(google.api.http)": { "put": "/v1/{name=projects/*/topics/*}", "body": "*" } }, { "(google.api.method_signature)": "name" } ] }, "UpdateTopic": { "requestType": "UpdateTopicRequest", "responseType": "Topic", "options": { "(google.api.http).patch": "/v1/{topic.name=projects/*/topics/*}", "(google.api.http).body": "*", "(google.api.method_signature)": "topic,update_mask" }, "parsedOptions": [ { "(google.api.http)": { "patch": "/v1/{topic.name=projects/*/topics/*}", "body": "*" } }, { "(google.api.method_signature)": "topic,update_mask" } ] }, "Publish": { "requestType": "PublishRequest", "responseType": "PublishResponse", "options": { "(google.api.http).post": "/v1/{topic=projects/*/topics/*}:publish", "(google.api.http).body": "*", "(google.api.method_signature)": "topic,messages" }, "parsedOptions": [ { "(google.api.http)": { "post": "/v1/{topic=projects/*/topics/*}:publish", "body": "*" } }, { "(google.api.method_signature)": "topic,messages" } ] }, "GetTopic": { "requestType": "GetTopicRequest", "responseType": "Topic", "options": { "(google.api.http).get": "/v1/{topic=projects/*/topics/*}", "(google.api.method_signature)": "topic" }, "parsedOptions": [ { "(google.api.http)": { "get": "/v1/{topic=projects/*/topics/*}" } }, { "(google.api.method_signature)": "topic" } ] }, "ListTopics": { "requestType": "ListTopicsRequest", "responseType": "ListTopicsResponse", "options": { "(google.api.http).get": "/v1/{project=projects/*}/topics", "(google.api.method_signature)": "project" }, "parsedOptions": [ { "(google.api.http)": { "get": "/v1/{project=projects/*}/topics" } }, { "(google.api.method_signature)": "project" } ] }, "ListTopicSubscriptions": { "requestType": "ListTopicSubscriptionsRequest", "responseType": "ListTopicSubscriptionsResponse", "options": { "(google.api.http).get": "/v1/{topic=projects/*/topics/*}/subscriptions", "(google.api.method_signature)": "topic" }, "parsedOptions": [ { "(google.api.http)": { "get": "/v1/{topic=projects/*/topics/*}/subscriptions" } }, { "(google.api.method_signature)": "topic" } ] }, "ListTopicSnapshots": { "requestType": "ListTopicSnapshotsRequest", "responseType": "ListTopicSnapshotsResponse", "options": { "(google.api.http).get": "/v1/{topic=projects/*/topics/*}/snapshots", "(google.api.method_signature)": "topic" }, "parsedOptions": [ { "(google.api.http)": { "get": "/v1/{topic=projects/*/topics/*}/snapshots" } }, { "(google.api.method_signature)": "topic" } ] }, "DeleteTopic": { "requestType": "DeleteTopicRequest", "responseType": "google.protobuf.Empty", "options": { "(google.api.http).delete": "/v1/{topic=projects/*/topics/*}", "(google.api.method_signature)": "topic" }, "parsedOptions": [ { "(google.api.http)": { "delete": "/v1/{topic=projects/*/topics/*}" } }, { "(google.api.method_signature)": "topic" } ] }, "DetachSubscription": { "requestType": "DetachSubscriptionRequest", "responseType": "DetachSubscriptionResponse", "options": { "(google.api.http).post": "/v1/{subscription=projects/*/subscriptions/*}:detach" }, "parsedOptions": [ { "(google.api.http)": { "post": "/v1/{subscription=projects/*/subscriptions/*}:detach" } } ] } } }, "MessageStoragePolicy": { "fields": { "allowedPersistenceRegions": { "rule": "repeated", "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "enforceInTransit": { "type": "bool", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } }, "SchemaSettings": { "fields": { "schema": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "REQUIRED", "(google.api.resource_reference).type": "pubsub.googleapis.com/Schema" } }, "encoding": { "type": "Encoding", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "firstRevisionId": { "type": "string", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "lastRevisionId": { "type": "string", "id": 4, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } }, "IngestionDataSourceSettings": { "oneofs": { "source": { "oneof": [ "awsKinesis", "cloudStorage", "azureEventHubs", "awsMsk", "confluentCloud" ] } }, "fields": { "awsKinesis": { "type": "AwsKinesis", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "cloudStorage": { "type": "CloudStorage", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "azureEventHubs": { "type": "AzureEventHubs", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "awsMsk": { "type": "AwsMsk", "id": 5, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "confluentCloud": { "type": "ConfluentCloud", "id": 6, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "platformLogsSettings": { "type": "PlatformLogsSettings", "id": 4, "options": { "(google.api.field_behavior)": "OPTIONAL" } } }, "nested": { "AwsKinesis": { "fields": { "state": { "type": "State", "id": 1, "options": { "(google.api.field_behavior)": "OUTPUT_ONLY" } }, "streamArn": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "consumerArn": { "type": "string", "id": 3, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "awsRoleArn": { "type": "string", "id": 4, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "gcpServiceAccount": { "type": "string", "id": 5, "options": { "(google.api.field_behavior)": "REQUIRED" } } }, "nested": { "State": { "values": { "STATE_UNSPECIFIED": 0, "ACTIVE": 1, "KINESIS_PERMISSION_DENIED": 2, "PUBLISH_PERMISSION_DENIED": 3, "STREAM_NOT_FOUND": 4, "CONSUMER_NOT_FOUND": 5 } } } }, "CloudStorage": { "oneofs": { "inputFormat": { "oneof": [ "textFormat", "avroFormat", "pubsubAvroFormat" ] } }, "fields": { "state": { "type": "State", "id": 1, "options": { "(google.api.field_behavior)": "OUTPUT_ONLY" } }, "bucket": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "textFormat": { "type": "TextFormat", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "avroFormat": { "type": "AvroFormat", "id": 4, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "pubsubAvroFormat": { "type": "PubSubAvroFormat", "id": 5, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "minimumObjectCreateTime": { "type": "google.protobuf.Timestamp", "id": 6, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "matchGlob": { "type": "string", "id": 9, "options": { "(google.api.field_behavior)": "OPTIONAL" } } }, "nested": { "State": { "values": { "STATE_UNSPECIFIED": 0, "ACTIVE": 1, "CLOUD_STORAGE_PERMISSION_DENIED": 2, "PUBLISH_PERMISSION_DENIED": 3, "BUCKET_NOT_FOUND": 4, "TOO_MANY_OBJECTS": 5 } }, "TextFormat": { "oneofs": { "_delimiter": { "oneof": [ "delimiter" ] } }, "fields": { "delimiter": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL", "proto3_optional": true } } } }, "AvroFormat": { "fields": {} }, "PubSubAvroFormat": { "fields": {} } } }, "AzureEventHubs": { "fields": { "state": { "type": "State", "id": 1, "options": { "(google.api.field_behavior)": "OUTPUT_ONLY" } }, "resourceGroup": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "namespace": { "type": "string", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "eventHub": { "type": "string", "id": 4, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "clientId": { "type": "string", "id": 5, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "tenantId": { "type": "string", "id": 6, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "subscriptionId": { "type": "string", "id": 7, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "gcpServiceAccount": { "type": "string", "id": 8, "options": { "(google.api.field_behavior)": "OPTIONAL" } } }, "nested": { "State": { "values": { "STATE_UNSPECIFIED": 0, "ACTIVE": 1, "EVENT_HUBS_PERMISSION_DENIED": 2, "PUBLISH_PERMISSION_DENIED": 3, "NAMESPACE_NOT_FOUND": 4, "EVENT_HUB_NOT_FOUND": 5, "SUBSCRIPTION_NOT_FOUND": 6, "RESOURCE_GROUP_NOT_FOUND": 7 } } } }, "AwsMsk": { "fields": { "state": { "type": "State", "id": 1, "options": { "(google.api.field_behavior)": "OUTPUT_ONLY" } }, "clusterArn": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "topic": { "type": "string", "id": 3, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "awsRoleArn": { "type": "string", "id": 4, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "gcpServiceAccount": { "type": "string", "id": 5, "options": { "(google.api.field_behavior)": "REQUIRED" } } }, "nested": { "State": { "values": { "STATE_UNSPECIFIED": 0, "ACTIVE": 1, "MSK_PERMISSION_DENIED": 2, "PUBLISH_PERMISSION_DENIED": 3, "CLUSTER_NOT_FOUND": 4, "TOPIC_NOT_FOUND": 5 } } } }, "ConfluentCloud": { "fields": { "state": { "type": "State", "id": 1, "options": { "(google.api.field_behavior)": "OUTPUT_ONLY" } }, "bootstrapServer": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "clusterId": { "type": "string", "id": 3, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "topic": { "type": "string", "id": 4, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "identityPoolId": { "type": "string", "id": 5, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "gcpServiceAccount": { "type": "string", "id": 6, "options": { "(google.api.field_behavior)": "REQUIRED" } } }, "nested": { "State": { "values": { "STATE_UNSPECIFIED": 0, "ACTIVE": 1, "CONFLUENT_CLOUD_PERMISSION_DENIED": 2, "PUBLISH_PERMISSION_DENIED": 3, "UNREACHABLE_BOOTSTRAP_SERVER": 4, "CLUSTER_NOT_FOUND": 5, "TOPIC_NOT_FOUND": 6 } } } } } }, "PlatformLogsSettings": { "fields": { "severity": { "type": "Severity", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL" } } }, "nested": { "Severity": { "values": { "SEVERITY_UNSPECIFIED": 0, "DISABLED": 1, "DEBUG": 2, "INFO": 3, "WARNING": 4, "ERROR": 5 } } } }, "IngestionFailureEvent": { "oneofs": { "failure": { "oneof": [ "cloudStorageFailure", "awsMskFailure", "azureEventHubsFailure", "confluentCloudFailure", "awsKinesisFailure" ] } }, "fields": { "topic": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "errorMessage": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "cloudStorageFailure": { "type": "CloudStorageFailure", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "awsMskFailure": { "type": "AwsMskFailureReason", "id": 4, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "azureEventHubsFailure": { "type": "AzureEventHubsFailureReason", "id": 5, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "confluentCloudFailure": { "type": "ConfluentCloudFailureReason", "id": 6, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "awsKinesisFailure": { "type": "AwsKinesisFailureReason", "id": 7, "options": { "(google.api.field_behavior)": "OPTIONAL" } } }, "nested": { "ApiViolationReason": { "fields": {} }, "AvroFailureReason": { "fields": {} }, "SchemaViolationReason": { "fields": {} }, "CloudStorageFailure": { "oneofs": { "reason": { "oneof": [ "avroFailureReason", "apiViolationReason", "schemaViolationReason" ] } }, "fields": { "bucket": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "objectName": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "objectGeneration": { "type": "int64", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "avroFailureReason": { "type": "AvroFailureReason", "id": 5, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "apiViolationReason": { "type": "ApiViolationReason", "id": 6, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "schemaViolationReason": { "type": "SchemaViolationReason", "id": 7, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } }, "AwsMskFailureReason": { "oneofs": { "reason": { "oneof": [ "apiViolationReason", "schemaViolationReason" ] } }, "fields": { "clusterArn": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "kafkaTopic": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "partitionId": { "type": "int64", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "offset": { "type": "int64", "id": 4, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "apiViolationReason": { "type": "ApiViolationReason", "id": 5, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "schemaViolationReason": { "type": "SchemaViolationReason", "id": 6, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } }, "AzureEventHubsFailureReason": { "oneofs": { "reason": { "oneof": [ "apiViolationReason", "schemaViolationReason" ] } }, "fields": { "namespace": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "eventHub": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "partitionId": { "type": "int64", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "offset": { "type": "int64", "id": 4, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "apiViolationReason": { "type": "ApiViolationReason", "id": 5, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "schemaViolationReason": { "type": "SchemaViolationReason", "id": 6, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } }, "ConfluentCloudFailureReason": { "oneofs": { "reason": { "oneof": [ "apiViolationReason", "schemaViolationReason" ] } }, "fields": { "clusterId": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "kafkaTopic": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "partitionId": { "type": "int64", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "offset": { "type": "int64", "id": 4, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "apiViolationReason": { "type": "ApiViolationReason", "id": 5, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "schemaViolationReason": { "type": "SchemaViolationReason", "id": 6, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } }, "AwsKinesisFailureReason": { "oneofs": { "reason": { "oneof": [ "schemaViolationReason" ] } }, "fields": { "streamArn": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "partitionKey": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "sequenceNumber": { "type": "string", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "schemaViolationReason": { "type": "SchemaViolationReason", "id": 4, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } } } }, "JavaScriptUDF": { "fields": { "functionName": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "code": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "REQUIRED" } } } }, "MessageTransform": { "oneofs": { "transform": { "oneof": [ "javascriptUdf" ] } }, "fields": { "javascriptUdf": { "type": "JavaScriptUDF", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "enabled": { "type": "bool", "id": 3, "options": { "deprecated": true, "(google.api.field_behavior)": "OPTIONAL" } }, "disabled": { "type": "bool", "id": 4, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } }, "Topic": { "options": { "(google.api.resource).type": "pubsub.googleapis.com/Topic", "(google.api.resource).pattern": "_deleted-topic_", "(google.api.resource).plural": "topics", "(google.api.resource).singular": "topic" }, "fields": { "name": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "labels": { "keyType": "string", "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "messageStoragePolicy": { "type": "MessageStoragePolicy", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "kmsKeyName": { "type": "string", "id": 5, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "schemaSettings": { "type": "SchemaSettings", "id": 6, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "satisfiesPzs": { "type": "bool", "id": 7, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "messageRetentionDuration": { "type": "google.protobuf.Duration", "id": 8, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "state": { "type": "State", "id": 9, "options": { "(google.api.field_behavior)": "OUTPUT_ONLY" } }, "ingestionDataSourceSettings": { "type": "IngestionDataSourceSettings", "id": 10, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "messageTransforms": { "rule": "repeated", "type": "MessageTransform", "id": 13, "options": { "(google.api.field_behavior)": "OPTIONAL" } } }, "nested": { "State": { "values": { "STATE_UNSPECIFIED": 0, "ACTIVE": 1, "INGESTION_RESOURCE_ERROR": 2 } } } }, "PubsubMessage": { "fields": { "data": { "type": "bytes", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "attributes": { "keyType": "string", "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "messageId": { "type": "string", "id": 3 }, "publishTime": { "type": "google.protobuf.Timestamp", "id": 4 }, "orderingKey": { "type": "string", "id": 5, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } }, "GetTopicRequest": { "fields": { "topic": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "REQUIRED", "(google.api.resource_reference).type": "pubsub.googleapis.com/Topic" } } } }, "UpdateTopicRequest": { "fields": { "topic": { "type": "Topic", "id": 1, "options": { "(google.api.field_behavior)": "REQUIRED" } }, "updateMask": { "type": "google.protobuf.FieldMask", "id": 2, "options": { "(google.api.field_behavior)": "REQUIRED" } } } }, "PublishRequest": { "fields": { "topic": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "REQUIRED", "(google.api.resource_reference).type": "pubsub.googleapis.com/Topic" } }, "messages": { "rule": "repeated", "type": "PubsubMessage", "id": 2, "options": { "(google.api.field_behavior)": "REQUIRED" } } } }, "PublishResponse": { "fields": { "messageIds": { "rule": "repeated", "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } }, "ListTopicsRequest": { "fields": { "project": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "REQUIRED", "(google.api.resource_reference).type": "cloudresourcemanager.googleapis.com/Project" } }, "pageSize": { "type": "int32", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "pageToken": { "type": "string", "id": 3, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } }, "ListTopicsResponse": { "fields": { "topics": { "rule": "repeated", "type": "Topic", "id": 1, "options": { "(google.api.field_behavior)": "OPTIONAL" } }, "nextPageToken": { "type": "string", "id": 2, "options": { "(google.api.field_behavior)": "OPTIONAL" } } } }, "ListTopicSubscriptionsRequest": { "fields": { "topic": { "type": "string", "id": 1, "options": { "(google.api.field_behavior)": "REQUIRED", "(google.api.resource_reference).type": "pubsub.googl