Disconnecting and revoking scopes

It is recommended that your app provide a way to delete the association between your app and a user's account. By adding this capability to your app, you can respond to the event and trigger any appropriate logic such as deleting personal information associated with the account.

The following JavaScript example demonstrates how to revoke a user's scopes programmatically.

  var 
  
 revokeAllScopes 
  
 = 
  
 function 
 () 
  
 { 
  
 gapi 
 . 
 auth2 
 . 
 getAuthInstance 
 () 
 . 
 disconnect 
 (); 
 } 
 
Create a Mobile Website
View Site in Mobile | Classic
Share by: