@@ -13,6 +13,7 @@ This client supports the following Google Cloud Platform services:
1313* [ Google BigQuery] ( #google-bigquery )
1414* [ Google Cloud Datastore] ( #google-cloud-datastore )
1515* [ Google Cloud DNS] ( #google-cloud-dns )
16+ * [ Google Cloud Logging] ( #google-cloud-logging )
1617* [ Google Cloud Pub/Sub] ( #google-cloud-pubsub )
1718* [ Google Cloud Storage] ( #google-cloud-storage )
1819* [ Google Compute Engine] ( #google-compute-engine )
@@ -209,6 +210,49 @@ zone.export('/zonefile.zone', function(err) {});
209210```
210211
211212
213+ ## Google Cloud Logging
214+
215+ - [ API Documentation] [ gcloud-logging-docs ]
216+ - [ Official Documentation] [ cloud-logging-docs ]
217+
218+ #### Preview
219+
220+ ``` js
221+ // Authenticating on a global-basis. You can also authenticate on a per-API-
222+ // basis (see Authentication section above).
223+ var gcloud = require (' gcloud' )({
224+ projectId: ' my-project' ,
225+ keyFilename: ' /path/to/keyfile.json'
226+ });
227+
228+ var logging = gcloud .logging ();
229+
230+ // Create a sink using a Bucket as a destination.
231+ var gcs = gcloud .storage ();
232+
233+ dns .createSink (' my-new-sink' , {
234+ destination: gcs .bucket (' my-sink' )
235+ }, function (err , sink ) {});
236+
237+ // Write a critical entry to a log.
238+ var log = logging .log (' compute.googleapis.com' );
239+
240+ log .critical ({
241+ metadata: {
242+ serviceName: ' compute.googleapis.com'
243+ },
244+ data: {
245+ delegate: process .env .USER
246+ }
247+ }, function (err ) {});
248+
249+ // Get indexes from a service like Compute Engine.
250+ var service = logging .service (' compute.googleapis.com' );
251+
252+ service .getIndexes (function (err , indexes ) {});
253+ ```
254+
255+
212256## Google Cloud Pub/Sub
213257
214258- [ API Documentation] [ gcloud-pubsub-docs ]
@@ -433,6 +477,7 @@ Apache 2.0 - See [COPYING](COPYING) for more information.
433477[ gcloud-compute-docs ] : https://googlecloudplatform.github.io/gcloud-node/#/docs/compute
434478[ gcloud-datastore-docs ] : https://googlecloudplatform.github.io/gcloud-node/#/docs/datastore
435479[ gcloud-dns-docs ] : https://googlecloudplatform.github.io/gcloud-node/#/docs/dns
480+ [ gcloud-logging-docs ] : https://googlecloudplatform.github.io/gcloud-node/#/docs/logging
436481[ gcloud-pubsub-docs ] : https://googlecloudplatform.github.io/gcloud-node/#/docs/pubsub
437482[ gcloud-resource-docs ] : https://googlecloudplatform.github.io/gcloud-node/#/docs/resource
438483[ gcloud-search-docs ] : https://googlecloudplatform.github.io/gcloud-node/#/docs/search
@@ -460,6 +505,8 @@ Apache 2.0 - See [COPYING](COPYING) for more information.
460505
461506[ cloud-dns-docs ] : https://cloud.google.com/dns/docs
462507
508+ [ cloud-logging-docs ] : https://cloud.google.com/logging/docs
509+
463510[ cloud-pubsub-docs ] : https://cloud.google.com/pubsub/docs
464511
465512[ cloud-resource-docs ] : https://cloud.google.com/resource-manager
0 commit comments