{"action":"created","comment":{"url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/comments/69942956","id":69942956,"diff_hunk":"@@ -0,0 +1,490 @@\n+/*!\n+ * Copyright 2016 Google Inc. All Rights Reserved.\n+ *\n+ * Licensed under the Apache License, Version 2.0 (the \"License\");\n+ * you may not use this file except in compliance with the License.\n+ * You may obtain a copy of the License at\n+ *\n+ *      http://www.apache.org/licenses/LICENSE-2.0\n+ *\n+ * Unless required by applicable law or agreed to in writing, software\n+ * distributed under the License is distributed on an \"AS IS\" BASIS,\n+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+ * See the License for the specific language governing permissions and\n+ * limitations under the License.\n+ */\n+\n+/*!\n+ * @module speech\n+ */\n+\n+'use strict';\n+\n+var arrify = require('arrify');\n+var async = require('async');\n+var extend = require('extend');\n+var format = require('string-format-obj');\n+var googleProtoFiles = require('google-proto-files');\n+var fs = require('fs');\n+var is = require('is');\n+var nodeutil = require('util');\n+var request = require('request');\n+var through = require('through2');\n+var duplexify = require('duplexify');\n+\n+/**\n+ * @type {module:storage/file}\n+ * @private\n+ */\n+var File = require('../storage/file.js');\n+\n+/**\n+ * @type {module:common/grpc-service}\n+ * @private\n+ */\n+var GrpcService = require('../common/grpc-service.js');\n+\n+/**\n+ * @type {module:common/util}\n+ * @private\n+ */\n+var util = require('../common/util.js');\n+\n+/**\n+ * The [Cloud Speech API](https://cloud.google.com/speech/docs) enables easy\n+ * integration of Google speech recognition technologies into developer\n+ * applications. Send audio and receive a text transcription from the Cloud\n+ * Speech API service.\n+ *\n+ * @constructor\n+ * @alias module:speech\n+ *\n+ * @classdesc\n+ * <p class=\"notice\">\n+ *   **This is an Alpha release of Google Cloud Speech.** This API is not\n+ *   covered by any SLA or deprecation policy and may be subject to backward-\n+ *   incompatible changes.\n+ * </p>\n+ *\n+ * To learn more about the Speech API, see the\n+ * [Getting Started guide](https://cloud.google.com/speech/docs/getting-started).\n+ *\n+ * @resource [Getting Started]{@link https://cloud.google.com/speech/docs/getting-started}\n+ * @resource [Image Best Practices]{@link https://cloud.google.com/speech/docs/best-practices}\n+ *\n+ * @param {object} options - [Configuration object](#/docs).\n+ *\n+ * @example\n+ * var gcloud = require('gcloud')({\n+ *   keyFilename: '/path/to/keyfile.json',\n+ *   projectId: 'grape-spaceship-123'\n+ * });\n+ *\n+ * var speech = gcloud.speech();\n+ */\n+function Speech(options) {\n+  if (!(this instanceof Speech)) {\n+    options = util.normalizeArguments(this, options);\n+    return new Speech(options);\n+  }\n+\n+  var config = {\n+    baseUrl: 'speech.googleapis.com',\n+    projectIdRequired: false,\n+    service: 'speech',\n+    apiVersion: 'v1',","path":"lib/speech/index.js","position":95,"original_position":95,"commit_id":"a6b53488be81fed9e394188ab301ab3f967d0e97","original_commit_id":"a6b53488be81fed9e394188ab301ab3f967d0e97","user":{"login":"pbogle","id":19914915,"avatar_url":"https://avatars.githubusercontent.com/u/19914915?v=3","gravatar_id":"","url":"https://api.github.com/users/pbogle","html_url":"https://github.com/pbogle","followers_url":"https://api.github.com/users/pbogle/followers","following_url":"https://api.github.com/users/pbogle/following{/other_user}","gists_url":"https://api.github.com/users/pbogle/gists{/gist_id}","starred_url":"https://api.github.com/users/pbogle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pbogle/subscriptions","organizations_url":"https://api.github.com/users/pbogle/orgs","repos_url":"https://api.github.com/users/pbogle/repos","events_url":"https://api.github.com/users/pbogle/events{/privacy}","received_events_url":"https://api.github.com/users/pbogle/received_events","type":"User","site_admin":false},"body":"Please use the v1beta1 version of the api rather than the alpha version (which unfortunately is named v1).  There are some breaking changes between the two, by the way.","created_at":"2016-07-07T16:48:36Z","updated_at":"2016-07-07T16:48:36Z","html_url":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1407#discussion_r69942956","pull_request_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1407","_links":{"self":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/comments/69942956"},"html":{"href":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1407#discussion_r69942956"},"pull_request":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1407"}}},"pull_request":{"url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1407","id":76055472,"html_url":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1407","diff_url":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1407.diff","patch_url":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1407.patch","issue_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/1407","number":1407,"state":"open","locked":false,"title":"speech: initial support","user":{"login":"jmdobry","id":1213510,"avatar_url":"https://avatars.githubusercontent.com/u/1213510?v=3","gravatar_id":"","url":"https://api.github.com/users/jmdobry","html_url":"https://github.com/jmdobry","followers_url":"https://api.github.com/users/jmdobry/followers","following_url":"https://api.github.com/users/jmdobry/following{/other_user}","gists_url":"https://api.github.com/users/jmdobry/gists{/gist_id}","starred_url":"https://api.github.com/users/jmdobry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jmdobry/subscriptions","organizations_url":"https://api.github.com/users/jmdobry/orgs","repos_url":"https://api.github.com/users/jmdobry/repos","events_url":"https://api.github.com/users/jmdobry/events{/privacy}","received_events_url":"https://api.github.com/users/jmdobry/received_events","type":"User","site_admin":false},"body":"Closes #1406\r\n\r\nAdd support for the Speech API!\r\n\r\nNote: I may have opened this PR too early, because it's branched off an un-merged PR (#1279). Unfortunately, GitHub doesn't have a \"diffbase\" feature, so this PR looks massive. Opening anyway for initial review.\r\n\r\n----\r\n\r\n- [x] Implementation\r\n  - [x] Speech service\r\n- [x] Docs\r\n- [x] Tests\r\n  - [x] e2e Tests\r\n  - [x] Unit Tests\r\n\r\nNew files:\r\n\r\n* lib/speech/index.js\r\n* test/speech/index.js\r\n* system-test/speech.js\r\n* system-test/data/bridge.raw\r\n* system-test/data/spain.raw\r\n* system-test/data/quit.raw\r\n\r\nModified:\r\n\r\n* lib/index.js\r\n* lib/common/grpc-service.js\r\n* docs/toc.json\r\n* README.md\r\n* package.json\r\n* CONTRIBUTORS","created_at":"2016-07-02T04:11:46Z","updated_at":"2016-07-07T16:48:36Z","closed_at":null,"merged_at":null,"merge_commit_sha":"04c0f0710417179e8fd8ba8fd2d94d1a05bf7f4d","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1407/commits","review_comments_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1407/comments","review_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/comments{/number}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/1407/comments","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/statuses/a6b53488be81fed9e394188ab301ab3f967d0e97","head":{"label":"jmdobry:speech","ref":"speech","sha":"a6b53488be81fed9e394188ab301ab3f967d0e97","user":{"login":"jmdobry","id":1213510,"avatar_url":"https://avatars.githubusercontent.com/u/1213510?v=3","gravatar_id":"","url":"https://api.github.com/users/jmdobry","html_url":"https://github.com/jmdobry","followers_url":"https://api.github.com/users/jmdobry/followers","following_url":"https://api.github.com/users/jmdobry/following{/other_user}","gists_url":"https://api.github.com/users/jmdobry/gists{/gist_id}","starred_url":"https://api.github.com/users/jmdobry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jmdobry/subscriptions","organizations_url":"https://api.github.com/users/jmdobry/orgs","repos_url":"https://api.github.com/users/jmdobry/repos","events_url":"https://api.github.com/users/jmdobry/events{/privacy}","received_events_url":"https://api.github.com/users/jmdobry/received_events","type":"User","site_admin":false},"repo":{"id":62340865,"name":"gcloud-node","full_name":"jmdobry/gcloud-node","owner":{"login":"jmdobry","id":1213510,"avatar_url":"https://avatars.githubusercontent.com/u/1213510?v=3","gravatar_id":"","url":"https://api.github.com/users/jmdobry","html_url":"https://github.com/jmdobry","followers_url":"https://api.github.com/users/jmdobry/followers","following_url":"https://api.github.com/users/jmdobry/following{/other_user}","gists_url":"https://api.github.com/users/jmdobry/gists{/gist_id}","starred_url":"https://api.github.com/users/jmdobry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jmdobry/subscriptions","organizations_url":"https://api.github.com/users/jmdobry/orgs","repos_url":"https://api.github.com/users/jmdobry/repos","events_url":"https://api.github.com/users/jmdobry/events{/privacy}","received_events_url":"https://api.github.com/users/jmdobry/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jmdobry/gcloud-node","description":"Google Cloud Client Library for Node.js","fork":true,"url":"https://api.github.com/repos/jmdobry/gcloud-node","forks_url":"https://api.github.com/repos/jmdobry/gcloud-node/forks","keys_url":"https://api.github.com/repos/jmdobry/gcloud-node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jmdobry/gcloud-node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jmdobry/gcloud-node/teams","hooks_url":"https://api.github.com/repos/jmdobry/gcloud-node/hooks","issue_events_url":"https://api.github.com/repos/jmdobry/gcloud-node/issues/events{/number}","events_url":"https://api.github.com/repos/jmdobry/gcloud-node/events","assignees_url":"https://api.github.com/repos/jmdobry/gcloud-node/assignees{/user}","branches_url":"https://api.github.com/repos/jmdobry/gcloud-node/branches{/branch}","tags_url":"https://api.github.com/repos/jmdobry/gcloud-node/tags","blobs_url":"https://api.github.com/repos/jmdobry/gcloud-node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jmdobry/gcloud-node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jmdobry/gcloud-node/git/refs{/sha}","trees_url":"https://api.github.com/repos/jmdobry/gcloud-node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jmdobry/gcloud-node/statuses/{sha}","languages_url":"https://api.github.com/repos/jmdobry/gcloud-node/languages","stargazers_url":"https://api.github.com/repos/jmdobry/gcloud-node/stargazers","contributors_url":"https://api.github.com/repos/jmdobry/gcloud-node/contributors","subscribers_url":"https://api.github.com/repos/jmdobry/gcloud-node/subscribers","subscription_url":"https://api.github.com/repos/jmdobry/gcloud-node/subscription","commits_url":"https://api.github.com/repos/jmdobry/gcloud-node/commits{/sha}","git_commits_url":"https://api.github.com/repos/jmdobry/gcloud-node/git/commits{/sha}","comments_url":"https://api.github.com/repos/jmdobry/gcloud-node/comments{/number}","issue_comment_url":"https://api.github.com/repos/jmdobry/gcloud-node/issues/comments{/number}","contents_url":"https://api.github.com/repos/jmdobry/gcloud-node/contents/{+path}","compare_url":"https://api.github.com/repos/jmdobry/gcloud-node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jmdobry/gcloud-node/merges","archive_url":"https://api.github.com/repos/jmdobry/gcloud-node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jmdobry/gcloud-node/downloads","issues_url":"https://api.github.com/repos/jmdobry/gcloud-node/issues{/number}","pulls_url":"https://api.github.com/repos/jmdobry/gcloud-node/pulls{/number}","milestones_url":"https://api.github.com/repos/jmdobry/gcloud-node/milestones{/number}","notifications_url":"https://api.github.com/repos/jmdobry/gcloud-node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jmdobry/gcloud-node/labels{/name}","releases_url":"https://api.github.com/repos/jmdobry/gcloud-node/releases{/id}","deployments_url":"https://api.github.com/repos/jmdobry/gcloud-node/deployments","created_at":"2016-06-30T20:38:57Z","updated_at":"2016-06-30T20:38:59Z","pushed_at":"2016-07-06T18:19:32Z","git_url":"git://github.com/jmdobry/gcloud-node.git","ssh_url":"git@github.com:jmdobry/gcloud-node.git","clone_url":"https://github.com/jmdobry/gcloud-node.git","svn_url":"https://github.com/jmdobry/gcloud-node","homepage":"https://googlecloudplatform.github.io/gcloud-node/","size":15294,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"GoogleCloudPlatform:master","ref":"master","sha":"0a6da605e283fcd563a3fe0653c4d7b0761996cf","user":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars.githubusercontent.com/u/2810941?v=3","gravatar_id":"","url":"https://api.github.com/users/GoogleCloudPlatform","html_url":"https://github.com/GoogleCloudPlatform","followers_url":"https://api.github.com/users/GoogleCloudPlatform/followers","following_url":"https://api.github.com/users/GoogleCloudPlatform/following{/other_user}","gists_url":"https://api.github.com/users/GoogleCloudPlatform/gists{/gist_id}","starred_url":"https://api.github.com/users/GoogleCloudPlatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoogleCloudPlatform/subscriptions","organizations_url":"https://api.github.com/users/GoogleCloudPlatform/orgs","repos_url":"https://api.github.com/users/GoogleCloudPlatform/repos","events_url":"https://api.github.com/users/GoogleCloudPlatform/events{/privacy}","received_events_url":"https://api.github.com/users/GoogleCloudPlatform/received_events","type":"Organization","site_admin":false},"repo":{"id":19483273,"name":"gcloud-node","full_name":"GoogleCloudPlatform/gcloud-node","owner":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars.githubusercontent.com/u/2810941?v=3","gravatar_id":"","url":"https://api.github.com/users/GoogleCloudPlatform","html_url":"https://github.com/GoogleCloudPlatform","followers_url":"https://api.github.com/users/GoogleCloudPlatform/followers","following_url":"https://api.github.com/users/GoogleCloudPlatform/following{/other_user}","gists_url":"https://api.github.com/users/GoogleCloudPlatform/gists{/gist_id}","starred_url":"https://api.github.com/users/GoogleCloudPlatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoogleCloudPlatform/subscriptions","organizations_url":"https://api.github.com/users/GoogleCloudPlatform/orgs","repos_url":"https://api.github.com/users/GoogleCloudPlatform/repos","events_url":"https://api.github.com/users/GoogleCloudPlatform/events{/privacy}","received_events_url":"https://api.github.com/users/GoogleCloudPlatform/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/GoogleCloudPlatform/gcloud-node","description":"Google Cloud Client Library for Node.js","fork":false,"url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node","forks_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/forks","keys_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/teams","hooks_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/hooks","issue_events_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/events{/number}","events_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/events","assignees_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/assignees{/user}","branches_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/branches{/branch}","tags_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/tags","blobs_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/git/refs{/sha}","trees_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/statuses/{sha}","languages_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/languages","stargazers_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/stargazers","contributors_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/contributors","subscribers_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/subscribers","subscription_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/subscription","commits_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/commits{/sha}","git_commits_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/git/commits{/sha}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/comments{/number}","issue_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/comments{/number}","contents_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/contents/{+path}","compare_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/merges","archive_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/downloads","issues_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues{/number}","pulls_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls{/number}","milestones_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/milestones{/number}","notifications_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/labels{/name}","releases_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/releases{/id}","deployments_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/deployments","created_at":"2014-05-06T06:18:00Z","updated_at":"2016-07-07T05:11:03Z","pushed_at":"2016-07-06T23:25:09Z","git_url":"git://github.com/GoogleCloudPlatform/gcloud-node.git","ssh_url":"git@github.com:GoogleCloudPlatform/gcloud-node.git","clone_url":"https://github.com/GoogleCloudPlatform/gcloud-node.git","svn_url":"https://github.com/GoogleCloudPlatform/gcloud-node","homepage":"https://googlecloudplatform.github.io/gcloud-node/","size":16673,"stargazers_count":834,"watchers_count":834,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":175,"mirror_url":null,"open_issues_count":44,"forks":175,"open_issues":44,"watchers":834,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1407"},"html":{"href":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1407"},"issue":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/1407"},"comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/1407/comments"},"review_comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1407/comments"},"review_comment":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1407/commits"},"statuses":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/statuses/a6b53488be81fed9e394188ab301ab3f967d0e97"}}}}
{"actor":{"display_login":"pbogle"}}