OLD | NEW |
1 { | 1 { |
2 "auth": { | 2 "auth": { |
3 "oauth2": { | 3 "oauth2": { |
4 "scopes": { | 4 "scopes": { |
5 "https://www.googleapis.com/auth/cloud-platform": { | 5 "https://www.googleapis.com/auth/cloud-platform": { |
6 "description": "View and manage your data across Google Clou
d Platform services" | 6 "description": "View and manage your data across Google Clou
d Platform services" |
7 } | 7 } |
8 } | 8 } |
9 } | 9 } |
10 }, | 10 }, |
11 "basePath": "", | 11 "basePath": "", |
12 "baseUrl": "https://speech.googleapis.com/", | 12 "baseUrl": "https://speech.googleapis.com/", |
13 "batchPath": "batch", | 13 "batchPath": "batch", |
14 "canonicalName": "Speech", | 14 "canonicalName": "Speech", |
15 "description": "Converts audio to text by applying powerful neural network m
odels.", | 15 "description": "Converts audio to text by applying powerful neural network m
odels.", |
16 "discoveryVersion": "v1", | 16 "discoveryVersion": "v1", |
17 "documentationLink": "https://cloud.google.com/speech/", | 17 "documentationLink": "https://cloud.google.com/speech/", |
18 "icons": { | 18 "icons": { |
19 "x16": "http://www.google.com/images/icons/product/search-16.gif", | 19 "x16": "http://www.google.com/images/icons/product/search-16.gif", |
20 "x32": "http://www.google.com/images/icons/product/search-32.gif" | 20 "x32": "http://www.google.com/images/icons/product/search-32.gif" |
21 }, | 21 }, |
22 "id": "speech:v1beta1", | 22 "id": "speech:v1beta1", |
23 "kind": "discovery#restDescription", | 23 "kind": "discovery#restDescription", |
24 "name": "speech", | 24 "name": "speech", |
25 "ownerDomain": "google.com", | 25 "ownerDomain": "google.com", |
26 "ownerName": "Google", | 26 "ownerName": "Google", |
27 "parameters": { | 27 "parameters": { |
| 28 "pp": { |
| 29 "default": "true", |
| 30 "description": "Pretty-print response.", |
| 31 "location": "query", |
| 32 "type": "boolean" |
| 33 }, |
| 34 "oauth_token": { |
| 35 "description": "OAuth 2.0 token for the current user.", |
| 36 "location": "query", |
| 37 "type": "string" |
| 38 }, |
| 39 "bearer_token": { |
| 40 "description": "OAuth bearer token.", |
| 41 "location": "query", |
| 42 "type": "string" |
| 43 }, |
28 "upload_protocol": { | 44 "upload_protocol": { |
29 "description": "Upload protocol for media (e.g. \"raw\", \"multipart
\").", | 45 "description": "Upload protocol for media (e.g. \"raw\", \"multipart
\").", |
30 "location": "query", | 46 "location": "query", |
31 "type": "string" | 47 "type": "string" |
32 }, | 48 }, |
33 "prettyPrint": { | 49 "prettyPrint": { |
34 "default": "true", | 50 "default": "true", |
35 "description": "Returns response with indentations and line breaks."
, | 51 "description": "Returns response with indentations and line breaks."
, |
36 "location": "query", | 52 "location": "query", |
37 "type": "boolean" | 53 "type": "boolean" |
38 }, | 54 }, |
| 55 "fields": { |
| 56 "description": "Selector specifying which fields to include in a par
tial response.", |
| 57 "location": "query", |
| 58 "type": "string" |
| 59 }, |
39 "uploadType": { | 60 "uploadType": { |
40 "description": "Legacy upload protocol for media (e.g. \"media\", \"
multipart\").", | 61 "description": "Legacy upload protocol for media (e.g. \"media\", \"
multipart\").", |
41 "location": "query", | 62 "location": "query", |
42 "type": "string" | 63 "type": "string" |
43 }, | 64 }, |
44 "fields": { | |
45 "description": "Selector specifying which fields to include in a par
tial response.", | |
46 "location": "query", | |
47 "type": "string" | |
48 }, | |
49 "callback": { | 65 "callback": { |
50 "description": "JSONP", | 66 "description": "JSONP", |
51 "location": "query", | 67 "location": "query", |
52 "type": "string" | 68 "type": "string" |
53 }, | 69 }, |
54 "$.xgafv": { | 70 "$.xgafv": { |
55 "description": "V1 error format.", | 71 "description": "V1 error format.", |
56 "enum": [ | 72 "enum": [ |
57 "1", | 73 "1", |
58 "2" | 74 "2" |
(...skipping 14 matching lines...) Expand all Loading... |
73 "proto" | 89 "proto" |
74 ], | 90 ], |
75 "enumDescriptions": [ | 91 "enumDescriptions": [ |
76 "Responses with Content-Type of application/json", | 92 "Responses with Content-Type of application/json", |
77 "Media download with context-dependent Content-Type", | 93 "Media download with context-dependent Content-Type", |
78 "Responses with Content-Type of application/x-protobuf" | 94 "Responses with Content-Type of application/x-protobuf" |
79 ], | 95 ], |
80 "location": "query", | 96 "location": "query", |
81 "type": "string" | 97 "type": "string" |
82 }, | 98 }, |
| 99 "key": { |
| 100 "description": "API key. Your API key identifies your project and pr
ovides you with API access, quota, and reports. Required unless you provide an O
Auth 2.0 token.", |
| 101 "location": "query", |
| 102 "type": "string" |
| 103 }, |
83 "access_token": { | 104 "access_token": { |
84 "description": "OAuth access token.", | 105 "description": "OAuth access token.", |
85 "location": "query", | 106 "location": "query", |
86 "type": "string" | 107 "type": "string" |
87 }, | 108 }, |
88 "key": { | |
89 "description": "API key. Your API key identifies your project and pr
ovides you with API access, quota, and reports. Required unless you provide an O
Auth 2.0 token.", | |
90 "location": "query", | |
91 "type": "string" | |
92 }, | |
93 "quotaUser": { | 109 "quotaUser": { |
94 "description": "Available to use for quota purposes for server-side
applications. Can be any arbitrary string assigned to a user, but should not exc
eed 40 characters.", | 110 "description": "Available to use for quota purposes for server-side
applications. Can be any arbitrary string assigned to a user, but should not exc
eed 40 characters.", |
95 "location": "query", | 111 "location": "query", |
96 "type": "string" | 112 "type": "string" |
97 }, | |
98 "pp": { | |
99 "default": "true", | |
100 "description": "Pretty-print response.", | |
101 "location": "query", | |
102 "type": "boolean" | |
103 }, | |
104 "bearer_token": { | |
105 "description": "OAuth bearer token.", | |
106 "location": "query", | |
107 "type": "string" | |
108 }, | |
109 "oauth_token": { | |
110 "description": "OAuth 2.0 token for the current user.", | |
111 "location": "query", | |
112 "type": "string" | |
113 } | 113 } |
114 }, | 114 }, |
115 "protocol": "rest", | 115 "protocol": "rest", |
116 "resources": { | 116 "resources": { |
117 "operations": { | 117 "operations": { |
118 "methods": { | 118 "methods": { |
119 "list": { | 119 "cancel": { |
120 "description": "Lists operations that match the specified fi
lter in the request. If the\nserver doesn't support this method, it returns `UNI
MPLEMENTED`.\n\nNOTE: the `name` binding allows API services to override the bin
ding\nto use different resource name schemes, such as `users/*/operations`. To\n
override the binding, API services can add a binding such as\n`\"/v1/{name=users
/*}/operations\"` to their service configuration.\nFor backwards compatibility,
the default name includes the operations\ncollection id, however overriding user
s must ensure the name binding\nis the parent resource, without the operations c
ollection id.", | 120 "description": "Starts asynchronous cancellation on a long-r
unning operation. The server\nmakes a best effort to cancel the operation, but
success is not\nguaranteed. If the server doesn't support this method, it retur
ns\n`google.rpc.Code.UNIMPLEMENTED`. Clients can use\nOperations.GetOperation o
r\nother methods to check whether the cancellation succeeded or whether the\nope
ration completed despite cancellation. On successful cancellation,\nthe operatio
n is not deleted; instead, it becomes an operation with\nan Operation.error valu
e with a google.rpc.Status.code of 1,\ncorresponding to `Code.CANCELLED`.", |
121 "httpMethod": "GET", | 121 "httpMethod": "POST", |
122 "id": "speech.operations.list", | 122 "id": "speech.operations.cancel", |
123 "parameterOrder": [], | 123 "parameterOrder": [ |
| 124 "name" |
| 125 ], |
124 "parameters": { | 126 "parameters": { |
125 "filter": { | 127 "name": { |
126 "description": "The standard list filter.", | 128 "description": "The name of the operation resource t
o be cancelled.", |
127 "location": "query", | 129 "location": "path", |
| 130 "pattern": "^[^/]+$", |
| 131 "required": true, |
128 "type": "string" | 132 "type": "string" |
129 }, | |
130 "name": { | |
131 "description": "The name of the operation's parent r
esource.", | |
132 "location": "query", | |
133 "type": "string" | |
134 }, | |
135 "pageToken": { | |
136 "description": "The standard list page token.", | |
137 "location": "query", | |
138 "type": "string" | |
139 }, | |
140 "pageSize": { | |
141 "description": "The standard list page size.", | |
142 "format": "int32", | |
143 "location": "query", | |
144 "type": "integer" | |
145 } | 133 } |
146 }, | 134 }, |
147 "path": "v1beta1/operations", | 135 "path": "v1beta1/operations/{+name}:cancel", |
148 "response": { | 136 "response": { |
149 "$ref": "ListOperationsResponse" | 137 "$ref": "Empty" |
150 }, | 138 }, |
151 "scopes": [ | 139 "scopes": [ |
152 "https://www.googleapis.com/auth/cloud-platform" | 140 "https://www.googleapis.com/auth/cloud-platform" |
153 ] | 141 ] |
154 }, | 142 }, |
155 "get": { | 143 "delete": { |
156 "description": "Gets the latest state of a long-running oper
ation. Clients can use this\nmethod to poll the operation result at intervals a
s recommended by the API\nservice.", | 144 "description": "Deletes a long-running operation. This metho
d indicates that the client is\nno longer interested in the operation result. It
does not cancel the\noperation. If the server doesn't support this method, it r
eturns\n`google.rpc.Code.UNIMPLEMENTED`.", |
157 "httpMethod": "GET", | 145 "httpMethod": "DELETE", |
158 "id": "speech.operations.get", | 146 "id": "speech.operations.delete", |
159 "parameterOrder": [ | 147 "parameterOrder": [ |
160 "name" | 148 "name" |
161 ], | 149 ], |
162 "parameters": { | 150 "parameters": { |
163 "name": { | 151 "name": { |
164 "description": "The name of the operation resource."
, | 152 "description": "The name of the operation resource t
o be deleted.", |
165 "location": "path", | 153 "location": "path", |
166 "pattern": "^[^/]+$", | 154 "pattern": "^[^/]+$", |
167 "required": true, | 155 "required": true, |
168 "type": "string" | 156 "type": "string" |
169 } | 157 } |
170 }, | 158 }, |
171 "path": "v1beta1/operations/{+name}", | 159 "path": "v1beta1/operations/{+name}", |
172 "response": { | 160 "response": { |
| 161 "$ref": "Empty" |
| 162 }, |
| 163 "scopes": [ |
| 164 "https://www.googleapis.com/auth/cloud-platform" |
| 165 ] |
| 166 }, |
| 167 "get": { |
| 168 "description": "Gets the latest state of a long-running oper
ation. Clients can use this\nmethod to poll the operation result at intervals a
s recommended by the API\nservice.", |
| 169 "httpMethod": "GET", |
| 170 "id": "speech.operations.get", |
| 171 "parameterOrder": [ |
| 172 "name" |
| 173 ], |
| 174 "parameters": { |
| 175 "name": { |
| 176 "description": "The name of the operation resource."
, |
| 177 "location": "path", |
| 178 "pattern": "^[^/]+$", |
| 179 "required": true, |
| 180 "type": "string" |
| 181 } |
| 182 }, |
| 183 "path": "v1beta1/operations/{+name}", |
| 184 "response": { |
173 "$ref": "Operation" | 185 "$ref": "Operation" |
174 }, | 186 }, |
175 "scopes": [ | 187 "scopes": [ |
176 "https://www.googleapis.com/auth/cloud-platform" | 188 "https://www.googleapis.com/auth/cloud-platform" |
177 ] | 189 ] |
178 }, | 190 }, |
179 "cancel": { | 191 "list": { |
180 "description": "Starts asynchronous cancellation on a long-r
unning operation. The server\nmakes a best effort to cancel the operation, but
success is not\nguaranteed. If the server doesn't support this method, it retur
ns\n`google.rpc.Code.UNIMPLEMENTED`. Clients can use\nOperations.GetOperation o
r\nother methods to check whether the cancellation succeeded or whether the\nope
ration completed despite cancellation. On successful cancellation,\nthe operatio
n is not deleted; instead, it becomes an operation with\nan Operation.error valu
e with a google.rpc.Status.code of 1,\ncorresponding to `Code.CANCELLED`.", | 192 "description": "Lists operations that match the specified fi
lter in the request. If the\nserver doesn't support this method, it returns `UNI
MPLEMENTED`.\n\nNOTE: the `name` binding allows API services to override the bin
ding\nto use different resource name schemes, such as `users/*/operations`. To\n
override the binding, API services can add a binding such as\n`\"/v1/{name=users
/*}/operations\"` to their service configuration.\nFor backwards compatibility,
the default name includes the operations\ncollection id, however overriding user
s must ensure the name binding\nis the parent resource, without the operations c
ollection id.", |
181 "httpMethod": "POST", | 193 "httpMethod": "GET", |
182 "id": "speech.operations.cancel", | 194 "id": "speech.operations.list", |
183 "parameterOrder": [ | 195 "parameterOrder": [], |
184 "name" | |
185 ], | |
186 "parameters": { | 196 "parameters": { |
| 197 "pageSize": { |
| 198 "description": "The standard list page size.", |
| 199 "format": "int32", |
| 200 "location": "query", |
| 201 "type": "integer" |
| 202 }, |
| 203 "filter": { |
| 204 "description": "The standard list filter.", |
| 205 "location": "query", |
| 206 "type": "string" |
| 207 }, |
| 208 "pageToken": { |
| 209 "description": "The standard list page token.", |
| 210 "location": "query", |
| 211 "type": "string" |
| 212 }, |
187 "name": { | 213 "name": { |
188 "description": "The name of the operation resource t
o be cancelled.", | 214 "description": "The name of the operation's parent r
esource.", |
189 "location": "path", | 215 "location": "query", |
190 "pattern": "^[^/]+$", | |
191 "required": true, | |
192 "type": "string" | 216 "type": "string" |
193 } | 217 } |
194 }, | 218 }, |
195 "path": "v1beta1/operations/{+name}:cancel", | 219 "path": "v1beta1/operations", |
196 "response": { | 220 "response": { |
197 "$ref": "Empty" | 221 "$ref": "ListOperationsResponse" |
198 }, | 222 }, |
199 "scopes": [ | 223 "scopes": [ |
200 "https://www.googleapis.com/auth/cloud-platform" | 224 "https://www.googleapis.com/auth/cloud-platform" |
201 ] | |
202 }, | |
203 "delete": { | |
204 "description": "Deletes a long-running operation. This metho
d indicates that the client is\nno longer interested in the operation result. It
does not cancel the\noperation. If the server doesn't support this method, it r
eturns\n`google.rpc.Code.UNIMPLEMENTED`.", | |
205 "httpMethod": "DELETE", | |
206 "id": "speech.operations.delete", | |
207 "parameterOrder": [ | |
208 "name" | |
209 ], | |
210 "parameters": { | |
211 "name": { | |
212 "description": "The name of the operation resource t
o be deleted.", | |
213 "location": "path", | |
214 "pattern": "^[^/]+$", | |
215 "required": true, | |
216 "type": "string" | |
217 } | |
218 }, | |
219 "path": "v1beta1/operations/{+name}", | |
220 "response": { | |
221 "$ref": "Empty" | |
222 }, | |
223 "scopes": [ | |
224 "https://www.googleapis.com/auth/cloud-platform" | |
225 ] | 225 ] |
226 } | 226 } |
227 } | 227 } |
228 }, | 228 }, |
229 "speech": { | 229 "speech": { |
230 "methods": { | 230 "methods": { |
231 "asyncrecognize": { | 231 "asyncrecognize": { |
232 "description": "Performs asynchronous speech recognition: re
ceive results via the\n[google.longrunning.Operations]\n(/speech/reference/rest/
v1beta1/operations#Operation)\ninterface. Returns either an\n`Operation.error` o
r an `Operation.response` which contains\nan `AsyncRecognizeResponse` message.", | 232 "description": "Performs asynchronous speech recognition: re
ceive results via the\n[google.longrunning.Operations]\n(/speech/reference/rest/
v1beta1/operations#Operation)\ninterface. Returns either an\n`Operation.error` o
r an `Operation.response` which contains\nan `AsyncRecognizeResponse` message.", |
233 "httpMethod": "POST", | 233 "httpMethod": "POST", |
234 "id": "speech.speech.asyncrecognize", | 234 "id": "speech.speech.asyncrecognize", |
(...skipping 23 matching lines...) Expand all Loading... |
258 "response": { | 258 "response": { |
259 "$ref": "SyncRecognizeResponse" | 259 "$ref": "SyncRecognizeResponse" |
260 }, | 260 }, |
261 "scopes": [ | 261 "scopes": [ |
262 "https://www.googleapis.com/auth/cloud-platform" | 262 "https://www.googleapis.com/auth/cloud-platform" |
263 ] | 263 ] |
264 } | 264 } |
265 } | 265 } |
266 } | 266 } |
267 }, | 267 }, |
268 "revision": "20170609", | 268 "revision": "20170705", |
269 "rootUrl": "https://speech.googleapis.com/", | 269 "rootUrl": "https://speech.googleapis.com/", |
270 "schemas": { | 270 "schemas": { |
| 271 "RecognitionConfig": { |
| 272 "description": "Provides information to the recognizer that specifie
s how to process the\nrequest.", |
| 273 "id": "RecognitionConfig", |
| 274 "properties": { |
| 275 "sampleRate": { |
| 276 "description": "*Required* Sample rate in Hertz of the audio
data sent in all\n`RecognitionAudio` messages. Valid values are: 8000-48000.\n1
6000 is optimal. For best results, set the sampling rate of the audio\nsource to
16000 Hz. If that's not possible, use the native sample rate of\nthe audio sour
ce (instead of re-sampling).", |
| 277 "format": "int32", |
| 278 "type": "integer" |
| 279 }, |
| 280 "languageCode": { |
| 281 "description": "*Optional* The language of the supplied audi
o as a BCP-47 language tag.\nExample: \"en-GB\" https://www.rfc-editor.org/rfc/
bcp/bcp47.txt\nIf omitted, defaults to \"en-US\". See\n[Language Support](https:
//cloud.google.com/speech/docs/languages)\nfor a list of the currently supported
language codes.", |
| 282 "type": "string" |
| 283 }, |
| 284 "encoding": { |
| 285 "description": "*Required* Encoding of audio data sent in al
l `RecognitionAudio` messages.", |
| 286 "enum": [ |
| 287 "ENCODING_UNSPECIFIED", |
| 288 "LINEAR16", |
| 289 "FLAC", |
| 290 "MULAW", |
| 291 "AMR", |
| 292 "AMR_WB" |
| 293 ], |
| 294 "enumDescriptions": [ |
| 295 "Not specified. Will return result google.rpc.Code.INVAL
ID_ARGUMENT.", |
| 296 "Uncompressed 16-bit signed little-endian samples (Linea
r PCM).\nThis is the only encoding that may be used by `AsyncRecognize`.", |
| 297 "This is the recommended encoding for `SyncRecognize` an
d\n`StreamingRecognize` because it uses lossless compression; therefore\nrecogni
tion accuracy is not compromised by a lossy codec.\n\nThe stream FLAC (Free Loss
less Audio Codec) encoding is specified at:\nhttp://flac.sourceforge.net/documen
tation.html.\n16-bit and 24-bit samples are supported.\nNot all fields in STREAM
INFO are supported.", |
| 298 "8-bit samples that compand 14-bit audio samples using G
.711 PCMU/mu-law.", |
| 299 "Adaptive Multi-Rate Narrowband codec. `sample_rate` mus
t be 8000 Hz.", |
| 300 "Adaptive Multi-Rate Wideband codec. `sample_rate` must
be 16000 Hz." |
| 301 ], |
| 302 "type": "string" |
| 303 }, |
| 304 "profanityFilter": { |
| 305 "description": "*Optional* If set to `true`, the server will
attempt to filter out\nprofanities, replacing all but the initial character in
each filtered word\nwith asterisks, e.g. \"f***\". If set to `false` or omitted,
profanities\nwon't be filtered out.", |
| 306 "type": "boolean" |
| 307 }, |
| 308 "speechContext": { |
| 309 "$ref": "SpeechContext", |
| 310 "description": "*Optional* A means to provide context to ass
ist the speech recognition." |
| 311 }, |
| 312 "maxAlternatives": { |
| 313 "description": "*Optional* Maximum number of recognition hyp
otheses to be returned.\nSpecifically, the maximum number of `SpeechRecognitionA
lternative` messages\nwithin each `SpeechRecognitionResult`.\nThe server may ret
urn fewer than `max_alternatives`.\nValid values are `0`-`30`. A value of `0` or
`1` will return a maximum of\none. If omitted, will return a maximum of one.", |
| 314 "format": "int32", |
| 315 "type": "integer" |
| 316 } |
| 317 }, |
| 318 "type": "object" |
| 319 }, |
| 320 "SyncRecognizeRequest": { |
| 321 "description": "The top-level message sent by the client for the `Sy
ncRecognize` method.", |
| 322 "id": "SyncRecognizeRequest", |
| 323 "properties": { |
| 324 "audio": { |
| 325 "$ref": "RecognitionAudio", |
| 326 "description": "*Required* The audio data to be recognized." |
| 327 }, |
| 328 "config": { |
| 329 "$ref": "RecognitionConfig", |
| 330 "description": "*Required* Provides information to the recog
nizer that specifies how to\nprocess the request." |
| 331 } |
| 332 }, |
| 333 "type": "object" |
| 334 }, |
| 335 "SyncRecognizeResponse": { |
| 336 "description": "The only message returned to the client by `SyncReco
gnize`. method. It\ncontains the result as zero or more sequential `SpeechRecogn
itionResult`\nmessages.", |
| 337 "id": "SyncRecognizeResponse", |
| 338 "properties": { |
| 339 "results": { |
| 340 "description": "*Output-only* Sequential list of transcripti
on results corresponding to\nsequential portions of audio.", |
| 341 "items": { |
| 342 "$ref": "SpeechRecognitionResult" |
| 343 }, |
| 344 "type": "array" |
| 345 } |
| 346 }, |
| 347 "type": "object" |
| 348 }, |
| 349 "Status": { |
| 350 "description": "The `Status` type defines a logical error model that
is suitable for different\nprogramming environments, including REST APIs and RP
C APIs. It is used by\n[gRPC](https://github.com/grpc). The error model is desig
ned to be:\n\n- Simple to use and understand for most users\n- Flexible enough t
o meet unexpected needs\n\n# Overview\n\nThe `Status` message contains three pie
ces of data: error code, error message,\nand error details. The error code shoul
d be an enum value of\ngoogle.rpc.Code, but it may accept additional error codes
if needed. The\nerror message should be a developer-facing English message tha
t helps\ndevelopers *understand* and *resolve* the error. If a localized user-fa
cing\nerror message is needed, put the localized message in the error details or
\nlocalize it in the client. The optional error details may contain arbitrary\ni
nformation about the error. There is a predefined set of error detail types\nin
the package `google.rpc` that can be used for common error conditions.\n\n# Lang
uage mapping\n\nThe `Status` message is the logical representation of the error
model, but it\nis not necessarily the actual wire format. When the `Status` mess
age is\nexposed in different client libraries and different wire protocols, it c
an be\nmapped differently. For example, it will likely be mapped to some excepti
ons\nin Java, but more likely mapped to some error codes in C.\n\n# Other uses\n
\nThe error model and the `Status` message can be used in a variety of\nenvironm
ents, either with or without APIs, to provide a\nconsistent developer experience
across different environments.\n\nExample uses of this error model include:\n\n
- Partial errors. If a service needs to return partial errors to the client,\n
it may embed the `Status` in the normal response to indicate the partial\n
errors.\n\n- Workflow errors. A typical workflow has multiple steps. Each step m
ay\n have a `Status` message for error reporting.\n\n- Batch operations. If a
client uses batch request and batch response, the\n `Status` message should
be used directly inside batch response, one for\n each error sub-response.\n\
n- Asynchronous operations. If an API call embeds asynchronous operation\n re
sults in its response, the status of those operations should be\n represented
directly using the `Status` message.\n\n- Logging. If some API errors are store
d in logs, the message `Status` could\n be used directly after any stripping
needed for security/privacy reasons.", |
| 351 "id": "Status", |
| 352 "properties": { |
| 353 "details": { |
| 354 "description": "A list of messages that carry the error deta
ils. There will be a\ncommon set of message types for APIs to use.", |
| 355 "items": { |
| 356 "additionalProperties": { |
| 357 "description": "Properties of the object. Contains f
ield @type with type URL.", |
| 358 "type": "any" |
| 359 }, |
| 360 "type": "object" |
| 361 }, |
| 362 "type": "array" |
| 363 }, |
| 364 "code": { |
| 365 "description": "The status code, which should be an enum val
ue of google.rpc.Code.", |
| 366 "format": "int32", |
| 367 "type": "integer" |
| 368 }, |
| 369 "message": { |
| 370 "description": "A developer-facing error message, which shou
ld be in English. Any\nuser-facing error message should be localized and sent in
the\ngoogle.rpc.Status.details field, or localized by the client.", |
| 371 "type": "string" |
| 372 } |
| 373 }, |
| 374 "type": "object" |
| 375 }, |
271 "Empty": { | 376 "Empty": { |
272 "description": "A generic empty message that you can re-use to avoid
defining duplicated\nempty messages in your APIs. A typical example is to use i
t as the request\nor the response type of an API method. For instance:\n\n se
rvice Foo {\n rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty
);\n }\n\nThe JSON representation for `Empty` is empty JSON object `{}`.", | 377 "description": "A generic empty message that you can re-use to avoid
defining duplicated\nempty messages in your APIs. A typical example is to use i
t as the request\nor the response type of an API method. For instance:\n\n se
rvice Foo {\n rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty
);\n }\n\nThe JSON representation for `Empty` is empty JSON object `{}`.", |
273 "id": "Empty", | 378 "id": "Empty", |
274 "properties": {}, | 379 "properties": {}, |
275 "type": "object" | 380 "type": "object" |
276 }, | 381 }, |
277 "SpeechRecognitionAlternative": { | 382 "SpeechRecognitionAlternative": { |
278 "description": "Alternative hypotheses (a.k.a. n-best list).", | 383 "description": "Alternative hypotheses (a.k.a. n-best list).", |
279 "id": "SpeechRecognitionAlternative", | 384 "id": "SpeechRecognitionAlternative", |
280 "properties": { | 385 "properties": { |
(...skipping 20 matching lines...) Expand all Loading... |
301 }, | 406 }, |
302 "type": "array" | 407 "type": "array" |
303 } | 408 } |
304 }, | 409 }, |
305 "type": "object" | 410 "type": "object" |
306 }, | 411 }, |
307 "ListOperationsResponse": { | 412 "ListOperationsResponse": { |
308 "description": "The response message for Operations.ListOperations."
, | 413 "description": "The response message for Operations.ListOperations."
, |
309 "id": "ListOperationsResponse", | 414 "id": "ListOperationsResponse", |
310 "properties": { | 415 "properties": { |
| 416 "nextPageToken": { |
| 417 "description": "The standard List next-page token.", |
| 418 "type": "string" |
| 419 }, |
311 "operations": { | 420 "operations": { |
312 "description": "A list of operations that matches the specif
ied filter in the request.", | 421 "description": "A list of operations that matches the specif
ied filter in the request.", |
313 "items": { | 422 "items": { |
314 "$ref": "Operation" | 423 "$ref": "Operation" |
315 }, | 424 }, |
316 "type": "array" | 425 "type": "array" |
317 }, | |
318 "nextPageToken": { | |
319 "description": "The standard List next-page token.", | |
320 "type": "string" | |
321 } | 426 } |
322 }, | 427 }, |
323 "type": "object" | 428 "type": "object" |
324 }, | 429 }, |
325 "SpeechRecognitionResult": { | 430 "SpeechRecognitionResult": { |
326 "description": "A speech recognition result corresponding to a porti
on of the audio.", | 431 "description": "A speech recognition result corresponding to a porti
on of the audio.", |
327 "id": "SpeechRecognitionResult", | 432 "id": "SpeechRecognitionResult", |
328 "properties": { | 433 "properties": { |
329 "alternatives": { | 434 "alternatives": { |
330 "description": "*Output-only* May contain one or more recogn
ition hypotheses (up to the\nmaximum specified in `max_alternatives`).", | 435 "description": "*Output-only* May contain one or more recogn
ition hypotheses (up to the\nmaximum specified in `max_alternatives`).", |
(...skipping 18 matching lines...) Expand all Loading... |
349 "description": "URI that points to a file that contains audi
o data bytes as specified in\n`RecognitionConfig`. Currently, only Google Cloud
Storage URIs are\nsupported, which must be specified in the following format:\n`
gs://bucket_name/object_name` (other URI formats return\ngoogle.rpc.Code.INVALID
_ARGUMENT). For more information, see\n[Request URIs](https://cloud.google.com/s
torage/docs/reference-uris).", | 454 "description": "URI that points to a file that contains audi
o data bytes as specified in\n`RecognitionConfig`. Currently, only Google Cloud
Storage URIs are\nsupported, which must be specified in the following format:\n`
gs://bucket_name/object_name` (other URI formats return\ngoogle.rpc.Code.INVALID
_ARGUMENT). For more information, see\n[Request URIs](https://cloud.google.com/s
torage/docs/reference-uris).", |
350 "type": "string" | 455 "type": "string" |
351 } | 456 } |
352 }, | 457 }, |
353 "type": "object" | 458 "type": "object" |
354 }, | 459 }, |
355 "AsyncRecognizeRequest": { | 460 "AsyncRecognizeRequest": { |
356 "description": "The top-level message sent by the client for the `As
yncRecognize` method.", | 461 "description": "The top-level message sent by the client for the `As
yncRecognize` method.", |
357 "id": "AsyncRecognizeRequest", | 462 "id": "AsyncRecognizeRequest", |
358 "properties": { | 463 "properties": { |
| 464 "audio": { |
| 465 "$ref": "RecognitionAudio", |
| 466 "description": "*Required* The audio data to be recognized." |
| 467 }, |
359 "config": { | 468 "config": { |
360 "$ref": "RecognitionConfig", | 469 "$ref": "RecognitionConfig", |
361 "description": "*Required* Provides information to the recog
nizer that specifies how to\nprocess the request." | 470 "description": "*Required* Provides information to the recog
nizer that specifies how to\nprocess the request." |
362 }, | |
363 "audio": { | |
364 "$ref": "RecognitionAudio", | |
365 "description": "*Required* The audio data to be recognized." | |
366 } | 471 } |
367 }, | 472 }, |
368 "type": "object" | 473 "type": "object" |
369 }, | 474 }, |
370 "Operation": { | 475 "Operation": { |
371 "description": "This resource represents a long-running operation th
at is the result of a\nnetwork API call.", | 476 "description": "This resource represents a long-running operation th
at is the result of a\nnetwork API call.", |
372 "id": "Operation", | 477 "id": "Operation", |
373 "properties": { | 478 "properties": { |
374 "done": { | |
375 "description": "If the value is `false`, it means the operat
ion is still in progress.\nIf true, the operation is completed, and either `erro
r` or `response` is\navailable.", | |
376 "type": "boolean" | |
377 }, | |
378 "response": { | |
379 "additionalProperties": { | |
380 "description": "Properties of the object. Contains field
@type with type URL.", | |
381 "type": "any" | |
382 }, | |
383 "description": "The normal response of the operation in case
of success. If the original\nmethod returns no data on success, such as `Delet
e`, the response is\n`google.protobuf.Empty`. If the original method is standar
d\n`Get`/`Create`/`Update`, the response should be the resource. For other\nmet
hods, the response should have the type `XxxResponse`, where `Xxx`\nis the origi
nal method name. For example, if the original method name\nis `TakeSnapshot()`,
the inferred response type is\n`TakeSnapshotResponse`.", | |
384 "type": "object" | |
385 }, | |
386 "name": { | |
387 "description": "The server-assigned name, which is only uniq
ue within the same service that\noriginally returns it. If you use the default H
TTP mapping, the\n`name` should have the format of `operations/some/unique/name`
.", | |
388 "type": "string" | |
389 }, | |
390 "error": { | 479 "error": { |
391 "$ref": "Status", | 480 "$ref": "Status", |
392 "description": "The error result of the operation in case of
failure or cancellation." | 481 "description": "The error result of the operation in case of
failure or cancellation." |
393 }, | 482 }, |
394 "metadata": { | 483 "metadata": { |
395 "additionalProperties": { | 484 "additionalProperties": { |
396 "description": "Properties of the object. Contains field
@type with type URL.", | 485 "description": "Properties of the object. Contains field
@type with type URL.", |
397 "type": "any" | 486 "type": "any" |
398 }, | 487 }, |
399 "description": "Service-specific metadata associated with th
e operation. It typically\ncontains progress information and common metadata su
ch as create time.\nSome services might not provide such metadata. Any method t
hat returns a\nlong-running operation should document the metadata type, if any.
", | 488 "description": "Service-specific metadata associated with th
e operation. It typically\ncontains progress information and common metadata su
ch as create time.\nSome services might not provide such metadata. Any method t
hat returns a\nlong-running operation should document the metadata type, if any.
", |
400 "type": "object" | 489 "type": "object" |
| 490 }, |
| 491 "done": { |
| 492 "description": "If the value is `false`, it means the operat
ion is still in progress.\nIf true, the operation is completed, and either `erro
r` or `response` is\navailable.", |
| 493 "type": "boolean" |
| 494 }, |
| 495 "response": { |
| 496 "additionalProperties": { |
| 497 "description": "Properties of the object. Contains field
@type with type URL.", |
| 498 "type": "any" |
| 499 }, |
| 500 "description": "The normal response of the operation in case
of success. If the original\nmethod returns no data on success, such as `Delet
e`, the response is\n`google.protobuf.Empty`. If the original method is standar
d\n`Get`/`Create`/`Update`, the response should be the resource. For other\nmet
hods, the response should have the type `XxxResponse`, where `Xxx`\nis the origi
nal method name. For example, if the original method name\nis `TakeSnapshot()`,
the inferred response type is\n`TakeSnapshotResponse`.", |
| 501 "type": "object" |
| 502 }, |
| 503 "name": { |
| 504 "description": "The server-assigned name, which is only uniq
ue within the same service that\noriginally returns it. If you use the default H
TTP mapping, the\n`name` should have the format of `operations/some/unique/name`
.", |
| 505 "type": "string" |
401 } | 506 } |
402 }, | 507 }, |
403 "type": "object" | 508 "type": "object" |
404 }, | |
405 "RecognitionConfig": { | |
406 "description": "Provides information to the recognizer that specifie
s how to process the\nrequest.", | |
407 "id": "RecognitionConfig", | |
408 "properties": { | |
409 "maxAlternatives": { | |
410 "description": "*Optional* Maximum number of recognition hyp
otheses to be returned.\nSpecifically, the maximum number of `SpeechRecognitionA
lternative` messages\nwithin each `SpeechRecognitionResult`.\nThe server may ret
urn fewer than `max_alternatives`.\nValid values are `0`-`30`. A value of `0` or
`1` will return a maximum of\none. If omitted, will return a maximum of one.", | |
411 "format": "int32", | |
412 "type": "integer" | |
413 }, | |
414 "sampleRate": { | |
415 "description": "*Required* Sample rate in Hertz of the audio
data sent in all\n`RecognitionAudio` messages. Valid values are: 8000-48000.\n1
6000 is optimal. For best results, set the sampling rate of the audio\nsource to
16000 Hz. If that's not possible, use the native sample rate of\nthe audio sour
ce (instead of re-sampling).", | |
416 "format": "int32", | |
417 "type": "integer" | |
418 }, | |
419 "languageCode": { | |
420 "description": "*Optional* The language of the supplied audi
o as a BCP-47 language tag.\nExample: \"en-GB\" https://www.rfc-editor.org/rfc/
bcp/bcp47.txt\nIf omitted, defaults to \"en-US\". See\n[Language Support](https:
//cloud.google.com/speech/docs/languages)\nfor a list of the currently supported
language codes.", | |
421 "type": "string" | |
422 }, | |
423 "speechContext": { | |
424 "$ref": "SpeechContext", | |
425 "description": "*Optional* A means to provide context to ass
ist the speech recognition." | |
426 }, | |
427 "encoding": { | |
428 "description": "*Required* Encoding of audio data sent in al
l `RecognitionAudio` messages.", | |
429 "enum": [ | |
430 "ENCODING_UNSPECIFIED", | |
431 "LINEAR16", | |
432 "FLAC", | |
433 "MULAW", | |
434 "AMR", | |
435 "AMR_WB" | |
436 ], | |
437 "enumDescriptions": [ | |
438 "Not specified. Will return result google.rpc.Code.INVAL
ID_ARGUMENT.", | |
439 "Uncompressed 16-bit signed little-endian samples (Linea
r PCM).\nThis is the only encoding that may be used by `AsyncRecognize`.", | |
440 "This is the recommended encoding for `SyncRecognize` an
d\n`StreamingRecognize` because it uses lossless compression; therefore\nrecogni
tion accuracy is not compromised by a lossy codec.\n\nThe stream FLAC (Free Loss
less Audio Codec) encoding is specified at:\nhttp://flac.sourceforge.net/documen
tation.html.\n16-bit and 24-bit samples are supported.\nNot all fields in STREAM
INFO are supported.", | |
441 "8-bit samples that compand 14-bit audio samples using G
.711 PCMU/mu-law.", | |
442 "Adaptive Multi-Rate Narrowband codec. `sample_rate` mus
t be 8000 Hz.", | |
443 "Adaptive Multi-Rate Wideband codec. `sample_rate` must
be 16000 Hz." | |
444 ], | |
445 "type": "string" | |
446 }, | |
447 "profanityFilter": { | |
448 "description": "*Optional* If set to `true`, the server will
attempt to filter out\nprofanities, replacing all but the initial character in
each filtered word\nwith asterisks, e.g. \"f***\". If set to `false` or omitted,
profanities\nwon't be filtered out.", | |
449 "type": "boolean" | |
450 } | |
451 }, | |
452 "type": "object" | |
453 }, | |
454 "SyncRecognizeRequest": { | |
455 "description": "The top-level message sent by the client for the `Sy
ncRecognize` method.", | |
456 "id": "SyncRecognizeRequest", | |
457 "properties": { | |
458 "config": { | |
459 "$ref": "RecognitionConfig", | |
460 "description": "*Required* Provides information to the recog
nizer that specifies how to\nprocess the request." | |
461 }, | |
462 "audio": { | |
463 "$ref": "RecognitionAudio", | |
464 "description": "*Required* The audio data to be recognized." | |
465 } | |
466 }, | |
467 "type": "object" | |
468 }, | |
469 "SyncRecognizeResponse": { | |
470 "description": "The only message returned to the client by `SyncReco
gnize`. method. It\ncontains the result as zero or more sequential `SpeechRecogn
itionResult`\nmessages.", | |
471 "id": "SyncRecognizeResponse", | |
472 "properties": { | |
473 "results": { | |
474 "description": "*Output-only* Sequential list of transcripti
on results corresponding to\nsequential portions of audio.", | |
475 "items": { | |
476 "$ref": "SpeechRecognitionResult" | |
477 }, | |
478 "type": "array" | |
479 } | |
480 }, | |
481 "type": "object" | |
482 }, | |
483 "Status": { | |
484 "description": "The `Status` type defines a logical error model that
is suitable for different\nprogramming environments, including REST APIs and RP
C APIs. It is used by\n[gRPC](https://github.com/grpc). The error model is desig
ned to be:\n\n- Simple to use and understand for most users\n- Flexible enough t
o meet unexpected needs\n\n# Overview\n\nThe `Status` message contains three pie
ces of data: error code, error message,\nand error details. The error code shoul
d be an enum value of\ngoogle.rpc.Code, but it may accept additional error codes
if needed. The\nerror message should be a developer-facing English message tha
t helps\ndevelopers *understand* and *resolve* the error. If a localized user-fa
cing\nerror message is needed, put the localized message in the error details or
\nlocalize it in the client. The optional error details may contain arbitrary\ni
nformation about the error. There is a predefined set of error detail types\nin
the package `google.rpc` that can be used for common error conditions.\n\n# Lang
uage mapping\n\nThe `Status` message is the logical representation of the error
model, but it\nis not necessarily the actual wire format. When the `Status` mess
age is\nexposed in different client libraries and different wire protocols, it c
an be\nmapped differently. For example, it will likely be mapped to some excepti
ons\nin Java, but more likely mapped to some error codes in C.\n\n# Other uses\n
\nThe error model and the `Status` message can be used in a variety of\nenvironm
ents, either with or without APIs, to provide a\nconsistent developer experience
across different environments.\n\nExample uses of this error model include:\n\n
- Partial errors. If a service needs to return partial errors to the client,\n
it may embed the `Status` in the normal response to indicate the partial\n
errors.\n\n- Workflow errors. A typical workflow has multiple steps. Each step m
ay\n have a `Status` message for error reporting.\n\n- Batch operations. If a
client uses batch request and batch response, the\n `Status` message should
be used directly inside batch response, one for\n each error sub-response.\n\
n- Asynchronous operations. If an API call embeds asynchronous operation\n re
sults in its response, the status of those operations should be\n represented
directly using the `Status` message.\n\n- Logging. If some API errors are store
d in logs, the message `Status` could\n be used directly after any stripping
needed for security/privacy reasons.", | |
485 "id": "Status", | |
486 "properties": { | |
487 "message": { | |
488 "description": "A developer-facing error message, which shou
ld be in English. Any\nuser-facing error message should be localized and sent in
the\ngoogle.rpc.Status.details field, or localized by the client.", | |
489 "type": "string" | |
490 }, | |
491 "details": { | |
492 "description": "A list of messages that carry the error deta
ils. There will be a\ncommon set of message types for APIs to use.", | |
493 "items": { | |
494 "additionalProperties": { | |
495 "description": "Properties of the object. Contains f
ield @type with type URL.", | |
496 "type": "any" | |
497 }, | |
498 "type": "object" | |
499 }, | |
500 "type": "array" | |
501 }, | |
502 "code": { | |
503 "description": "The status code, which should be an enum val
ue of google.rpc.Code.", | |
504 "format": "int32", | |
505 "type": "integer" | |
506 } | |
507 }, | |
508 "type": "object" | |
509 } | 509 } |
510 }, | 510 }, |
511 "servicePath": "", | 511 "servicePath": "", |
512 "title": "Google Cloud Speech API", | 512 "title": "Google Cloud Speech API", |
513 "version": "v1beta1" | 513 "version": "v1beta1" |
514 } | 514 } |
OLD | NEW |