GSheets constructor
GSheets(})
Creates an instance of GSheets.
credentialsJson - must be provided, it can be either a Map or a
JSON map encoded as a String.
impersonatedUser - optional, used to set the user to impersonate
scopes - optional (defaults to [SpreadsheetsScope, DriveScope]).
Implementation
GSheets(
credentialsJson, {
String? impersonatedUser,
List<String> scopes = const [
SheetsApi.spreadsheetsScope,
SheetsApi.driveScope,
],
}) : _externalClient = null,
_scopes = scopes,
_credentials = ServiceAccountCredentials.fromJson(
credentialsJson,
impersonatedUser: impersonatedUser,
),
_clientId = null;