var SpotifyWebApi = require("../");

/**
 * This example retrives an access token using the Client Credentials Flow. It's well documented here:
 * https://developer.spotify.com/web-api/authorization-guide/#client_credentials_flow
 */

/*
 * https://developer.spotify.com/spotify-web-api/using-scopes/
 */

 /**
 * Set the credentials given on Spotify's My Applications page.
 * https://developer.spotify.com/my-applications
 */
var spotifyApi = new SpotifyWebApi({
  clientId : 'fcecfc79122e4cd299473677a17cbd4d',
  clientSecret : 'f6338737c9bb4bc9a71924cb2940eaedb'
});

// Retrieve an access token
spotifyApi.clientCredentialsGrant()
  .then(function(data) {
    console.log('The access token expires in ' + data.body['expires_in']);
    console.log('The access token is ' + data.body['access_token']);

    // Save the access token so that it's used in future calls
    spotifyApi.setAccessToken(data['access_token']);
  }, function(err) {
    console.log('Something went wrong when retrieving an access token', err.message);
  });
@@ -896,16 +896,21 @@
 ken(data
+.body
 %5B'access
@@ -1032,8 +1032,9 @@
 );%0A  %7D);
+%0A

Fix missing property