diff --git a/README.md b/README.md
index a72f632a09c..9034ad6ed78 100644
--- a/README.md
+++ b/README.md
@@ -23,7 +23,7 @@ This client supports the following Google Cloud Platform services at a [Beta](#v
* [Cloud Firestore](https://github.com/googleapis/nodejs-firestore/) (Beta)
* [Cloud Pub/Sub](#cloud-pubsub-beta) (Beta)
* [Cloud Spanner](https://github.com/googleapis/nodejs-spanner/) (Beta)
-* [Cloud Speech](#cloud-speech-beta) (Beta)
+* [Cloud Speech](https://github.com/googleapis/nodejs-speech/) (Beta)
* [Cloud Video Intelligence](https://github.com/googleapis/nodejs-video-intelligence/) (Beta)
* [Cloud Vision](#cloud-vision-beta) (Beta)
* [Google BigQuery](#google-bigquery-beta) (Beta)
diff --git a/packages/speech/README.md b/packages/speech/README.md
deleted file mode 100644
index ad7bfc45c83..00000000000
--- a/packages/speech/README.md
+++ /dev/null
@@ -1,59 +0,0 @@
-# Node.js Client for Google Cloud Speech API ([Beta](https://github.com/GoogleCloudPlatform/google-cloud-node#versioning))
-
-[Google Cloud Speech API][Product Documentation]: Google Cloud Speech API.
-- [Client Library Documentation][]
-- [Product Documentation][]
-
-## Quick Start
-In order to use this library, you first need to go through the following steps:
-
-1. [Select or create a Cloud Platform project.](https://console.cloud.google.com/project)
-2. [Enable the Google Cloud Speech API.](https://console.cloud.google.com/apis/api/speech)
-3. [Setup Authentication.](https://googlecloudplatform.github.io/google-cloud-node/#/docs/google-cloud/master/guides/authentication)
-
-### Installation
-```
-$ npm install --save @google-cloud/speech
-```
-
-### Preview
-#### SpeechClient
-```js
- var speech = require('@google-cloud/speech');
-
- var client = speech({
- // optional auth parameters.
- });
-
- var languageCode = 'en-US';
- var sampleRateHertz = 44100;
- var encoding = speech.v1.types.RecognitionConfig.AudioEncoding.FLAC;
- var config = {
- languageCode : languageCode,
- sampleRateHertz : sampleRateHertz,
- encoding : encoding
- };
- var uri = 'gs://gapic-toolkit/hello.flac';
- var audio = {
- uri : uri
- };
- var request = {
- config: config,
- audio: audio
- };
- client.recognize(request).then(function(responses) {
- var response = responses[0];
- // doThingsWith(response)
- })
- .catch(function(err) {
- console.error(err);
- });
-```
-
-### Next Steps
-- Read the [Client Library Documentation][] for Google Cloud Speech API to see other available methods on the client.
-- Read the [Google Cloud Speech API Product documentation][Product Documentation] to learn more about the product and see How-to Guides.
-- View this [repository's main README](https://github.com/GoogleCloudPlatform/google-cloud-node/blob/master/README.md) to see the full list of Cloud APIs that we cover.
-
-[Client Library Documentation]: https://googlecloudplatform.github.io/google-cloud-node/#/docs/speech
-[Product Documentation]: https://cloud.google.com/speech
\ No newline at end of file
diff --git a/packages/speech/package.json b/packages/speech/package.json
deleted file mode 100644
index 0edfb2f345f..00000000000
--- a/packages/speech/package.json
+++ /dev/null
@@ -1,79 +0,0 @@
-{
- "repository": "GoogleCloudPlatform/google-cloud-node",
- "name": "@google-cloud/speech",
- "version": "0.10.3",
- "author": "Google Inc.",
- "description": "Cloud Speech Client Library for Node.js",
- "contributors": [
- {
- "name": "Burcu Dogan",
- "email": "jbd@google.com"
- },
- {
- "name": "Jason Dobry",
- "email": "jason.dobry@gmail.com"
- },
- {
- "name": "Johan Euphrosine",
- "email": "proppy@google.com"
- },
- {
- "name": "Patrick Costello",
- "email": "pcostell@google.com"
- },
- {
- "name": "Ryan Seys",
- "email": "ryan@ryanseys.com"
- },
- {
- "name": "Silvano Luciani",
- "email": "silvano@google.com"
- },
- {
- "name": "Stephen Sawchuk",
- "email": "sawchuk@gmail.com"
- }
- ],
- "main": "./src/index.js",
- "files": [
- "protos",
- "src",
- "AUTHORS",
- "LICENSE"
- ],
- "keywords": [
- "google apis client",
- "google api client",
- "google apis",
- "google api",
- "google",
- "google cloud platform",
- "google cloud",
- "cloud",
- "google speech",
- "speech",
- "Google Cloud Speech API"
- ],
- "dependencies": {
- "google-proto-files": "^0.13.1",
- "google-gax": "^0.14.2",
- "extend": "^3.0.0",
- "pumpify": "^1.3.5",
- "stream-events": "^1.0.1",
- "through2": "^2.0.3"
- },
- "devDependencies": {
- "mocha": "^3.2.0",
- "power-assert": "^1.4.2",
- "sinon": "^2.2.0"
- },
- "scripts": {
- "publish-module": "node ../../scripts/publish.js speech",
- "smoke-test": "mocha smoke-test/*.js --timeout 5000",
- "test": "mocha test/*.js"
- },
- "license": "Apache-2.0",
- "engines": {
- "node": ">=4.0.0"
- }
-}
diff --git a/packages/speech/protos/google/api/annotations.proto b/packages/speech/protos/google/api/annotations.proto
deleted file mode 100644
index 85c361b47fe..00000000000
--- a/packages/speech/protos/google/api/annotations.proto
+++ /dev/null
@@ -1,31 +0,0 @@
-// Copyright (c) 2015, Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/http.proto";
-import "google/protobuf/descriptor.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/annotations;annotations";
-option java_multiple_files = true;
-option java_outer_classname = "AnnotationsProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-extend google.protobuf.MethodOptions {
- // See `HttpRule`.
- HttpRule http = 72295728;
-}
diff --git a/packages/speech/protos/google/api/auth.proto b/packages/speech/protos/google/api/auth.proto
deleted file mode 100644
index 0ef63863192..00000000000
--- a/packages/speech/protos/google/api/auth.proto
+++ /dev/null
@@ -1,183 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/annotations.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "AuthProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// `Authentication` defines the authentication configuration for an API.
-//
-// Example for an API targeted for external use:
-//
-// name: calendar.googleapis.com
-// authentication:
-// providers:
-// - id: google_calendar_auth
-// jwks_uri: https://www.googleapis.com/oauth2/v1/certs
-// issuer: https://securetoken.google.com
-// rules:
-// - selector: "*"
-// requirements:
-// provider_id: google_calendar_auth
-message Authentication {
- // A list of authentication rules that apply to individual API methods.
- //
- // **NOTE:** All service configuration rules follow "last one wins" order.
- repeated AuthenticationRule rules = 3;
-
- // Defines a set of authentication providers that a service supports.
- repeated AuthProvider providers = 4;
-}
-
-// Authentication rules for the service.
-//
-// By default, if a method has any authentication requirements, every request
-// must include a valid credential matching one of the requirements.
-// It's an error to include more than one kind of credential in a single
-// request.
-//
-// If a method doesn't have any auth requirements, request credentials will be
-// ignored.
-message AuthenticationRule {
- // Selects the methods to which this rule applies.
- //
- // Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
- string selector = 1;
-
- // The requirements for OAuth credentials.
- OAuthRequirements oauth = 2;
-
- // Whether to allow requests without a credential. The credential can be
- // an OAuth token, Google cookies (first-party auth) or EndUserCreds.
- //
- // For requests without credentials, if the service control environment is
- // specified, each incoming request **must** be associated with a service
- // consumer. This can be done by passing an API key that belongs to a consumer
- // project.
- bool allow_without_credential = 5;
-
- // Requirements for additional authentication providers.
- repeated AuthRequirement requirements = 7;
-}
-
-// Configuration for an anthentication provider, including support for
-// [JSON Web Token (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32).
-message AuthProvider {
- // The unique identifier of the auth provider. It will be referred to by
- // `AuthRequirement.provider_id`.
- //
- // Example: "bookstore_auth".
- string id = 1;
-
- // Identifies the principal that issued the JWT. See
- // https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.1
- // Usually a URL or an email address.
- //
- // Example: https://securetoken.google.com
- // Example: 1234567-compute@developer.gserviceaccount.com
- string issuer = 2;
-
- // URL of the provider's public key set to validate signature of the JWT. See
- // [OpenID Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata).
- // Optional if the key set document:
- // - can be retrieved from
- // [OpenID Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html
- // of the issuer.
- // - can be inferred from the email domain of the issuer (e.g. a Google service account).
- //
- // Example: https://www.googleapis.com/oauth2/v1/certs
- string jwks_uri = 3;
-
- // The list of JWT
- // [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3).
- // that are allowed to access. A JWT containing any of these audiences will
- // be accepted. When this setting is absent, only JWTs with audience
- // "https://[Service_name][google.api.Service.name]/[API_name][google.protobuf.Api.name]"
- // will be accepted. For example, if no audiences are in the setting,
- // LibraryService API will only accept JWTs with the following audience
- // "https://library-example.googleapis.com/google.example.library.v1.LibraryService".
- //
- // Example:
- //
- // audiences: bookstore_android.apps.googleusercontent.com,
- // bookstore_web.apps.googleusercontent.com
- string audiences = 4;
-}
-
-// OAuth scopes are a way to define data and permissions on data. For example,
-// there are scopes defined for "Read-only access to Google Calendar" and
-// "Access to Cloud Platform". Users can consent to a scope for an application,
-// giving it permission to access that data on their behalf.
-//
-// OAuth scope specifications should be fairly coarse grained; a user will need
-// to see and understand the text description of what your scope means.
-//
-// In most cases: use one or at most two OAuth scopes for an entire family of
-// products. If your product has multiple APIs, you should probably be sharing
-// the OAuth scope across all of those APIs.
-//
-// When you need finer grained OAuth consent screens: talk with your product
-// management about how developers will use them in practice.
-//
-// Please note that even though each of the canonical scopes is enough for a
-// request to be accepted and passed to the backend, a request can still fail
-// due to the backend requiring additional scopes or permissions.
-message OAuthRequirements {
- // The list of publicly documented OAuth scopes that are allowed access. An
- // OAuth token containing any of these scopes will be accepted.
- //
- // Example:
- //
- // canonical_scopes: https://www.googleapis.com/auth/calendar,
- // https://www.googleapis.com/auth/calendar.read
- string canonical_scopes = 1;
-}
-
-// User-defined authentication requirements, including support for
-// [JSON Web Token (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32).
-message AuthRequirement {
- // [id][google.api.AuthProvider.id] from authentication provider.
- //
- // Example:
- //
- // provider_id: bookstore_auth
- string provider_id = 1;
-
- // NOTE: This will be deprecated soon, once AuthProvider.audiences is
- // implemented and accepted in all the runtime components.
- //
- // The list of JWT
- // [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3).
- // that are allowed to access. A JWT containing any of these audiences will
- // be accepted. When this setting is absent, only JWTs with audience
- // "https://[Service_name][google.api.Service.name]/[API_name][google.protobuf.Api.name]"
- // will be accepted. For example, if no audiences are in the setting,
- // LibraryService API will only accept JWTs with the following audience
- // "https://library-example.googleapis.com/google.example.library.v1.LibraryService".
- //
- // Example:
- //
- // audiences: bookstore_android.apps.googleusercontent.com,
- // bookstore_web.apps.googleusercontent.com
- string audiences = 2;
-}
diff --git a/packages/speech/protos/google/api/backend.proto b/packages/speech/protos/google/api/backend.proto
deleted file mode 100644
index 61a72e14d19..00000000000
--- a/packages/speech/protos/google/api/backend.proto
+++ /dev/null
@@ -1,47 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "BackendProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// `Backend` defines the backend configuration for a service.
-message Backend {
- // A list of API backend rules that apply to individual API methods.
- //
- // **NOTE:** All service configuration rules follow "last one wins" order.
- repeated BackendRule rules = 1;
-}
-
-// A backend rule provides configuration for an individual API element.
-message BackendRule {
- // Selects the methods to which this rule applies.
- //
- // Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
- string selector = 1;
-
- // The address of the API backend.
- string address = 2;
-
- // The number of seconds to wait for a response from a request. The
- // default depends on the deployment context.
- double deadline = 3;
-}
diff --git a/packages/speech/protos/google/api/billing.proto b/packages/speech/protos/google/api/billing.proto
deleted file mode 100644
index 6ecffd5451e..00000000000
--- a/packages/speech/protos/google/api/billing.proto
+++ /dev/null
@@ -1,98 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/annotations.proto";
-import "google/api/metric.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "BillingProto";
-option java_package = "com.google.api";
-
-
-// Billing related configuration of the service.
-//
-// The following example shows how to configure metrics for billing:
-//
-// metrics:
-// - name: library.googleapis.com/read_calls
-// metric_kind: DELTA
-// value_type: INT64
-// - name: library.googleapis.com/write_calls
-// metric_kind: DELTA
-// value_type: INT64
-// billing:
-// metrics:
-// - library.googleapis.com/read_calls
-// - library.googleapis.com/write_calls
-//
-// The next example shows how to enable billing status check and customize the
-// check behavior. It makes sure billing status check is included in the `Check`
-// method of [Service Control API](https://cloud.google.com/service-control/).
-// In the example, "google.storage.Get" method can be served when the billing
-// status is either `current` or `delinquent`, while "google.storage.Write"
-// method can only be served when the billing status is `current`:
-//
-// billing:
-// rules:
-// - selector: google.storage.Get
-// allowed_statuses:
-// - current
-// - delinquent
-// - selector: google.storage.Write
-// allowed_statuses: current
-//
-// Mostly services should only allow `current` status when serving requests.
-// In addition, services can choose to allow both `current` and `delinquent`
-// statuses when serving read-only requests to resources. If there's no
-// matching selector for operation, no billing status check will be performed.
-//
-message Billing {
- // Names of the metrics to report to billing. Each name must
- // be defined in [Service.metrics][google.api.Service.metrics] section.
- repeated string metrics = 1;
-
- // A list of billing status rules for configuring billing status check.
- repeated BillingStatusRule rules = 5;
-}
-
-// Defines the billing status requirements for operations.
-//
-// When used with
-// [Service Control API](https://cloud.google.com/service-control/), the
-// following statuses are supported:
-//
-// - **current**: the associated billing account is up to date and capable of
-// paying for resource usages.
-// - **delinquent**: the associated billing account has a correctable problem,
-// such as late payment.
-//
-// Mostly services should only allow `current` status when serving requests.
-// In addition, services can choose to allow both `current` and `delinquent`
-// statuses when serving read-only requests to resources. If the list of
-// allowed_statuses is empty, it means no billing requirement.
-//
-message BillingStatusRule {
- // Selects the operation names to which this rule applies.
- // Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
- string selector = 1;
-
- // Allowed billing statuses. The billing status check passes if the actual
- // billing status matches any of the provided values here.
- repeated string allowed_statuses = 2;
-}
diff --git a/packages/speech/protos/google/api/config_change.proto b/packages/speech/protos/google/api/config_change.proto
deleted file mode 100644
index 3c416164ec5..00000000000
--- a/packages/speech/protos/google/api/config_change.proto
+++ /dev/null
@@ -1,85 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-option go_package = "google.golang.org/genproto/googleapis/api/configchange;configchange";
-option java_multiple_files = true;
-option java_outer_classname = "ConfigChangeProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Output generated from semantically comparing two versions of a service
-// configuration.
-//
-// Includes detailed information about a field that have changed with
-// applicable advice about potential consequences for the change, such as
-// backwards-incompatibility.
-message ConfigChange {
- // Object hierarchy path to the change, with levels separated by a '.'
- // character. For repeated fields, an applicable unique identifier field is
- // used for the index (usually selector, name, or id). For maps, the term
- // 'key' is used. If the field has no unique identifier, the numeric index
- // is used.
- // Examples:
- // - visibility.rules[selector=="google.LibraryService.CreateBook"].restriction
- // - quota.metric_rules[selector=="google"].metric_costs[key=="reads"].value
- // - logging.producer_destinations[0]
- string element = 1;
-
- // Value of the changed object in the old Service configuration,
- // in JSON format. This field will not be populated if ChangeType == ADDED.
- string old_value = 2;
-
- // Value of the changed object in the new Service configuration,
- // in JSON format. This field will not be populated if ChangeType == REMOVED.
- string new_value = 3;
-
- // The type for this change, either ADDED, REMOVED, or MODIFIED.
- ChangeType change_type = 4;
-
- // Collection of advice provided for this change, useful for determining the
- // possible impact of this change.
- repeated Advice advices = 5;
-}
-
-// Generated advice about this change, used for providing more
-// information about how a change will affect the existing service.
-message Advice {
- // Useful description for why this advice was applied and what actions should
- // be taken to mitigate any implied risks.
- string description = 2;
-}
-
-// Classifies set of possible modifications to an object in the service
-// configuration.
-enum ChangeType {
- // No value was provided.
- CHANGE_TYPE_UNSPECIFIED = 0;
-
- // The changed object exists in the 'new' service configuration, but not
- // in the 'old' service configuration.
- ADDED = 1;
-
- // The changed object exists in the 'old' service configuration, but not
- // in the 'new' service configuration.
- REMOVED = 2;
-
- // The changed object exists in both service configurations, but its value
- // is different.
- MODIFIED = 3;
-}
diff --git a/packages/speech/protos/google/api/consumer.proto b/packages/speech/protos/google/api/consumer.proto
deleted file mode 100644
index 4e963168efc..00000000000
--- a/packages/speech/protos/google/api/consumer.proto
+++ /dev/null
@@ -1,83 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "ConsumerProto";
-option java_package = "com.google.api";
-
-
-// A descriptor for defining project properties for a service. One service may
-// have many consumer projects, and the service may want to behave differently
-// depending on some properties on the project. For example, a project may be
-// associated with a school, or a business, or a government agency, a business
-// type property on the project may affect how a service responds to the client.
-// This descriptor defines which properties are allowed to be set on a project.
-//
-// Example:
-//
-// project_properties:
-// properties:
-// - name: NO_WATERMARK
-// type: BOOL
-// description: Allows usage of the API without watermarks.
-// - name: EXTENDED_TILE_CACHE_PERIOD
-// type: INT64
-message ProjectProperties {
- // List of per consumer project-specific properties.
- repeated Property properties = 1;
-}
-
-// Defines project properties.
-//
-// API services can define properties that can be assigned to consumer projects
-// so that backends can perform response customization without having to make
-// additional calls or maintain additional storage. For example, Maps API
-// defines properties that controls map tile cache period, or whether to embed a
-// watermark in a result.
-//
-// These values can be set via API producer console. Only API providers can
-// define and set these properties.
-message Property {
- // Supported data type of the property values
- enum PropertyType {
- // The type is unspecified, and will result in an error.
- UNSPECIFIED = 0;
-
- // The type is `int64`.
- INT64 = 1;
-
- // The type is `bool`.
- BOOL = 2;
-
- // The type is `string`.
- STRING = 3;
-
- // The type is 'double'.
- DOUBLE = 4;
- }
-
- // The name of the property (a.k.a key).
- string name = 1;
-
- // The type of this property.
- PropertyType type = 2;
-
- // The description of the property
- string description = 3;
-}
diff --git a/packages/speech/protos/google/api/context.proto b/packages/speech/protos/google/api/context.proto
deleted file mode 100644
index fd03fcae916..00000000000
--- a/packages/speech/protos/google/api/context.proto
+++ /dev/null
@@ -1,63 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "ContextProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// `Context` defines which contexts an API requests.
-//
-// Example:
-//
-// context:
-// rules:
-// - selector: "*"
-// requested:
-// - google.rpc.context.ProjectContext
-// - google.rpc.context.OriginContext
-//
-// The above specifies that all methods in the API request
-// `google.rpc.context.ProjectContext` and
-// `google.rpc.context.OriginContext`.
-//
-// Available context types are defined in package
-// `google.rpc.context`.
-message Context {
- // A list of RPC context rules that apply to individual API methods.
- //
- // **NOTE:** All service configuration rules follow "last one wins" order.
- repeated ContextRule rules = 1;
-}
-
-// A context rule provides information about the context for an individual API
-// element.
-message ContextRule {
- // Selects the methods to which this rule applies.
- //
- // Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
- string selector = 1;
-
- // A list of full type names of requested contexts.
- repeated string requested = 2;
-
- // A list of full type names of provided contexts.
- repeated string provided = 3;
-}
diff --git a/packages/speech/protos/google/api/control.proto b/packages/speech/protos/google/api/control.proto
deleted file mode 100644
index acad56cbdde..00000000000
--- a/packages/speech/protos/google/api/control.proto
+++ /dev/null
@@ -1,33 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "ControlProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Selects and configures the service controller used by the service. The
-// service controller handles features like abuse, quota, billing, logging,
-// monitoring, etc.
-message Control {
- // The service control environment to use. If empty, no control plane
- // feature (like quota and billing) will be enabled.
- string environment = 1;
-}
diff --git a/packages/speech/protos/google/api/distribution.proto b/packages/speech/protos/google/api/distribution.proto
deleted file mode 100644
index 2861e9b6f3a..00000000000
--- a/packages/speech/protos/google/api/distribution.proto
+++ /dev/null
@@ -1,185 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/annotations.proto";
-import "google/protobuf/any.proto";
-import "google/protobuf/timestamp.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/distribution;distribution";
-option java_multiple_files = true;
-option java_outer_classname = "DistributionProto";
-option java_package = "com.google.api";
-
-
-// Distribution contains summary statistics for a population of values and,
-// optionally, a histogram representing the distribution of those values across
-// a specified set of histogram buckets.
-//
-// The summary statistics are the count, mean, sum of the squared deviation from
-// the mean, the minimum, and the maximum of the set of population of values.
-//
-// The histogram is based on a sequence of buckets and gives a count of values
-// that fall into each bucket. The boundaries of the buckets are given either
-// explicitly or by specifying parameters for a method of computing them
-// (buckets of fixed width or buckets of exponentially increasing width).
-//
-// Although it is not forbidden, it is generally a bad idea to include
-// non-finite values (infinities or NaNs) in the population of values, as this
-// will render the `mean` and `sum_of_squared_deviation` fields meaningless.
-message Distribution {
- // The range of the population values.
- message Range {
- // The minimum of the population values.
- double min = 1;
-
- // The maximum of the population values.
- double max = 2;
- }
-
- // A Distribution may optionally contain a histogram of the values in the
- // population. The histogram is given in `bucket_counts` as counts of values
- // that fall into one of a sequence of non-overlapping buckets. The sequence
- // of buckets is described by `bucket_options`.
- //
- // A bucket specifies an inclusive lower bound and exclusive upper bound for
- // the values that are counted for that bucket. The upper bound of a bucket
- // is strictly greater than the lower bound.
- //
- // The sequence of N buckets for a Distribution consists of an underflow
- // bucket (number 0), zero or more finite buckets (number 1 through N - 2) and
- // an overflow bucket (number N - 1). The buckets are contiguous: the lower
- // bound of bucket i (i > 0) is the same as the upper bound of bucket i - 1.
- // The buckets span the whole range of finite values: lower bound of the
- // underflow bucket is -infinity and the upper bound of the overflow bucket is
- // +infinity. The finite buckets are so-called because both bounds are
- // finite.
- //
- // `BucketOptions` describes bucket boundaries in one of three ways. Two
- // describe the boundaries by giving parameters for a formula to generate
- // boundaries and one gives the bucket boundaries explicitly.
- //
- // If `bucket_boundaries` is not given, then no `bucket_counts` may be given.
- message BucketOptions {
- // Specify a sequence of buckets that all have the same width (except
- // overflow and underflow). Each bucket represents a constant absolute
- // uncertainty on the specific value in the bucket.
- //
- // Defines `num_finite_buckets + 2` (= N) buckets with these boundaries for
- // bucket `i`:
- //
- // Upper bound (0 <= i < N-1): offset + (width * i).
- // Lower bound (1 <= i < N): offset + (width * (i - 1)).
- message Linear {
- // Must be greater than 0.
- int32 num_finite_buckets = 1;
-
- // Must be greater than 0.
- double width = 2;
-
- // Lower bound of the first bucket.
- double offset = 3;
- }
-
- // Specify a sequence of buckets that have a width that is proportional to
- // the value of the lower bound. Each bucket represents a constant relative
- // uncertainty on a specific value in the bucket.
- //
- // Defines `num_finite_buckets + 2` (= N) buckets with these boundaries for
- // bucket i:
- //
- // Upper bound (0 <= i < N-1): scale * (growth_factor ^ i).
- // Lower bound (1 <= i < N): scale * (growth_factor ^ (i - 1)).
- message Exponential {
- // Must be greater than 0.
- int32 num_finite_buckets = 1;
-
- // Must be greater than 1.
- double growth_factor = 2;
-
- // Must be greater than 0.
- double scale = 3;
- }
-
- // A set of buckets with arbitrary widths.
- //
- // Defines `size(bounds) + 1` (= N) buckets with these boundaries for
- // bucket i:
- //
- // Upper bound (0 <= i < N-1): bounds[i]
- // Lower bound (1 <= i < N); bounds[i - 1]
- //
- // There must be at least one element in `bounds`. If `bounds` has only one
- // element, there are no finite buckets, and that single element is the
- // common boundary of the overflow and underflow buckets.
- message Explicit {
- // The values must be monotonically increasing.
- repeated double bounds = 1;
- }
-
- // Exactly one of these three fields must be set.
- oneof options {
- // The linear bucket.
- Linear linear_buckets = 1;
-
- // The exponential buckets.
- Exponential exponential_buckets = 2;
-
- // The explicit buckets.
- Explicit explicit_buckets = 3;
- }
- }
-
- // The number of values in the population. Must be non-negative.
- int64 count = 1;
-
- // The arithmetic mean of the values in the population. If `count` is zero
- // then this field must be zero.
- double mean = 2;
-
- // The sum of squared deviations from the mean of the values in the
- // population. For values x_i this is:
- //
- // Sum[i=1..n]((x_i - mean)^2)
- //
- // Knuth, "The Art of Computer Programming", Vol. 2, page 323, 3rd edition
- // describes Welford's method for accumulating this sum in one pass.
- //
- // If `count` is zero then this field must be zero.
- double sum_of_squared_deviation = 3;
-
- // If specified, contains the range of the population values. The field
- // must not be present if the `count` is zero.
- Range range = 4;
-
- // Defines the histogram bucket boundaries.
- BucketOptions bucket_options = 6;
-
- // If `bucket_options` is given, then the sum of the values in `bucket_counts`
- // must equal the value in `count`. If `bucket_options` is not given, no
- // `bucket_counts` fields may be given.
- //
- // Bucket counts are given in order under the numbering scheme described
- // above (the underflow bucket has number 0; the finite buckets, if any,
- // have numbers 1 through N-2; the overflow bucket has number N-1).
- //
- // The size of `bucket_counts` must be no greater than N as defined in
- // `bucket_options`.
- //
- // Any suffix of trailing zero bucket_count fields may be omitted.
- repeated int64 bucket_counts = 7;
-}
diff --git a/packages/speech/protos/google/api/documentation.proto b/packages/speech/protos/google/api/documentation.proto
deleted file mode 100644
index 0b85eca51e5..00000000000
--- a/packages/speech/protos/google/api/documentation.proto
+++ /dev/null
@@ -1,159 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "DocumentationProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// `Documentation` provides the information for describing a service.
-//
-// Example:
-//
documentation:
-// summary: >
-// The Google Calendar API gives access
-// to most calendar features.
-// pages:
-// - name: Overview
-// content: (== include google/foo/overview.md ==)
-// - name: Tutorial
-// content: (== include google/foo/tutorial.md ==)
-// subpages;
-// - name: Java
-// content: (== include google/foo/tutorial_java.md ==)
-// rules:
-// - selector: google.calendar.Calendar.Get
-// description: >
-// ...
-// - selector: google.calendar.Calendar.Put
-// description: >
-// ...
-//
-// Documentation is provided in markdown syntax. In addition to
-// standard markdown features, definition lists, tables and fenced
-// code blocks are supported. Section headers can be provided and are
-// interpreted relative to the section nesting of the context where
-// a documentation fragment is embedded.
-//
-// Documentation from the IDL is merged with documentation defined
-// via the config at normalization time, where documentation provided
-// by config rules overrides IDL provided.
-//
-// A number of constructs specific to the API platform are supported
-// in documentation text.
-//
-// In order to reference a proto element, the following
-// notation can be used:
-// [fully.qualified.proto.name][]
-// To override the display text used for the link, this can be used:
-// [display text][fully.qualified.proto.name]
-// Text can be excluded from doc using the following notation:
-// (-- internal comment --)
-// Comments can be made conditional using a visibility label. The below
-// text will be only rendered if the `BETA` label is available:
-// (--BETA: comment for BETA users --)
-// A few directives are available in documentation. Note that
-// directives must appear on a single line to be properly
-// identified. The `include` directive includes a markdown file from
-// an external source:
-// (== include path/to/file ==)
-// The `resource_for` directive marks a message to be the resource of
-// a collection in REST view. If it is not specified, tools attempt
-// to infer the resource from the operations in a collection:
-// (== resource_for v1.shelves.books ==)
-// The directive `suppress_warning` does not directly affect documentation
-// and is documented together with service config validation.
-message Documentation {
- // A short summary of what the service does. Can only be provided by
- // plain text.
- string summary = 1;
-
- // The top level pages for the documentation set.
- repeated Page pages = 5;
-
- // A list of documentation rules that apply to individual API elements.
- //
- // **NOTE:** All service configuration rules follow "last one wins" order.
- repeated DocumentationRule rules = 3;
-
- // The URL to the root of documentation.
- string documentation_root_url = 4;
-
- // Declares a single overview page. For example:
- // documentation:
- // summary: ...
- // overview: (== include overview.md ==)
- //
- // This is a shortcut for the following declaration (using pages style):
- // documentation:
- // summary: ...
- // pages:
- // - name: Overview
- // content: (== include overview.md ==)
- //
- // Note: you cannot specify both `overview` field and `pages` field.
- string overview = 2;
-}
-
-// A documentation rule provides information about individual API elements.
-message DocumentationRule {
- // The selector is a comma-separated list of patterns. Each pattern is a
- // qualified name of the element which may end in "*", indicating a wildcard.
- // Wildcards are only allowed at the end and for a whole component of the
- // qualified name, i.e. "foo.*" is ok, but not "foo.b*" or "foo.*.bar". To
- // specify a default for all applicable elements, the whole pattern "*"
- // is used.
- string selector = 1;
-
- // Description of the selected API(s).
- string description = 2;
-
- // Deprecation description of the selected element(s). It can be provided if an
- // element is marked as `deprecated`.
- string deprecation_description = 3;
-}
-
-// Represents a documentation page. A page can contain subpages to represent
-// nested documentation set structure.
-message Page {
- // The name of the page. It will be used as an identity of the page to
- // generate URI of the page, text of the link to this page in navigation,
- // etc. The full page name (start from the root page name to this page
- // concatenated with `.`) can be used as reference to the page in your
- // documentation. For example:
- // pages:
- // - name: Tutorial
- // content: (== include tutorial.md ==)
- // subpages:
- // - name: Java
- // content: (== include tutorial_java.md ==)
- //
- // You can reference `Java` page using Markdown reference link syntax:
- // `[Java][Tutorial.Java]`.
- string name = 1;
-
- // The Markdown content of the page. You can use (== include {path} ==)
- // to include content from a Markdown file.
- string content = 2;
-
- // Subpages of this page. The order of subpages specified here will be
- // honored in the generated docset.
- repeated Page subpages = 3;
-}
diff --git a/packages/speech/protos/google/api/endpoint.proto b/packages/speech/protos/google/api/endpoint.proto
deleted file mode 100644
index 68655b26a08..00000000000
--- a/packages/speech/protos/google/api/endpoint.proto
+++ /dev/null
@@ -1,74 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/annotations.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "EndpointProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// `Endpoint` describes a network endpoint that serves a set of APIs.
-// A service may expose any number of endpoints, and all endpoints share the
-// same service configuration, such as quota configuration and monitoring
-// configuration.
-//
-// Example service configuration:
-//
-// name: library-example.googleapis.com
-// endpoints:
-// # Below entry makes 'google.example.library.v1.Library'
-// # API be served from endpoint address library-example.googleapis.com.
-// # It also allows HTTP OPTIONS calls to be passed to the backend, for
-// # it to decide whether the subsequent cross-origin request is
-// # allowed to proceed.
-// - name: library-example.googleapis.com
-// allow_cors: true
-message Endpoint {
- // The canonical name of this endpoint.
- string name = 1;
-
- // DEPRECATED: This field is no longer supported. Instead of using aliases,
- // please specify multiple [google.api.Endpoint][google.api.Endpoint] for each of the intented
- // alias.
- //
- // Additional names that this endpoint will be hosted on.
- repeated string aliases = 2;
-
- // The list of APIs served by this endpoint.
- repeated string apis = 3;
-
- // The list of features enabled on this endpoint.
- repeated string features = 4;
-
- // The specification of an Internet routable address of API frontend that will
- // handle requests to this [API Endpoint](https://cloud.google.com/apis/design/glossary).
- // It should be either a valid IPv4 address or a fully-qualified domain name.
- // For example, "8.8.8.8" or "myservice.appspot.com".
- string target = 101;
-
- // Allowing
- // [CORS](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing), aka
- // cross-domain traffic, would allow the backends served from this endpoint to
- // receive and respond to HTTP OPTIONS requests. The response will be used by
- // the browser to determine whether the subsequent cross-origin request is
- // allowed to proceed.
- bool allow_cors = 5;
-}
diff --git a/packages/speech/protos/google/api/experimental/authorization_config.proto b/packages/speech/protos/google/api/experimental/authorization_config.proto
deleted file mode 100644
index 5c213c62531..00000000000
--- a/packages/speech/protos/google/api/experimental/authorization_config.proto
+++ /dev/null
@@ -1,40 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-option go_package = "google.golang.org/genproto/googleapis/api;api";
-option java_multiple_files = true;
-option java_outer_classname = "AuthorizationConfigProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Configuration of authorization.
-//
-// This section determines the authorization provider, if unspecified, then no
-// authorization check will be done.
-//
-// Example:
-//
-// experimental:
-// authorization:
-// provider: firebaserules.googleapis.com
-message AuthorizationConfig {
- // The name of the authorization provider, such as
- // firebaserules.googleapis.com.
- string provider = 1;
-}
diff --git a/packages/speech/protos/google/api/experimental/experimental.proto b/packages/speech/protos/google/api/experimental/experimental.proto
deleted file mode 100644
index b98097df54a..00000000000
--- a/packages/speech/protos/google/api/experimental/experimental.proto
+++ /dev/null
@@ -1,34 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/annotations.proto";
-import "google/api/experimental/authorization_config.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api;api";
-option java_multiple_files = true;
-option java_outer_classname = "ExperimentalProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Experimental service configuration. These configuration options can
-// only be used by whitelisted users.
-message Experimental {
- // Authorization configuration.
- AuthorizationConfig authorization = 8;
-}
diff --git a/packages/speech/protos/google/api/http.proto b/packages/speech/protos/google/api/http.proto
deleted file mode 100644
index 5f8538a0164..00000000000
--- a/packages/speech/protos/google/api/http.proto
+++ /dev/null
@@ -1,291 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-option cc_enable_arenas = true;
-option go_package = "google.golang.org/genproto/googleapis/api/annotations;annotations";
-option java_multiple_files = true;
-option java_outer_classname = "HttpProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Defines the HTTP configuration for a service. It contains a list of
-// [HttpRule][google.api.HttpRule], each specifying the mapping of an RPC method
-// to one or more HTTP REST API methods.
-message Http {
- // A list of HTTP configuration rules that apply to individual API methods.
- //
- // **NOTE:** All service configuration rules follow "last one wins" order.
- repeated HttpRule rules = 1;
-}
-
-// `HttpRule` defines the mapping of an RPC method to one or more HTTP
-// REST APIs. The mapping determines what portions of the request
-// message are populated from the path, query parameters, or body of
-// the HTTP request. The mapping is typically specified as an
-// `google.api.http` annotation, see "google/api/annotations.proto"
-// for details.
-//
-// The mapping consists of a field specifying the path template and
-// method kind. The path template can refer to fields in the request
-// message, as in the example below which describes a REST GET
-// operation on a resource collection of messages:
-//
-//
-// service Messaging {
-// rpc GetMessage(GetMessageRequest) returns (Message) {
-// option (google.api.http).get = "/v1/messages/{message_id}/{sub.subfield}";
-// }
-// }
-// message GetMessageRequest {
-// message SubMessage {
-// string subfield = 1;
-// }
-// string message_id = 1; // mapped to the URL
-// SubMessage sub = 2; // `sub.subfield` is url-mapped
-// }
-// message Message {
-// string text = 1; // content of the resource
-// }
-//
-// The same http annotation can alternatively be expressed inside the
-// `GRPC API Configuration` YAML file.
-//
-// http:
-// rules:
-// - selector: .Messaging.GetMessage
-// get: /v1/messages/{message_id}/{sub.subfield}
-//
-// This definition enables an automatic, bidrectional mapping of HTTP
-// JSON to RPC. Example:
-//
-// HTTP | RPC
-// -----|-----
-// `GET /v1/messages/123456/foo` | `GetMessage(message_id: "123456" sub: SubMessage(subfield: "foo"))`
-//
-// In general, not only fields but also field paths can be referenced
-// from a path pattern. Fields mapped to the path pattern cannot be
-// repeated and must have a primitive (non-message) type.
-//
-// Any fields in the request message which are not bound by the path
-// pattern automatically become (optional) HTTP query
-// parameters. Assume the following definition of the request message:
-//
-//
-// message GetMessageRequest {
-// message SubMessage {
-// string subfield = 1;
-// }
-// string message_id = 1; // mapped to the URL
-// int64 revision = 2; // becomes a parameter
-// SubMessage sub = 3; // `sub.subfield` becomes a parameter
-// }
-//
-//
-// This enables a HTTP JSON to RPC mapping as below:
-//
-// HTTP | RPC
-// -----|-----
-// `GET /v1/messages/123456?revision=2&sub.subfield=foo` | `GetMessage(message_id: "123456" revision: 2 sub: SubMessage(subfield: "foo"))`
-//
-// Note that fields which are mapped to HTTP parameters must have a
-// primitive type or a repeated primitive type. Message types are not
-// allowed. In the case of a repeated type, the parameter can be
-// repeated in the URL, as in `...?param=A¶m=B`.
-//
-// For HTTP method kinds which allow a request body, the `body` field
-// specifies the mapping. Consider a REST update method on the
-// message resource collection:
-//
-//
-// service Messaging {
-// rpc UpdateMessage(UpdateMessageRequest) returns (Message) {
-// option (google.api.http) = {
-// put: "/v1/messages/{message_id}"
-// body: "message"
-// };
-// }
-// }
-// message UpdateMessageRequest {
-// string message_id = 1; // mapped to the URL
-// Message message = 2; // mapped to the body
-// }
-//
-//
-// The following HTTP JSON to RPC mapping is enabled, where the
-// representation of the JSON in the request body is determined by
-// protos JSON encoding:
-//
-// HTTP | RPC
-// -----|-----
-// `PUT /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id: "123456" message { text: "Hi!" })`
-//
-// The special name `*` can be used in the body mapping to define that
-// every field not bound by the path template should be mapped to the
-// request body. This enables the following alternative definition of
-// the update method:
-//
-// service Messaging {
-// rpc UpdateMessage(Message) returns (Message) {
-// option (google.api.http) = {
-// put: "/v1/messages/{message_id}"
-// body: "*"
-// };
-// }
-// }
-// message Message {
-// string message_id = 1;
-// string text = 2;
-// }
-//
-//
-// The following HTTP JSON to RPC mapping is enabled:
-//
-// HTTP | RPC
-// -----|-----
-// `PUT /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id: "123456" text: "Hi!")`
-//
-// Note that when using `*` in the body mapping, it is not possible to
-// have HTTP parameters, as all fields not bound by the path end in
-// the body. This makes this option more rarely used in practice of
-// defining REST APIs. The common usage of `*` is in custom methods
-// which don't use the URL at all for transferring data.
-//
-// It is possible to define multiple HTTP methods for one RPC by using
-// the `additional_bindings` option. Example:
-//
-// service Messaging {
-// rpc GetMessage(GetMessageRequest) returns (Message) {
-// option (google.api.http) = {
-// get: "/v1/messages/{message_id}"
-// additional_bindings {
-// get: "/v1/users/{user_id}/messages/{message_id}"
-// }
-// };
-// }
-// }
-// message GetMessageRequest {
-// string message_id = 1;
-// string user_id = 2;
-// }
-//
-//
-// This enables the following two alternative HTTP JSON to RPC
-// mappings:
-//
-// HTTP | RPC
-// -----|-----
-// `GET /v1/messages/123456` | `GetMessage(message_id: "123456")`
-// `GET /v1/users/me/messages/123456` | `GetMessage(user_id: "me" message_id: "123456")`
-//
-// # Rules for HTTP mapping
-//
-// The rules for mapping HTTP path, query parameters, and body fields
-// to the request message are as follows:
-//
-// 1. The `body` field specifies either `*` or a field path, or is
-// omitted. If omitted, it assumes there is no HTTP body.
-// 2. Leaf fields (recursive expansion of nested messages in the
-// request) can be classified into three types:
-// (a) Matched in the URL template.
-// (b) Covered by body (if body is `*`, everything except (a) fields;
-// else everything under the body field)
-// (c) All other fields.
-// 3. URL query parameters found in the HTTP request are mapped to (c) fields.
-// 4. Any body sent with an HTTP request can contain only (b) fields.
-//
-// The syntax of the path template is as follows:
-//
-// Template = "/" Segments [ Verb ] ;
-// Segments = Segment { "/" Segment } ;
-// Segment = "*" | "**" | LITERAL | Variable ;
-// Variable = "{" FieldPath [ "=" Segments ] "}" ;
-// FieldPath = IDENT { "." IDENT } ;
-// Verb = ":" LITERAL ;
-//
-// The syntax `*` matches a single path segment. It follows the semantics of
-// [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String
-// Expansion.
-//
-// The syntax `**` matches zero or more path segments. It follows the semantics
-// of [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.3 Reserved
-// Expansion. NOTE: it must be the last segment in the path except the Verb.
-//
-// The syntax `LITERAL` matches literal text in the URL path.
-//
-// The syntax `Variable` matches the entire path as specified by its template;
-// this nested template must not contain further variables. If a variable
-// matches a single path segment, its template may be omitted, e.g. `{var}`
-// is equivalent to `{var=*}`.
-//
-// NOTE: the field paths in variables and in the `body` must not refer to
-// repeated fields or map fields.
-//
-// Use CustomHttpPattern to specify any HTTP method that is not included in the
-// `pattern` field, such as HEAD, or "*" to leave the HTTP method unspecified for
-// a given URL path rule. The wild-card rule is useful for services that provide
-// content to Web (HTML) clients.
-message HttpRule {
- // Selects methods to which this rule applies.
- //
- // Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
- string selector = 1;
-
- // Determines the URL pattern is matched by this rules. This pattern can be
- // used with any of the {get|put|post|delete|patch} methods. A custom method
- // can be defined using the 'custom' field.
- oneof pattern {
- // Used for listing and getting information about resources.
- string get = 2;
-
- // Used for updating a resource.
- string put = 3;
-
- // Used for creating a resource.
- string post = 4;
-
- // Used for deleting a resource.
- string delete = 5;
-
- // Used for updating a resource.
- string patch = 6;
-
- // Custom pattern is used for defining custom verbs.
- CustomHttpPattern custom = 8;
- }
-
- // The name of the request field whose value is mapped to the HTTP body, or
- // `*` for mapping all fields not captured by the path pattern to the HTTP
- // body. NOTE: the referred field must not be a repeated field and must be
- // present at the top-level of request message type.
- string body = 7;
-
- // Additional HTTP bindings for the selector. Nested bindings must
- // not contain an `additional_bindings` field themselves (that is,
- // the nesting may only be one level deep).
- repeated HttpRule additional_bindings = 11;
-}
-
-// A custom pattern is used for defining custom HTTP verb.
-message CustomHttpPattern {
- // The name of this custom HTTP verb.
- string kind = 1;
-
- // The path matched by this custom verb.
- string path = 2;
-}
diff --git a/packages/speech/protos/google/api/httpbody.proto b/packages/speech/protos/google/api/httpbody.proto
deleted file mode 100644
index f5176634b0b..00000000000
--- a/packages/speech/protos/google/api/httpbody.proto
+++ /dev/null
@@ -1,70 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-option go_package = "google.golang.org/genproto/googleapis/api/httpbody;httpbody";
-option java_multiple_files = true;
-option java_outer_classname = "HttpBodyProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Message that represents an arbitrary HTTP body. It should only be used for
-// payload formats that can't be represented as JSON, such as raw binary or
-// an HTML page.
-//
-//
-// This message can be used both in streaming and non-streaming API methods in
-// the request as well as the response.
-//
-// It can be used as a top-level request field, which is convenient if one
-// wants to extract parameters from either the URL or HTTP template into the
-// request fields and also want access to the raw HTTP body.
-//
-// Example:
-//
-// message GetResourceRequest {
-// // A unique request id.
-// string request_id = 1;
-//
-// // The raw HTTP body is bound to this field.
-// google.api.HttpBody http_body = 2;
-// }
-//
-// service ResourceService {
-// rpc GetResource(GetResourceRequest) returns (google.api.HttpBody);
-// rpc UpdateResource(google.api.HttpBody) returns (google.protobuf.Empty);
-// }
-//
-// Example with streaming methods:
-//
-// service CaldavService {
-// rpc GetCalendar(stream google.api.HttpBody)
-// returns (stream google.api.HttpBody);
-// rpc UpdateCalendar(stream google.api.HttpBody)
-// returns (stream google.api.HttpBody);
-// }
-//
-// Use of this type only changes how the request and response bodies are
-// handled, all other features will continue to work unchanged.
-message HttpBody {
- // The HTTP Content-Type string representing the content type of the body.
- string content_type = 1;
-
- // HTTP body binary data.
- bytes data = 2;
-}
diff --git a/packages/speech/protos/google/api/label.proto b/packages/speech/protos/google/api/label.proto
deleted file mode 100644
index ec2c14f0c35..00000000000
--- a/packages/speech/protos/google/api/label.proto
+++ /dev/null
@@ -1,49 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-option cc_enable_arenas = true;
-option go_package = "google.golang.org/genproto/googleapis/api/label;label";
-option java_multiple_files = true;
-option java_outer_classname = "LabelProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// A description of a label.
-message LabelDescriptor {
- // Value types that can be used as label values.
- enum ValueType {
- // A variable-length string. This is the default.
- STRING = 0;
-
- // Boolean; true or false.
- BOOL = 1;
-
- // A 64-bit signed integer.
- INT64 = 2;
- }
-
- // The label key.
- string key = 1;
-
- // The type of data that can be assigned to the label.
- ValueType value_type = 2;
-
- // A human-readable description for the label.
- string description = 3;
-}
diff --git a/packages/speech/protos/google/api/log.proto b/packages/speech/protos/google/api/log.proto
deleted file mode 100644
index d64f2439581..00000000000
--- a/packages/speech/protos/google/api/log.proto
+++ /dev/null
@@ -1,55 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/label.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "LogProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// A description of a log type. Example in YAML format:
-//
-// - name: library.googleapis.com/activity_history
-// description: The history of borrowing and returning library items.
-// display_name: Activity
-// labels:
-// - key: /customer_id
-// description: Identifier of a library customer
-message LogDescriptor {
- // The name of the log. It must be less than 512 characters long and can
- // include the following characters: upper- and lower-case alphanumeric
- // characters [A-Za-z0-9], and punctuation characters including
- // slash, underscore, hyphen, period [/_-.].
- string name = 1;
-
- // The set of labels that are available to describe a specific log entry.
- // Runtime requests that contain labels not specified here are
- // considered invalid.
- repeated LabelDescriptor labels = 2;
-
- // A human-readable description of this log. This information appears in
- // the documentation and can contain details.
- string description = 3;
-
- // The human-readable name for this log. This information appears on
- // the user interface and should be concise.
- string display_name = 4;
-}
diff --git a/packages/speech/protos/google/api/logging.proto b/packages/speech/protos/google/api/logging.proto
deleted file mode 100644
index 15c8a996e97..00000000000
--- a/packages/speech/protos/google/api/logging.proto
+++ /dev/null
@@ -1,83 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/annotations.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "LoggingProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Logging configuration of the service.
-//
-// The following example shows how to configure logs to be sent to the
-// producer and consumer projects. In the example, the `activity_history`
-// log is sent to both the producer and consumer projects, whereas the
-// `purchase_history` log is only sent to the producer project.
-//
-// monitored_resources:
-// - type: library.googleapis.com/branch
-// labels:
-// - key: /city
-// description: The city where the library branch is located in.
-// - key: /name
-// description: The name of the branch.
-// logs:
-// - name: activity_history
-// labels:
-// - key: /customer_id
-// - name: purchase_history
-// logging:
-// producer_destinations:
-// - monitored_resource: library.googleapis.com/branch
-// logs:
-// - activity_history
-// - purchase_history
-// consumer_destinations:
-// - monitored_resource: library.googleapis.com/branch
-// logs:
-// - activity_history
-message Logging {
- // Configuration of a specific logging destination (the producer project
- // or the consumer project).
- message LoggingDestination {
- // The monitored resource type. The type must be defined in the
- // [Service.monitored_resources][google.api.Service.monitored_resources] section.
- string monitored_resource = 3;
-
- // Names of the logs to be sent to this destination. Each name must
- // be defined in the [Service.logs][google.api.Service.logs] section. If the log name is
- // not a domain scoped name, it will be automatically prefixed with
- // the service name followed by "/".
- repeated string logs = 1;
- }
-
- // Logging configurations for sending logs to the producer project.
- // There can be multiple producer destinations, each one must have a
- // different monitored resource type. A log can be used in at most
- // one producer destination.
- repeated LoggingDestination producer_destinations = 1;
-
- // Logging configurations for sending logs to the consumer project.
- // There can be multiple consumer destinations, each one must have a
- // different monitored resource type. A log can be used in at most
- // one consumer destination.
- repeated LoggingDestination consumer_destinations = 2;
-}
diff --git a/packages/speech/protos/google/api/metric.proto b/packages/speech/protos/google/api/metric.proto
deleted file mode 100644
index 17b7263a334..00000000000
--- a/packages/speech/protos/google/api/metric.proto
+++ /dev/null
@@ -1,196 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/label.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/metric;metric";
-option java_multiple_files = true;
-option java_outer_classname = "MetricProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Defines a metric type and its schema. Once a metric descriptor is created,
-// deleting or altering it stops data collection and makes the metric type's
-// existing data unusable.
-message MetricDescriptor {
- // The kind of measurement. It describes how the data is reported.
- enum MetricKind {
- // Do not use this default value.
- METRIC_KIND_UNSPECIFIED = 0;
-
- // An instantaneous measurement of a value.
- GAUGE = 1;
-
- // The change in a value during a time interval.
- DELTA = 2;
-
- // A value accumulated over a time interval. Cumulative
- // measurements in a time series should have the same start time
- // and increasing end times, until an event resets the cumulative
- // value to zero and sets a new start time for the following
- // points.
- CUMULATIVE = 3;
- }
-
- // The value type of a metric.
- enum ValueType {
- // Do not use this default value.
- VALUE_TYPE_UNSPECIFIED = 0;
-
- // The value is a boolean.
- // This value type can be used only if the metric kind is `GAUGE`.
- BOOL = 1;
-
- // The value is a signed 64-bit integer.
- INT64 = 2;
-
- // The value is a double precision floating point number.
- DOUBLE = 3;
-
- // The value is a text string.
- // This value type can be used only if the metric kind is `GAUGE`.
- STRING = 4;
-
- // The value is a [`Distribution`][google.api.Distribution].
- DISTRIBUTION = 5;
-
- // The value is money.
- MONEY = 6;
- }
-
- // The resource name of the metric descriptor. Depending on the
- // implementation, the name typically includes: (1) the parent resource name
- // that defines the scope of the metric type or of its data; and (2) the
- // metric's URL-encoded type, which also appears in the `type` field of this
- // descriptor. For example, following is the resource name of a custom
- // metric within the GCP project `my-project-id`:
- //
- // "projects/my-project-id/metricDescriptors/custom.googleapis.com%2Finvoice%2Fpaid%2Famount"
- string name = 1;
-
- // The metric type, including its DNS name prefix. The type is not
- // URL-encoded. All user-defined custom metric types have the DNS name
- // `custom.googleapis.com`. Metric types should use a natural hierarchical
- // grouping. For example:
- //
- // "custom.googleapis.com/invoice/paid/amount"
- // "appengine.googleapis.com/http/server/response_latencies"
- string type = 8;
-
- // The set of labels that can be used to describe a specific
- // instance of this metric type. For example, the
- // `appengine.googleapis.com/http/server/response_latencies` metric
- // type has a label for the HTTP response code, `response_code`, so
- // you can look at latencies for successful responses or just
- // for responses that failed.
- repeated LabelDescriptor labels = 2;
-
- // Whether the metric records instantaneous values, changes to a value, etc.
- // Some combinations of `metric_kind` and `value_type` might not be supported.
- MetricKind metric_kind = 3;
-
- // Whether the measurement is an integer, a floating-point number, etc.
- // Some combinations of `metric_kind` and `value_type` might not be supported.
- ValueType value_type = 4;
-
- // The unit in which the metric value is reported. It is only applicable
- // if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The
- // supported units are a subset of [The Unified Code for Units of
- // Measure](http://unitsofmeasure.org/ucum.html) standard:
- //
- // **Basic units (UNIT)**
- //
- // * `bit` bit
- // * `By` byte
- // * `s` second
- // * `min` minute
- // * `h` hour
- // * `d` day
- //
- // **Prefixes (PREFIX)**
- //
- // * `k` kilo (10**3)
- // * `M` mega (10**6)
- // * `G` giga (10**9)
- // * `T` tera (10**12)
- // * `P` peta (10**15)
- // * `E` exa (10**18)
- // * `Z` zetta (10**21)
- // * `Y` yotta (10**24)
- // * `m` milli (10**-3)
- // * `u` micro (10**-6)
- // * `n` nano (10**-9)
- // * `p` pico (10**-12)
- // * `f` femto (10**-15)
- // * `a` atto (10**-18)
- // * `z` zepto (10**-21)
- // * `y` yocto (10**-24)
- // * `Ki` kibi (2**10)
- // * `Mi` mebi (2**20)
- // * `Gi` gibi (2**30)
- // * `Ti` tebi (2**40)
- //
- // **Grammar**
- //
- // The grammar includes the dimensionless unit `1`, such as `1/s`.
- //
- // The grammar also includes these connectors:
- //
- // * `/` division (as an infix operator, e.g. `1/s`).
- // * `.` multiplication (as an infix operator, e.g. `GBy.d`)
- //
- // The grammar for a unit is as follows:
- //
- // Expression = Component { "." Component } { "/" Component } ;
- //
- // Component = [ PREFIX ] UNIT [ Annotation ]
- // | Annotation
- // | "1"
- // ;
- //
- // Annotation = "{" NAME "}" ;
- //
- // Notes:
- //
- // * `Annotation` is just a comment if it follows a `UNIT` and is
- // equivalent to `1` if it is used alone. For examples,
- // `{requests}/s == 1/s`, `By{transmitted}/s == By/s`.
- // * `NAME` is a sequence of non-blank printable ASCII characters not
- // containing '{' or '}'.
- string unit = 5;
-
- // A detailed description of the metric, which can be used in documentation.
- string description = 6;
-
- // A concise name for the metric, which can be displayed in user interfaces.
- // Use sentence case without an ending period, for example "Request count".
- string display_name = 7;
-}
-
-// A specific metric, identified by specifying values for all of the
-// labels of a [`MetricDescriptor`][google.api.MetricDescriptor].
-message Metric {
- // An existing metric type, see [google.api.MetricDescriptor][google.api.MetricDescriptor].
- // For example, `custom.googleapis.com/invoice/paid/amount`.
- string type = 3;
-
- // The set of label values that uniquely identify this metric. All
- // labels listed in the `MetricDescriptor` must be assigned values.
- map labels = 2;
-}
diff --git a/packages/speech/protos/google/api/monitored_resource.proto b/packages/speech/protos/google/api/monitored_resource.proto
deleted file mode 100644
index 612ffa18da4..00000000000
--- a/packages/speech/protos/google/api/monitored_resource.proto
+++ /dev/null
@@ -1,91 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/label.proto";
-
-option cc_enable_arenas = true;
-option go_package = "google.golang.org/genproto/googleapis/api/monitoredres;monitoredres";
-option java_multiple_files = true;
-option java_outer_classname = "MonitoredResourceProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// An object that describes the schema of a [MonitoredResource][google.api.MonitoredResource] object using a
-// type name and a set of labels. For example, the monitored resource
-// descriptor for Google Compute Engine VM instances has a type of
-// `"gce_instance"` and specifies the use of the labels `"instance_id"` and
-// `"zone"` to identify particular VM instances.
-//
-// Different APIs can support different monitored resource types. APIs generally
-// provide a `list` method that returns the monitored resource descriptors used
-// by the API.
-message MonitoredResourceDescriptor {
- // Optional. The resource name of the monitored resource descriptor:
- // `"projects/{project_id}/monitoredResourceDescriptors/{type}"` where
- // {type} is the value of the `type` field in this object and
- // {project_id} is a project ID that provides API-specific context for
- // accessing the type. APIs that do not use project information can use the
- // resource name format `"monitoredResourceDescriptors/{type}"`.
- string name = 5;
-
- // Required. The monitored resource type. For example, the type
- // `"cloudsql_database"` represents databases in Google Cloud SQL.
- // The maximum length of this value is 256 characters.
- string type = 1;
-
- // Optional. A concise name for the monitored resource type that might be
- // displayed in user interfaces. It should be a Title Cased Noun Phrase,
- // without any article or other determiners. For example,
- // `"Google Cloud SQL Database"`.
- string display_name = 2;
-
- // Optional. A detailed description of the monitored resource type that might
- // be used in documentation.
- string description = 3;
-
- // Required. A set of labels used to describe instances of this monitored
- // resource type. For example, an individual Google Cloud SQL database is
- // identified by values for the labels `"database_id"` and `"zone"`.
- repeated LabelDescriptor labels = 4;
-}
-
-// An object representing a resource that can be used for monitoring, logging,
-// billing, or other purposes. Examples include virtual machine instances,
-// databases, and storage devices such as disks. The `type` field identifies a
-// [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor] object that describes the resource's
-// schema. Information in the `labels` field identifies the actual resource and
-// its attributes according to the schema. For example, a particular Compute
-// Engine VM instance could be represented by the following object, because the
-// [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor] for `"gce_instance"` has labels
-// `"instance_id"` and `"zone"`:
-//
-// { "type": "gce_instance",
-// "labels": { "instance_id": "12345678901234",
-// "zone": "us-central1-a" }}
-message MonitoredResource {
- // Required. The monitored resource type. This field must match
- // the `type` field of a [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor] object. For
- // example, the type of a Cloud SQL database is `"cloudsql_database"`.
- string type = 1;
-
- // Required. Values for all of the labels listed in the associated monitored
- // resource descriptor. For example, Cloud SQL databases use the labels
- // `"database_id"` and `"zone"`.
- map labels = 2;
-}
diff --git a/packages/speech/protos/google/api/monitoring.proto b/packages/speech/protos/google/api/monitoring.proto
deleted file mode 100644
index f49c85f85ee..00000000000
--- a/packages/speech/protos/google/api/monitoring.proto
+++ /dev/null
@@ -1,89 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/annotations.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "MonitoringProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Monitoring configuration of the service.
-//
-// The example below shows how to configure monitored resources and metrics
-// for monitoring. In the example, a monitored resource and two metrics are
-// defined. The `library.googleapis.com/book/returned_count` metric is sent
-// to both producer and consumer projects, whereas the
-// `library.googleapis.com/book/overdue_count` metric is only sent to the
-// consumer project.
-//
-// monitored_resources:
-// - type: library.googleapis.com/branch
-// labels:
-// - key: /city
-// description: The city where the library branch is located in.
-// - key: /name
-// description: The name of the branch.
-// metrics:
-// - name: library.googleapis.com/book/returned_count
-// metric_kind: DELTA
-// value_type: INT64
-// labels:
-// - key: /customer_id
-// - name: library.googleapis.com/book/overdue_count
-// metric_kind: GAUGE
-// value_type: INT64
-// labels:
-// - key: /customer_id
-// monitoring:
-// producer_destinations:
-// - monitored_resource: library.googleapis.com/branch
-// metrics:
-// - library.googleapis.com/book/returned_count
-// consumer_destinations:
-// - monitored_resource: library.googleapis.com/branch
-// metrics:
-// - library.googleapis.com/book/returned_count
-// - library.googleapis.com/book/overdue_count
-message Monitoring {
- // Configuration of a specific monitoring destination (the producer project
- // or the consumer project).
- message MonitoringDestination {
- // The monitored resource type. The type must be defined in
- // [Service.monitored_resources][google.api.Service.monitored_resources] section.
- string monitored_resource = 1;
-
- // Names of the metrics to report to this monitoring destination.
- // Each name must be defined in [Service.metrics][google.api.Service.metrics] section.
- repeated string metrics = 2;
- }
-
- // Monitoring configurations for sending metrics to the producer project.
- // There can be multiple producer destinations, each one must have a
- // different monitored resource type. A metric can be used in at most
- // one producer destination.
- repeated MonitoringDestination producer_destinations = 1;
-
- // Monitoring configurations for sending metrics to the consumer project.
- // There can be multiple consumer destinations, each one must have a
- // different monitored resource type. A metric can be used in at most
- // one consumer destination.
- repeated MonitoringDestination consumer_destinations = 2;
-}
diff --git a/packages/speech/protos/google/api/quota.proto b/packages/speech/protos/google/api/quota.proto
deleted file mode 100644
index aa327a19694..00000000000
--- a/packages/speech/protos/google/api/quota.proto
+++ /dev/null
@@ -1,259 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/annotations.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "QuotaProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Quota configuration helps to achieve fairness and budgeting in service
-// usage.
-//
-// The quota configuration works this way:
-// - The service configuration defines a set of metrics.
-// - For API calls, the quota.metric_rules maps methods to metrics with
-// corresponding costs.
-// - The quota.limits defines limits on the metrics, which will be used for
-// quota checks at runtime.
-//
-// An example quota configuration in yaml format:
-//
-// quota:
-// limits:
-//
-// - name: apiWriteQpsPerProject
-// metric: library.googleapis.com/write_calls
-// unit: "1/min/{project}" # rate limit for consumer projects
-// values:
-// STANDARD: 10000
-//
-// # The metric rules bind all methods to the read_calls metric,
-// # except for the UpdateBook and DeleteBook methods. These two methods
-// # are mapped to the write_calls metric, with the UpdateBook method
-// # consuming at twice rate as the DeleteBook method.
-// metric_rules:
-// - selector: "*"
-// metric_costs:
-// library.googleapis.com/read_calls: 1
-// - selector: google.example.library.v1.LibraryService.UpdateBook
-// metric_costs:
-// library.googleapis.com/write_calls: 2
-// - selector: google.example.library.v1.LibraryService.DeleteBook
-// metric_costs:
-// library.googleapis.com/write_calls: 1
-//
-// Corresponding Metric definition:
-//
-// metrics:
-// - name: library.googleapis.com/read_calls
-// display_name: Read requests
-// metric_kind: DELTA
-// value_type: INT64
-//
-// - name: library.googleapis.com/write_calls
-// display_name: Write requests
-// metric_kind: DELTA
-// value_type: INT64
-//
-message Quota {
- // List of `QuotaLimit` definitions for the service.
- //
- // Used by metric-based quotas only.
- repeated QuotaLimit limits = 3;
-
- // List of `MetricRule` definitions, each one mapping a selected method to one
- // or more metrics.
- //
- // Used by metric-based quotas only.
- repeated MetricRule metric_rules = 4;
-}
-
-// Bind API methods to metrics. Binding a method to a metric causes that
-// metric's configured quota, billing, and monitoring behaviors to apply to the
-// method call.
-//
-// Used by metric-based quotas only.
-message MetricRule {
- // Selects the methods to which this rule applies.
- //
- // Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
- string selector = 1;
-
- // Metrics to update when the selected methods are called, and the associated
- // cost applied to each metric.
- //
- // The key of the map is the metric name, and the values are the amount
- // increased for the metric against which the quota limits are defined.
- // The value must not be negative.
- map metric_costs = 2;
-}
-
-// `QuotaLimit` defines a specific limit that applies over a specified duration
-// for a limit type. There can be at most one limit for a duration and limit
-// type combination defined within a `QuotaGroup`.
-message QuotaLimit {
- // Name of the quota limit. The name is used to refer to the limit when
- // overriding the default limit on per-consumer basis.
- //
- // For group-based quota limits, the name must be unique within the quota
- // group. If a name is not provided, it will be generated from the limit_by
- // and duration fields.
- //
- // For metric-based quota limits, the name must be provided, and it must be
- // unique within the service. The name can only include alphanumeric
- // characters as well as '-'.
- //
- // The maximum length of the limit name is 64 characters.
- //
- // The name of a limit is used as a unique identifier for this limit.
- // Therefore, once a limit has been put into use, its name should be
- // immutable. You can use the display_name field to provide a user-friendly
- // name for the limit. The display name can be evolved over time without
- // affecting the identity of the limit.
- string name = 6;
-
- // Optional. User-visible, extended description for this quota limit.
- // Should be used only when more context is needed to understand this limit
- // than provided by the limit's display name (see: `display_name`).
- string description = 2;
-
- // Default number of tokens that can be consumed during the specified
- // duration. This is the number of tokens assigned when a client
- // application developer activates the service for his/her project.
- //
- // Specifying a value of 0 will block all requests. This can be used if you
- // are provisioning quota to selected consumers and blocking others.
- // Similarly, a value of -1 will indicate an unlimited quota. No other
- // negative values are allowed.
- //
- // Used by group-based quotas only.
- int64 default_limit = 3;
-
- // Maximum number of tokens that can be consumed during the specified
- // duration. Client application developers can override the default limit up
- // to this maximum. If specified, this value cannot be set to a value less
- // than the default limit. If not specified, it is set to the default limit.
- //
- // To allow clients to apply overrides with no upper bound, set this to -1,
- // indicating unlimited maximum quota.
- //
- // Used by group-based quotas only.
- int64 max_limit = 4;
-
- // Free tier value displayed in the Developers Console for this limit.
- // The free tier is the number of tokens that will be subtracted from the
- // billed amount when billing is enabled.
- // This field can only be set on a limit with duration "1d", in a billable
- // group; it is invalid on any other limit. If this field is not set, it
- // defaults to 0, indicating that there is no free tier for this service.
- //
- // Used by group-based quotas only.
- int64 free_tier = 7;
-
- // Duration of this limit in textual notation. Example: "100s", "24h", "1d".
- // For duration longer than a day, only multiple of days is supported. We
- // support only "100s" and "1d" for now. Additional support will be added in
- // the future. "0" indicates indefinite duration.
- //
- // Used by group-based quotas only.
- string duration = 5;
-
- // The name of the metric this quota limit applies to. The quota limits with
- // the same metric will be checked together during runtime. The metric must be
- // defined within the service config.
- //
- // Used by metric-based quotas only.
- string metric = 8;
-
- // Specify the unit of the quota limit. It uses the same syntax as
- // [Metric.unit][]. The supported unit kinds are determined by the quota
- // backend system.
- //
- // The [Google Service Control](https://cloud.google.com/service-control)
- // supports the following unit components:
- // * One of the time intevals:
- // * "/min" for quota every minute.
- // * "/d" for quota every 24 hours, starting 00:00 US Pacific Time.
- // * Otherwise the quota won't be reset by time, such as storage limit.
- // * One and only one of the granted containers:
- // * "/{organization}" quota for an organization.
- // * "/{project}" quota for a project.
- // * "/{folder}" quota for a folder.
- // * "/{resource}" quota for a universal resource.
- // * Zero or more quota segmentation dimension. Not all combos are valid.
- // * "/{region}" quota for every region. Not to be used with time intervals.
- // * Otherwise the resources granted on the target is not segmented.
- // * "/{zone}" quota for every zone. Not to be used with time intervals.
- // * Otherwise the resources granted on the target is not segmented.
- // * "/{resource}" quota for a resource associated with a project or org.
- //
- // Here are some examples:
- // * "1/min/{project}" for quota per minute per project.
- // * "1/min/{user}" for quota per minute per user.
- // * "1/min/{organization}" for quota per minute per organization.
- //
- // Note: the order of unit components is insignificant.
- // The "1" at the beginning is required to follow the metric unit syntax.
- //
- // Used by metric-based quotas only.
- string unit = 9;
-
- // Tiered limit values. Also allows for regional or zone overrides for these
- // values if "/{region}" or "/{zone}" is specified in the unit field.
- //
- // Currently supported tiers from low to high:
- // VERY_LOW, LOW, STANDARD, HIGH, VERY_HIGH
- //
- // To apply different limit values for users according to their tiers, specify
- // the values for the tiers you want to differentiate. For example:
- // {LOW:100, STANDARD:500, HIGH:1000, VERY_HIGH:5000}
- //
- // The limit value for each tier is optional except for the tier STANDARD.
- // The limit value for an unspecified tier falls to the value of its next
- // tier towards tier STANDARD. For the above example, the limit value for tier
- // STANDARD is 500.
- //
- // To apply the same limit value for all users, just specify limit value for
- // tier STANDARD. For example: {STANDARD:500}.
- //
- // To apply a regional overide for a tier, add a map entry with key
- // "/", where is a region name. Similarly, for a zone
- // override, add a map entry with key "/{zone}".
- // Further, a wildcard can be used at the end of a zone name in order to
- // specify zone level overrides. For example:
- // LOW: 10, STANDARD: 50, HIGH: 100,
- // LOW/us-central1: 20, STANDARD/us-central1: 60, HIGH/us-central1: 200,
- // LOW/us-central1-*: 10, STANDARD/us-central1-*: 20, HIGH/us-central1-*: 80
- //
- // The regional overrides tier set for each region must be the same as
- // the tier set for default limit values. Same rule applies for zone overrides
- // tier as well.
- //
- // Used by metric-based quotas only.
- map values = 10;
-
- // User-visible display name for this limit.
- // Optional. If not set, the UI will provide a default display name based on
- // the quota configuration. This field can be used to override the default
- // display name generated from the configuration.
- string display_name = 12;
-}
diff --git a/packages/speech/protos/google/api/service.proto b/packages/speech/protos/google/api/service.proto
deleted file mode 100644
index 04c7fd700b1..00000000000
--- a/packages/speech/protos/google/api/service.proto
+++ /dev/null
@@ -1,176 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/annotations.proto";
-import "google/api/auth.proto";
-import "google/api/backend.proto";
-import "google/api/context.proto";
-import "google/api/control.proto";
-import "google/api/documentation.proto";
-import "google/api/endpoint.proto";
-import "google/api/experimental/experimental.proto";
-import "google/api/http.proto";
-import "google/api/label.proto";
-import "google/api/log.proto";
-import "google/api/logging.proto";
-import "google/api/metric.proto";
-import "google/api/monitored_resource.proto";
-import "google/api/monitoring.proto";
-import "google/api/quota.proto";
-import "google/api/source_info.proto";
-import "google/api/system_parameter.proto";
-import "google/api/usage.proto";
-import "google/protobuf/any.proto";
-import "google/protobuf/api.proto";
-import "google/protobuf/type.proto";
-import "google/protobuf/wrappers.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "ServiceProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// `Service` is the root object of Google service configuration schema. It
-// describes basic information about a service, such as the name and the
-// title, and delegates other aspects to sub-sections. Each sub-section is
-// either a proto message or a repeated proto message that configures a
-// specific aspect, such as auth. See each proto message definition for details.
-//
-// Example:
-//
-// type: google.api.Service
-// config_version: 3
-// name: calendar.googleapis.com
-// title: Google Calendar API
-// apis:
-// - name: google.calendar.v3.Calendar
-// authentication:
-// providers:
-// - id: google_calendar_auth
-// jwks_uri: https://www.googleapis.com/oauth2/v1/certs
-// issuer: https://securetoken.google.com
-// rules:
-// - selector: "*"
-// requirements:
-// provider_id: google_calendar_auth
-message Service {
- // The version of the service configuration. The config version may
- // influence interpretation of the configuration, for example, to
- // determine defaults. This is documented together with applicable
- // options. The current default for the config version itself is `3`.
- google.protobuf.UInt32Value config_version = 20;
-
- // The DNS address at which this service is available,
- // e.g. `calendar.googleapis.com`.
- string name = 1;
-
- // A unique ID for a specific instance of this message, typically assigned
- // by the client for tracking purpose. If empty, the server may choose to
- // generate one instead.
- string id = 33;
-
- // The product title associated with this service.
- string title = 2;
-
- // The id of the Google developer project that owns the service.
- // Members of this project can manage the service configuration,
- // manage consumption of the service, etc.
- string producer_project_id = 22;
-
- // A list of API interfaces exported by this service. Only the `name` field
- // of the [google.protobuf.Api][google.protobuf.Api] needs to be provided by the configuration
- // author, as the remaining fields will be derived from the IDL during the
- // normalization process. It is an error to specify an API interface here
- // which cannot be resolved against the associated IDL files.
- repeated google.protobuf.Api apis = 3;
-
- // A list of all proto message types included in this API service.
- // Types referenced directly or indirectly by the `apis` are
- // automatically included. Messages which are not referenced but
- // shall be included, such as types used by the `google.protobuf.Any` type,
- // should be listed here by name. Example:
- //
- // types:
- // - name: google.protobuf.Int32
- repeated google.protobuf.Type types = 4;
-
- // A list of all enum types included in this API service. Enums
- // referenced directly or indirectly by the `apis` are automatically
- // included. Enums which are not referenced but shall be included
- // should be listed here by name. Example:
- //
- // enums:
- // - name: google.someapi.v1.SomeEnum
- repeated google.protobuf.Enum enums = 5;
-
- // Additional API documentation.
- Documentation documentation = 6;
-
- // API backend configuration.
- Backend backend = 8;
-
- // HTTP configuration.
- Http http = 9;
-
- // Quota configuration.
- Quota quota = 10;
-
- // Auth configuration.
- Authentication authentication = 11;
-
- // Context configuration.
- Context context = 12;
-
- // Configuration controlling usage of this service.
- Usage usage = 15;
-
- // Configuration for network endpoints. If this is empty, then an endpoint
- // with the same name as the service is automatically generated to service all
- // defined APIs.
- repeated Endpoint endpoints = 18;
-
- // Configuration for the service control plane.
- Control control = 21;
-
- // Defines the logs used by this service.
- repeated LogDescriptor logs = 23;
-
- // Defines the metrics used by this service.
- repeated MetricDescriptor metrics = 24;
-
- // Defines the monitored resources used by this service. This is required
- // by the [Service.monitoring][google.api.Service.monitoring] and [Service.logging][google.api.Service.logging] configurations.
- repeated MonitoredResourceDescriptor monitored_resources = 25;
-
- // Logging configuration.
- Logging logging = 27;
-
- // Monitoring configuration.
- Monitoring monitoring = 28;
-
- // System parameter configuration.
- SystemParameters system_parameters = 29;
-
- // Output only. The source information for this configuration if available.
- SourceInfo source_info = 37;
-
- // Experimental configuration.
- Experimental experimental = 101;
-}
diff --git a/packages/speech/protos/google/api/servicecontrol/v1/check_error.proto b/packages/speech/protos/google/api/servicecontrol/v1/check_error.proto
deleted file mode 100644
index 4fa31cf4c26..00000000000
--- a/packages/speech/protos/google/api/servicecontrol/v1/check_error.proto
+++ /dev/null
@@ -1,95 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api.servicecontrol.v1;
-
-import "google/api/annotations.proto";
-
-option cc_enable_arenas = true;
-option go_package = "google.golang.org/genproto/googleapis/api/servicecontrol/v1;servicecontrol";
-option java_multiple_files = true;
-option java_outer_classname = "CheckErrorProto";
-option java_package = "com.google.api.servicecontrol.v1";
-
-
-// Defines the errors to be returned in
-// [google.api.servicecontrol.v1.CheckResponse.check_errors][google.api.servicecontrol.v1.CheckResponse.check_errors].
-message CheckError {
- // Error codes for Check responses.
- enum Code {
- // This is never used in `CheckResponse`.
- ERROR_CODE_UNSPECIFIED = 0;
-
- // The consumer's project id was not found.
- // Same as [google.rpc.Code.NOT_FOUND][].
- NOT_FOUND = 5;
-
- // The consumer doesn't have access to the specified resource.
- // Same as [google.rpc.Code.PERMISSION_DENIED][].
- PERMISSION_DENIED = 7;
-
- // Quota check failed. Same as [google.rpc.Code.RESOURCE_EXHAUSTED][].
- RESOURCE_EXHAUSTED = 8;
-
- // The consumer hasn't activated the service.
- SERVICE_NOT_ACTIVATED = 104;
-
- // The consumer cannot access the service because billing is disabled.
- BILLING_DISABLED = 107;
-
- // The consumer's project has been marked as deleted (soft deletion).
- PROJECT_DELETED = 108;
-
- // The consumer's project number or id does not represent a valid project.
- PROJECT_INVALID = 114;
-
- // The IP address of the consumer is invalid for the specific consumer
- // project.
- IP_ADDRESS_BLOCKED = 109;
-
- // The referer address of the consumer request is invalid for the specific
- // consumer project.
- REFERER_BLOCKED = 110;
-
- // The client application of the consumer request is invalid for the
- // specific consumer project.
- CLIENT_APP_BLOCKED = 111;
-
- // The consumer's API key is invalid.
- API_KEY_INVALID = 105;
-
- // The consumer's API Key has expired.
- API_KEY_EXPIRED = 112;
-
- // The consumer's API Key was not found in config record.
- API_KEY_NOT_FOUND = 113;
-
- // The backend server for looking up project id/number is unavailable.
- NAMESPACE_LOOKUP_UNAVAILABLE = 300;
-
- // The backend server for checking service status is unavailable.
- SERVICE_STATUS_UNAVAILABLE = 301;
-
- // The backend server for checking billing status is unavailable.
- BILLING_STATUS_UNAVAILABLE = 302;
- }
-
- // The error code.
- Code code = 1;
-
- // Free-form text providing details on the error cause of the error.
- string detail = 2;
-}
diff --git a/packages/speech/protos/google/api/servicecontrol/v1/distribution.proto b/packages/speech/protos/google/api/servicecontrol/v1/distribution.proto
deleted file mode 100644
index 93ec2e4d675..00000000000
--- a/packages/speech/protos/google/api/servicecontrol/v1/distribution.proto
+++ /dev/null
@@ -1,159 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api.servicecontrol.v1;
-
-option cc_enable_arenas = true;
-option go_package = "google.golang.org/genproto/googleapis/api/servicecontrol/v1;servicecontrol";
-option java_multiple_files = true;
-option java_outer_classname = "DistributionProto";
-option java_package = "com.google.api.servicecontrol.v1";
-
-
-// Distribution represents a frequency distribution of double-valued sample
-// points. It contains the size of the population of sample points plus
-// additional optional information:
-//
-// - the arithmetic mean of the samples
-// - the minimum and maximum of the samples
-// - the sum-squared-deviation of the samples, used to compute variance
-// - a histogram of the values of the sample points
-message Distribution {
- // Describing buckets with constant width.
- message LinearBuckets {
- // The number of finite buckets. With the underflow and overflow buckets,
- // the total number of buckets is `num_finite_buckets` + 2.
- // See comments on `bucket_options` for details.
- int32 num_finite_buckets = 1;
-
- // The i'th linear bucket covers the interval
- // [offset + (i-1) * width, offset + i * width)
- // where i ranges from 1 to num_finite_buckets, inclusive.
- // Must be strictly positive.
- double width = 2;
-
- // The i'th linear bucket covers the interval
- // [offset + (i-1) * width, offset + i * width)
- // where i ranges from 1 to num_finite_buckets, inclusive.
- double offset = 3;
- }
-
- // Describing buckets with exponentially growing width.
- message ExponentialBuckets {
- // The number of finite buckets. With the underflow and overflow buckets,
- // the total number of buckets is `num_finite_buckets` + 2.
- // See comments on `bucket_options` for details.
- int32 num_finite_buckets = 1;
-
- // The i'th exponential bucket covers the interval
- // [scale * growth_factor^(i-1), scale * growth_factor^i)
- // where i ranges from 1 to num_finite_buckets inclusive.
- // Must be larger than 1.0.
- double growth_factor = 2;
-
- // The i'th exponential bucket covers the interval
- // [scale * growth_factor^(i-1), scale * growth_factor^i)
- // where i ranges from 1 to num_finite_buckets inclusive.
- // Must be > 0.
- double scale = 3;
- }
-
- // Describing buckets with arbitrary user-provided width.
- message ExplicitBuckets {
- // 'bound' is a list of strictly increasing boundaries between
- // buckets. Note that a list of length N-1 defines N buckets because
- // of fenceposting. See comments on `bucket_options` for details.
- //
- // The i'th finite bucket covers the interval
- // [bound[i-1], bound[i])
- // where i ranges from 1 to bound_size() - 1. Note that there are no
- // finite buckets at all if 'bound' only contains a single element; in
- // that special case the single bound defines the boundary between the
- // underflow and overflow buckets.
- //
- // bucket number lower bound upper bound
- // i == 0 (underflow) -inf bound[i]
- // 0 < i < bound_size() bound[i-1] bound[i]
- // i == bound_size() (overflow) bound[i-1] +inf
- repeated double bounds = 1;
- }
-
- // The total number of samples in the distribution. Must be >= 0.
- int64 count = 1;
-
- // The arithmetic mean of the samples in the distribution. If `count` is
- // zero then this field must be zero.
- double mean = 2;
-
- // The minimum of the population of values. Ignored if `count` is zero.
- double minimum = 3;
-
- // The maximum of the population of values. Ignored if `count` is zero.
- double maximum = 4;
-
- // The sum of squared deviations from the mean:
- // Sum[i=1..count]((x_i - mean)^2)
- // where each x_i is a sample values. If `count` is zero then this field
- // must be zero, otherwise validation of the request fails.
- double sum_of_squared_deviation = 5;
-
- // The number of samples in each histogram bucket. `bucket_counts` are
- // optional. If present, they must sum to the `count` value.
- //
- // The buckets are defined below in `bucket_option`. There are N buckets.
- // `bucket_counts[0]` is the number of samples in the underflow bucket.
- // `bucket_counts[1]` to `bucket_counts[N-1]` are the numbers of samples
- // in each of the finite buckets. And `bucket_counts[N] is the number
- // of samples in the overflow bucket. See the comments of `bucket_option`
- // below for more details.
- //
- // Any suffix of trailing zeros may be omitted.
- repeated int64 bucket_counts = 6;
-
- // Defines the buckets in the histogram. `bucket_option` and `bucket_counts`
- // must be both set, or both unset.
- //
- // Buckets are numbered the the range of [0, N], with a total of N+1 buckets.
- // There must be at least two buckets (a single-bucket histogram gives
- // no information that isn't already provided by `count`).
- //
- // The first bucket is the underflow bucket which has a lower bound
- // of -inf. The last bucket is the overflow bucket which has an
- // upper bound of +inf. All other buckets (if any) are called "finite"
- // buckets because they have finite lower and upper bounds. As described
- // below, there are three ways to define the finite buckets.
- //
- // (1) Buckets with constant width.
- // (2) Buckets with exponentially growing widths.
- // (3) Buckets with arbitrary user-provided widths.
- //
- // In all cases, the buckets cover the entire real number line (-inf,
- // +inf). Bucket upper bounds are exclusive and lower bounds are
- // inclusive. The upper bound of the underflow bucket is equal to the
- // lower bound of the smallest finite bucket; the lower bound of the
- // overflow bucket is equal to the upper bound of the largest finite
- // bucket.
- oneof bucket_option {
- // Buckets with constant width.
- LinearBuckets linear_buckets = 7;
-
- // Buckets with exponentially growing width.
- ExponentialBuckets exponential_buckets = 8;
-
- // Buckets with arbitrary user-provided width.
- ExplicitBuckets explicit_buckets = 9;
- }
-}
diff --git a/packages/speech/protos/google/api/servicecontrol/v1/log_entry.proto b/packages/speech/protos/google/api/servicecontrol/v1/log_entry.proto
deleted file mode 100644
index fddb9851eca..00000000000
--- a/packages/speech/protos/google/api/servicecontrol/v1/log_entry.proto
+++ /dev/null
@@ -1,67 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api.servicecontrol.v1;
-
-import "google/api/annotations.proto";
-import "google/logging/type/log_severity.proto";
-import "google/protobuf/any.proto";
-import "google/protobuf/struct.proto";
-import "google/protobuf/timestamp.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/servicecontrol/v1;servicecontrol";
-option java_multiple_files = true;
-option java_outer_classname = "LogEntryProto";
-option java_package = "com.google.api.servicecontrol.v1";
-
-
-// An individual log entry.
-message LogEntry {
- // Required. The log to which this log entry belongs. Examples: `"syslog"`,
- // `"book_log"`.
- string name = 10;
-
- // The time the event described by the log entry occurred. If
- // omitted, defaults to operation start time.
- google.protobuf.Timestamp timestamp = 11;
-
- // The severity of the log entry. The default value is
- // `LogSeverity.DEFAULT`.
- google.logging.type.LogSeverity severity = 12;
-
- // A unique ID for the log entry used for deduplication. If omitted,
- // the implementation will generate one based on operation_id.
- string insert_id = 4;
-
- // A set of user-defined (key, value) data that provides additional
- // information about the log entry.
- map labels = 13;
-
- // The log entry payload, which can be one of multiple types.
- oneof payload {
- // The log entry payload, represented as a protocol buffer that is
- // expressed as a JSON object. You can only pass `protoPayload`
- // values that belong to a set of approved types.
- google.protobuf.Any proto_payload = 2;
-
- // The log entry payload, represented as a Unicode string (UTF-8).
- string text_payload = 3;
-
- // The log entry payload, represented as a structure that
- // is expressed as a JSON object.
- google.protobuf.Struct struct_payload = 6;
- }
-}
diff --git a/packages/speech/protos/google/api/servicecontrol/v1/metric_value.proto b/packages/speech/protos/google/api/servicecontrol/v1/metric_value.proto
deleted file mode 100644
index d5e5803b7a0..00000000000
--- a/packages/speech/protos/google/api/servicecontrol/v1/metric_value.proto
+++ /dev/null
@@ -1,78 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api.servicecontrol.v1;
-
-import "google/api/annotations.proto";
-import "google/api/servicecontrol/v1/distribution.proto";
-import "google/protobuf/timestamp.proto";
-import "google/type/money.proto";
-
-option cc_enable_arenas = true;
-option go_package = "google.golang.org/genproto/googleapis/api/servicecontrol/v1;servicecontrol";
-option java_multiple_files = true;
-option java_outer_classname = "MetricValueSetProto";
-option java_package = "com.google.api.servicecontrol.v1";
-
-
-// Represents a single metric value.
-message MetricValue {
- // The labels describing the metric value.
- // See comments on [google.api.servicecontrol.v1.Operation.labels][google.api.servicecontrol.v1.Operation.labels] for
- // the overriding relationship.
- map labels = 1;
-
- // The start of the time period over which this metric value's measurement
- // applies. The time period has different semantics for different metric
- // types (cumulative, delta, and gauge). See the metric definition
- // documentation in the service configuration for details.
- google.protobuf.Timestamp start_time = 2;
-
- // The end of the time period over which this metric value's measurement
- // applies.
- google.protobuf.Timestamp end_time = 3;
-
- // The value. The type of value used in the request must
- // agree with the metric definition in the service configuration, otherwise
- // the MetricValue is rejected.
- oneof value {
- // A boolean value.
- bool bool_value = 4;
-
- // A signed 64-bit integer value.
- int64 int64_value = 5;
-
- // A double precision floating point value.
- double double_value = 6;
-
- // A text string value.
- string string_value = 7;
-
- // A distribution value.
- Distribution distribution_value = 8;
- }
-}
-
-// Represents a set of metric values in the same metric.
-// Each metric value in the set should have a unique combination of start time,
-// end time, and label values.
-message MetricValueSet {
- // The metric name defined in the service configuration.
- string metric_name = 1;
-
- // The values in this metric.
- repeated MetricValue metric_values = 2;
-}
diff --git a/packages/speech/protos/google/api/servicecontrol/v1/operation.proto b/packages/speech/protos/google/api/servicecontrol/v1/operation.proto
deleted file mode 100644
index 568108af539..00000000000
--- a/packages/speech/protos/google/api/servicecontrol/v1/operation.proto
+++ /dev/null
@@ -1,112 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api.servicecontrol.v1;
-
-import "google/api/annotations.proto";
-import "google/api/servicecontrol/v1/log_entry.proto";
-import "google/api/servicecontrol/v1/metric_value.proto";
-import "google/protobuf/timestamp.proto";
-
-option cc_enable_arenas = true;
-option go_package = "google.golang.org/genproto/googleapis/api/servicecontrol/v1;servicecontrol";
-option java_multiple_files = true;
-option java_outer_classname = "OperationProto";
-option java_package = "com.google.api.servicecontrol.v1";
-
-
-// Represents information regarding an operation.
-message Operation {
- // Defines the importance of the data contained in the operation.
- enum Importance {
- // The API implementation may cache and aggregate the data.
- // The data may be lost when rare and unexpected system failures occur.
- LOW = 0;
-
- // The API implementation doesn't cache and aggregate the data.
- // If the method returns successfully, it's guaranteed that the data has
- // been persisted in durable storage.
- HIGH = 1;
- }
-
- // Identity of the operation. This must be unique within the scope of the
- // service that generated the operation. If the service calls
- // Check() and Report() on the same operation, the two calls should carry
- // the same id.
- //
- // UUID version 4 is recommended, though not required.
- // In scenarios where an operation is computed from existing information
- // and an idempotent id is desirable for deduplication purpose, UUID version 5
- // is recommended. See RFC 4122 for details.
- string operation_id = 1;
-
- // Fully qualified name of the operation. Reserved for future use.
- string operation_name = 2;
-
- // Identity of the consumer who is using the service.
- // This field should be filled in for the operations initiated by a
- // consumer, but not for service-initiated operations that are
- // not related to a specific consumer.
- //
- // This can be in one of the following formats:
- // project:,
- // project_number:,
- // api_key:.
- string consumer_id = 3;
-
- // Required. Start time of the operation.
- google.protobuf.Timestamp start_time = 4;
-
- // End time of the operation.
- // Required when the operation is used in [ServiceController.Report][google.api.servicecontrol.v1.ServiceController.Report],
- // but optional when the operation is used in [ServiceController.Check][google.api.servicecontrol.v1.ServiceController.Check].
- google.protobuf.Timestamp end_time = 5;
-
- // Labels describing the operation. Only the following labels are allowed:
- //
- // - Labels describing monitored resources as defined in
- // the service configuration.
- // - Default labels of metric values. When specified, labels defined in the
- // metric value override these default.
- // - The following labels defined by Google Cloud Platform:
- // - `cloud.googleapis.com/location` describing the location where the
- // operation happened,
- // - `servicecontrol.googleapis.com/user_agent` describing the user agent
- // of the API request,
- // - `servicecontrol.googleapis.com/service_agent` describing the service
- // used to handle the API request (e.g. ESP),
- // - `servicecontrol.googleapis.com/platform` describing the platform
- // where the API is served (e.g. GAE, GCE, GKE).
- map labels = 6;
-
- // Represents information about this operation. Each MetricValueSet
- // corresponds to a metric defined in the service configuration.
- // The data type used in the MetricValueSet must agree with
- // the data type specified in the metric definition.
- //
- // Within a single operation, it is not allowed to have more than one
- // MetricValue instances that have the same metric names and identical
- // label value combinations. If a request has such duplicated MetricValue
- // instances, the entire request is rejected with
- // an invalid argument error.
- repeated MetricValueSet metric_value_sets = 7;
-
- // Represents information to be logged.
- repeated LogEntry log_entries = 8;
-
- // DO NOT USE. This is an experimental field.
- Importance importance = 11;
-}
diff --git a/packages/speech/protos/google/api/servicecontrol/v1/service_controller.proto b/packages/speech/protos/google/api/servicecontrol/v1/service_controller.proto
deleted file mode 100644
index 2d0ec8e9fd7..00000000000
--- a/packages/speech/protos/google/api/servicecontrol/v1/service_controller.proto
+++ /dev/null
@@ -1,161 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api.servicecontrol.v1;
-
-import "google/api/annotations.proto";
-import "google/api/servicecontrol/v1/check_error.proto";
-import "google/api/servicecontrol/v1/operation.proto";
-import "google/rpc/status.proto";
-
-option cc_enable_arenas = true;
-option go_package = "google.golang.org/genproto/googleapis/api/servicecontrol/v1;servicecontrol";
-option java_multiple_files = true;
-option java_outer_classname = "ServiceControllerProto";
-option java_package = "com.google.api.servicecontrol.v1";
-option objc_class_prefix = "GASC";
-
-
-// [Google Service Control API](/service-control/overview)
-//
-// Lets clients check and report operations against
-// a [managed service][google.api.servicemanagement.v1.ManagedService].
-service ServiceController {
- // Checks an operation with Google Service Control to decide whether
- // the given operation should proceed. It should be called before the
- // operation is executed.
- //
- // If feasible, the client should cache the check results and reuse them for
- // up to 60s. In case of server errors, the client may rely on the cached
- // results for longer time.
- //
- // This method requires the `servicemanagement.services.check` permission
- // on the specified service. For more information, see
- // [Google Cloud IAM](https://cloud.google.com/iam).
- rpc Check(CheckRequest) returns (CheckResponse) {
- option (google.api.http) = { post: "/v1/services/{service_name}:check" body: "*" };
- }
-
- // Reports operations to Google Service Control. It should be called
- // after the operation is completed.
- //
- // If feasible, the client should aggregate reporting data for up to 5s to
- // reduce API traffic. Limiting aggregation to 5s is to reduce data loss
- // during client crashes. Clients should carefully choose the aggregation
- // window to avoid data loss risk more than 0.01% for business and
- // compliance reasons.
- //
- // This method requires the `servicemanagement.services.report` permission
- // on the specified service. For more information, see
- // [Google Cloud IAM](https://cloud.google.com/iam).
- rpc Report(ReportRequest) returns (ReportResponse) {
- option (google.api.http) = { post: "/v1/services/{service_name}:report" body: "*" };
- }
-}
-
-// Request message for the Check method.
-message CheckRequest {
- // The service name as specified in its service configuration. For example,
- // `"pubsub.googleapis.com"`.
- //
- // See [google.api.Service][google.api.Service] for the definition of a service name.
- string service_name = 1;
-
- // The operation to be checked.
- Operation operation = 2;
-
- // Specifies which version of service configuration should be used to process
- // the request.
- //
- // If unspecified or no matching version can be found, the
- // latest one will be used.
- string service_config_id = 4;
-}
-
-// Response message for the Check method.
-message CheckResponse {
- // The same operation_id value used in the CheckRequest.
- // Used for logging and diagnostics purposes.
- string operation_id = 1;
-
- // Indicate the decision of the check.
- //
- // If no check errors are present, the service should process the operation.
- // Otherwise the service should use the list of errors to determine the
- // appropriate action.
- repeated CheckError check_errors = 2;
-
- // The actual config id used to process the request.
- string service_config_id = 5;
-}
-
-// Request message for the Report method.
-message ReportRequest {
- // The service name as specified in its service configuration. For example,
- // `"pubsub.googleapis.com"`.
- //
- // See [google.api.Service][google.api.Service] for the definition of a service name.
- string service_name = 1;
-
- // Operations to be reported.
- //
- // Typically the service should report one operation per request.
- // Putting multiple operations into a single request is allowed, but should
- // be used only when multiple operations are natually available at the time
- // of the report.
- //
- // If multiple operations are in a single request, the total request size
- // should be no larger than 1MB. See [ReportResponse.report_errors][google.api.servicecontrol.v1.ReportResponse.report_errors] for
- // partial failure behavior.
- repeated Operation operations = 2;
-
- // Specifies which version of service config should be used to process the
- // request.
- //
- // If unspecified or no matching version can be found, the
- // latest one will be used.
- string service_config_id = 3;
-}
-
-// Response message for the Report method.
-message ReportResponse {
- // Represents the processing error of one `Operation` in the request.
- message ReportError {
- // The [Operation.operation_id][google.api.servicecontrol.v1.Operation.operation_id] value from the request.
- string operation_id = 1;
-
- // Details of the error when processing the `Operation`.
- google.rpc.Status status = 2;
- }
-
- // Partial failures, one for each `Operation` in the request that failed
- // processing. There are three possible combinations of the RPC status:
- //
- // 1. The combination of a successful RPC status and an empty `report_errors`
- // list indicates a complete success where all `Operations` in the
- // request are processed successfully.
- // 2. The combination of a successful RPC status and a non-empty
- // `report_errors` list indicates a partial success where some
- // `Operations` in the request succeeded. Each
- // `Operation` that failed processing has a corresponding item
- // in this list.
- // 3. A failed RPC status indicates a complete failure where none of the
- // `Operations` in the request succeeded.
- repeated ReportError report_errors = 1;
-
- // The actual config id used to process the request.
- string service_config_id = 2;
-}
diff --git a/packages/speech/protos/google/api/servicemanagement/v1/resources.proto b/packages/speech/protos/google/api/servicemanagement/v1/resources.proto
deleted file mode 100644
index 0d0f34d62ef..00000000000
--- a/packages/speech/protos/google/api/servicemanagement/v1/resources.proto
+++ /dev/null
@@ -1,286 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api.servicemanagement.v1;
-
-import "google/api/annotations.proto";
-import "google/api/config_change.proto";
-import "google/api/service.proto";
-import "google/longrunning/operations.proto";
-import "google/protobuf/any.proto";
-import "google/protobuf/field_mask.proto";
-import "google/protobuf/struct.proto";
-import "google/protobuf/timestamp.proto";
-import "google/rpc/status.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/servicemanagement/v1;servicemanagement";
-option java_multiple_files = true;
-option java_outer_classname = "ResourcesProto";
-option java_package = "com.google.api.servicemanagement.v1";
-option objc_class_prefix = "GASM";
-
-
-// The full representation of a Service that is managed by
-// Google Service Management.
-message ManagedService {
- // The name of the service. See the [overview](/service-management/overview)
- // for naming requirements.
- string service_name = 2;
-
- // ID of the project that produces and owns this service.
- string producer_project_id = 3;
-}
-
-// The metadata associated with a long running operation resource.
-message OperationMetadata {
- // Represents the status of one operation step.
- message Step {
- // The short description of the step.
- string description = 2;
-
- // The status code.
- Status status = 4;
- }
-
- // Code describes the status of one operation step.
- enum Status {
- // Unspecifed code.
- STATUS_UNSPECIFIED = 0;
-
- // The step has completed without errors.
- DONE = 1;
-
- // The step has not started yet.
- NOT_STARTED = 2;
-
- // The step is in progress.
- IN_PROGRESS = 3;
-
- // The step has completed with errors.
- FAILED = 4;
-
- // The step has completed with cancellation.
- CANCELLED = 5;
- }
-
- // The full name of the resources that this operation is directly
- // associated with.
- repeated string resource_names = 1;
-
- // Detailed status information for each step. The order is undetermined.
- repeated Step steps = 2;
-
- // Percentage of completion of this operation, ranging from 0 to 100.
- int32 progress_percentage = 3;
-
- // The start time of the operation.
- google.protobuf.Timestamp start_time = 4;
-}
-
-// Represents a diagnostic message (error or warning)
-message Diagnostic {
- // The kind of diagnostic information possible.
- enum Kind {
- // Warnings and errors
- WARNING = 0;
-
- // Only errors
- ERROR = 1;
- }
-
- // File name and line number of the error or warning.
- string location = 1;
-
- // The kind of diagnostic information provided.
- Kind kind = 2;
-
- // Message describing the error or warning.
- string message = 3;
-}
-
-// Represents a source file which is used to generate the service configuration
-// defined by `google.api.Service`.
-message ConfigSource {
- // A unique ID for a specific instance of this message, typically assigned
- // by the client for tracking purpose. If empty, the server may choose to
- // generate one instead.
- string id = 5;
-
- // Set of source configuration files that are used to generate a service
- // configuration (`google.api.Service`).
- repeated ConfigFile files = 2;
-}
-
-// Generic specification of a source configuration file
-message ConfigFile {
- enum FileType {
- // Unknown file type.
- FILE_TYPE_UNSPECIFIED = 0;
-
- // YAML-specification of service.
- SERVICE_CONFIG_YAML = 1;
-
- // OpenAPI specification, serialized in JSON.
- OPEN_API_JSON = 2;
-
- // OpenAPI specification, serialized in YAML.
- OPEN_API_YAML = 3;
-
- // FileDescriptorSet, generated by protoc.
- //
- // To generate, use protoc with imports and source info included.
- // For an example test.proto file, the following command would put the value
- // in a new file named out.pb.
- //
- // $protoc --include_imports --include_source_info test.proto -o out.pb
- FILE_DESCRIPTOR_SET_PROTO = 4;
- }
-
- // The file name of the configuration file (full or relative path).
- string file_path = 1;
-
- // The bytes that constitute the file.
- bytes file_contents = 3;
-
- // The type of configuration file this represents.
- FileType file_type = 4;
-}
-
-// Represents a service configuration with its name and id.
-message ConfigRef {
- // Resource name of a service config. It must have the following
- // format: "services/{service name}/configs/{config id}".
- string name = 1;
-}
-
-// Change report associated with a particular service configuration.
-//
-// It contains a list of ConfigChanges based on the comparison between
-// two service configurations.
-message ChangeReport {
- // List of changes between two service configurations.
- // The changes will be alphabetically sorted based on the identifier
- // of each change.
- // A ConfigChange identifier is a dot separated path to the configuration.
- // Example: visibility.rules[selector='LibraryService.CreateBook'].restriction
- repeated google.api.ConfigChange config_changes = 1;
-}
-
-// A rollout resource that defines how service configuration versions are pushed
-// to control plane systems. Typically, you create a new version of the
-// service config, and then create a Rollout to push the service config.
-message Rollout {
- // Strategy that specifies how Google Service Control should select
- // different
- // versions of service configurations based on traffic percentage.
- //
- // One example of how to gradually rollout a new service configuration using
- // this
- // strategy:
- // Day 1
- //
- // Rollout {
- // id: "example.googleapis.com/rollout_20160206"
- // traffic_percent_strategy {
- // percentages: {
- // "example.googleapis.com/20160201": 70.00
- // "example.googleapis.com/20160206": 30.00
- // }
- // }
- // }
- //
- // Day 2
- //
- // Rollout {
- // id: "example.googleapis.com/rollout_20160207"
- // traffic_percent_strategy: {
- // percentages: {
- // "example.googleapis.com/20160206": 100.00
- // }
- // }
- // }
- message TrafficPercentStrategy {
- // Maps service configuration IDs to their corresponding traffic percentage.
- // Key is the service configuration ID, Value is the traffic percentage
- // which must be greater than 0.0 and the sum must equal to 100.0.
- map percentages = 1;
- }
-
- // Strategy used to delete a service. This strategy is a placeholder only
- // used by the system generated rollout to delete a service.
- message DeleteServiceStrategy {
-
- }
-
- // Status of a Rollout.
- enum RolloutStatus {
- // No status specified.
- ROLLOUT_STATUS_UNSPECIFIED = 0;
-
- // The Rollout is in progress.
- IN_PROGRESS = 1;
-
- // The Rollout has completed successfully.
- SUCCESS = 2;
-
- // The Rollout has been cancelled. This can happen if you have overlapping
- // Rollout pushes, and the previous ones will be cancelled.
- CANCELLED = 3;
-
- // The Rollout has failed. It is typically caused by configuration errors.
- FAILED = 4;
-
- // The Rollout has not started yet and is pending for execution.
- PENDING = 5;
- }
-
- // Optional unique identifier of this Rollout. Only lower case letters, digits
- // and '-' are allowed.
- //
- // If not specified by client, the server will generate one. The generated id
- // will have the form of , where "date" is the create
- // date in ISO 8601 format. "revision number" is a monotonically increasing
- // positive number that is reset every day for each service.
- // An example of the generated rollout_id is '2016-02-16r1'
- string rollout_id = 1;
-
- // Creation time of the rollout. Readonly.
- google.protobuf.Timestamp create_time = 2;
-
- // The user who created the Rollout. Readonly.
- string created_by = 3;
-
- // The status of this rollout. Readonly. In case of a failed rollout,
- // the system will automatically rollback to the current Rollout
- // version. Readonly.
- RolloutStatus status = 4;
-
- // Strategy that defines which versions of service configurations should be
- // pushed
- // and how they should be used at runtime.
- oneof strategy {
- // Google Service Control selects service configurations based on
- // traffic percentage.
- TrafficPercentStrategy traffic_percent_strategy = 5;
-
- // The strategy associated with a rollout to delete a `ManagedService`.
- // Readonly.
- DeleteServiceStrategy delete_service_strategy = 200;
- }
-
- // The name of the service associated with this Rollout.
- string service_name = 8;
-}
diff --git a/packages/speech/protos/google/api/servicemanagement/v1/servicemanager.proto b/packages/speech/protos/google/api/servicemanagement/v1/servicemanager.proto
deleted file mode 100644
index 62af1893ec2..00000000000
--- a/packages/speech/protos/google/api/servicemanagement/v1/servicemanager.proto
+++ /dev/null
@@ -1,392 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api.servicemanagement.v1;
-
-import "google/api/annotations.proto";
-import "google/api/service.proto";
-import "google/api/servicemanagement/v1/resources.proto";
-import "google/longrunning/operations.proto";
-import "google/protobuf/any.proto";
-import "google/protobuf/empty.proto";
-import "google/protobuf/field_mask.proto";
-import "google/protobuf/struct.proto";
-import "google/rpc/status.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/servicemanagement/v1;servicemanagement";
-option java_multiple_files = true;
-option java_outer_classname = "ServiceManagerProto";
-option java_package = "com.google.api.servicemanagement.v1";
-option objc_class_prefix = "GASM";
-
-
-// [Google Service Management API](/service-management/overview)
-service ServiceManager {
- // Lists all managed services.
- rpc ListServices(ListServicesRequest) returns (ListServicesResponse) {
- option (google.api.http) = { get: "/v1/services" };
- }
-
- // Gets a managed service.
- rpc GetService(GetServiceRequest) returns (ManagedService) {
- option (google.api.http) = { get: "/v1/services/{service_name}" };
- }
-
- // Creates a new managed service.
- // Please note one producer project can own no more than 20 services.
- //
- // Operation
- rpc CreateService(CreateServiceRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = { post: "/v1/services" body: "service" };
- }
-
- // Deletes a managed service. This method will change the serivce in the
- // `Soft-Delete` state for 30 days. Within this period, service producers may
- // call [UndeleteService][google.api.servicemanagement.v1.ServiceManager.UndeleteService] to restore the service.
- // After 30 days, the service will be permanently deleted.
- //
- // Operation
- rpc DeleteService(DeleteServiceRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = { delete: "/v1/services/{service_name}" };
- }
-
- // Revives a previously deleted managed service. The method restores the
- // service using the configuration at the time the service was deleted.
- // The target service must exist and must have been deleted within the
- // last 30 days.
- //
- // Operation
- rpc UndeleteService(UndeleteServiceRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = { post: "/v1/services/{service_name}:undelete" body: "" };
- }
-
- // Lists the history of the service configuration for a managed service,
- // from the newest to the oldest.
- rpc ListServiceConfigs(ListServiceConfigsRequest) returns (ListServiceConfigsResponse) {
- option (google.api.http) = { get: "/v1/services/{service_name}/configs" };
- }
-
- // Gets a service configuration (version) for a managed service.
- rpc GetServiceConfig(GetServiceConfigRequest) returns (google.api.Service) {
- option (google.api.http) = { get: "/v1/services/{service_name}/configs/{config_id}" };
- }
-
- // Creates a new service configuration (version) for a managed service.
- // This method only stores the service configuration. To roll out the service
- // configuration to backend systems please call
- // [CreateServiceRollout][google.api.servicemanagement.v1.ServiceManager.CreateServiceRollout].
- rpc CreateServiceConfig(CreateServiceConfigRequest) returns (google.api.Service) {
- option (google.api.http) = { post: "/v1/services/{service_name}/configs" body: "service_config" };
- }
-
- // Creates a new service configuration (version) for a managed service based
- // on
- // user-supplied configuration source files (for example: OpenAPI
- // Specification). This method stores the source configurations as well as the
- // generated service configuration. To rollout the service configuration to
- // other services,
- // please call [CreateServiceRollout][google.api.servicemanagement.v1.ServiceManager.CreateServiceRollout].
- //
- // Operation
- rpc SubmitConfigSource(SubmitConfigSourceRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = { post: "/v1/services/{service_name}/configs:submit" body: "*" };
- }
-
- // Lists the history of the service configuration rollouts for a managed
- // service, from the newest to the oldest.
- rpc ListServiceRollouts(ListServiceRolloutsRequest) returns (ListServiceRolloutsResponse) {
- option (google.api.http) = { get: "/v1/services/{service_name}/rollouts" };
- }
-
- // Gets a service configuration [rollout][google.api.servicemanagement.v1.Rollout].
- rpc GetServiceRollout(GetServiceRolloutRequest) returns (Rollout) {
- option (google.api.http) = { get: "/v1/services/{service_name}/rollouts/{rollout_id}" };
- }
-
- // Creates a new service configuration rollout. Based on rollout, the
- // Google Service Management will roll out the service configurations to
- // different backend services. For example, the logging configuration will be
- // pushed to Google Cloud Logging.
- //
- // Please note that any previous pending and running Rollouts and associated
- // Operations will be automatically cancelled so that the latest Rollout will
- // not be blocked by previous Rollouts.
- //
- // Operation
- rpc CreateServiceRollout(CreateServiceRolloutRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = { post: "/v1/services/{service_name}/rollouts" body: "rollout" };
- }
-
- // Generates and returns a report (errors, warnings and changes from
- // existing configurations) associated with
- // GenerateConfigReportRequest.new_value
- //
- // If GenerateConfigReportRequest.old_value is specified,
- // GenerateConfigReportRequest will contain a single ChangeReport based on the
- // comparison between GenerateConfigReportRequest.new_value and
- // GenerateConfigReportRequest.old_value.
- // If GenerateConfigReportRequest.old_value is not specified, this method
- // will compare GenerateConfigReportRequest.new_value with the last pushed
- // service configuration.
- rpc GenerateConfigReport(GenerateConfigReportRequest) returns (GenerateConfigReportResponse) {
- option (google.api.http) = { post: "/v1/services:generateConfigReport" body: "*" };
- }
-
- // Enable a managed service for a project with default setting.
- //
- // Operation
- //
- // [google.rpc.Status][google.rpc.Status] errors may contain a
- // [google.rpc.PreconditionFailure][] error detail.
- rpc EnableService(EnableServiceRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = { post: "/v1/services/{service_name}:enable" body: "*" };
- }
-
- // Disable a managed service for a project.
- //
- // Operation
- rpc DisableService(DisableServiceRequest) returns (google.longrunning.Operation) {
- option (google.api.http) = { post: "/v1/services/{service_name}:disable" body: "*" };
- }
-}
-
-// Request message for `ListServices` method.
-message ListServicesRequest {
- // Include services produced by the specified project.
- string producer_project_id = 1;
-
- // Requested size of the next page of data.
- int32 page_size = 5;
-
- // Token identifying which result to start with; returned by a previous list
- // call.
- string page_token = 6;
-}
-
-// Response message for `ListServices` method.
-message ListServicesResponse {
- // The results of the query.
- repeated ManagedService services = 1;
-
- // Token that can be passed to `ListServices` to resume a paginated query.
- string next_page_token = 2;
-}
-
-// Request message for `GetService` method.
-message GetServiceRequest {
- // The name of the service. See the `ServiceManager` overview for naming
- // requirements. For example: `example.googleapis.com`.
- string service_name = 1;
-}
-
-// Request message for CreateService method.
-message CreateServiceRequest {
- // Initial values for the service resource.
- ManagedService service = 1;
-}
-
-// Request message for DeleteService method.
-message DeleteServiceRequest {
- // The name of the service. See the [overview](/service-management/overview)
- // for naming requirements. For example: `example.googleapis.com`.
- string service_name = 1;
-}
-
-// Request message for UndeleteService method.
-message UndeleteServiceRequest {
- // The name of the service. See the [overview](/service-management/overview)
- // for naming requirements. For example: `example.googleapis.com`.
- string service_name = 1;
-}
-
-// Response message for UndeleteService method.
-message UndeleteServiceResponse {
- // Revived service resource.
- ManagedService service = 1;
-}
-
-// Request message for GetServiceConfig method.
-message GetServiceConfigRequest {
- // The name of the service. See the [overview](/service-management/overview)
- // for naming requirements. For example: `example.googleapis.com`.
- string service_name = 1;
-
- string config_id = 2;
-}
-
-// Request message for ListServiceConfigs method.
-message ListServiceConfigsRequest {
- // The name of the service. See the [overview](/service-management/overview)
- // for naming requirements. For example: `example.googleapis.com`.
- string service_name = 1;
-
- // The token of the page to retrieve.
- string page_token = 2;
-
- // The max number of items to include in the response list.
- int32 page_size = 3;
-}
-
-// Response message for ListServiceConfigs method.
-message ListServiceConfigsResponse {
- // The list of service configuration resources.
- repeated google.api.Service service_configs = 1;
-
- // The token of the next page of results.
- string next_page_token = 2;
-}
-
-// Request message for CreateServiceConfig method.
-message CreateServiceConfigRequest {
- // The name of the service. See the [overview](/service-management/overview)
- // for naming requirements. For example: `example.googleapis.com`.
- string service_name = 1;
-
- // The service configuration resource.
- google.api.Service service_config = 2;
-}
-
-// Request message for SubmitConfigSource method.
-message SubmitConfigSourceRequest {
- // The name of the service. See the [overview](/service-management/overview)
- // for naming requirements. For example: `example.googleapis.com`.
- string service_name = 1;
-
- // The source configuration for the service.
- ConfigSource config_source = 2;
-
- // Optional. If set, this will result in the generation of a
- // `google.api.Service` configuration based on the `ConfigSource` provided,
- // but the generated config and the sources will NOT be persisted.
- bool validate_only = 3;
-}
-
-// Response message for SubmitConfigSource method.
-message SubmitConfigSourceResponse {
- // The generated service configuration.
- google.api.Service service_config = 1;
-}
-
-// Request message for 'CreateServiceRollout'
-message CreateServiceRolloutRequest {
- // The name of the service. See the [overview](/service-management/overview)
- // for naming requirements. For example: `example.googleapis.com`.
- string service_name = 1;
-
- // The rollout resource. The `service_name` field is output only.
- Rollout rollout = 2;
-}
-
-// Request message for 'ListServiceRollouts'
-message ListServiceRolloutsRequest {
- // The name of the service. See the [overview](/service-management/overview)
- // for naming requirements. For example: `example.googleapis.com`.
- string service_name = 1;
-
- // The token of the page to retrieve.
- string page_token = 2;
-
- // The max number of items to include in the response list.
- int32 page_size = 3;
-}
-
-// Response message for ListServiceRollouts method.
-message ListServiceRolloutsResponse {
- // The list of rollout resources.
- repeated Rollout rollouts = 1;
-
- // The token of the next page of results.
- string next_page_token = 2;
-}
-
-// Request message for GetServiceRollout method.
-message GetServiceRolloutRequest {
- // The name of the service. See the [overview](/service-management/overview)
- // for naming requirements. For example: `example.googleapis.com`.
- string service_name = 1;
-
- // The id of the rollout resource.
- string rollout_id = 2;
-}
-
-// Request message for EnableService method.
-message EnableServiceRequest {
- // Name of the service to enable. Specifying an unknown service name will
- // cause the request to fail.
- string service_name = 1;
-
- // The identity of consumer resource which service enablement will be
- // applied to.
- //
- // The Google Service Management implementation accepts the following
- // forms: "project:", "project_number:".
- //
- // Note: this is made compatible with
- // google.api.servicecontrol.v1.Operation.consumer_id.
- string consumer_id = 2;
-}
-
-// Request message for DisableService method.
-message DisableServiceRequest {
- // Name of the service to disable. Specifying an unknown service name
- // will cause the request to fail.
- string service_name = 1;
-
- // The identity of consumer resource which service disablement will be
- // applied to.
- //
- // The Google Service Management implementation accepts the following
- // forms: "project:", "project_number:".
- //
- // Note: this is made compatible with
- // google.api.servicecontrol.v1.Operation.consumer_id.
- string consumer_id = 2;
-}
-
-// Request message for GenerateConfigReport method.
-message GenerateConfigReportRequest {
- // Service configuration for which we want to generate the report.
- // For this version of API, the supported types are
- // [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef],
- // [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource],
- // and [google.api.Service][google.api.Service]
- google.protobuf.Any new_config = 1;
-
- // Service configuration against which the comparison will be done.
- // For this version of API, the supported types are
- // [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef],
- // [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource],
- // and [google.api.Service][google.api.Service]
- google.protobuf.Any old_config = 2;
-}
-
-// Response message for GenerateConfigReport method.
-message GenerateConfigReportResponse {
- // Name of the service this report belongs to.
- string service_name = 1;
-
- // ID of the service configuration this report belongs to.
- string id = 2;
-
- // list of ChangeReport, each corresponding to comparison between two
- // service configurations.
- repeated ChangeReport change_reports = 3;
-
- // Errors / Linter warnings associated with the service definition this
- // report
- // belongs to.
- repeated Diagnostic diagnostics = 4;
-}
diff --git a/packages/speech/protos/google/api/source_info.proto b/packages/speech/protos/google/api/source_info.proto
deleted file mode 100644
index 5d0f7bd721f..00000000000
--- a/packages/speech/protos/google/api/source_info.proto
+++ /dev/null
@@ -1,32 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/protobuf/any.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "SourceInfoProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Source information used to create a Service Config
-message SourceInfo {
- // All files used during config generation.
- repeated google.protobuf.Any source_files = 1;
-}
diff --git a/packages/speech/protos/google/api/system_parameter.proto b/packages/speech/protos/google/api/system_parameter.proto
deleted file mode 100644
index ed36a3d0bce..00000000000
--- a/packages/speech/protos/google/api/system_parameter.proto
+++ /dev/null
@@ -1,96 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "SystemParameterProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// ### System parameter configuration
-//
-// A system parameter is a special kind of parameter defined by the API
-// system, not by an individual API. It is typically mapped to an HTTP header
-// and/or a URL query parameter. This configuration specifies which methods
-// change the names of the system parameters.
-message SystemParameters {
- // Define system parameters.
- //
- // The parameters defined here will override the default parameters
- // implemented by the system. If this field is missing from the service
- // config, default system parameters will be used. Default system parameters
- // and names is implementation-dependent.
- //
- // Example: define api key for all methods
- //
- // system_parameters
- // rules:
- // - selector: "*"
- // parameters:
- // - name: api_key
- // url_query_parameter: api_key
- //
- //
- // Example: define 2 api key names for a specific method.
- //
- // system_parameters
- // rules:
- // - selector: "/ListShelves"
- // parameters:
- // - name: api_key
- // http_header: Api-Key1
- // - name: api_key
- // http_header: Api-Key2
- //
- // **NOTE:** All service configuration rules follow "last one wins" order.
- repeated SystemParameterRule rules = 1;
-}
-
-// Define a system parameter rule mapping system parameter definitions to
-// methods.
-message SystemParameterRule {
- // Selects the methods to which this rule applies. Use '*' to indicate all
- // methods in all APIs.
- //
- // Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
- string selector = 1;
-
- // Define parameters. Multiple names may be defined for a parameter.
- // For a given method call, only one of them should be used. If multiple
- // names are used the behavior is implementation-dependent.
- // If none of the specified names are present the behavior is
- // parameter-dependent.
- repeated SystemParameter parameters = 2;
-}
-
-// Define a parameter's name and location. The parameter may be passed as either
-// an HTTP header or a URL query parameter, and if both are passed the behavior
-// is implementation-dependent.
-message SystemParameter {
- // Define the name of the parameter, such as "api_key" . It is case sensitive.
- string name = 1;
-
- // Define the HTTP header name to use for the parameter. It is case
- // insensitive.
- string http_header = 2;
-
- // Define the URL query parameter name to use for the parameter. It is case
- // sensitive.
- string url_query_parameter = 3;
-}
diff --git a/packages/speech/protos/google/api/usage.proto b/packages/speech/protos/google/api/usage.proto
deleted file mode 100644
index 29c601382d4..00000000000
--- a/packages/speech/protos/google/api/usage.proto
+++ /dev/null
@@ -1,85 +0,0 @@
-// Copyright 2017 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.api;
-
-import "google/api/annotations.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
-option java_multiple_files = true;
-option java_outer_classname = "UsageProto";
-option java_package = "com.google.api";
-option objc_class_prefix = "GAPI";
-
-
-// Configuration controlling usage of a service.
-message Usage {
- // Requirements that must be satisfied before a consumer project can use the
- // service. Each requirement is of the form /;
- // for example 'serviceusage.googleapis.com/billing-enabled'.
- repeated string requirements = 1;
-
- // A list of usage rules that apply to individual API methods.
- //
- // **NOTE:** All service configuration rules follow "last one wins" order.
- repeated UsageRule rules = 6;
-
- // The full resource name of a channel used for sending notifications to the
- // service producer.
- //
- // Google Service Management currently only supports
- // [Google Cloud Pub/Sub](https://cloud.google.com/pubsub) as a notification
- // channel. To use Google Cloud Pub/Sub as the channel, this must be the name
- // of a Cloud Pub/Sub topic that uses the Cloud Pub/Sub topic name format
- // documented in https://cloud.google.com/pubsub/docs/overview.
- string producer_notification_channel = 7;
-}
-
-// Usage configuration rules for the service.
-//
-// NOTE: Under development.
-//
-//
-// Use this rule to configure unregistered calls for the service. Unregistered
-// calls are calls that do not contain consumer project identity.
-// (Example: calls that do not contain an API key).
-// By default, API methods do not allow unregistered calls, and each method call
-// must be identified by a consumer project identity. Use this rule to
-// allow/disallow unregistered calls.
-//
-// Example of an API that wants to allow unregistered calls for entire service.
-//
-// usage:
-// rules:
-// - selector: "*"
-// allow_unregistered_calls: true
-//
-// Example of a method that wants to allow unregistered calls.
-//
-// usage:
-// rules:
-// - selector: "google.example.library.v1.LibraryService.CreateBook"
-// allow_unregistered_calls: true
-message UsageRule {
- // Selects the methods to which this rule applies. Use '*' to indicate all
- // methods in all APIs.
- //
- // Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
- string selector = 1;
-
- // True, if the method allows unregistered calls; false otherwise.
- bool allow_unregistered_calls = 2;
-}
diff --git a/packages/speech/protos/google/longrunning/operations.proto b/packages/speech/protos/google/longrunning/operations.proto
deleted file mode 100644
index 2fb7a31ad7b..00000000000
--- a/packages/speech/protos/google/longrunning/operations.proto
+++ /dev/null
@@ -1,159 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.longrunning;
-
-import "google/api/annotations.proto";
-import "google/protobuf/any.proto";
-import "google/protobuf/empty.proto";
-import "google/rpc/status.proto";
-
-option csharp_namespace = "Google.LongRunning";
-option go_package = "google.golang.org/genproto/googleapis/longrunning;longrunning";
-option java_multiple_files = true;
-option java_outer_classname = "OperationsProto";
-option java_package = "com.google.longrunning";
-
-
-// Manages long-running operations with an API service.
-//
-// When an API method normally takes long time to complete, it can be designed
-// to return [Operation][google.longrunning.Operation] to the client, and the client can use this
-// interface to receive the real response asynchronously by polling the
-// operation resource, or pass the operation resource to another API (such as
-// Google Cloud Pub/Sub API) to receive the response. Any API service that
-// returns long-running operations should implement the `Operations` interface
-// so developers can have a consistent client experience.
-service Operations {
- // Lists operations that match the specified filter in the request. If the
- // server doesn't support this method, it returns `UNIMPLEMENTED`.
- //
- // NOTE: the `name` binding below allows API services to override the binding
- // to use different resource name schemes, such as `users/*/operations`.
- rpc ListOperations(ListOperationsRequest) returns (ListOperationsResponse) {
- option (google.api.http) = { get: "/v1/{name=operations}" };
- }
-
- // Gets the latest state of a long-running operation. Clients can use this
- // method to poll the operation result at intervals as recommended by the API
- // service.
- rpc GetOperation(GetOperationRequest) returns (Operation) {
- option (google.api.http) = { get: "/v1/{name=operations/**}" };
- }
-
- // Deletes a long-running operation. This method indicates that the client is
- // no longer interested in the operation result. It does not cancel the
- // operation. If the server doesn't support this method, it returns
- // `google.rpc.Code.UNIMPLEMENTED`.
- rpc DeleteOperation(DeleteOperationRequest) returns (google.protobuf.Empty) {
- option (google.api.http) = { delete: "/v1/{name=operations/**}" };
- }
-
- // Starts asynchronous cancellation on a long-running operation. The server
- // makes a best effort to cancel the operation, but success is not
- // guaranteed. If the server doesn't support this method, it returns
- // `google.rpc.Code.UNIMPLEMENTED`. Clients can use
- // [Operations.GetOperation][google.longrunning.Operations.GetOperation] or
- // other methods to check whether the cancellation succeeded or whether the
- // operation completed despite cancellation. On successful cancellation,
- // the operation is not deleted; instead, it becomes an operation with
- // an [Operation.error][google.longrunning.Operation.error] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
- // corresponding to `Code.CANCELLED`.
- rpc CancelOperation(CancelOperationRequest) returns (google.protobuf.Empty) {
- option (google.api.http) = { post: "/v1/{name=operations/**}:cancel" body: "*" };
- }
-}
-
-// This resource represents a long-running operation that is the result of a
-// network API call.
-message Operation {
- // The server-assigned name, which is only unique within the same service that
- // originally returns it. If you use the default HTTP mapping, the
- // `name` should have the format of `operations/some/unique/name`.
- string name = 1;
-
- // Service-specific metadata associated with the operation. It typically
- // contains progress information and common metadata such as create time.
- // Some services might not provide such metadata. Any method that returns a
- // long-running operation should document the metadata type, if any.
- google.protobuf.Any metadata = 2;
-
- // If the value is `false`, it means the operation is still in progress.
- // If true, the operation is completed, and either `error` or `response` is
- // available.
- bool done = 3;
-
- // The operation result, which can be either an `error` or a valid `response`.
- // If `done` == `false`, neither `error` nor `response` is set.
- // If `done` == `true`, exactly one of `error` or `response` is set.
- oneof result {
- // The error result of the operation in case of failure or cancellation.
- google.rpc.Status error = 4;
-
- // The normal response of the operation in case of success. If the original
- // method returns no data on success, such as `Delete`, the response is
- // `google.protobuf.Empty`. If the original method is standard
- // `Get`/`Create`/`Update`, the response should be the resource. For other
- // methods, the response should have the type `XxxResponse`, where `Xxx`
- // is the original method name. For example, if the original method name
- // is `TakeSnapshot()`, the inferred response type is
- // `TakeSnapshotResponse`.
- google.protobuf.Any response = 5;
- }
-}
-
-// The request message for [Operations.GetOperation][google.longrunning.Operations.GetOperation].
-message GetOperationRequest {
- // The name of the operation resource.
- string name = 1;
-}
-
-// The request message for [Operations.ListOperations][google.longrunning.Operations.ListOperations].
-message ListOperationsRequest {
- // The name of the operation collection.
- string name = 4;
-
- // The standard list filter.
- string filter = 1;
-
- // The standard list page size.
- int32 page_size = 2;
-
- // The standard list page token.
- string page_token = 3;
-}
-
-// The response message for [Operations.ListOperations][google.longrunning.Operations.ListOperations].
-message ListOperationsResponse {
- // A list of operations that matches the specified filter in the request.
- repeated Operation operations = 1;
-
- // The standard List next-page token.
- string next_page_token = 2;
-}
-
-// The request message for [Operations.CancelOperation][google.longrunning.Operations.CancelOperation].
-message CancelOperationRequest {
- // The name of the operation resource to be cancelled.
- string name = 1;
-}
-
-// The request message for [Operations.DeleteOperation][google.longrunning.Operations.DeleteOperation].
-message DeleteOperationRequest {
- // The name of the operation resource to be deleted.
- string name = 1;
-}
-
diff --git a/packages/speech/protos/google/protobuf/any.proto b/packages/speech/protos/google/protobuf/any.proto
deleted file mode 100644
index 9bd3f50a453..00000000000
--- a/packages/speech/protos/google/protobuf/any.proto
+++ /dev/null
@@ -1,139 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-syntax = "proto3";
-
-package google.protobuf;
-
-option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-option go_package = "github.com/golang/protobuf/ptypes/any";
-option java_package = "com.google.protobuf";
-option java_outer_classname = "AnyProto";
-option java_multiple_files = true;
-option objc_class_prefix = "GPB";
-
-// `Any` contains an arbitrary serialized protocol buffer message along with a
-// URL that describes the type of the serialized message.
-//
-// Protobuf library provides support to pack/unpack Any values in the form
-// of utility functions or additional generated methods of the Any type.
-//
-// Example 1: Pack and unpack a message in C++.
-//
-// Foo foo = ...;
-// Any any;
-// any.PackFrom(foo);
-// ...
-// if (any.UnpackTo(&foo)) {
-// ...
-// }
-//
-// Example 2: Pack and unpack a message in Java.
-//
-// Foo foo = ...;
-// Any any = Any.pack(foo);
-// ...
-// if (any.is(Foo.class)) {
-// foo = any.unpack(Foo.class);
-// }
-//
-// Example 3: Pack and unpack a message in Python.
-//
-// foo = Foo(...)
-// any = Any()
-// any.Pack(foo)
-// ...
-// if any.Is(Foo.DESCRIPTOR):
-// any.Unpack(foo)
-// ...
-//
-// The pack methods provided by protobuf library will by default use
-// 'type.googleapis.com/full.type.name' as the type URL and the unpack
-// methods only use the fully qualified type name after the last '/'
-// in the type URL, for example "foo.bar.com/x/y.z" will yield type
-// name "y.z".
-//
-//
-// JSON
-// ====
-// The JSON representation of an `Any` value uses the regular
-// representation of the deserialized, embedded message, with an
-// additional field `@type` which contains the type URL. Example:
-//
-// package google.profile;
-// message Person {
-// string first_name = 1;
-// string last_name = 2;
-// }
-//
-// {
-// "@type": "type.googleapis.com/google.profile.Person",
-// "firstName": ,
-// "lastName":
-// }
-//
-// If the embedded message type is well-known and has a custom JSON
-// representation, that representation will be embedded adding a field
-// `value` which holds the custom JSON in addition to the `@type`
-// field. Example (for message [google.protobuf.Duration][]):
-//
-// {
-// "@type": "type.googleapis.com/google.protobuf.Duration",
-// "value": "1.212s"
-// }
-//
-message Any {
- // A URL/resource name whose content describes the type of the
- // serialized protocol buffer message.
- //
- // For URLs which use the scheme `http`, `https`, or no scheme, the
- // following restrictions and interpretations apply:
- //
- // * If no scheme is provided, `https` is assumed.
- // * The last segment of the URL's path must represent the fully
- // qualified name of the type (as in `path/google.protobuf.Duration`).
- // The name should be in a canonical form (e.g., leading "." is
- // not accepted).
- // * An HTTP GET on the URL must yield a [google.protobuf.Type][]
- // value in binary format, or produce an error.
- // * Applications are allowed to cache lookup results based on the
- // URL, or have them precompiled into a binary to avoid any
- // lookup. Therefore, binary compatibility needs to be preserved
- // on changes to types. (Use versioned type names to manage
- // breaking changes.)
- //
- // Schemes other than `http`, `https` (or the empty scheme) might be
- // used with implementation specific semantics.
- //
- string type_url = 1;
-
- // Must be a valid serialized protocol buffer of the above specified type.
- bytes value = 2;
-}
diff --git a/packages/speech/protos/google/protobuf/api.proto b/packages/speech/protos/google/protobuf/api.proto
deleted file mode 100644
index 7c30e8b7ad3..00000000000
--- a/packages/speech/protos/google/protobuf/api.proto
+++ /dev/null
@@ -1,202 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-syntax = "proto3";
-
-package google.protobuf;
-
-import "google/protobuf/source_context.proto";
-import "google/protobuf/type.proto";
-
-option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-option java_package = "com.google.protobuf";
-option java_outer_classname = "ApiProto";
-option java_multiple_files = true;
-option objc_class_prefix = "GPB";
-option go_package = "google.golang.org/genproto/protobuf/api;api";
-
-// Api is a light-weight descriptor for a protocol buffer service.
-message Api {
-
- // The fully qualified name of this api, including package name
- // followed by the api's simple name.
- string name = 1;
-
- // The methods of this api, in unspecified order.
- repeated Method methods = 2;
-
- // Any metadata attached to the API.
- repeated Option options = 3;
-
- // A version string for this api. If specified, must have the form
- // `major-version.minor-version`, as in `1.10`. If the minor version
- // is omitted, it defaults to zero. If the entire version field is
- // empty, the major version is derived from the package name, as
- // outlined below. If the field is not empty, the version in the
- // package name will be verified to be consistent with what is
- // provided here.
- //
- // The versioning schema uses [semantic
- // versioning](http://semver.org) where the major version number
- // indicates a breaking change and the minor version an additive,
- // non-breaking change. Both version numbers are signals to users
- // what to expect from different versions, and should be carefully
- // chosen based on the product plan.
- //
- // The major version is also reflected in the package name of the
- // API, which must end in `v`, as in
- // `google.feature.v1`. For major versions 0 and 1, the suffix can
- // be omitted. Zero major versions must only be used for
- // experimental, none-GA apis.
- //
- //
- string version = 4;
-
- // Source context for the protocol buffer service represented by this
- // message.
- SourceContext source_context = 5;
-
- // Included APIs. See [Mixin][].
- repeated Mixin mixins = 6;
-
- // The source syntax of the service.
- Syntax syntax = 7;
-}
-
-// Method represents a method of an api.
-message Method {
-
- // The simple name of this method.
- string name = 1;
-
- // A URL of the input message type.
- string request_type_url = 2;
-
- // If true, the request is streamed.
- bool request_streaming = 3;
-
- // The URL of the output message type.
- string response_type_url = 4;
-
- // If true, the response is streamed.
- bool response_streaming = 5;
-
- // Any metadata attached to the method.
- repeated Option options = 6;
-
- // The source syntax of this method.
- Syntax syntax = 7;
-}
-
-// Declares an API to be included in this API. The including API must
-// redeclare all the methods from the included API, but documentation
-// and options are inherited as follows:
-//
-// - If after comment and whitespace stripping, the documentation
-// string of the redeclared method is empty, it will be inherited
-// from the original method.
-//
-// - Each annotation belonging to the service config (http,
-// visibility) which is not set in the redeclared method will be
-// inherited.
-//
-// - If an http annotation is inherited, the path pattern will be
-// modified as follows. Any version prefix will be replaced by the
-// version of the including API plus the [root][] path if specified.
-//
-// Example of a simple mixin:
-//
-// package google.acl.v1;
-// service AccessControl {
-// // Get the underlying ACL object.
-// rpc GetAcl(GetAclRequest) returns (Acl) {
-// option (google.api.http).get = "/v1/{resource=**}:getAcl";
-// }
-// }
-//
-// package google.storage.v2;
-// service Storage {
-// rpc GetAcl(GetAclRequest) returns (Acl);
-//
-// // Get a data record.
-// rpc GetData(GetDataRequest) returns (Data) {
-// option (google.api.http).get = "/v2/{resource=**}";
-// }
-// }
-//
-// Example of a mixin configuration:
-//
-// apis:
-// - name: google.storage.v2.Storage
-// mixins:
-// - name: google.acl.v1.AccessControl
-//
-// The mixin construct implies that all methods in `AccessControl` are
-// also declared with same name and request/response types in
-// `Storage`. A documentation generator or annotation processor will
-// see the effective `Storage.GetAcl` method after inherting
-// documentation and annotations as follows:
-//
-// service Storage {
-// // Get the underlying ACL object.
-// rpc GetAcl(GetAclRequest) returns (Acl) {
-// option (google.api.http).get = "/v2/{resource=**}:getAcl";
-// }
-// ...
-// }
-//
-// Note how the version in the path pattern changed from `v1` to `v2`.
-//
-// If the `root` field in the mixin is specified, it should be a
-// relative path under which inherited HTTP paths are placed. Example:
-//
-// apis:
-// - name: google.storage.v2.Storage
-// mixins:
-// - name: google.acl.v1.AccessControl
-// root: acls
-//
-// This implies the following inherited HTTP annotation:
-//
-// service Storage {
-// // Get the underlying ACL object.
-// rpc GetAcl(GetAclRequest) returns (Acl) {
-// option (google.api.http).get = "/v2/acls/{resource=**}:getAcl";
-// }
-// ...
-// }
-message Mixin {
- // The fully qualified name of the API which is included.
- string name = 1;
-
- // If non-empty specifies a path under which inherited HTTP paths
- // are rooted.
- string root = 2;
-}
diff --git a/packages/speech/protos/google/protobuf/descriptor.proto b/packages/speech/protos/google/protobuf/descriptor.proto
deleted file mode 100644
index f859c42972f..00000000000
--- a/packages/speech/protos/google/protobuf/descriptor.proto
+++ /dev/null
@@ -1,831 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-// Author: kenton@google.com (Kenton Varda)
-// Based on original Protocol Buffers design by
-// Sanjay Ghemawat, Jeff Dean, and others.
-//
-// The messages in this file describe the definitions found in .proto files.
-// A valid .proto file can be translated directly to a FileDescriptorProto
-// without any other information (e.g. without reading its imports).
-
-
-syntax = "proto2";
-
-package google.protobuf;
-option go_package = "github.com/golang/protobuf/protoc-gen-go/descriptor;descriptor";
-option java_package = "com.google.protobuf";
-option java_outer_classname = "DescriptorProtos";
-option csharp_namespace = "Google.Protobuf.Reflection";
-option objc_class_prefix = "GPB";
-
-// descriptor.proto must be optimized for speed because reflection-based
-// algorithms don't work during bootstrapping.
-option optimize_for = SPEED;
-
-// The protocol compiler can output a FileDescriptorSet containing the .proto
-// files it parses.
-message FileDescriptorSet {
- repeated FileDescriptorProto file = 1;
-}
-
-// Describes a complete .proto file.
-message FileDescriptorProto {
- optional string name = 1; // file name, relative to root of source tree
- optional string package = 2; // e.g. "foo", "foo.bar", etc.
-
- // Names of files imported by this file.
- repeated string dependency = 3;
- // Indexes of the public imported files in the dependency list above.
- repeated int32 public_dependency = 10;
- // Indexes of the weak imported files in the dependency list.
- // For Google-internal migration only. Do not use.
- repeated int32 weak_dependency = 11;
-
- // All top-level definitions in this file.
- repeated DescriptorProto message_type = 4;
- repeated EnumDescriptorProto enum_type = 5;
- repeated ServiceDescriptorProto service = 6;
- repeated FieldDescriptorProto extension = 7;
-
- optional FileOptions options = 8;
-
- // This field contains optional information about the original source code.
- // You may safely remove this entire field without harming runtime
- // functionality of the descriptors -- the information is needed only by
- // development tools.
- optional SourceCodeInfo source_code_info = 9;
-
- // The syntax of the proto file.
- // The supported values are "proto2" and "proto3".
- optional string syntax = 12;
-}
-
-// Describes a message type.
-message DescriptorProto {
- optional string name = 1;
-
- repeated FieldDescriptorProto field = 2;
- repeated FieldDescriptorProto extension = 6;
-
- repeated DescriptorProto nested_type = 3;
- repeated EnumDescriptorProto enum_type = 4;
-
- message ExtensionRange {
- optional int32 start = 1;
- optional int32 end = 2;
- }
- repeated ExtensionRange extension_range = 5;
-
- repeated OneofDescriptorProto oneof_decl = 8;
-
- optional MessageOptions options = 7;
-
- // Range of reserved tag numbers. Reserved tag numbers may not be used by
- // fields or extension ranges in the same message. Reserved ranges may
- // not overlap.
- message ReservedRange {
- optional int32 start = 1; // Inclusive.
- optional int32 end = 2; // Exclusive.
- }
- repeated ReservedRange reserved_range = 9;
- // Reserved field names, which may not be used by fields in the same message.
- // A given name may only be reserved once.
- repeated string reserved_name = 10;
-}
-
-// Describes a field within a message.
-message FieldDescriptorProto {
- enum Type {
- // 0 is reserved for errors.
- // Order is weird for historical reasons.
- TYPE_DOUBLE = 1;
- TYPE_FLOAT = 2;
- // Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT64 if
- // negative values are likely.
- TYPE_INT64 = 3;
- TYPE_UINT64 = 4;
- // Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT32 if
- // negative values are likely.
- TYPE_INT32 = 5;
- TYPE_FIXED64 = 6;
- TYPE_FIXED32 = 7;
- TYPE_BOOL = 8;
- TYPE_STRING = 9;
- // Tag-delimited aggregate.
- // Group type is deprecated and not supported in proto3. However, Proto3
- // implementations should still be able to parse the group wire format and
- // treat group fields as unknown fields.
- TYPE_GROUP = 10;
- TYPE_MESSAGE = 11; // Length-delimited aggregate.
-
- // New in version 2.
- TYPE_BYTES = 12;
- TYPE_UINT32 = 13;
- TYPE_ENUM = 14;
- TYPE_SFIXED32 = 15;
- TYPE_SFIXED64 = 16;
- TYPE_SINT32 = 17; // Uses ZigZag encoding.
- TYPE_SINT64 = 18; // Uses ZigZag encoding.
- };
-
- enum Label {
- // 0 is reserved for errors
- LABEL_OPTIONAL = 1;
- LABEL_REQUIRED = 2;
- LABEL_REPEATED = 3;
- };
-
- optional string name = 1;
- optional int32 number = 3;
- optional Label label = 4;
-
- // If type_name is set, this need not be set. If both this and type_name
- // are set, this must be one of TYPE_ENUM, TYPE_MESSAGE or TYPE_GROUP.
- optional Type type = 5;
-
- // For message and enum types, this is the name of the type. If the name
- // starts with a '.', it is fully-qualified. Otherwise, C++-like scoping
- // rules are used to find the type (i.e. first the nested types within this
- // message are searched, then within the parent, on up to the root
- // namespace).
- optional string type_name = 6;
-
- // For extensions, this is the name of the type being extended. It is
- // resolved in the same manner as type_name.
- optional string extendee = 2;
-
- // For numeric types, contains the original text representation of the value.
- // For booleans, "true" or "false".
- // For strings, contains the default text contents (not escaped in any way).
- // For bytes, contains the C escaped value. All bytes >= 128 are escaped.
- // TODO(kenton): Base-64 encode?
- optional string default_value = 7;
-
- // If set, gives the index of a oneof in the containing type's oneof_decl
- // list. This field is a member of that oneof.
- optional int32 oneof_index = 9;
-
- // JSON name of this field. The value is set by protocol compiler. If the
- // user has set a "json_name" option on this field, that option's value
- // will be used. Otherwise, it's deduced from the field's name by converting
- // it to camelCase.
- optional string json_name = 10;
-
- optional FieldOptions options = 8;
-}
-
-// Describes a oneof.
-message OneofDescriptorProto {
- optional string name = 1;
- optional OneofOptions options = 2;
-}
-
-// Describes an enum type.
-message EnumDescriptorProto {
- optional string name = 1;
-
- repeated EnumValueDescriptorProto value = 2;
-
- optional EnumOptions options = 3;
-}
-
-// Describes a value within an enum.
-message EnumValueDescriptorProto {
- optional string name = 1;
- optional int32 number = 2;
-
- optional EnumValueOptions options = 3;
-}
-
-// Describes a service.
-message ServiceDescriptorProto {
- optional string name = 1;
- repeated MethodDescriptorProto method = 2;
-
- optional ServiceOptions options = 3;
-}
-
-// Describes a method of a service.
-message MethodDescriptorProto {
- optional string name = 1;
-
- // Input and output type names. These are resolved in the same way as
- // FieldDescriptorProto.type_name, but must refer to a message type.
- optional string input_type = 2;
- optional string output_type = 3;
-
- optional MethodOptions options = 4;
-
- // Identifies if client streams multiple client messages
- optional bool client_streaming = 5 [default=false];
- // Identifies if server streams multiple server messages
- optional bool server_streaming = 6 [default=false];
-}
-
-
-// ===================================================================
-// Options
-
-// Each of the definitions above may have "options" attached. These are
-// just annotations which may cause code to be generated slightly differently
-// or may contain hints for code that manipulates protocol messages.
-//
-// Clients may define custom options as extensions of the *Options messages.
-// These extensions may not yet be known at parsing time, so the parser cannot
-// store the values in them. Instead it stores them in a field in the *Options
-// message called uninterpreted_option. This field must have the same name
-// across all *Options messages. We then use this field to populate the
-// extensions when we build a descriptor, at which point all protos have been
-// parsed and so all extensions are known.
-//
-// Extension numbers for custom options may be chosen as follows:
-// * For options which will only be used within a single application or
-// organization, or for experimental options, use field numbers 50000
-// through 99999. It is up to you to ensure that you do not use the
-// same number for multiple options.
-// * For options which will be published and used publicly by multiple
-// independent entities, e-mail protobuf-global-extension-registry@google.com
-// to reserve extension numbers. Simply provide your project name (e.g.
-// Objective-C plugin) and your project website (if available) -- there's no
-// need to explain how you intend to use them. Usually you only need one
-// extension number. You can declare multiple options with only one extension
-// number by putting them in a sub-message. See the Custom Options section of
-// the docs for examples:
-// https://developers.google.com/protocol-buffers/docs/proto#options
-// If this turns out to be popular, a web service will be set up
-// to automatically assign option numbers.
-
-
-message FileOptions {
-
- // Sets the Java package where classes generated from this .proto will be
- // placed. By default, the proto package is used, but this is often
- // inappropriate because proto packages do not normally start with backwards
- // domain names.
- optional string java_package = 1;
-
-
- // If set, all the classes from the .proto file are wrapped in a single
- // outer class with the given name. This applies to both Proto1
- // (equivalent to the old "--one_java_file" option) and Proto2 (where
- // a .proto always translates to a single class, but you may want to
- // explicitly choose the class name).
- optional string java_outer_classname = 8;
-
- // If set true, then the Java code generator will generate a separate .java
- // file for each top-level message, enum, and service defined in the .proto
- // file. Thus, these types will *not* be nested inside the outer class
- // named by java_outer_classname. However, the outer class will still be
- // generated to contain the file's getDescriptor() method as well as any
- // top-level extensions defined in the file.
- optional bool java_multiple_files = 10 [default=false];
-
- // This option does nothing.
- optional bool java_generate_equals_and_hash = 20 [deprecated=true];
-
- // If set true, then the Java2 code generator will generate code that
- // throws an exception whenever an attempt is made to assign a non-UTF-8
- // byte sequence to a string field.
- // Message reflection will do the same.
- // However, an extension field still accepts non-UTF-8 byte sequences.
- // This option has no effect on when used with the lite runtime.
- optional bool java_string_check_utf8 = 27 [default=false];
-
-
- // Generated classes can be optimized for speed or code size.
- enum OptimizeMode {
- SPEED = 1; // Generate complete code for parsing, serialization,
- // etc.
- CODE_SIZE = 2; // Use ReflectionOps to implement these methods.
- LITE_RUNTIME = 3; // Generate code using MessageLite and the lite runtime.
- }
- optional OptimizeMode optimize_for = 9 [default=SPEED];
-
- // Sets the Go package where structs generated from this .proto will be
- // placed. If omitted, the Go package will be derived from the following:
- // - The basename of the package import path, if provided.
- // - Otherwise, the package statement in the .proto file, if present.
- // - Otherwise, the basename of the .proto file, without extension.
- optional string go_package = 11;
-
-
-
- // Should generic services be generated in each language? "Generic" services
- // are not specific to any particular RPC system. They are generated by the
- // main code generators in each language (without additional plugins).
- // Generic services were the only kind of service generation supported by
- // early versions of google.protobuf.
- //
- // Generic services are now considered deprecated in favor of using plugins
- // that generate code specific to your particular RPC system. Therefore,
- // these default to false. Old code which depends on generic services should
- // explicitly set them to true.
- optional bool cc_generic_services = 16 [default=false];
- optional bool java_generic_services = 17 [default=false];
- optional bool py_generic_services = 18 [default=false];
-
- // Is this file deprecated?
- // Depending on the target platform, this can emit Deprecated annotations
- // for everything in the file, or it will be completely ignored; in the very
- // least, this is a formalization for deprecating files.
- optional bool deprecated = 23 [default=false];
-
- // Enables the use of arenas for the proto messages in this file. This applies
- // only to generated classes for C++.
- optional bool cc_enable_arenas = 31 [default=false];
-
-
- // Sets the objective c class prefix which is prepended to all objective c
- // generated classes from this .proto. There is no default.
- optional string objc_class_prefix = 36;
-
- // Namespace for generated classes; defaults to the package.
- optional string csharp_namespace = 37;
-
- // By default Swift generators will take the proto package and CamelCase it
- // replacing '.' with underscore and use that to prefix the types/symbols
- // defined. When this options is provided, they will use this value instead
- // to prefix the types/symbols defined.
- optional string swift_prefix = 39;
-
- // Sets the php class prefix which is prepended to all php generated classes
- // from this .proto. Default is empty.
- optional string php_class_prefix = 40;
-
- // The parser stores options it doesn't recognize here. See above.
- repeated UninterpretedOption uninterpreted_option = 999;
-
- // Clients can define custom options in extensions of this message. See above.
- extensions 1000 to max;
-
- reserved 38;
-}
-
-message MessageOptions {
- // Set true to use the old proto1 MessageSet wire format for extensions.
- // This is provided for backwards-compatibility with the MessageSet wire
- // format. You should not use this for any other reason: It's less
- // efficient, has fewer features, and is more complicated.
- //
- // The message must be defined exactly as follows:
- // message Foo {
- // option message_set_wire_format = true;
- // extensions 4 to max;
- // }
- // Note that the message cannot have any defined fields; MessageSets only
- // have extensions.
- //
- // All extensions of your type must be singular messages; e.g. they cannot
- // be int32s, enums, or repeated messages.
- //
- // Because this is an option, the above two restrictions are not enforced by
- // the protocol compiler.
- optional bool message_set_wire_format = 1 [default=false];
-
- // Disables the generation of the standard "descriptor()" accessor, which can
- // conflict with a field of the same name. This is meant to make migration
- // from proto1 easier; new code should avoid fields named "descriptor".
- optional bool no_standard_descriptor_accessor = 2 [default=false];
-
- // Is this message deprecated?
- // Depending on the target platform, this can emit Deprecated annotations
- // for the message, or it will be completely ignored; in the very least,
- // this is a formalization for deprecating messages.
- optional bool deprecated = 3 [default=false];
-
- // Whether the message is an automatically generated map entry type for the
- // maps field.
- //
- // For maps fields:
- // map map_field = 1;
- // The parsed descriptor looks like:
- // message MapFieldEntry {
- // option map_entry = true;
- // optional KeyType key = 1;
- // optional ValueType value = 2;
- // }
- // repeated MapFieldEntry map_field = 1;
- //
- // Implementations may choose not to generate the map_entry=true message, but
- // use a native map in the target language to hold the keys and values.
- // The reflection APIs in such implementions still need to work as
- // if the field is a repeated message field.
- //
- // NOTE: Do not set the option in .proto files. Always use the maps syntax
- // instead. The option should only be implicitly set by the proto compiler
- // parser.
- optional bool map_entry = 7;
-
- reserved 8; // javalite_serializable
- reserved 9; // javanano_as_lite
-
- // The parser stores options it doesn't recognize here. See above.
- repeated UninterpretedOption uninterpreted_option = 999;
-
- // Clients can define custom options in extensions of this message. See above.
- extensions 1000 to max;
-}
-
-message FieldOptions {
- // The ctype option instructs the C++ code generator to use a different
- // representation of the field than it normally would. See the specific
- // options below. This option is not yet implemented in the open source
- // release -- sorry, we'll try to include it in a future version!
- optional CType ctype = 1 [default = STRING];
- enum CType {
- // Default mode.
- STRING = 0;
-
- CORD = 1;
-
- STRING_PIECE = 2;
- }
- // The packed option can be enabled for repeated primitive fields to enable
- // a more efficient representation on the wire. Rather than repeatedly
- // writing the tag and type for each element, the entire array is encoded as
- // a single length-delimited blob. In proto3, only explicit setting it to
- // false will avoid using packed encoding.
- optional bool packed = 2;
-
- // The jstype option determines the JavaScript type used for values of the
- // field. The option is permitted only for 64 bit integral and fixed types
- // (int64, uint64, sint64, fixed64, sfixed64). By default these types are
- // represented as JavaScript strings. This avoids loss of precision that can
- // happen when a large value is converted to a floating point JavaScript
- // numbers. Specifying JS_NUMBER for the jstype causes the generated
- // JavaScript code to use the JavaScript "number" type instead of strings.
- // This option is an enum to permit additional types to be added,
- // e.g. goog.math.Integer.
- optional JSType jstype = 6 [default = JS_NORMAL];
- enum JSType {
- // Use the default type.
- JS_NORMAL = 0;
-
- // Use JavaScript strings.
- JS_STRING = 1;
-
- // Use JavaScript numbers.
- JS_NUMBER = 2;
- }
-
- // Should this field be parsed lazily? Lazy applies only to message-type
- // fields. It means that when the outer message is initially parsed, the
- // inner message's contents will not be parsed but instead stored in encoded
- // form. The inner message will actually be parsed when it is first accessed.
- //
- // This is only a hint. Implementations are free to choose whether to use
- // eager or lazy parsing regardless of the value of this option. However,
- // setting this option true suggests that the protocol author believes that
- // using lazy parsing on this field is worth the additional bookkeeping
- // overhead typically needed to implement it.
- //
- // This option does not affect the public interface of any generated code;
- // all method signatures remain the same. Furthermore, thread-safety of the
- // interface is not affected by this option; const methods remain safe to
- // call from multiple threads concurrently, while non-const methods continue
- // to require exclusive access.
- //
- //
- // Note that implementations may choose not to check required fields within
- // a lazy sub-message. That is, calling IsInitialized() on the outer message
- // may return true even if the inner message has missing required fields.
- // This is necessary because otherwise the inner message would have to be
- // parsed in order to perform the check, defeating the purpose of lazy
- // parsing. An implementation which chooses not to check required fields
- // must be consistent about it. That is, for any particular sub-message, the
- // implementation must either *always* check its required fields, or *never*
- // check its required fields, regardless of whether or not the message has
- // been parsed.
- optional bool lazy = 5 [default=false];
-
- // Is this field deprecated?
- // Depending on the target platform, this can emit Deprecated annotations
- // for accessors, or it will be completely ignored; in the very least, this
- // is a formalization for deprecating fields.
- optional bool deprecated = 3 [default=false];
-
- // For Google-internal migration only. Do not use.
- optional bool weak = 10 [default=false];
-
-
- // The parser stores options it doesn't recognize here. See above.
- repeated UninterpretedOption uninterpreted_option = 999;
-
- // Clients can define custom options in extensions of this message. See above.
- extensions 1000 to max;
-
- reserved 4; // removed jtype
-}
-
-message OneofOptions {
- // The parser stores options it doesn't recognize here. See above.
- repeated UninterpretedOption uninterpreted_option = 999;
-
- // Clients can define custom options in extensions of this message. See above.
- extensions 1000 to max;
-}
-
-message EnumOptions {
-
- // Set this option to true to allow mapping different tag names to the same
- // value.
- optional bool allow_alias = 2;
-
- // Is this enum deprecated?
- // Depending on the target platform, this can emit Deprecated annotations
- // for the enum, or it will be completely ignored; in the very least, this
- // is a formalization for deprecating enums.
- optional bool deprecated = 3 [default=false];
-
- reserved 5; // javanano_as_lite
-
- // The parser stores options it doesn't recognize here. See above.
- repeated UninterpretedOption uninterpreted_option = 999;
-
- // Clients can define custom options in extensions of this message. See above.
- extensions 1000 to max;
-}
-
-message EnumValueOptions {
- // Is this enum value deprecated?
- // Depending on the target platform, this can emit Deprecated annotations
- // for the enum value, or it will be completely ignored; in the very least,
- // this is a formalization for deprecating enum values.
- optional bool deprecated = 1 [default=false];
-
- // The parser stores options it doesn't recognize here. See above.
- repeated UninterpretedOption uninterpreted_option = 999;
-
- // Clients can define custom options in extensions of this message. See above.
- extensions 1000 to max;
-}
-
-message ServiceOptions {
-
- // Note: Field numbers 1 through 32 are reserved for Google's internal RPC
- // framework. We apologize for hoarding these numbers to ourselves, but
- // we were already using them long before we decided to release Protocol
- // Buffers.
-
- // Is this service deprecated?
- // Depending on the target platform, this can emit Deprecated annotations
- // for the service, or it will be completely ignored; in the very least,
- // this is a formalization for deprecating services.
- optional bool deprecated = 33 [default=false];
-
- // The parser stores options it doesn't recognize here. See above.
- repeated UninterpretedOption uninterpreted_option = 999;
-
- // Clients can define custom options in extensions of this message. See above.
- extensions 1000 to max;
-}
-
-message MethodOptions {
-
- // Note: Field numbers 1 through 32 are reserved for Google's internal RPC
- // framework. We apologize for hoarding these numbers to ourselves, but
- // we were already using them long before we decided to release Protocol
- // Buffers.
-
- // Is this method deprecated?
- // Depending on the target platform, this can emit Deprecated annotations
- // for the method, or it will be completely ignored; in the very least,
- // this is a formalization for deprecating methods.
- optional bool deprecated = 33 [default=false];
-
- // Is this method side-effect-free (or safe in HTTP parlance), or idempotent,
- // or neither? HTTP based RPC implementation may choose GET verb for safe
- // methods, and PUT verb for idempotent methods instead of the default POST.
- enum IdempotencyLevel {
- IDEMPOTENCY_UNKNOWN = 0;
- NO_SIDE_EFFECTS = 1; // implies idempotent
- IDEMPOTENT = 2; // idempotent, but may have side effects
- }
- optional IdempotencyLevel idempotency_level =
- 34 [default=IDEMPOTENCY_UNKNOWN];
-
- // The parser stores options it doesn't recognize here. See above.
- repeated UninterpretedOption uninterpreted_option = 999;
-
- // Clients can define custom options in extensions of this message. See above.
- extensions 1000 to max;
-}
-
-
-// A message representing a option the parser does not recognize. This only
-// appears in options protos created by the compiler::Parser class.
-// DescriptorPool resolves these when building Descriptor objects. Therefore,
-// options protos in descriptor objects (e.g. returned by Descriptor::options(),
-// or produced by Descriptor::CopyTo()) will never have UninterpretedOptions
-// in them.
-message UninterpretedOption {
- // The name of the uninterpreted option. Each string represents a segment in
- // a dot-separated name. is_extension is true iff a segment represents an
- // extension (denoted with parentheses in options specs in .proto files).
- // E.g.,{ ["foo", false], ["bar.baz", true], ["qux", false] } represents
- // "foo.(bar.baz).qux".
- message NamePart {
- required string name_part = 1;
- required bool is_extension = 2;
- }
- repeated NamePart name = 2;
-
- // The value of the uninterpreted option, in whatever type the tokenizer
- // identified it as during parsing. Exactly one of these should be set.
- optional string identifier_value = 3;
- optional uint64 positive_int_value = 4;
- optional int64 negative_int_value = 5;
- optional double double_value = 6;
- optional bytes string_value = 7;
- optional string aggregate_value = 8;
-}
-
-// ===================================================================
-// Optional source code info
-
-// Encapsulates information about the original source file from which a
-// FileDescriptorProto was generated.
-message SourceCodeInfo {
- // A Location identifies a piece of source code in a .proto file which
- // corresponds to a particular definition. This information is intended
- // to be useful to IDEs, code indexers, documentation generators, and similar
- // tools.
- //
- // For example, say we have a file like:
- // message Foo {
- // optional string foo = 1;
- // }
- // Let's look at just the field definition:
- // optional string foo = 1;
- // ^ ^^ ^^ ^ ^^^
- // a bc de f ghi
- // We have the following locations:
- // span path represents
- // [a,i) [ 4, 0, 2, 0 ] The whole field definition.
- // [a,b) [ 4, 0, 2, 0, 4 ] The label (optional).
- // [c,d) [ 4, 0, 2, 0, 5 ] The type (string).
- // [e,f) [ 4, 0, 2, 0, 1 ] The name (foo).
- // [g,h) [ 4, 0, 2, 0, 3 ] The number (1).
- //
- // Notes:
- // - A location may refer to a repeated field itself (i.e. not to any
- // particular index within it). This is used whenever a set of elements are
- // logically enclosed in a single code segment. For example, an entire
- // extend block (possibly containing multiple extension definitions) will
- // have an outer location whose path refers to the "extensions" repeated
- // field without an index.
- // - Multiple locations may have the same path. This happens when a single
- // logical declaration is spread out across multiple places. The most
- // obvious example is the "extend" block again -- there may be multiple
- // extend blocks in the same scope, each of which will have the same path.
- // - A location's span is not always a subset of its parent's span. For
- // example, the "extendee" of an extension declaration appears at the
- // beginning of the "extend" block and is shared by all extensions within
- // the block.
- // - Just because a location's span is a subset of some other location's span
- // does not mean that it is a descendent. For example, a "group" defines
- // both a type and a field in a single declaration. Thus, the locations
- // corresponding to the type and field and their components will overlap.
- // - Code which tries to interpret locations should probably be designed to
- // ignore those that it doesn't understand, as more types of locations could
- // be recorded in the future.
- repeated Location location = 1;
- message Location {
- // Identifies which part of the FileDescriptorProto was defined at this
- // location.
- //
- // Each element is a field number or an index. They form a path from
- // the root FileDescriptorProto to the place where the definition. For
- // example, this path:
- // [ 4, 3, 2, 7, 1 ]
- // refers to:
- // file.message_type(3) // 4, 3
- // .field(7) // 2, 7
- // .name() // 1
- // This is because FileDescriptorProto.message_type has field number 4:
- // repeated DescriptorProto message_type = 4;
- // and DescriptorProto.field has field number 2:
- // repeated FieldDescriptorProto field = 2;
- // and FieldDescriptorProto.name has field number 1:
- // optional string name = 1;
- //
- // Thus, the above path gives the location of a field name. If we removed
- // the last element:
- // [ 4, 3, 2, 7 ]
- // this path refers to the whole field declaration (from the beginning
- // of the label to the terminating semicolon).
- repeated int32 path = 1 [packed=true];
-
- // Always has exactly three or four elements: start line, start column,
- // end line (optional, otherwise assumed same as start line), end column.
- // These are packed into a single field for efficiency. Note that line
- // and column numbers are zero-based -- typically you will want to add
- // 1 to each before displaying to a user.
- repeated int32 span = 2 [packed=true];
-
- // If this SourceCodeInfo represents a complete declaration, these are any
- // comments appearing before and after the declaration which appear to be
- // attached to the declaration.
- //
- // A series of line comments appearing on consecutive lines, with no other
- // tokens appearing on those lines, will be treated as a single comment.
- //
- // leading_detached_comments will keep paragraphs of comments that appear
- // before (but not connected to) the current element. Each paragraph,
- // separated by empty lines, will be one comment element in the repeated
- // field.
- //
- // Only the comment content is provided; comment markers (e.g. //) are
- // stripped out. For block comments, leading whitespace and an asterisk
- // will be stripped from the beginning of each line other than the first.
- // Newlines are included in the output.
- //
- // Examples:
- //
- // optional int32 foo = 1; // Comment attached to foo.
- // // Comment attached to bar.
- // optional int32 bar = 2;
- //
- // optional string baz = 3;
- // // Comment attached to baz.
- // // Another line attached to baz.
- //
- // // Comment attached to qux.
- // //
- // // Another line attached to qux.
- // optional double qux = 4;
- //
- // // Detached comment for corge. This is not leading or trailing comments
- // // to qux or corge because there are blank lines separating it from
- // // both.
- //
- // // Detached comment for corge paragraph 2.
- //
- // optional string corge = 5;
- // /* Block comment attached
- // * to corge. Leading asterisks
- // * will be removed. */
- // /* Block comment attached to
- // * grault. */
- // optional int32 grault = 6;
- //
- // // ignored detached comments.
- optional string leading_comments = 3;
- optional string trailing_comments = 4;
- repeated string leading_detached_comments = 6;
- }
-}
-
-// Describes the relationship between generated code and its original source
-// file. A GeneratedCodeInfo message is associated with only one generated
-// source file, but may contain references to different source .proto files.
-message GeneratedCodeInfo {
- // An Annotation connects some span of text in generated code to an element
- // of its generating .proto file.
- repeated Annotation annotation = 1;
- message Annotation {
- // Identifies the element in the original source .proto file. This field
- // is formatted the same as SourceCodeInfo.Location.path.
- repeated int32 path = 1 [packed=true];
-
- // Identifies the filesystem path to the original source .proto.
- optional string source_file = 2;
-
- // Identifies the starting offset in bytes in the generated code
- // that relates to the identified object.
- optional int32 begin = 3;
-
- // Identifies the ending offset in bytes in the generated code that
- // relates to the identified offset. The end offset should be one past
- // the last relevant byte (so the length of the text = end - begin).
- optional int32 end = 4;
- }
-}
diff --git a/packages/speech/protos/google/protobuf/duration.proto b/packages/speech/protos/google/protobuf/duration.proto
deleted file mode 100644
index 975fce41aae..00000000000
--- a/packages/speech/protos/google/protobuf/duration.proto
+++ /dev/null
@@ -1,117 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-syntax = "proto3";
-
-package google.protobuf;
-
-option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-option cc_enable_arenas = true;
-option go_package = "github.com/golang/protobuf/ptypes/duration";
-option java_package = "com.google.protobuf";
-option java_outer_classname = "DurationProto";
-option java_multiple_files = true;
-option objc_class_prefix = "GPB";
-
-// A Duration represents a signed, fixed-length span of time represented
-// as a count of seconds and fractions of seconds at nanosecond
-// resolution. It is independent of any calendar and concepts like "day"
-// or "month". It is related to Timestamp in that the difference between
-// two Timestamp values is a Duration and it can be added or subtracted
-// from a Timestamp. Range is approximately +-10,000 years.
-//
-// # Examples
-//
-// Example 1: Compute Duration from two Timestamps in pseudo code.
-//
-// Timestamp start = ...;
-// Timestamp end = ...;
-// Duration duration = ...;
-//
-// duration.seconds = end.seconds - start.seconds;
-// duration.nanos = end.nanos - start.nanos;
-//
-// if (duration.seconds < 0 && duration.nanos > 0) {
-// duration.seconds += 1;
-// duration.nanos -= 1000000000;
-// } else if (durations.seconds > 0 && duration.nanos < 0) {
-// duration.seconds -= 1;
-// duration.nanos += 1000000000;
-// }
-//
-// Example 2: Compute Timestamp from Timestamp + Duration in pseudo code.
-//
-// Timestamp start = ...;
-// Duration duration = ...;
-// Timestamp end = ...;
-//
-// end.seconds = start.seconds + duration.seconds;
-// end.nanos = start.nanos + duration.nanos;
-//
-// if (end.nanos < 0) {
-// end.seconds -= 1;
-// end.nanos += 1000000000;
-// } else if (end.nanos >= 1000000000) {
-// end.seconds += 1;
-// end.nanos -= 1000000000;
-// }
-//
-// Example 3: Compute Duration from datetime.timedelta in Python.
-//
-// td = datetime.timedelta(days=3, minutes=10)
-// duration = Duration()
-// duration.FromTimedelta(td)
-//
-// # JSON Mapping
-//
-// In JSON format, the Duration type is encoded as a string rather than an
-// object, where the string ends in the suffix "s" (indicating seconds) and
-// is preceded by the number of seconds, with nanoseconds expressed as
-// fractional seconds. For example, 3 seconds with 0 nanoseconds should be
-// encoded in JSON format as "3s", while 3 seconds and 1 nanosecond should
-// be expressed in JSON format as "3.000000001s", and 3 seconds and 1
-// microsecond should be expressed in JSON format as "3.000001s".
-//
-//
-message Duration {
-
- // Signed seconds of the span of time. Must be from -315,576,000,000
- // to +315,576,000,000 inclusive. Note: these bounds are computed from:
- // 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
- int64 seconds = 1;
-
- // Signed fractions of a second at nanosecond resolution of the span
- // of time. Durations less than one second are represented with a 0
- // `seconds` field and a positive or negative `nanos` field. For durations
- // of one second or more, a non-zero value for the `nanos` field must be
- // of the same sign as the `seconds` field. Must be from -999,999,999
- // to +999,999,999 inclusive.
- int32 nanos = 2;
-}
diff --git a/packages/speech/protos/google/protobuf/empty.proto b/packages/speech/protos/google/protobuf/empty.proto
deleted file mode 100644
index 03cacd23308..00000000000
--- a/packages/speech/protos/google/protobuf/empty.proto
+++ /dev/null
@@ -1,52 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-syntax = "proto3";
-
-package google.protobuf;
-
-option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-option go_package = "github.com/golang/protobuf/ptypes/empty";
-option java_package = "com.google.protobuf";
-option java_outer_classname = "EmptyProto";
-option java_multiple_files = true;
-option objc_class_prefix = "GPB";
-option cc_enable_arenas = true;
-
-// A generic empty message that you can re-use to avoid defining duplicated
-// empty messages in your APIs. A typical example is to use it as the request
-// or the response type of an API method. For instance:
-//
-// service Foo {
-// rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
-// }
-//
-// The JSON representation for `Empty` is empty JSON object `{}`.
-message Empty {}
diff --git a/packages/speech/protos/google/protobuf/field_mask.proto b/packages/speech/protos/google/protobuf/field_mask.proto
deleted file mode 100644
index c68d247c8a4..00000000000
--- a/packages/speech/protos/google/protobuf/field_mask.proto
+++ /dev/null
@@ -1,246 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-syntax = "proto3";
-
-package google.protobuf;
-
-option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-option java_package = "com.google.protobuf";
-option java_outer_classname = "FieldMaskProto";
-option java_multiple_files = true;
-option objc_class_prefix = "GPB";
-option go_package = "google.golang.org/genproto/protobuf/field_mask;field_mask";
-
-// `FieldMask` represents a set of symbolic field paths, for example:
-//
-// paths: "f.a"
-// paths: "f.b.d"
-//
-// Here `f` represents a field in some root message, `a` and `b`
-// fields in the message found in `f`, and `d` a field found in the
-// message in `f.b`.
-//
-// Field masks are used to specify a subset of fields that should be
-// returned by a get operation or modified by an update operation.
-// Field masks also have a custom JSON encoding (see below).
-//
-// # Field Masks in Projections
-//
-// When used in the context of a projection, a response message or
-// sub-message is filtered by the API to only contain those fields as
-// specified in the mask. For example, if the mask in the previous
-// example is applied to a response message as follows:
-//
-// f {
-// a : 22
-// b {
-// d : 1
-// x : 2
-// }
-// y : 13
-// }
-// z: 8
-//
-// The result will not contain specific values for fields x,y and z
-// (their value will be set to the default, and omitted in proto text
-// output):
-//
-//
-// f {
-// a : 22
-// b {
-// d : 1
-// }
-// }
-//
-// A repeated field is not allowed except at the last position of a
-// paths string.
-//
-// If a FieldMask object is not present in a get operation, the
-// operation applies to all fields (as if a FieldMask of all fields
-// had been specified).
-//
-// Note that a field mask does not necessarily apply to the
-// top-level response message. In case of a REST get operation, the
-// field mask applies directly to the response, but in case of a REST
-// list operation, the mask instead applies to each individual message
-// in the returned resource list. In case of a REST custom method,
-// other definitions may be used. Where the mask applies will be
-// clearly documented together with its declaration in the API. In
-// any case, the effect on the returned resource/resources is required
-// behavior for APIs.
-//
-// # Field Masks in Update Operations
-//
-// A field mask in update operations specifies which fields of the
-// targeted resource are going to be updated. The API is required
-// to only change the values of the fields as specified in the mask
-// and leave the others untouched. If a resource is passed in to
-// describe the updated values, the API ignores the values of all
-// fields not covered by the mask.
-//
-// If a repeated field is specified for an update operation, the existing
-// repeated values in the target resource will be overwritten by the new values.
-// Note that a repeated field is only allowed in the last position of a `paths`
-// string.
-//
-// If a sub-message is specified in the last position of the field mask for an
-// update operation, then the existing sub-message in the target resource is
-// overwritten. Given the target message:
-//
-// f {
-// b {
-// d : 1
-// x : 2
-// }
-// c : 1
-// }
-//
-// And an update message:
-//
-// f {
-// b {
-// d : 10
-// }
-// }
-//
-// then if the field mask is:
-//
-// paths: "f.b"
-//
-// then the result will be:
-//
-// f {
-// b {
-// d : 10
-// }
-// c : 1
-// }
-//
-// However, if the update mask was:
-//
-// paths: "f.b.d"
-//
-// then the result would be:
-//
-// f {
-// b {
-// d : 10
-// x : 2
-// }
-// c : 1
-// }
-//
-// In order to reset a field's value to the default, the field must
-// be in the mask and set to the default value in the provided resource.
-// Hence, in order to reset all fields of a resource, provide a default
-// instance of the resource and set all fields in the mask, or do
-// not provide a mask as described below.
-//
-// If a field mask is not present on update, the operation applies to
-// all fields (as if a field mask of all fields has been specified).
-// Note that in the presence of schema evolution, this may mean that
-// fields the client does not know and has therefore not filled into
-// the request will be reset to their default. If this is unwanted
-// behavior, a specific service may require a client to always specify
-// a field mask, producing an error if not.
-//
-// As with get operations, the location of the resource which
-// describes the updated values in the request message depends on the
-// operation kind. In any case, the effect of the field mask is
-// required to be honored by the API.
-//
-// ## Considerations for HTTP REST
-//
-// The HTTP kind of an update operation which uses a field mask must
-// be set to PATCH instead of PUT in order to satisfy HTTP semantics
-// (PUT must only be used for full updates).
-//
-// # JSON Encoding of Field Masks
-//
-// In JSON, a field mask is encoded as a single string where paths are
-// separated by a comma. Fields name in each path are converted
-// to/from lower-camel naming conventions.
-//
-// As an example, consider the following message declarations:
-//
-// message Profile {
-// User user = 1;
-// Photo photo = 2;
-// }
-// message User {
-// string display_name = 1;
-// string address = 2;
-// }
-//
-// In proto a field mask for `Profile` may look as such:
-//
-// mask {
-// paths: "user.display_name"
-// paths: "photo"
-// }
-//
-// In JSON, the same mask is represented as below:
-//
-// {
-// mask: "user.displayName,photo"
-// }
-//
-// # Field Masks and Oneof Fields
-//
-// Field masks treat fields in oneofs just as regular fields. Consider the
-// following message:
-//
-// message SampleMessage {
-// oneof test_oneof {
-// string name = 4;
-// SubMessage sub_message = 9;
-// }
-// }
-//
-// The field mask can be:
-//
-// mask {
-// paths: "name"
-// }
-//
-// Or:
-//
-// mask {
-// paths: "sub_message"
-// }
-//
-// Note that oneof type names ("test_oneof" in this case) cannot be used in
-// paths.
-message FieldMask {
- // The set of field mask paths.
- repeated string paths = 1;
-}
diff --git a/packages/speech/protos/google/protobuf/source_context.proto b/packages/speech/protos/google/protobuf/source_context.proto
deleted file mode 100644
index f3b2c966811..00000000000
--- a/packages/speech/protos/google/protobuf/source_context.proto
+++ /dev/null
@@ -1,48 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-syntax = "proto3";
-
-package google.protobuf;
-
-option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-option java_package = "com.google.protobuf";
-option java_outer_classname = "SourceContextProto";
-option java_multiple_files = true;
-option objc_class_prefix = "GPB";
-option go_package = "google.golang.org/genproto/protobuf/source_context;source_context";
-
-// `SourceContext` represents information about the source of a
-// protobuf element, like the file in which it is defined.
-message SourceContext {
- // The path-qualified name of the .proto file that contained the associated
- // protobuf element. For example: `"google/protobuf/source_context.proto"`.
- string file_name = 1;
-}
diff --git a/packages/speech/protos/google/protobuf/struct.proto b/packages/speech/protos/google/protobuf/struct.proto
deleted file mode 100644
index 7d7808e7fbb..00000000000
--- a/packages/speech/protos/google/protobuf/struct.proto
+++ /dev/null
@@ -1,96 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-syntax = "proto3";
-
-package google.protobuf;
-
-option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-option cc_enable_arenas = true;
-option go_package = "github.com/golang/protobuf/ptypes/struct;structpb";
-option java_package = "com.google.protobuf";
-option java_outer_classname = "StructProto";
-option java_multiple_files = true;
-option objc_class_prefix = "GPB";
-
-
-// `Struct` represents a structured data value, consisting of fields
-// which map to dynamically typed values. In some languages, `Struct`
-// might be supported by a native representation. For example, in
-// scripting languages like JS a struct is represented as an
-// object. The details of that representation are described together
-// with the proto support for the language.
-//
-// The JSON representation for `Struct` is JSON object.
-message Struct {
- // Unordered map of dynamically typed values.
- map fields = 1;
-}
-
-// `Value` represents a dynamically typed value which can be either
-// null, a number, a string, a boolean, a recursive struct value, or a
-// list of values. A producer of value is expected to set one of that
-// variants, absence of any variant indicates an error.
-//
-// The JSON representation for `Value` is JSON value.
-message Value {
- // The kind of value.
- oneof kind {
- // Represents a null value.
- NullValue null_value = 1;
- // Represents a double value.
- double number_value = 2;
- // Represents a string value.
- string string_value = 3;
- // Represents a boolean value.
- bool bool_value = 4;
- // Represents a structured value.
- Struct struct_value = 5;
- // Represents a repeated `Value`.
- ListValue list_value = 6;
- }
-}
-
-// `NullValue` is a singleton enumeration to represent the null value for the
-// `Value` type union.
-//
-// The JSON representation for `NullValue` is JSON `null`.
-enum NullValue {
- // Null value.
- NULL_VALUE = 0;
-}
-
-// `ListValue` is a wrapper around a repeated field of values.
-//
-// The JSON representation for `ListValue` is JSON array.
-message ListValue {
- // Repeated field of dynamically typed values.
- repeated Value values = 1;
-}
diff --git a/packages/speech/protos/google/protobuf/timestamp.proto b/packages/speech/protos/google/protobuf/timestamp.proto
deleted file mode 100644
index b7cbd17502f..00000000000
--- a/packages/speech/protos/google/protobuf/timestamp.proto
+++ /dev/null
@@ -1,133 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-syntax = "proto3";
-
-package google.protobuf;
-
-option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-option cc_enable_arenas = true;
-option go_package = "github.com/golang/protobuf/ptypes/timestamp";
-option java_package = "com.google.protobuf";
-option java_outer_classname = "TimestampProto";
-option java_multiple_files = true;
-option objc_class_prefix = "GPB";
-
-// A Timestamp represents a point in time independent of any time zone
-// or calendar, represented as seconds and fractions of seconds at
-// nanosecond resolution in UTC Epoch time. It is encoded using the
-// Proleptic Gregorian Calendar which extends the Gregorian calendar
-// backwards to year one. It is encoded assuming all minutes are 60
-// seconds long, i.e. leap seconds are "smeared" so that no leap second
-// table is needed for interpretation. Range is from
-// 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z.
-// By restricting to that range, we ensure that we can convert to
-// and from RFC 3339 date strings.
-// See [https://www.ietf.org/rfc/rfc3339.txt](https://www.ietf.org/rfc/rfc3339.txt).
-//
-// # Examples
-//
-// Example 1: Compute Timestamp from POSIX `time()`.
-//
-// Timestamp timestamp;
-// timestamp.set_seconds(time(NULL));
-// timestamp.set_nanos(0);
-//
-// Example 2: Compute Timestamp from POSIX `gettimeofday()`.
-//
-// struct timeval tv;
-// gettimeofday(&tv, NULL);
-//
-// Timestamp timestamp;
-// timestamp.set_seconds(tv.tv_sec);
-// timestamp.set_nanos(tv.tv_usec * 1000);
-//
-// Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`.
-//
-// FILETIME ft;
-// GetSystemTimeAsFileTime(&ft);
-// UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime;
-//
-// // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z
-// // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z.
-// Timestamp timestamp;
-// timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL));
-// timestamp.set_nanos((INT32) ((ticks % 10000000) * 100));
-//
-// Example 4: Compute Timestamp from Java `System.currentTimeMillis()`.
-//
-// long millis = System.currentTimeMillis();
-//
-// Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000)
-// .setNanos((int) ((millis % 1000) * 1000000)).build();
-//
-//
-// Example 5: Compute Timestamp from current time in Python.
-//
-// timestamp = Timestamp()
-// timestamp.GetCurrentTime()
-//
-// # JSON Mapping
-//
-// In JSON format, the Timestamp type is encoded as a string in the
-// [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the
-// format is "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z"
-// where {year} is always expressed using four digits while {month}, {day},
-// {hour}, {min}, and {sec} are zero-padded to two digits each. The fractional
-// seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution),
-// are optional. The "Z" suffix indicates the timezone ("UTC"); the timezone
-// is required, though only UTC (as indicated by "Z") is presently supported.
-//
-// For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past
-// 01:30 UTC on January 15, 2017.
-//
-// In JavaScript, one can convert a Date object to this format using the
-// standard [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString]
-// method. In Python, a standard `datetime.datetime` object can be converted
-// to this format using [`strftime`](https://docs.python.org/2/library/time.html#time.strftime)
-// with the time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one
-// can use the Joda Time's [`ISODateTimeFormat.dateTime()`](
-// http://joda-time.sourceforge.net/apidocs/org/joda/time/format/ISODateTimeFormat.html#dateTime())
-// to obtain a formatter capable of generating timestamps in this format.
-//
-//
-message Timestamp {
-
- // Represents seconds of UTC time since Unix epoch
- // 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to
- // 9999-12-31T23:59:59Z inclusive.
- int64 seconds = 1;
-
- // Non-negative fractions of a second at nanosecond resolution. Negative
- // second values with fractions must still have non-negative nanos values
- // that count forward in time. Must be from 0 to 999,999,999
- // inclusive.
- int32 nanos = 2;
-}
diff --git a/packages/speech/protos/google/protobuf/type.proto b/packages/speech/protos/google/protobuf/type.proto
deleted file mode 100644
index 624c15ee616..00000000000
--- a/packages/speech/protos/google/protobuf/type.proto
+++ /dev/null
@@ -1,187 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-syntax = "proto3";
-
-package google.protobuf;
-
-import "google/protobuf/any.proto";
-import "google/protobuf/source_context.proto";
-
-option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-option cc_enable_arenas = true;
-option java_package = "com.google.protobuf";
-option java_outer_classname = "TypeProto";
-option java_multiple_files = true;
-option objc_class_prefix = "GPB";
-option go_package = "google.golang.org/genproto/protobuf/ptype;ptype";
-
-// A protocol buffer message type.
-message Type {
- // The fully qualified message name.
- string name = 1;
- // The list of fields.
- repeated Field fields = 2;
- // The list of types appearing in `oneof` definitions in this type.
- repeated string oneofs = 3;
- // The protocol buffer options.
- repeated Option options = 4;
- // The source context.
- SourceContext source_context = 5;
- // The source syntax.
- Syntax syntax = 6;
-}
-
-// A single field of a message type.
-message Field {
- // Basic field types.
- enum Kind {
- // Field type unknown.
- TYPE_UNKNOWN = 0;
- // Field type double.
- TYPE_DOUBLE = 1;
- // Field type float.
- TYPE_FLOAT = 2;
- // Field type int64.
- TYPE_INT64 = 3;
- // Field type uint64.
- TYPE_UINT64 = 4;
- // Field type int32.
- TYPE_INT32 = 5;
- // Field type fixed64.
- TYPE_FIXED64 = 6;
- // Field type fixed32.
- TYPE_FIXED32 = 7;
- // Field type bool.
- TYPE_BOOL = 8;
- // Field type string.
- TYPE_STRING = 9;
- // Field type group. Proto2 syntax only, and deprecated.
- TYPE_GROUP = 10;
- // Field type message.
- TYPE_MESSAGE = 11;
- // Field type bytes.
- TYPE_BYTES = 12;
- // Field type uint32.
- TYPE_UINT32 = 13;
- // Field type enum.
- TYPE_ENUM = 14;
- // Field type sfixed32.
- TYPE_SFIXED32 = 15;
- // Field type sfixed64.
- TYPE_SFIXED64 = 16;
- // Field type sint32.
- TYPE_SINT32 = 17;
- // Field type sint64.
- TYPE_SINT64 = 18;
- };
-
- // Whether a field is optional, required, or repeated.
- enum Cardinality {
- // For fields with unknown cardinality.
- CARDINALITY_UNKNOWN = 0;
- // For optional fields.
- CARDINALITY_OPTIONAL = 1;
- // For required fields. Proto2 syntax only.
- CARDINALITY_REQUIRED = 2;
- // For repeated fields.
- CARDINALITY_REPEATED = 3;
- };
-
- // The field type.
- Kind kind = 1;
- // The field cardinality.
- Cardinality cardinality = 2;
- // The field number.
- int32 number = 3;
- // The field name.
- string name = 4;
- // The field type URL, without the scheme, for message or enumeration
- // types. Example: `"type.googleapis.com/google.protobuf.Timestamp"`.
- string type_url = 6;
- // The index of the field type in `Type.oneofs`, for message or enumeration
- // types. The first type has index 1; zero means the type is not in the list.
- int32 oneof_index = 7;
- // Whether to use alternative packed wire representation.
- bool packed = 8;
- // The protocol buffer options.
- repeated Option options = 9;
- // The field JSON name.
- string json_name = 10;
- // The string value of the default value of this field. Proto2 syntax only.
- string default_value = 11;
-}
-
-// Enum type definition.
-message Enum {
- // Enum type name.
- string name = 1;
- // Enum value definitions.
- repeated EnumValue enumvalue = 2;
- // Protocol buffer options.
- repeated Option options = 3;
- // The source context.
- SourceContext source_context = 4;
- // The source syntax.
- Syntax syntax = 5;
-}
-
-// Enum value definition.
-message EnumValue {
- // Enum value name.
- string name = 1;
- // Enum value number.
- int32 number = 2;
- // Protocol buffer options.
- repeated Option options = 3;
-}
-
-// A protocol buffer option, which can be attached to a message, field,
-// enumeration, etc.
-message Option {
- // The option's name. For protobuf built-in options (options defined in
- // descriptor.proto), this is the short name. For example, `"map_entry"`.
- // For custom options, it should be the fully-qualified name. For example,
- // `"google.api.http"`.
- string name = 1;
- // The option's value packed in an Any message. If the value is a primitive,
- // the corresponding wrapper type defined in google/protobuf/wrappers.proto
- // should be used. If the value is an enum, it should be stored as an int32
- // value using the google.protobuf.Int32Value type.
- Any value = 2;
-}
-
-// The syntax in which a protocol buffer element is defined.
-enum Syntax {
- // Syntax `proto2`.
- SYNTAX_PROTO2 = 0;
- // Syntax `proto3`.
- SYNTAX_PROTO3 = 1;
-}
diff --git a/packages/speech/protos/google/protobuf/util/json_format_proto3.proto b/packages/speech/protos/google/protobuf/util/json_format_proto3.proto
deleted file mode 100644
index 8a0441c8f64..00000000000
--- a/packages/speech/protos/google/protobuf/util/json_format_proto3.proto
+++ /dev/null
@@ -1,183 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-syntax = "proto3";
-
-package proto3;
-
-option java_package = "com.google.protobuf.util";
-option java_outer_classname = "JsonFormatProto3";
-
-import "google/protobuf/duration.proto";
-import "google/protobuf/timestamp.proto";
-import "google/protobuf/wrappers.proto";
-import "google/protobuf/struct.proto";
-import "google/protobuf/any.proto";
-import "google/protobuf/field_mask.proto";
-import "google/protobuf/unittest.proto";
-
-enum EnumType {
- FOO = 0;
- BAR = 1;
-}
-
-message MessageType {
- int32 value = 1;
-}
-
-message TestMessage {
- bool bool_value = 1;
- int32 int32_value = 2;
- int64 int64_value = 3;
- uint32 uint32_value = 4;
- uint64 uint64_value = 5;
- float float_value = 6;
- double double_value = 7;
- string string_value = 8;
- bytes bytes_value = 9;
- EnumType enum_value = 10;
- MessageType message_value = 11;
-
- repeated bool repeated_bool_value = 21;
- repeated int32 repeated_int32_value = 22;
- repeated int64 repeated_int64_value = 23;
- repeated uint32 repeated_uint32_value = 24;
- repeated uint64 repeated_uint64_value = 25;
- repeated float repeated_float_value = 26;
- repeated double repeated_double_value = 27;
- repeated string repeated_string_value = 28;
- repeated bytes repeated_bytes_value = 29;
- repeated EnumType repeated_enum_value = 30;
- repeated MessageType repeated_message_value = 31;
-}
-
-message TestOneof {
- // In JSON format oneof fields behave mostly the same as optional
- // fields except that:
- // 1. Oneof fields have field presence information and will be
- // printed if it's set no matter whether it's the default value.
- // 2. Multiple oneof fields in the same oneof cannot appear at the
- // same time in the input.
- oneof oneof_value {
- int32 oneof_int32_value = 1;
- string oneof_string_value = 2;
- bytes oneof_bytes_value = 3;
- EnumType oneof_enum_value = 4;
- MessageType oneof_message_value = 5;
- }
-}
-
-message TestMap {
- map bool_map = 1;
- map int32_map = 2;
- map int64_map = 3;
- map uint32_map = 4;
- map uint64_map = 5;
- map string_map = 6;
-}
-
-message TestNestedMap {
- map bool_map = 1;
- map int32_map = 2;
- map int64_map = 3;
- map uint32_map = 4;
- map uint64_map = 5;
- map string_map = 6;
- map map_map = 7;
-}
-
-message TestWrapper {
- google.protobuf.BoolValue bool_value = 1;
- google.protobuf.Int32Value int32_value = 2;
- google.protobuf.Int64Value int64_value = 3;
- google.protobuf.UInt32Value uint32_value = 4;
- google.protobuf.UInt64Value uint64_value = 5;
- google.protobuf.FloatValue float_value = 6;
- google.protobuf.DoubleValue double_value = 7;
- google.protobuf.StringValue string_value = 8;
- google.protobuf.BytesValue bytes_value = 9;
-
- repeated google.protobuf.BoolValue repeated_bool_value = 11;
- repeated google.protobuf.Int32Value repeated_int32_value = 12;
- repeated google.protobuf.Int64Value repeated_int64_value = 13;
- repeated google.protobuf.UInt32Value repeated_uint32_value = 14;
- repeated google.protobuf.UInt64Value repeated_uint64_value = 15;
- repeated google.protobuf.FloatValue repeated_float_value = 16;
- repeated google.protobuf.DoubleValue repeated_double_value = 17;
- repeated google.protobuf.StringValue repeated_string_value = 18;
- repeated google.protobuf.BytesValue repeated_bytes_value = 19;
-}
-
-message TestTimestamp {
- google.protobuf.Timestamp value = 1;
- repeated google.protobuf.Timestamp repeated_value = 2;
-}
-
-message TestDuration {
- google.protobuf.Duration value = 1;
- repeated google.protobuf.Duration repeated_value = 2;
-}
-
-message TestFieldMask {
- google.protobuf.FieldMask value = 1;
-}
-
-message TestStruct {
- google.protobuf.Struct value = 1;
- repeated google.protobuf.Struct repeated_value = 2;
-}
-
-message TestAny {
- google.protobuf.Any value = 1;
- repeated google.protobuf.Any repeated_value = 2;
-}
-
-message TestValue {
- google.protobuf.Value value = 1;
- repeated google.protobuf.Value repeated_value = 2;
-}
-
-message TestListValue {
- google.protobuf.ListValue value = 1;
- repeated google.protobuf.ListValue repeated_value = 2;
-}
-
-message TestBoolValue {
- bool bool_value = 1;
- map bool_map = 2;
-}
-
-message TestCustomJsonName {
- int32 value = 1 [json_name = "@value"];
-}
-
-message TestExtensions {
- .protobuf_unittest.TestAllExtensions extensions = 1;
-}
diff --git a/packages/speech/protos/google/protobuf/wrappers.proto b/packages/speech/protos/google/protobuf/wrappers.proto
deleted file mode 100644
index 01947639ac4..00000000000
--- a/packages/speech/protos/google/protobuf/wrappers.proto
+++ /dev/null
@@ -1,118 +0,0 @@
-// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-// Wrappers for primitive (non-message) types. These types are useful
-// for embedding primitives in the `google.protobuf.Any` type and for places
-// where we need to distinguish between the absence of a primitive
-// typed field and its default value.
-
-syntax = "proto3";
-
-package google.protobuf;
-
-option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-option cc_enable_arenas = true;
-option go_package = "github.com/golang/protobuf/ptypes/wrappers";
-option java_package = "com.google.protobuf";
-option java_outer_classname = "WrappersProto";
-option java_multiple_files = true;
-option objc_class_prefix = "GPB";
-
-// Wrapper message for `double`.
-//
-// The JSON representation for `DoubleValue` is JSON number.
-message DoubleValue {
- // The double value.
- double value = 1;
-}
-
-// Wrapper message for `float`.
-//
-// The JSON representation for `FloatValue` is JSON number.
-message FloatValue {
- // The float value.
- float value = 1;
-}
-
-// Wrapper message for `int64`.
-//
-// The JSON representation for `Int64Value` is JSON string.
-message Int64Value {
- // The int64 value.
- int64 value = 1;
-}
-
-// Wrapper message for `uint64`.
-//
-// The JSON representation for `UInt64Value` is JSON string.
-message UInt64Value {
- // The uint64 value.
- uint64 value = 1;
-}
-
-// Wrapper message for `int32`.
-//
-// The JSON representation for `Int32Value` is JSON number.
-message Int32Value {
- // The int32 value.
- int32 value = 1;
-}
-
-// Wrapper message for `uint32`.
-//
-// The JSON representation for `UInt32Value` is JSON number.
-message UInt32Value {
- // The uint32 value.
- uint32 value = 1;
-}
-
-// Wrapper message for `bool`.
-//
-// The JSON representation for `BoolValue` is JSON `true` and `false`.
-message BoolValue {
- // The bool value.
- bool value = 1;
-}
-
-// Wrapper message for `string`.
-//
-// The JSON representation for `StringValue` is JSON string.
-message StringValue {
- // The string value.
- string value = 1;
-}
-
-// Wrapper message for `bytes`.
-//
-// The JSON representation for `BytesValue` is JSON string.
-message BytesValue {
- // The bytes value.
- bytes value = 1;
-}
diff --git a/packages/speech/protos/google/rpc/code.proto b/packages/speech/protos/google/rpc/code.proto
deleted file mode 100644
index 9a450956a27..00000000000
--- a/packages/speech/protos/google/rpc/code.proto
+++ /dev/null
@@ -1,180 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.rpc;
-
-option go_package = "google.golang.org/genproto/googleapis/rpc/code;code";
-option java_multiple_files = true;
-option java_outer_classname = "CodeProto";
-option java_package = "com.google.rpc";
-option objc_class_prefix = "RPC";
-
-
-// The canonical error codes for Google APIs.
-//
-//
-// Sometimes multiple error codes may apply. Services should return
-// the most specific error code that applies. For example, prefer
-// `OUT_OF_RANGE` over `FAILED_PRECONDITION` if both codes apply.
-// Similarly prefer `NOT_FOUND` or `ALREADY_EXISTS` over `FAILED_PRECONDITION`.
-enum Code {
- // Not an error; returned on success
- //
- // HTTP Mapping: 200 OK
- OK = 0;
-
- // The operation was cancelled, typically by the caller.
- //
- // HTTP Mapping: 499 Client Closed Request
- CANCELLED = 1;
-
- // Unknown error. For example, this error may be returned when
- // a `Status` value received from another address space belongs to
- // an error space that is not known in this address space. Also
- // errors raised by APIs that do not return enough error information
- // may be converted to this error.
- //
- // HTTP Mapping: 500 Internal Server Error
- UNKNOWN = 2;
-
- // The client specified an invalid argument. Note that this differs
- // from `FAILED_PRECONDITION`. `INVALID_ARGUMENT` indicates arguments
- // that are problematic regardless of the state of the system
- // (e.g., a malformed file name).
- //
- // HTTP Mapping: 400 Bad Request
- INVALID_ARGUMENT = 3;
-
- // The deadline expired before the operation could complete. For operations
- // that change the state of the system, this error may be returned
- // even if the operation has completed successfully. For example, a
- // successful response from a server could have been delayed long
- // enough for the deadline to expire.
- //
- // HTTP Mapping: 504 Gateway Timeout
- DEADLINE_EXCEEDED = 4;
-
- // Some requested entity (e.g., file or directory) was not found.
- // For privacy reasons, this code *may* be returned when the client
- // does not have the access rights to the entity, though such usage is
- // discouraged.
- //
- // HTTP Mapping: 404 Not Found
- NOT_FOUND = 5;
-
- // The entity that a client attempted to create (e.g., file or directory)
- // already exists.
- //
- // HTTP Mapping: 409 Conflict
- ALREADY_EXISTS = 6;
-
- // The caller does not have permission to execute the specified
- // operation. `PERMISSION_DENIED` must not be used for rejections
- // caused by exhausting some resource (use `RESOURCE_EXHAUSTED`
- // instead for those errors). `PERMISSION_DENIED` must not be
- // used if the caller can not be identified (use `UNAUTHENTICATED`
- // instead for those errors).
- //
- // HTTP Mapping: 403 Forbidden
- PERMISSION_DENIED = 7;
-
- // The request does not have valid authentication credentials for the
- // operation.
- //
- // HTTP Mapping: 401 Unauthorized
- UNAUTHENTICATED = 16;
-
- // Some resource has been exhausted, perhaps a per-user quota, or
- // perhaps the entire file system is out of space.
- //
- // HTTP Mapping: 429 Too Many Requests
- RESOURCE_EXHAUSTED = 8;
-
- // The operation was rejected because the system is not in a state
- // required for the operation's execution. For example, the directory
- // to be deleted is non-empty, an rmdir operation is applied to
- // a non-directory, etc.
- //
- // Service implementors can use the following guidelines to decide
- // between `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`:
- // (a) Use `UNAVAILABLE` if the client can retry just the failing call.
- // (b) Use `ABORTED` if the client should retry at a higher level
- // (e.g., restarting a read-modify-write sequence).
- // (c) Use `FAILED_PRECONDITION` if the client should not retry until
- // the system state has been explicitly fixed. E.g., if an "rmdir"
- // fails because the directory is non-empty, `FAILED_PRECONDITION`
- // should be returned since the client should not retry unless
- // the files are deleted from the directory.
- //
- // HTTP Mapping: 400 Bad Request
- FAILED_PRECONDITION = 9;
-
- // The operation was aborted, typically due to a concurrency issue such as
- // a sequencer check failure or transaction abort.
- //
- // See the guidelines above for deciding between `FAILED_PRECONDITION`,
- // `ABORTED`, and `UNAVAILABLE`.
- //
- // HTTP Mapping: 409 Conflict
- ABORTED = 10;
-
- // The operation was attempted past the valid range. E.g., seeking or
- // reading past end-of-file.
- //
- // Unlike `INVALID_ARGUMENT`, this error indicates a problem that may
- // be fixed if the system state changes. For example, a 32-bit file
- // system will generate `INVALID_ARGUMENT` if asked to read at an
- // offset that is not in the range [0,2^32-1], but it will generate
- // `OUT_OF_RANGE` if asked to read from an offset past the current
- // file size.
- //
- // There is a fair bit of overlap between `FAILED_PRECONDITION` and
- // `OUT_OF_RANGE`. We recommend using `OUT_OF_RANGE` (the more specific
- // error) when it applies so that callers who are iterating through
- // a space can easily look for an `OUT_OF_RANGE` error to detect when
- // they are done.
- //
- // HTTP Mapping: 400 Bad Request
- OUT_OF_RANGE = 11;
-
- // The operation is not implemented or is not supported/enabled in this
- // service.
- //
- // HTTP Mapping: 501 Not Implemented
- UNIMPLEMENTED = 12;
-
- // Internal errors. This means that some invariants expected by the
- // underlying system have been broken. This error code is reserved
- // for serious errors.
- //
- // HTTP Mapping: 500 Internal Server Error
- INTERNAL = 13;
-
- // The service is currently unavailable. This is most likely a
- // transient condition, which can be corrected by retrying with
- // a backoff.
- //
- // See the guidelines above for deciding between `FAILED_PRECONDITION`,
- // `ABORTED`, and `UNAVAILABLE`.
- //
- // HTTP Mapping: 503 Service Unavailable
- UNAVAILABLE = 14;
-
- // Unrecoverable data loss or corruption.
- //
- // HTTP Mapping: 500 Internal Server Error
- DATA_LOSS = 15;
-}
diff --git a/packages/speech/protos/google/rpc/error_details.proto b/packages/speech/protos/google/rpc/error_details.proto
deleted file mode 100644
index 4732d421d99..00000000000
--- a/packages/speech/protos/google/rpc/error_details.proto
+++ /dev/null
@@ -1,171 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.rpc;
-
-import "google/protobuf/duration.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/rpc/errdetails;errdetails";
-option java_multiple_files = true;
-option java_outer_classname = "ErrorDetailsProto";
-option java_package = "com.google.rpc";
-option objc_class_prefix = "RPC";
-
-
-// Describes when the clients can retry a failed request. Clients could ignore
-// the recommendation here or retry when this information is missing from error
-// responses.
-//
-// It's always recommended that clients should use exponential backoff when
-// retrying.
-//
-// Clients should wait until `retry_delay` amount of time has passed since
-// receiving the error response before retrying. If retrying requests also
-// fail, clients should use an exponential backoff scheme to gradually increase
-// the delay between retries based on `retry_delay`, until either a maximum
-// number of retires have been reached or a maximum retry delay cap has been
-// reached.
-message RetryInfo {
- // Clients should wait at least this long between retrying the same request.
- google.protobuf.Duration retry_delay = 1;
-}
-
-// Describes additional debugging info.
-message DebugInfo {
- // The stack trace entries indicating where the error occurred.
- repeated string stack_entries = 1;
-
- // Additional debugging information provided by the server.
- string detail = 2;
-}
-
-// Describes how a quota check failed.
-//
-// For example if a daily limit was exceeded for the calling project,
-// a service could respond with a QuotaFailure detail containing the project
-// id and the description of the quota limit that was exceeded. If the
-// calling project hasn't enabled the service in the developer console, then
-// a service could respond with the project id and set `service_disabled`
-// to true.
-//
-// Also see RetryDetail and Help types for other details about handling a
-// quota failure.
-message QuotaFailure {
- // A message type used to describe a single quota violation. For example, a
- // daily quota or a custom quota that was exceeded.
- message Violation {
- // The subject on which the quota check failed.
- // For example, "clientip:" or "project:".
- string subject = 1;
-
- // A description of how the quota check failed. Clients can use this
- // description to find more about the quota configuration in the service's
- // public documentation, or find the relevant quota limit to adjust through
- // developer console.
- //
- // For example: "Service disabled" or "Daily Limit for read operations
- // exceeded".
- string description = 2;
- }
-
- // Describes all quota violations.
- repeated Violation violations = 1;
-}
-
-// Describes violations in a client request. This error type focuses on the
-// syntactic aspects of the request.
-message BadRequest {
- // A message type used to describe a single bad request field.
- message FieldViolation {
- // A path leading to a field in the request body. The value will be a
- // sequence of dot-separated identifiers that identify a protocol buffer
- // field. E.g., "field_violations.field" would identify this field.
- string field = 1;
-
- // A description of why the request element is bad.
- string description = 2;
- }
-
- // Describes all violations in a client request.
- repeated FieldViolation field_violations = 1;
-}
-
-// Contains metadata about the request that clients can attach when filing a bug
-// or providing other forms of feedback.
-message RequestInfo {
- // An opaque string that should only be interpreted by the service generating
- // it. For example, it can be used to identify requests in the service's logs.
- string request_id = 1;
-
- // Any data that was used to serve this request. For example, an encrypted
- // stack trace that can be sent back to the service provider for debugging.
- string serving_data = 2;
-}
-
-// Describes the resource that is being accessed.
-message ResourceInfo {
- // A name for the type of resource being accessed, e.g. "sql table",
- // "cloud storage bucket", "file", "Google calendar"; or the type URL
- // of the resource: e.g. "type.googleapis.com/google.pubsub.v1.Topic".
- string resource_type = 1;
-
- // The name of the resource being accessed. For example, a shared calendar
- // name: "example.com_4fghdhgsrgh@group.calendar.google.com", if the current
- // error is [google.rpc.Code.PERMISSION_DENIED][google.rpc.Code.PERMISSION_DENIED].
- string resource_name = 2;
-
- // The owner of the resource (optional).
- // For example, "user:" or "project:".
- string owner = 3;
-
- // Describes what error is encountered when accessing this resource.
- // For example, updating a cloud project may require the `writer` permission
- // on the developer console project.
- string description = 4;
-}
-
-// Provides links to documentation or for performing an out of band action.
-//
-// For example, if a quota check failed with an error indicating the calling
-// project hasn't enabled the accessed service, this can contain a URL pointing
-// directly to the right place in the developer console to flip the bit.
-message Help {
- // Describes a URL link.
- message Link {
- // Describes what the link offers.
- string description = 1;
-
- // The URL of the link.
- string url = 2;
- }
-
- // URL(s) pointing to additional information on handling the current error.
- repeated Link links = 1;
-}
-
-// Provides a localized error message that is safe to return to the user
-// which can be attached to an RPC error.
-message LocalizedMessage {
- // The locale used following the specification defined at
- // http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
- // Examples are: "en-US", "fr-CH", "es-MX"
- string locale = 1;
-
- // The localized error message in the above locale.
- string message = 2;
-}
diff --git a/packages/speech/protos/google/rpc/status.proto b/packages/speech/protos/google/rpc/status.proto
deleted file mode 100644
index bc6097b29fb..00000000000
--- a/packages/speech/protos/google/rpc/status.proto
+++ /dev/null
@@ -1,92 +0,0 @@
-// Copyright 2016 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-syntax = "proto3";
-
-package google.rpc;
-
-import "google/protobuf/any.proto";
-
-option go_package = "google.golang.org/genproto/googleapis/rpc/status;status";
-option java_multiple_files = true;
-option java_outer_classname = "StatusProto";
-option java_package = "com.google.rpc";
-option objc_class_prefix = "RPC";
-
-
-// The `Status` type defines a logical error model that is suitable for different
-// programming environments, including REST APIs and RPC APIs. It is used by
-// [gRPC](https://github.com/grpc). The error model is designed to be:
-//
-// - Simple to use and understand for most users
-// - Flexible enough to meet unexpected needs
-//
-// # Overview
-//
-// The `Status` message contains three pieces of data: error code, error message,
-// and error details. The error code should be an enum value of
-// [google.rpc.Code][google.rpc.Code], but it may accept additional error codes if needed. The
-// error message should be a developer-facing English message that helps
-// developers *understand* and *resolve* the error. If a localized user-facing
-// error message is needed, put the localized message in the error details or
-// localize it in the client. The optional error details may contain arbitrary
-// information about the error. There is a predefined set of error detail types
-// in the package `google.rpc` which can be used for common error conditions.
-//
-// # Language mapping
-//
-// The `Status` message is the logical representation of the error model, but it
-// is not necessarily the actual wire format. When the `Status` message is
-// exposed in different client libraries and different wire protocols, it can be
-// mapped differently. For example, it will likely be mapped to some exceptions
-// in Java, but more likely mapped to some error codes in C.
-//
-// # Other uses
-//
-// The error model and the `Status` message can be used in a variety of
-// environments, either with or without APIs, to provide a
-// consistent developer experience across different environments.
-//
-// Example uses of this error model include:
-//
-// - Partial errors. If a service needs to return partial errors to the client,
-// it may embed the `Status` in the normal response to indicate the partial
-// errors.
-//
-// - Workflow errors. A typical workflow has multiple steps. Each step may
-// have a `Status` message for error reporting purpose.
-//
-// - Batch operations. If a client uses batch request and batch response, the
-// `Status` message should be used directly inside batch response, one for
-// each error sub-response.
-//
-// - Asynchronous operations. If an API call embeds asynchronous operation
-// results in its response, the status of those operations should be
-// represented directly using the `Status` message.
-//
-// - Logging. If some API errors are stored in logs, the message `Status` could
-// be used directly after any stripping needed for security/privacy reasons.
-message Status {
- // The status code, which should be an enum value of [google.rpc.Code][google.rpc.Code].
- int32 code = 1;
-
- // A developer-facing error message, which should be in English. Any
- // user-facing error message should be localized and sent in the
- // [google.rpc.Status.details][google.rpc.Status.details] field, or localized by the client.
- string message = 2;
-
- // A list of messages that carry the error details. There will be a
- // common set of message types for APIs to use.
- repeated google.protobuf.Any details = 3;
-}
diff --git a/packages/speech/smoke-test/speech_smoke_test.js b/packages/speech/smoke-test/speech_smoke_test.js
deleted file mode 100644
index 7477fbaaa1b..00000000000
--- a/packages/speech/smoke-test/speech_smoke_test.js
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright 2017, Google Inc. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-'use strict';
-
-describe('SpeechSmokeTest', function() {
-
- it('successfully makes a call to the service', function(done) {
- var speech = require('../src');
-
- var client = speech.v1({
- // optional auth parameters.
- });
-
- var languageCode = 'en-US';
- var sampleRateHertz = 44100;
- var encoding = speech.v1.types.RecognitionConfig.AudioEncoding.FLAC;
- var config = {
- languageCode : languageCode,
- sampleRateHertz : sampleRateHertz,
- encoding : encoding
- };
- var uri = 'gs://gapic-toolkit/hello.flac';
- var audio = {
- uri : uri
- };
- var request = {
- config: config,
- audio: audio
- };
- client.recognize(request).then(function(responses) {
- var response = responses[0];
- console.log(response);
- })
- .then(done)
- .catch(done);
- });
-});
\ No newline at end of file
diff --git a/packages/speech/src/helpers.js b/packages/speech/src/helpers.js
deleted file mode 100644
index 6f81ef2dfe1..00000000000
--- a/packages/speech/src/helpers.js
+++ /dev/null
@@ -1,122 +0,0 @@
-/*!
- * Copyright 2017 Google Inc. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*!
- * @module speech/helpers
- */
-
-'use strict';
-
-var pumpify = require('pumpify');
-var streamEvents = require('stream-events');
-var through = require('through2');
-
-/*!
- * Return a dictionary-like object with helpers to augment the Speech
- * GAPIC.
- *
- * @return {Object} - An object with keys and functions which are placed
- * onto the pure GAPIC.
- */
-module.exports = () => {
- var methods = {};
-
- /**
- * Performs bidirectional streaming speech recognition: receive results while
- * sending audio. This method is only available via the gRPC API (not REST).
- *
- * @param {Object} config
- * The configuration for the stream. This is appropriately wrapped and
- * sent as the first argument. It should be an object conforming to the
- * [StreamingRecognitionConfig]{@link StreamingRecognitionConfig}
- * structure.
- * @param {Object=} options
- * Optional parameters. You can override the default settings for this
- * call, e.g, timeout, retries, paginations, etc. See
- * [gax.CallOptions]{@link https://googleapis.github.io/gax-nodejs/global.html#CallOptions}
- * for the details.
- * @returns {Stream}
- * An object stream which is both readable and writable. It accepts
- * raw audio for the write() method, and will emit objects representing
- * [StreamingRecognizeResponse]{@link StreamingRecognizeResponse} on the
- * 'data' event asynchronously.
- *
- * @example
- *
- * var stream = speech.streamingRecognize({
- * config: {
- * encoding: 'LINEAR16',
- * languageCode: 'en-us',
- * sampleRateHertz: 44100,
- * },
- * }).on('data', function(response) {
- * // doThingsWith(response);
- * });
- * var request = {};
- * // Write request objects.
- * stream.write(request);
- */
- methods.streamingRecognize = function(config, options) {
- if (options === undefined) {
- options = {};
- }
-
- var requestStream = this._streamingRecognize(options);
-
- // Format the audio content as input request for pipeline
- var recognizeStream = streamEvents(pumpify.obj());
-
- // Attach the events to the request stream, but only do so
- // when the first write (of data) comes in.
- //
- // This also means that the sending of the initial request (with the
- // config) is delayed until we get the first burst of data.
- recognizeStream.once('writing', () => {
- requestStream.on('error', err => {
- recognizeStream.destroy(err);
- });
-
- // Responses must be explicitly forwarded.
- requestStream.on('response', response => {
- recognizeStream.emit('response', response);
- });
-
- // Write the initial configuration to the stream.
- requestStream.write({
- streamingConfig: config
- });
-
- // Set up appropriate piping between the stream returned by
- // the underlying API method and the one that we return.
- recognizeStream.setPipeline([
- // Format the user's input.
- // This entails that the user sends raw audio; it is wrapped in
- // the appropriate request structure.
- through.obj((obj, _, next) => {
- next(null, {
- audioContent: obj
- });
- }),
- requestStream,
- through.obj()
- ]);
- });
-
- return recognizeStream;
- };
-
- return methods;
-};
diff --git a/packages/speech/src/index.js b/packages/speech/src/index.js
deleted file mode 100644
index d55e6a74498..00000000000
--- a/packages/speech/src/index.js
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright 2017, Google Inc. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*!
- * @module speech
- * @name Speech
- */
-
-'use strict';
-
-var extend = require('extend');
-var gapic = {
- v1: require('./v1')
-};
-var gaxGrpc = require('google-gax').grpc();
-var helpers = require('./helpers');
-
-const VERSION = require('../package.json').version;
-
-/**
- * Create an speechClient with additional helpers for common
- * tasks.
- *
- * Service that implements Google Cloud Speech API.
- *
- * @constructor
- * @alias module:speech
- * @mixes module:speech/helpers
- *
- * @param {object=} options - [Configuration object](#/docs).
- * @param {number=} options.port - The port on which to connect to
- * the remote host.
- * @param {string=} options.servicePath - The domain name of the
- * API remote host.
- */
-function speechV1(options) {
- // Define the header options.
- options = extend({}, options, {
- libName: 'gccl',
- libVersion: VERSION
- });
-
- // Create the speech client with the provided options.
- var client = gapic.v1(options).speechClient(options);
- Object.assign(client.constructor.prototype, helpers());
- return client;
-}
-
-var v1Protos = {};
-
-extend(v1Protos, gaxGrpc.load([{
- root: require('google-proto-files')('..'),
- file: 'google/cloud/speech/v1/cloud_speech.proto'
-}]).google.cloud.speech.v1);
-
-module.exports = speechV1;
-module.exports.types = v1Protos;
-module.exports.v1 = speechV1;
-module.exports.v1.types = v1Protos;
diff --git a/packages/speech/src/v1/doc/doc_cloud_speech.js b/packages/speech/src/v1/doc/doc_cloud_speech.js
deleted file mode 100644
index 0438652ccb2..00000000000
--- a/packages/speech/src/v1/doc/doc_cloud_speech.js
+++ /dev/null
@@ -1,534 +0,0 @@
-/*
- * Copyright 2017, Google Inc. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*
- * Note: this file is purely for documentation. Any contents are not expected
- * to be loaded as the JS file.
- */
-
-/**
- * The top-level message sent by the client for the `Recognize` method.
- *
- * @property {Object} config
- * *Required* Provides information to the recognizer that specifies how to
- * process the request.
- *
- * This object should have the same structure as [RecognitionConfig]{@link RecognitionConfig}
- *
- * @property {Object} audio
- * *Required* The audio data to be recognized.
- *
- * This object should have the same structure as [RecognitionAudio]{@link RecognitionAudio}
- *
- * @class
- * @see [google.cloud.speech.v1.RecognizeRequest definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var RecognizeRequest = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
-
-/**
- * The top-level message sent by the client for the `LongRunningRecognize`
- * method.
- *
- * @property {Object} config
- * *Required* Provides information to the recognizer that specifies how to
- * process the request.
- *
- * This object should have the same structure as [RecognitionConfig]{@link RecognitionConfig}
- *
- * @property {Object} audio
- * *Required* The audio data to be recognized.
- *
- * This object should have the same structure as [RecognitionAudio]{@link RecognitionAudio}
- *
- * @class
- * @see [google.cloud.speech.v1.LongRunningRecognizeRequest definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var LongRunningRecognizeRequest = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
-
-/**
- * The top-level message sent by the client for the `StreamingRecognize` method.
- * Multiple `StreamingRecognizeRequest` messages are sent. The first message
- * must contain a `streaming_config` message and must not contain `audio` data.
- * All subsequent messages must contain `audio` data and must not contain a
- * `streaming_config` message.
- *
- * @property {Object} streamingConfig
- * Provides information to the recognizer that specifies how to process the
- * request. The first `StreamingRecognizeRequest` message must contain a
- * `streaming_config` message.
- *
- * This object should have the same structure as [StreamingRecognitionConfig]{@link StreamingRecognitionConfig}
- *
- * @property {string} audioContent
- * The audio data to be recognized. Sequential chunks of audio data are sent
- * in sequential `StreamingRecognizeRequest` messages. The first
- * `StreamingRecognizeRequest` message must not contain `audio_content` data
- * and all subsequent `StreamingRecognizeRequest` messages must contain
- * `audio_content` data. The audio bytes must be encoded as specified in
- * `RecognitionConfig`. Note: as with all bytes fields, protobuffers use a
- * pure binary representation (not base64). See
- * [audio limits](https://cloud.google.com/speech/limits#content).
- *
- * @class
- * @see [google.cloud.speech.v1.StreamingRecognizeRequest definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var StreamingRecognizeRequest = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
-
-/**
- * Provides information to the recognizer that specifies how to process the
- * request.
- *
- * @property {Object} config
- * *Required* Provides information to the recognizer that specifies how to
- * process the request.
- *
- * This object should have the same structure as [RecognitionConfig]{@link RecognitionConfig}
- *
- * @property {boolean} singleUtterance
- * *Optional* If `false` or omitted, the recognizer will perform continuous
- * recognition (continuing to wait for and process audio even if the user
- * pauses speaking) until the client closes the input stream (gRPC API) or
- * until the maximum time limit has been reached. May return multiple
- * `StreamingRecognitionResult`s with the `is_final` flag set to `true`.
- *
- * If `true`, the recognizer will detect a single spoken utterance. When it
- * detects that the user has paused or stopped speaking, it will return an
- * `END_OF_SINGLE_UTTERANCE` event and cease recognition. It will return no
- * more than one `StreamingRecognitionResult` with the `is_final` flag set to
- * `true`.
- *
- * @property {boolean} interimResults
- * *Optional* If `true`, interim results (tentative hypotheses) may be
- * returned as they become available (these interim results are indicated with
- * the `is_final=false` flag).
- * If `false` or omitted, only `is_final=true` result(s) are returned.
- *
- * @class
- * @see [google.cloud.speech.v1.StreamingRecognitionConfig definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var StreamingRecognitionConfig = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
-
-/**
- * Provides information to the recognizer that specifies how to process the
- * request.
- *
- * @property {number} encoding
- * *Required* Encoding of audio data sent in all `RecognitionAudio` messages.
- *
- * The number should be among the values of [AudioEncoding]{@link AudioEncoding}
- *
- * @property {number} sampleRateHertz
- * *Required* Sample rate in Hertz of the audio data sent in all
- * `RecognitionAudio` messages. Valid values are: 8000-48000.
- * 16000 is optimal. For best results, set the sampling rate of the audio
- * source to 16000 Hz. If that's not possible, use the native sample rate of
- * the audio source (instead of re-sampling).
- *
- * @property {string} languageCode
- * *Required* The language of the supplied audio as a
- * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag.
- * Example: "en-US".
- * See [Language Support](https://cloud.google.com/speech/docs/languages)
- * for a list of the currently supported language codes.
- *
- * @property {number} maxAlternatives
- * *Optional* Maximum number of recognition hypotheses to be returned.
- * Specifically, the maximum number of `SpeechRecognitionAlternative` messages
- * within each `SpeechRecognitionResult`.
- * The server may return fewer than `max_alternatives`.
- * Valid values are `0`-`30`. A value of `0` or `1` will return a maximum of
- * one. If omitted, will return a maximum of one.
- *
- * @property {boolean} profanityFilter
- * *Optional* If set to `true`, the server will attempt to filter out
- * profanities, replacing all but the initial character in each filtered word
- * with asterisks, e.g. "f***". If set to `false` or omitted, profanities
- * won't be filtered out.
- *
- * @property {Object[]} speechContexts
- * *Optional* A means to provide context to assist the speech recognition.
- *
- * This object should have the same structure as [SpeechContext]{@link SpeechContext}
- *
- * @class
- * @see [google.cloud.speech.v1.RecognitionConfig definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var RecognitionConfig = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-
- /**
- * Audio encoding of the data sent in the audio message. All encodings support
- * only 1 channel (mono) audio. Only `FLAC` includes a header that describes
- * the bytes of audio that follow the header. The other encodings are raw
- * audio bytes with no header.
- *
- * For best results, the audio source should be captured and transmitted using
- * a lossless encoding (`FLAC` or `LINEAR16`). Recognition accuracy may be
- * reduced if lossy codecs, which include the other codecs listed in
- * this section, are used to capture or transmit the audio, particularly if
- * background noise is present.
- *
- * @enum {number}
- */
- AudioEncoding: {
-
- /**
- * Not specified. Will return result {@link google.rpc.Code.INVALID_ARGUMENT}.
- */
- ENCODING_UNSPECIFIED: 0,
-
- /**
- * Uncompressed 16-bit signed little-endian samples (Linear PCM).
- */
- LINEAR16: 1,
-
- /**
- * [`FLAC`](https://xiph.org/flac/documentation.html) (Free Lossless Audio
- * Codec) is the recommended encoding because it is
- * lossless--therefore recognition is not compromised--and
- * requires only about half the bandwidth of `LINEAR16`. `FLAC` stream
- * encoding supports 16-bit and 24-bit samples, however, not all fields in
- * `STREAMINFO` are supported.
- */
- FLAC: 2,
-
- /**
- * 8-bit samples that compand 14-bit audio samples using G.711 PCMU/mu-law.
- */
- MULAW: 3,
-
- /**
- * Adaptive Multi-Rate Narrowband codec. `sample_rate_hertz` must be 8000.
- */
- AMR: 4,
-
- /**
- * Adaptive Multi-Rate Wideband codec. `sample_rate_hertz` must be 16000.
- */
- AMR_WB: 5,
-
- /**
- * Opus encoded audio frames in Ogg container
- * ([OggOpus](https://wiki.xiph.org/OggOpus)).
- * `sample_rate_hertz` must be 16000.
- */
- OGG_OPUS: 6,
-
- /**
- * Although the use of lossy encodings is not recommended, if a very low
- * bitrate encoding is required, `OGG_OPUS` is highly preferred over
- * Speex encoding. The [Speex](https://speex.org/) encoding supported by
- * Cloud Speech API has a header byte in each block, as in MIME type
- * `audio/x-speex-with-header-byte`.
- * It is a variant of the RTP Speex encoding defined in
- * [RFC 5574](https://tools.ietf.org/html/rfc5574).
- * The stream is a sequence of blocks, one block per RTP packet. Each block
- * starts with a byte containing the length of the block, in bytes, followed
- * by one or more frames of Speex data, padded to an integral number of
- * bytes (octets) as specified in RFC 5574. In other words, each RTP header
- * is replaced with a single byte containing the block length. Only Speex
- * wideband is supported. `sample_rate_hertz` must be 16000.
- */
- SPEEX_WITH_HEADER_BYTE: 7
- }
-};
-
-/**
- * Provides "hints" to the speech recognizer to favor specific words and phrases
- * in the results.
- *
- * @property {string[]} phrases
- * *Optional* A list of strings containing words and phrases "hints" so that
- * the speech recognition is more likely to recognize them. This can be used
- * to improve the accuracy for specific words and phrases, for example, if
- * specific commands are typically spoken by the user. This can also be used
- * to add additional words to the vocabulary of the recognizer. See
- * [usage limits](https://cloud.google.com/speech/limits#content).
- *
- * @class
- * @see [google.cloud.speech.v1.SpeechContext definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var SpeechContext = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
-
-/**
- * Contains audio data in the encoding specified in the `RecognitionConfig`.
- * Either `content` or `uri` must be supplied. Supplying both or neither
- * returns {@link google.rpc.Code.INVALID_ARGUMENT}. See
- * [audio limits](https://cloud.google.com/speech/limits#content).
- *
- * @property {string} content
- * The audio data bytes encoded as specified in
- * `RecognitionConfig`. Note: as with all bytes fields, protobuffers use a
- * pure binary representation, whereas JSON representations use base64.
- *
- * @property {string} uri
- * URI that points to a file that contains audio data bytes as specified in
- * `RecognitionConfig`. Currently, only Google Cloud Storage URIs are
- * supported, which must be specified in the following format:
- * `gs://bucket_name/object_name` (other URI formats return
- * {@link google.rpc.Code.INVALID_ARGUMENT}). For more information, see
- * [Request URIs](https://cloud.google.com/storage/docs/reference-uris).
- *
- * @class
- * @see [google.cloud.speech.v1.RecognitionAudio definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var RecognitionAudio = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
-
-/**
- * The only message returned to the client by the `Recognize` method. It
- * contains the result as zero or more sequential `SpeechRecognitionResult`
- * messages.
- *
- * @property {Object[]} results
- * *Output-only* Sequential list of transcription results corresponding to
- * sequential portions of audio.
- *
- * This object should have the same structure as [SpeechRecognitionResult]{@link SpeechRecognitionResult}
- *
- * @class
- * @see [google.cloud.speech.v1.RecognizeResponse definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var RecognizeResponse = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
-
-/**
- * The only message returned to the client by the `LongRunningRecognize` method.
- * It contains the result as zero or more sequential `SpeechRecognitionResult`
- * messages. It is included in the `result.response` field of the `Operation`
- * returned by the `GetOperation` call of the `google::longrunning::Operations`
- * service.
- *
- * @property {Object[]} results
- * *Output-only* Sequential list of transcription results corresponding to
- * sequential portions of audio.
- *
- * This object should have the same structure as [SpeechRecognitionResult]{@link SpeechRecognitionResult}
- *
- * @class
- * @see [google.cloud.speech.v1.LongRunningRecognizeResponse definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var LongRunningRecognizeResponse = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
-
-/**
- * Describes the progress of a long-running `LongRunningRecognize` call. It is
- * included in the `metadata` field of the `Operation` returned by the
- * `GetOperation` call of the `google::longrunning::Operations` service.
- *
- * @property {number} progressPercent
- * Approximate percentage of audio processed thus far. Guaranteed to be 100
- * when the audio is fully processed and the results are available.
- *
- * @property {Object} startTime
- * Time when the request was received.
- *
- * This object should have the same structure as [google.protobuf.Timestamp]{@link external:"google.protobuf.Timestamp"}
- *
- * @property {Object} lastUpdateTime
- * Time of the most recent processing update.
- *
- * This object should have the same structure as [google.protobuf.Timestamp]{@link external:"google.protobuf.Timestamp"}
- *
- * @class
- * @see [google.cloud.speech.v1.LongRunningRecognizeMetadata definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var LongRunningRecognizeMetadata = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
-
-/**
- * `StreamingRecognizeResponse` is the only message returned to the client by
- * `StreamingRecognize`. A series of one or more `StreamingRecognizeResponse`
- * messages are streamed back to the client.
- *
- * Here's an example of a series of ten `StreamingRecognizeResponse`s that might
- * be returned while processing audio:
- *
- * 1. results { alternatives { transcript: "tube" } stability: 0.01 }
- *
- * 2. results { alternatives { transcript: "to be a" } stability: 0.01 }
- *
- * 3. results { alternatives { transcript: "to be" } stability: 0.9 }
- * results { alternatives { transcript: " or not to be" } stability: 0.01 }
- *
- * 4. results { alternatives { transcript: "to be or not to be"
- * confidence: 0.92 }
- * alternatives { transcript: "to bee or not to bee" }
- * is_final: true }
- *
- * 5. results { alternatives { transcript: " that's" } stability: 0.01 }
- *
- * 6. results { alternatives { transcript: " that is" } stability: 0.9 }
- * results { alternatives { transcript: " the question" } stability: 0.01 }
- *
- * 7. speech_event_type: END_OF_SINGLE_UTTERANCE
- *
- * 8. results { alternatives { transcript: " that is the question"
- * confidence: 0.98 }
- * alternatives { transcript: " that was the question" }
- * is_final: true }
- *
- * Notes:
- *
- * - Only two of the above responses #4 and #8 contain final results; they are
- * indicated by `is_final: true`. Concatenating these together generates the
- * full transcript: "to be or not to be that is the question".
- *
- * - The others contain interim `results`. #3 and #6 contain two interim
- * `results`: the first portion has a high stability and is less likely to
- * change; the second portion has a low stability and is very likely to
- * change. A UI designer might choose to show only high stability `results`.
- *
- * - The specific `stability` and `confidence` values shown above are only for
- * illustrative purposes. Actual values may vary.
- *
- * - In each response, only one of these fields will be set:
- * `error`,
- * `speech_event_type`, or
- * one or more (repeated) `results`.
- *
- * @property {Object} error
- * *Output-only* If set, returns a {@link google.rpc.Status} message that
- * specifies the error for the operation.
- *
- * This object should have the same structure as [google.rpc.Status]{@link external:"google.rpc.Status"}
- *
- * @property {Object[]} results
- * *Output-only* This repeated list contains zero or more results that
- * correspond to consecutive portions of the audio currently being processed.
- * It contains zero or one `is_final=true` result (the newly settled portion),
- * followed by zero or more `is_final=false` results.
- *
- * This object should have the same structure as [StreamingRecognitionResult]{@link StreamingRecognitionResult}
- *
- * @property {number} speechEventType
- * *Output-only* Indicates the type of speech event.
- *
- * The number should be among the values of [SpeechEventType]{@link SpeechEventType}
- *
- * @class
- * @see [google.cloud.speech.v1.StreamingRecognizeResponse definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var StreamingRecognizeResponse = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-
- /**
- * Indicates the type of speech event.
- *
- * @enum {number}
- */
- SpeechEventType: {
-
- /**
- * No speech event specified.
- */
- SPEECH_EVENT_UNSPECIFIED: 0,
-
- /**
- * This event indicates that the server has detected the end of the user's
- * speech utterance and expects no additional speech. Therefore, the server
- * will not process additional audio (although it may subsequently return
- * additional results). The client should stop sending additional audio
- * data, half-close the gRPC connection, and wait for any additional results
- * until the server closes the gRPC connection. This event is only sent if
- * `single_utterance` was set to `true`, and is not used otherwise.
- */
- END_OF_SINGLE_UTTERANCE: 1
- }
-};
-
-/**
- * A streaming speech recognition result corresponding to a portion of the audio
- * that is currently being processed.
- *
- * @property {Object[]} alternatives
- * *Output-only* May contain one or more recognition hypotheses (up to the
- * maximum specified in `max_alternatives`).
- *
- * This object should have the same structure as [SpeechRecognitionAlternative]{@link SpeechRecognitionAlternative}
- *
- * @property {boolean} isFinal
- * *Output-only* If `false`, this `StreamingRecognitionResult` represents an
- * interim result that may change. If `true`, this is the final time the
- * speech service will return this particular `StreamingRecognitionResult`,
- * the recognizer will not return any further hypotheses for this portion of
- * the transcript and corresponding audio.
- *
- * @property {number} stability
- * *Output-only* An estimate of the likelihood that the recognizer will not
- * change its guess about this interim result. Values range from 0.0
- * (completely unstable) to 1.0 (completely stable).
- * This field is only provided for interim results (`is_final=false`).
- * The default of 0.0 is a sentinel value indicating `stability` was not set.
- *
- * @class
- * @see [google.cloud.speech.v1.StreamingRecognitionResult definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var StreamingRecognitionResult = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
-
-/**
- * A speech recognition result corresponding to a portion of the audio.
- *
- * @property {Object[]} alternatives
- * *Output-only* May contain one or more recognition hypotheses (up to the
- * maximum specified in `max_alternatives`).
- *
- * This object should have the same structure as [SpeechRecognitionAlternative]{@link SpeechRecognitionAlternative}
- *
- * @class
- * @see [google.cloud.speech.v1.SpeechRecognitionResult definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var SpeechRecognitionResult = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
-
-/**
- * Alternative hypotheses (a.k.a. n-best list).
- *
- * @property {string} transcript
- * *Output-only* Transcript text representing the words that the user spoke.
- *
- * @property {number} confidence
- * *Output-only* The confidence estimate between 0.0 and 1.0. A higher number
- * indicates an estimated greater likelihood that the recognized words are
- * correct. This field is typically provided only for the top hypothesis, and
- * only for `is_final=true` results. Clients should not rely on the
- * `confidence` field as it is not guaranteed to be accurate, or even set, in
- * any of the results.
- * The default of 0.0 is a sentinel value indicating `confidence` was not set.
- *
- * @class
- * @see [google.cloud.speech.v1.SpeechRecognitionAlternative definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
- */
-var SpeechRecognitionAlternative = {
- // This is for documentation. Actual contents will be loaded by gRPC.
-};
\ No newline at end of file
diff --git a/packages/speech/src/v1/doc/doc_google_protobuf_any.js b/packages/speech/src/v1/doc/doc_google_protobuf_any.js
deleted file mode 100644
index 0697ec15814..00000000000
--- a/packages/speech/src/v1/doc/doc_google_protobuf_any.js
+++ /dev/null
@@ -1,121 +0,0 @@
-/*
- * Copyright 2017, Google Inc. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*
- * Note: this file is purely for documentation. Any contents are not expected
- * to be loaded as the JS file.
- */
-
-/**
- * `Any` contains an arbitrary serialized protocol buffer message along with a
- * URL that describes the type of the serialized message.
- *
- * Protobuf library provides support to pack/unpack Any values in the form
- * of utility functions or additional generated methods of the Any type.
- *
- * Example 1: Pack and unpack a message in C++.
- *
- * Foo foo = ...;
- * Any any;
- * any.PackFrom(foo);
- * ...
- * if (any.UnpackTo(&foo)) {
- * ...
- * }
- *
- * Example 2: Pack and unpack a message in Java.
- *
- * Foo foo = ...;
- * Any any = Any.pack(foo);
- * ...
- * if (any.is(Foo.class)) {
- * foo = any.unpack(Foo.class);
- * }
- *
- * Example 3: Pack and unpack a message in Python.
- *
- * foo = Foo(...)
- * any = Any()
- * any.Pack(foo)
- * ...
- * if any.Is(Foo.DESCRIPTOR):
- * any.Unpack(foo)
- * ...
- *
- * The pack methods provided by protobuf library will by default use
- * 'type.googleapis.com/full.type.name' as the type URL and the unpack
- * methods only use the fully qualified type name after the last '/'
- * in the type URL, for example "foo.bar.com/x/y.z" will yield type
- * name "y.z".
- *
- *
- * # JSON
- *
- * The JSON representation of an `Any` value uses the regular
- * representation of the deserialized, embedded message, with an
- * additional field `@type` which contains the type URL. Example:
- *
- * package google.profile;
- * message Person {
- * string first_name = 1;
- * string last_name = 2;
- * }
- *
- * {
- * "@type": "type.googleapis.com/google.profile.Person",
- * "firstName": ,
- * "lastName":
- * }
- *
- * If the embedded message type is well-known and has a custom JSON
- * representation, that representation will be embedded adding a field
- * `value` which holds the custom JSON in addition to the `@type`
- * field. Example (for message {@link google.protobuf.Duration}):
- *
- * {
- * "@type": "type.googleapis.com/google.protobuf.Duration",
- * "value": "1.212s"
- * }
- *
- * @external "google.protobuf.Any"
- * @property {string} typeUrl
- * A URL/resource name whose content describes the type of the
- * serialized protocol buffer message.
- *
- * For URLs which use the scheme `http`, `https`, or no scheme, the
- * following restrictions and interpretations apply:
- *
- * * If no scheme is provided, `https` is assumed.
- * * The last segment of the URL's path must represent the fully
- * qualified name of the type (as in `path/google.protobuf.Duration`).
- * The name should be in a canonical form (e.g., leading "." is
- * not accepted).
- * * An HTTP GET on the URL must yield a {@link google.protobuf.Type}
- * value in binary format, or produce an error.
- * * Applications are allowed to cache lookup results based on the
- * URL, or have them precompiled into a binary to avoid any
- * lookup. Therefore, binary compatibility needs to be preserved
- * on changes to types. (Use versioned type names to manage
- * breaking changes.)
- *
- * Schemes other than `http`, `https` (or the empty scheme) might be
- * used with implementation specific semantics.
- *
- * @property {string} value
- * Must be a valid serialized protocol buffer of the above specified type.
- *
- * @see [google.protobuf.Any definition in proto format]{@link https://github.com/google/protobuf/blob/master/src/google/protobuf/any.proto}
- */
\ No newline at end of file
diff --git a/packages/speech/src/v1/doc/doc_google_rpc_status.js b/packages/speech/src/v1/doc/doc_google_rpc_status.js
deleted file mode 100644
index c85f1befe90..00000000000
--- a/packages/speech/src/v1/doc/doc_google_rpc_status.js
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * Copyright 2017, Google Inc. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*
- * Note: this file is purely for documentation. Any contents are not expected
- * to be loaded as the JS file.
- */
-
-/**
- * The `Status` type defines a logical error model that is suitable for different
- * programming environments, including REST APIs and RPC APIs. It is used by
- * [gRPC](https://github.com/grpc). The error model is designed to be:
- *
- * - Simple to use and understand for most users
- * - Flexible enough to meet unexpected needs
- *
- * # Overview
- *
- * The `Status` message contains three pieces of data: error code, error message,
- * and error details. The error code should be an enum value of
- * {@link google.rpc.Code}, but it may accept additional error codes if needed. The
- * error message should be a developer-facing English message that helps
- * developers *understand* and *resolve* the error. If a localized user-facing
- * error message is needed, put the localized message in the error details or
- * localize it in the client. The optional error details may contain arbitrary
- * information about the error. There is a predefined set of error detail types
- * in the package `google.rpc` which can be used for common error conditions.
- *
- * # Language mapping
- *
- * The `Status` message is the logical representation of the error model, but it
- * is not necessarily the actual wire format. When the `Status` message is
- * exposed in different client libraries and different wire protocols, it can be
- * mapped differently. For example, it will likely be mapped to some exceptions
- * in Java, but more likely mapped to some error codes in C.
- *
- * # Other uses
- *
- * The error model and the `Status` message can be used in a variety of
- * environments, either with or without APIs, to provide a
- * consistent developer experience across different environments.
- *
- * Example uses of this error model include:
- *
- * - Partial errors. If a service needs to return partial errors to the client,
- * it may embed the `Status` in the normal response to indicate the partial
- * errors.
- *
- * - Workflow errors. A typical workflow has multiple steps. Each step may
- * have a `Status` message for error reporting purpose.
- *
- * - Batch operations. If a client uses batch request and batch response, the
- * `Status` message should be used directly inside batch response, one for
- * each error sub-response.
- *
- * - Asynchronous operations. If an API call embeds asynchronous operation
- * results in its response, the status of those operations should be
- * represented directly using the `Status` message.
- *
- * - Logging. If some API errors are stored in logs, the message `Status` could
- * be used directly after any stripping needed for security/privacy reasons.
- *
- * @external "google.rpc.Status"
- * @property {number} code
- * The status code, which should be an enum value of {@link google.rpc.Code}.
- *
- * @property {string} message
- * A developer-facing error message, which should be in English. Any
- * user-facing error message should be localized and sent in the
- * {@link google.rpc.Status.details} field, or localized by the client.
- *
- * @property {Object[]} details
- * A list of messages that carry the error details. There will be a
- * common set of message types for APIs to use.
- *
- * This object should have the same structure as [google.protobuf.Any]{@link external:"google.protobuf.Any"}
- *
- * @see [google.rpc.Status definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/rpc/status.proto}
- */
\ No newline at end of file
diff --git a/packages/speech/src/v1/index.js b/packages/speech/src/v1/index.js
deleted file mode 100644
index 9aac5a2d5f9..00000000000
--- a/packages/speech/src/v1/index.js
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright 2017, Google Inc. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-'use strict';
-
-var speechClient = require('./speech_client');
-var gax = require('google-gax');
-var extend = require('extend');
-
-function v1(options) {
- options = extend({
- scopes: v1.ALL_SCOPES
- }, options);
- var gaxGrpc = gax.grpc(options);
- return speechClient(gaxGrpc);
-}
-
-v1.GAPIC_VERSION = '0.10.0';
-v1.SERVICE_ADDRESS = speechClient.SERVICE_ADDRESS;
-v1.ALL_SCOPES = speechClient.ALL_SCOPES;
-
-module.exports = v1;
\ No newline at end of file
diff --git a/packages/speech/src/v1/speech_client.js b/packages/speech/src/v1/speech_client.js
deleted file mode 100644
index 999514f7612..00000000000
--- a/packages/speech/src/v1/speech_client.js
+++ /dev/null
@@ -1,398 +0,0 @@
-/*
- * Copyright 2017, Google Inc. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- * EDITING INSTRUCTIONS
- * This file was generated from the file
- * https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto,
- * and updates to that file get reflected here through a refresh process.
- * For the short term, the refresh process will only be runnable by Google
- * engineers.
- *
- * The only allowed edits are to method and file documentation. A 3-way
- * merge preserves those additions if the generated source changes.
- */
-/* TODO: introduce line-wrapping so that it never exceeds the limit. */
-/* jscs: disable maximumLineLength */
-'use strict';
-
-var configData = require('./speech_client_config');
-var extend = require('extend');
-var gax = require('google-gax');
-
-var SERVICE_ADDRESS = 'speech.googleapis.com';
-
-var DEFAULT_SERVICE_PORT = 443;
-
-var CODE_GEN_NAME_VERSION = 'gapic/0.10.0';
-
-var STREAM_DESCRIPTORS = {
- streamingRecognize: new gax.StreamDescriptor(gax.StreamType.BIDI_STREAMING)
-};
-
-/**
- * The scopes needed to make gRPC calls to all of the methods defined in
- * this service.
- */
-var ALL_SCOPES = [
- 'https://www.googleapis.com/auth/cloud-platform'
-];
-
-/**
- * Service that implements Google Cloud Speech API.
- *
- *
- * @class
- */
-function SpeechClient(gaxGrpc, grpcClients, opts) {
- opts = extend({
- servicePath: SERVICE_ADDRESS,
- port: DEFAULT_SERVICE_PORT,
- clientConfig: {}
- }, opts);
-
- var googleApiClient = [
- 'gl-node/' + process.versions.node
- ];
- if (opts.libName && opts.libVersion) {
- googleApiClient.push(opts.libName + '/' + opts.libVersion);
- }
- googleApiClient.push(
- CODE_GEN_NAME_VERSION,
- 'gax/' + gax.version,
- 'grpc/' + gaxGrpc.grpcVersion
- );
-
- this.operationsClient = new gax.lro({
- auth: gaxGrpc.auth,
- grpc: gaxGrpc.grpc
- }).operationsClient(opts);
-
- this.longrunningDescriptors = {
- longRunningRecognize: new gax.LongrunningDescriptor(
- this.operationsClient,
- grpcClients.google.cloud.speech.v1.LongRunningRecognizeResponse.decode,
- grpcClients.google.cloud.speech.v1.LongRunningRecognizeMetadata.decode)
- };
-
- var defaults = gaxGrpc.constructSettings(
- 'google.cloud.speech.v1.Speech',
- configData,
- opts.clientConfig,
- {'x-goog-api-client': googleApiClient.join(' ')});
-
- var self = this;
-
- this.auth = gaxGrpc.auth;
- var speechStub = gaxGrpc.createStub(
- grpcClients.google.cloud.speech.v1.Speech,
- opts);
- var speechStubMethods = [
- 'recognize',
- 'longRunningRecognize',
- 'streamingRecognize'
- ];
- speechStubMethods.forEach(function(methodName) {
- self['_' + methodName] = gax.createApiCall(
- speechStub.then(function(speechStub) {
- return function() {
- var args = Array.prototype.slice.call(arguments, 0);
- return speechStub[methodName].apply(speechStub, args);
- };
- }),
- defaults[methodName],
- STREAM_DESCRIPTORS[methodName] || self.longrunningDescriptors[methodName]);
- });
-}
-
-
-/**
- * Get the project ID used by this class.
- * @param {function(Error, string)} callback - the callback to be called with
- * the current project Id.
- */
-SpeechClient.prototype.getProjectId = function(callback) {
- return this.auth.getProjectId(callback);
-};
-
-// Service calls
-
-/**
- * Performs synchronous speech recognition: receive results after all audio
- * has been sent and processed.
- *
- * @param {Object} request
- * The request object that will be sent.
- * @param {Object} request.config
- * *Required* Provides information to the recognizer that specifies how to
- * process the request.
- *
- * This object should have the same structure as [RecognitionConfig]{@link RecognitionConfig}
- * @param {Object} request.audio
- * *Required* The audio data to be recognized.
- *
- * This object should have the same structure as [RecognitionAudio]{@link RecognitionAudio}
- * @param {Object=} options
- * Optional parameters. You can override the default settings for this call, e.g, timeout,
- * retries, paginations, etc. See [gax.CallOptions]{@link https://googleapis.github.io/gax-nodejs/global.html#CallOptions} for the details.
- * @param {function(?Error, ?Object)=} callback
- * The function which will be called with the result of the API call.
- *
- * The second parameter to the callback is an object representing [RecognizeResponse]{@link RecognizeResponse}.
- * @return {Promise} - The promise which resolves to an array.
- * The first element of the array is an object representing [RecognizeResponse]{@link RecognizeResponse}.
- * The promise has a method named "cancel" which cancels the ongoing API call.
- *
- * @example
- *
- * var speech = require('@google-cloud/speech');
- *
- * var client = speech.v1({
- * // optional auth parameters.
- * });
- *
- * var encoding = speech.v1.types.RecognitionConfig.AudioEncoding.FLAC;
- * var sampleRateHertz = 44100;
- * var languageCode = 'en-US';
- * var config = {
- * encoding : encoding,
- * sampleRateHertz : sampleRateHertz,
- * languageCode : languageCode
- * };
- * var uri = 'gs://bucket_name/file_name.flac';
- * var audio = {
- * uri : uri
- * };
- * var request = {
- * config: config,
- * audio: audio
- * };
- * client.recognize(request).then(function(responses) {
- * var response = responses[0];
- * // doThingsWith(response)
- * })
- * .catch(function(err) {
- * console.error(err);
- * });
- */
-SpeechClient.prototype.recognize = function(request, options, callback) {
- if (options instanceof Function && callback === undefined) {
- callback = options;
- options = {};
- }
- if (options === undefined) {
- options = {};
- }
-
- return this._recognize(request, options, callback);
-};
-
-/**
- * Performs asynchronous speech recognition: receive results via the
- * google.longrunning.Operations interface. Returns either an
- * `Operation.error` or an `Operation.response` which contains
- * a `LongRunningRecognizeResponse` message.
- *
- * @param {Object} request
- * The request object that will be sent.
- * @param {Object} request.config
- * *Required* Provides information to the recognizer that specifies how to
- * process the request.
- *
- * This object should have the same structure as [RecognitionConfig]{@link RecognitionConfig}
- * @param {Object} request.audio
- * *Required* The audio data to be recognized.
- *
- * This object should have the same structure as [RecognitionAudio]{@link RecognitionAudio}
- * @param {Object=} options
- * Optional parameters. You can override the default settings for this call, e.g, timeout,
- * retries, paginations, etc. See [gax.CallOptions]{@link https://googleapis.github.io/gax-nodejs/global.html#CallOptions} for the details.
- * @param {function(?Error, ?Object)=} callback
- * The function which will be called with the result of the API call.
- *
- * The second parameter to the callback is a [gax.Operation]{@link https://googleapis.github.io/gax-nodejs/Operation} object.
- * @return {Promise} - The promise which resolves to an array.
- * The first element of the array is a [gax.Operation]{@link https://googleapis.github.io/gax-nodejs/Operation} object.
- * The promise has a method named "cancel" which cancels the ongoing API call.
- *
- * @example
- *
- * var speech = require('@google-cloud/speech');
- *
- * var client = speech.v1({
- * // optional auth parameters.
- * });
- *
- * var encoding = speech.v1.types.RecognitionConfig.AudioEncoding.FLAC;
- * var sampleRateHertz = 44100;
- * var languageCode = 'en-US';
- * var config = {
- * encoding : encoding,
- * sampleRateHertz : sampleRateHertz,
- * languageCode : languageCode
- * };
- * var uri = 'gs://bucket_name/file_name.flac';
- * var audio = {
- * uri : uri
- * };
- * var request = {
- * config: config,
- * audio: audio
- * };
- *
- * // Handle the operation using the promise pattern.
- * client.longRunningRecognize(request).then(function(responses) {
- * var operation = responses[0];
- * var initialApiResponse = responses[1];
- *
- * // Operation#promise starts polling for the completion of the LRO.
- * return operation.promise();
- * }).then(function(responses) {
- * // The final result of the operation.
- * var result = responses[0];
- *
- * // The metadata value of the completed operation.
- * var metadata = responses[1];
- *
- * // The response of the api call returning the complete operation.
- * var finalApiResponse = responses[2];
- * })
- * .catch(function(err) {
- * console.error(err);
- * });
- *
- * var encoding = speech.v1.types.RecognitionConfig.AudioEncoding.FLAC;
- * var sampleRateHertz = 44100;
- * var languageCode = 'en-US';
- * var config = {
- * encoding : encoding,
- * sampleRateHertz : sampleRateHertz,
- * languageCode : languageCode
- * };
- * var uri = 'gs://bucket_name/file_name.flac';
- * var audio = {
- * uri : uri
- * };
- * var request = {
- * config: config,
- * audio: audio
- * };
- *
- * // Handle the operation using the event emitter pattern.
- * client.longRunningRecognize(request).then(function(responses) {
- * var operation = responses[0];
- * var initialApiResponse = responses[1];
- *
- * // Adding a listener for the "complete" event starts polling for the
- * // completion of the operation.
- * operation.on('complete', function(result, metadata, finalApiResponse) {
- * // doSomethingWith(result);
- * });
- *
- * // Adding a listener for the "progress" event causes the callback to be
- * // called on any change in metadata when the operation is polled.
- * operation.on('progress', function(metadata, apiResponse) {
- * // doSomethingWith(metadata)
- * })
- *
- * // Adding a listener for the "error" event handles any errors found during polling.
- * operation.on('error', function(err) {
- * // throw(err);
- * })
- * })
- * .catch(function(err) {
- * console.error(err);
- * });
- */
-SpeechClient.prototype.longRunningRecognize = function(request, options, callback) {
- if (options instanceof Function && callback === undefined) {
- callback = options;
- options = {};
- }
- if (options === undefined) {
- options = {};
- }
-
- return this._longRunningRecognize(request, options, callback);
-};
-
-/**
- * Performs bidirectional streaming speech recognition: receive results while
- * sending audio. This method is only available via the gRPC API (not REST).
- *
- * @param {Object=} options
- * Optional parameters. You can override the default settings for this call, e.g, timeout,
- * retries, paginations, etc. See [gax.CallOptions]{@link https://googleapis.github.io/gax-nodejs/global.html#CallOptions} for the details.
- * @returns {Stream}
- * An object stream which is both readable and writable. It accepts objects
- * representing [StreamingRecognizeRequest]{@link StreamingRecognizeRequest} for write() method, and
- * will emit objects representing [StreamingRecognizeResponse]{@link StreamingRecognizeResponse} on 'data' event asynchronously.
- *
- * @example
- *
- * var speech = require('@google-cloud/speech');
- *
- * var client = speech.v1({
- * // optional auth parameters.
- * });
- *
- * var stream = client.streamingRecognize().on('data', function(response) {
- * // doThingsWith(response)
- * });
- * var request = {};
- * // Write request objects.
- * stream.write(request);
- */
-SpeechClient.prototype.streamingRecognize = function(options) {
- if (options === undefined) {
- options = {};
- }
-
- return this._streamingRecognize(options);
-};
-
-function SpeechClientBuilder(gaxGrpc) {
- if (!(this instanceof SpeechClientBuilder)) {
- return new SpeechClientBuilder(gaxGrpc);
- }
-
- var speechClient = gaxGrpc.load([{
- root: require('google-proto-files')('..'),
- file: 'google/cloud/speech/v1/cloud_speech.proto'
- }]);
- extend(this, speechClient.google.cloud.speech.v1);
-
-
- /**
- * Build a new instance of {@link SpeechClient}.
- *
- * @param {Object=} opts - The optional parameters.
- * @param {String=} opts.servicePath
- * The domain name of the API remote host.
- * @param {number=} opts.port
- * The port on which to connect to the remote host.
- * @param {grpc.ClientCredentials=} opts.sslCreds
- * A ClientCredentials for use with an SSL-enabled channel.
- * @param {Object=} opts.clientConfig
- * The customized config to build the call settings. See
- * {@link gax.constructSettings} for the format.
- */
- this.speechClient = function(opts) {
- return new SpeechClient(gaxGrpc, speechClient, opts);
- };
- extend(this.speechClient, SpeechClient);
-}
-module.exports = SpeechClientBuilder;
-module.exports.SERVICE_ADDRESS = SERVICE_ADDRESS;
-module.exports.ALL_SCOPES = ALL_SCOPES;
\ No newline at end of file
diff --git a/packages/speech/src/v1/speech_client_config.json b/packages/speech/src/v1/speech_client_config.json
deleted file mode 100644
index bf5c507caf1..00000000000
--- a/packages/speech/src/v1/speech_client_config.json
+++ /dev/null
@@ -1,41 +0,0 @@
-{
- "interfaces": {
- "google.cloud.speech.v1.Speech": {
- "retry_codes": {
- "idempotent": [
- "DEADLINE_EXCEEDED",
- "UNAVAILABLE"
- ],
- "non_idempotent": []
- },
- "retry_params": {
- "default": {
- "initial_retry_delay_millis": 100,
- "retry_delay_multiplier": 1.3,
- "max_retry_delay_millis": 60000,
- "initial_rpc_timeout_millis": 190000,
- "rpc_timeout_multiplier": 1.0,
- "max_rpc_timeout_millis": 190000,
- "total_timeout_millis": 600000
- }
- },
- "methods": {
- "Recognize": {
- "timeout_millis": 190000,
- "retry_codes_name": "idempotent",
- "retry_params_name": "default"
- },
- "LongRunningRecognize": {
- "timeout_millis": 60000,
- "retry_codes_name": "non_idempotent",
- "retry_params_name": "default"
- },
- "StreamingRecognize": {
- "timeout_millis": 190000,
- "retry_codes_name": "idempotent",
- "retry_params_name": "default"
- }
- }
- }
- }
-}
diff --git a/packages/speech/test/gapic-v1.test.js b/packages/speech/test/gapic-v1.test.js
deleted file mode 100644
index 2e37b7ff538..00000000000
--- a/packages/speech/test/gapic-v1.test.js
+++ /dev/null
@@ -1,253 +0,0 @@
-/*
- * Copyright 2017, Google Inc. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-'use strict';
-
-var assert = require('assert');
-var speechV1 = require('../src/v1')();
-var through2 = require('through2');
-
-var FAKE_STATUS_CODE = 1;
-var error = new Error();
-error.code = FAKE_STATUS_CODE;
-
-describe('SpeechClient', function() {
- describe('recognize', function() {
- it('invokes recognize without error', function(done) {
- var client = speechV1.speechClient();
- // Mock request
- var encoding = speechV1.RecognitionConfig.AudioEncoding.FLAC;
- var sampleRateHertz = 44100;
- var languageCode = 'en-US';
- var config = {
- encoding : encoding,
- sampleRateHertz : sampleRateHertz,
- languageCode : languageCode
- };
- var uri = 'gs://bucket_name/file_name.flac';
- var audio = {
- uri : uri
- };
- var request = {
- config : config,
- audio : audio
- };
-
- // Mock response
- var expectedResponse = {};
-
- // Mock Grpc layer
- client._recognize = mockSimpleGrpcMethod(request, expectedResponse);
-
- client.recognize(request, function(err, response) {
- assert.ifError(err);
- assert.deepStrictEqual(response, expectedResponse);
- done();
- });
- });
-
- it('invokes recognize with error', function(done) {
- var client = speechV1.speechClient();
- // Mock request
- var encoding = speechV1.RecognitionConfig.AudioEncoding.FLAC;
- var sampleRateHertz = 44100;
- var languageCode = 'en-US';
- var config = {
- encoding : encoding,
- sampleRateHertz : sampleRateHertz,
- languageCode : languageCode
- };
- var uri = 'gs://bucket_name/file_name.flac';
- var audio = {
- uri : uri
- };
- var request = {
- config : config,
- audio : audio
- };
-
- // Mock Grpc layer
- client._recognize = mockSimpleGrpcMethod(request, null, error);
-
- client.recognize(request, function(err, response) {
- assert(err instanceof Error);
- assert.equal(err.code, FAKE_STATUS_CODE);
- done();
- });
- });
- });
-
- describe('longRunningRecognize', function() {
- it('invokes longRunningRecognize without error', function(done) {
- var client = speechV1.speechClient();
- // Mock request
- var encoding = speechV1.RecognitionConfig.AudioEncoding.FLAC;
- var sampleRateHertz = 44100;
- var languageCode = 'en-US';
- var config = {
- encoding : encoding,
- sampleRateHertz : sampleRateHertz,
- languageCode : languageCode
- };
- var uri = 'gs://bucket_name/file_name.flac';
- var audio = {
- uri : uri
- };
- var request = {
- config : config,
- audio : audio
- };
-
- // Mock response
- var expectedResponse = {};
-
- // Mock Grpc layer
- client._longRunningRecognize = mockLongRunningGrpcMethod(request, expectedResponse);
-
- client.longRunningRecognize(request).then(function(responses) {
- var operation = responses[0];
- return operation.promise();
- }).then(function(responses) {
- assert.deepStrictEqual(responses[0], expectedResponse);
- done();
- }).catch(function(err) {
- done(err);
- });
- });
-
- it('invokes longRunningRecognize with error', function(done) {
- var client = speechV1.speechClient();
- // Mock request
- var encoding = speechV1.RecognitionConfig.AudioEncoding.FLAC;
- var sampleRateHertz = 44100;
- var languageCode = 'en-US';
- var config = {
- encoding : encoding,
- sampleRateHertz : sampleRateHertz,
- languageCode : languageCode
- };
- var uri = 'gs://bucket_name/file_name.flac';
- var audio = {
- uri : uri
- };
- var request = {
- config : config,
- audio : audio
- };
-
- // Mock Grpc layer
- client._longRunningRecognize = mockLongRunningGrpcMethod(request, null, error);
-
- client.longRunningRecognize(request).then(function(responses) {
- var operation = responses[0];
- return operation.promise();
- }).then(function(responses) {
- assert.fail();
- }).catch(function(err) {
- assert(err instanceof Error);
- assert.equal(err.code, FAKE_STATUS_CODE);
- done();
- });
- });
- });
-
- describe('streamingRecognize', function() {
- it('invokes streamingRecognize without error', function(done) {
- var client = speechV1.speechClient();
- // Mock request
- var request = {};
-
- // Mock response
- var expectedResponse = {};
-
- // Mock Grpc layer
- client._streamingRecognize = mockBidiStreamingGrpcMethod(request, expectedResponse);
-
- var stream = client.streamingRecognize().on('data', function(response) {
- assert.deepStrictEqual(response, expectedResponse);
- done()
- }).on('error', function(err) {
- done(err);
- });
-
- stream.write(request);
- });
-
- it('invokes streamingRecognize with error', function(done) {
- var client = speechV1.speechClient();
- // Mock request
- var request = {};
-
- // Mock Grpc layer
- client._streamingRecognize = mockBidiStreamingGrpcMethod(request, null, error);
-
- var stream = client.streamingRecognize().on('data', function(response) {
- assert.fail();
- }).on('error', function(err) {
- assert(err instanceof Error);
- assert.equal(err.code, FAKE_STATUS_CODE);
- done();
- });
-
- stream.write(request);
- });
- });
-
-});
-
-function mockSimpleGrpcMethod(expectedRequest, response, error) {
- return function(actualRequest, options, callback) {
- assert.deepStrictEqual(actualRequest, expectedRequest);
- if (error) {
- callback(error);
- } else if (response) {
- callback(null, response);
- } else {
- callback(null);
- }
- };
-}
-
-function mockBidiStreamingGrpcMethod(expectedRequest, response, error) {
- return function() {
- var mockStream = through2.obj(function (chunk, enc, callback) {
- assert.deepStrictEqual(chunk, expectedRequest);
- if (error) {
- callback(error);
- } else {
- callback(null, response);
- }
- });
- return mockStream;
- }
-}
-
-function mockLongRunningGrpcMethod(expectedRequest, response, error) {
- return function(request) {
- assert.deepStrictEqual(request, expectedRequest);
- var mockOperation = {
- promise: function() {
- return new Promise(function(resolve, reject) {
- if (error) {
- reject(error);
- } else {
- resolve([response]);
- }
- });
- }
- };
- return Promise.resolve([mockOperation]);
- };
-}
diff --git a/packages/speech/test/helpers.test.js b/packages/speech/test/helpers.test.js
deleted file mode 100644
index effdeefece0..00000000000
--- a/packages/speech/test/helpers.test.js
+++ /dev/null
@@ -1,143 +0,0 @@
-/*!
- * Copyright 2017 Google Inc. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-'use strict';
-
-var assert = require('assert');
-var sinon = require('sinon');
-var stream = require('stream');
-
-var Speech = require('../');
-
-describe('Speech helper methods', () => {
- var sandbox = sinon.sandbox.create();
- var speech;
-
- beforeEach(() => {
- speech = Speech.v1();
- });
-
- afterEach(() => {
- sandbox.restore();
- });
-
- describe('streamingRecognize', () => {
- var CONFIG = {config: {languageCode: 'en-us'}};
- var OPTIONS = {timeout: Infinity};
-
- it('writes the config to the resulting stream', (done) => {
- // Stub the underlying _streamingRecognize method to just return
- // a bogus stream.
- var requestStream = new stream.PassThrough({ objectMode: true });
- var sr = sandbox.stub(speech, '_streamingRecognize')
- .returns(requestStream);
-
- // Call the new helper method and establish that the config was
- // forwarded as expected.
- var userStream = speech.streamingRecognize(CONFIG, OPTIONS);
-
- // Establish that the underlying streamingRecognize was called with
- // the options.
- assert(sr.calledOnce);
- assert(sr.calledWithExactly(OPTIONS));
-
- requestStream._write = (data, enc, next) => {
- assert.deepStrictEqual(data, {
- streamingConfig: CONFIG
- });
- setImmediate(done);
- next(null, data);
- };
-
- userStream.emit('writing');
- });
-
- it('does not require options', () => {
- // Stub the underlying _streamingRecognize method to just return
- // a bogus stream.
- var requestStream = new stream.PassThrough({ objectMode: true });
- var sr = sandbox.stub(speech, '_streamingRecognize')
- .returns(requestStream);
-
- var userStream = speech.streamingRecognize(CONFIG);
-
- userStream.emit('writing');
-
- assert(sr.calledOnce);
- assert(sr.calledWithExactly({}));
- });
-
- it('destroys the user stream when the request stream errors', (done) => {
- // Stub the underlying _streamingRecognize method to just return
- // a bogus stream.
- var requestStream = new stream.PassThrough({ objectMode: true });
- sandbox.stub(speech, '_streamingRecognize').returns(requestStream);
-
- var userStream = speech.streamingRecognize(CONFIG, OPTIONS);
-
- var error = new Error('Request stream error');
-
- userStream.once('error', (err) => {
- assert.strictEqual(err, error);
- done();
- });
-
- userStream.emit('writing');
-
- requestStream.emit('error', error);
- });
-
- it('re-emits response from the request stream', (done) => {
- // Stub the underlying _streamingRecognize method to just return
- // a bogus stream.
- var requestStream = new stream.PassThrough({ objectMode: true });
- sandbox.stub(speech, '_streamingRecognize').returns(requestStream);
-
- var userStream = speech.streamingRecognize(CONFIG, OPTIONS);
-
- var response = {};
-
- userStream.on('response', (_response) => {
- assert.strictEqual(_response, response);
- done();
- });
-
- userStream.emit('writing');
- requestStream.emit('response', response);
- });
-
- it('wraps incoming audio data', (done) => {
- // Stub the underlying _streamingRecognize method to just return
- // a bogus stream.
- var requestStream = new stream.PassThrough({ objectMode: true });
- sandbox.stub(speech, '_streamingRecognize').returns(requestStream);
-
- var userStream = speech.streamingRecognize(CONFIG, OPTIONS);
- var audioContent = new Buffer('audio content');
-
- requestStream._write = (data, enc, next) => {
- if (data && data.streamingConfig !== CONFIG) {
- assert.deepStrictEqual(data, { audioContent });
- setImmediate(done);
- }
-
- next(null, data);
- };
-
- userStream.end(audioContent);
- });
- });
-});