Skip to content

Commit daa1258

Browse files
author
Eric Koleda
committed
Update the Domo samples to use the default client_credentials behavior.
1 parent e5a7db6 commit daa1258

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

samples/Domo.gs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,15 +41,13 @@ function getService() {
4141
// Set the endpoint URLs.
4242
.setTokenUrl('https://api.domo.com/oauth/token')
4343

44+
// Set the client ID and secret.
45+
.setClientId(CLIENT_ID)
46+
.setClientSecret(CLIENT_SECRET)
47+
4448
// Sets the custom grant type to use.
4549
.setGrantType('client_credentials')
4650

47-
// Sets the required Authorization header.
48-
.setTokenHeaders({
49-
Authorization: 'Basic ' +
50-
Utilities.base64Encode(CLIENT_ID + ':' + CLIENT_SECRET)
51-
})
52-
5351
// Set the property store where authorized tokens should be persisted.
5452
.setPropertyStore(PropertiesService.getUserProperties());
5553
}

0 commit comments

Comments
 (0)