Skip to content

Commit 8564915

Browse files
hongalexbshaffer
authored andcommitted
Add comment for clarification of authentication sample in docs (GoogleCloudPlatform#798)
1 parent 947e3fe commit 8564915

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

iot/src/create_registry.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,12 @@ function create_registry(
3838
) {
3939
print('Creating Registry' . PHP_EOL);
4040

41-
// Instantiate a client.
41+
// The Google Cloud Client Library automatically checks the environment
42+
// variable GOOGLE_APPLICATION_CREDENTIALS for the Service Account
43+
// credentials, and defaults scopes to [
44+
// 'https://www.googleapis.com/auth/cloud-platform',
45+
// 'https://www.googleapis.com/auth/cloudiot'
46+
// ].
4247
$deviceManager = new DeviceManagerClient();
4348
$locationName = $deviceManager->locationName($projectId, $location);
4449

0 commit comments

Comments
 (0)