@@ -23,6 +23,7 @@ This client supports the following Google Cloud Platform services at a [Beta](#v
23
23
* [ Cloud Firestore] ( https://github.com/googleapis/nodejs-firestore/ ) (Beta)
24
24
* [ Cloud Pub/Sub] ( #cloud-pubsub-beta ) (Beta)
25
25
* [ Cloud Spanner] ( https://github.com/googleapis/nodejs-spanner/ ) (Beta)
26
+ * [ Cloud Speech] ( #cloud-speech-beta ) (Beta)
26
27
* [ Cloud Video Intelligence] ( https://github.com/googleapis/nodejs-video-intelligence/ ) (Beta)
27
28
* [ Cloud Vision] ( #cloud-vision-beta ) (Beta)
28
29
* [ Google BigQuery] ( #google-bigquery-beta ) (Beta)
@@ -33,7 +34,6 @@ This client supports the following Google Cloud Platform services at an [Alpha](
33
34
* [ Cloud Bigtable] ( https://github.com/googleapis/nodejs-bigtable ) (Alpha)
34
35
* [ Cloud DNS] ( https://github.com/googleapis/nodejs-dns ) (Alpha)
35
36
* [ Cloud Resource Manager] ( #cloud-resource-manager-alpha ) (Alpha)
36
- * [ Cloud Speech] ( #cloud-speech-alpha ) (Alpha)
37
37
* [ Google Compute Engine] ( https://github.com/googleapis/nodejs-compute ) (Alpha)
38
38
* [ Google Prediction API] ( #google-prediction-api-alpha ) (Alpha)
39
39
* [ Google Stackdriver Debugger] ( #google-stackdriver-debugger-alpha ) (Alpha)
@@ -643,6 +643,59 @@ database.runStream('SELECT * FROM Singers')
643
643
```
644
644
645
645
646
+ ## Cloud Speech (Beta)
647
+
648
+ - [ API Documentation] [ gcloud-speech-docs ]
649
+ - [ Official Documentation] [ cloud-speech-docs ]
650
+
651
+ #### Using the Cloud Speech API module
652
+
653
+ ```
654
+ $ npm install --save @google-cloud/speech
655
+ ```
656
+
657
+ ``` js
658
+ var speech = require (' @google-cloud/speech' );
659
+ ```
660
+
661
+ #### Authentication
662
+
663
+ See [ Authentication] ( #authentication ) .
664
+
665
+ #### Preview
666
+
667
+ ``` js
668
+ var speechClient = speech ({
669
+ projectId: ' my-project' ,
670
+ keyFilename: ' /path/to/keyfile.json'
671
+ });
672
+
673
+ var languageCode = ' en-US' ;
674
+ var sampleRateHertz = 44100 ;
675
+ var encoding = speech .v1 .types .RecognitionConfig .AudioEncoding .FLAC ;
676
+ var config = {
677
+ languageCode : languageCode,
678
+ sampleRateHertz : sampleRateHertz,
679
+ encoding : encoding
680
+ };
681
+ var uri = ' gs://gapic-toolkit/hello.flac' ;
682
+ var audio = {
683
+ uri : uri
684
+ };
685
+ var request = {
686
+ config: config,
687
+ audio: audio
688
+ };
689
+ speechClient .recognize (request).then (function (responses ) {
690
+ var response = responses[0 ];
691
+ // doThingsWith(response)
692
+ })
693
+ .catch (function (err ) {
694
+ console .error (err);
695
+ });
696
+ ```
697
+
698
+
646
699
## Cloud Vision (Beta)
647
700
648
701
- [ API Documentation] [ gcloud-vision-docs ]
@@ -970,59 +1023,6 @@ project.getMetadata(function(err, metadata) {
970
1023
```
971
1024
972
1025
973
- ## Cloud Speech (Alpha)
974
-
975
- - [ API Documentation] [ gcloud-speech-docs ]
976
- - [ Official Documentation] [ cloud-speech-docs ]
977
-
978
- #### Using the Cloud Speech API module
979
-
980
- ```
981
- $ npm install --save @google-cloud/speech
982
- ```
983
-
984
- ``` js
985
- var speech = require (' @google-cloud/speech' );
986
- ```
987
-
988
- #### Authentication
989
-
990
- See [ Authentication] ( #authentication ) .
991
-
992
- #### Preview
993
-
994
- ``` js
995
- var speechClient = speech ({
996
- projectId: ' my-project' ,
997
- keyFilename: ' /path/to/keyfile.json'
998
- });
999
-
1000
- var languageCode = ' en-US' ;
1001
- var sampleRateHertz = 44100 ;
1002
- var encoding = speech .v1 .types .RecognitionConfig .AudioEncoding .FLAC ;
1003
- var config = {
1004
- languageCode : languageCode,
1005
- sampleRateHertz : sampleRateHertz,
1006
- encoding : encoding
1007
- };
1008
- var uri = ' gs://gapic-toolkit/hello.flac' ;
1009
- var audio = {
1010
- uri : uri
1011
- };
1012
- var request = {
1013
- config: config,
1014
- audio: audio
1015
- };
1016
- speechClient .recognize (request).then (function (responses ) {
1017
- var response = responses[0 ];
1018
- // doThingsWith(response)
1019
- })
1020
- .catch (function (err ) {
1021
- console .error (err);
1022
- });
1023
- ```
1024
-
1025
-
1026
1026
## Google Compute Engine (Alpha)
1027
1027
1028
1028
- [ API Documentation] [ gcloud-compute-docs ]
0 commit comments