credentials method

  1. @override
Future<Credentials> credentials(
  1. {int minTtl = 0,
  2. Set<String> scopes = const {},
  3. Map<String, String> parameters = const {}}

Retrieves the credentials from the storage and refreshes them if they have already expired.

Change the minimum time in seconds that the access token should last before expiration by setting the minTtl. Use the scopes parameter to set the scope to request for the access token. If null is passed, the previous scope will be kept. Use the parameters parameter to send additional parameters in the request to refresh expired credentials.


Future<Credentials> credentials({
  final int minTtl = 0,
  final Set<String> scopes = const {},
  final Map<String, String> parameters = const {},
}) =>
      minTtl: minTtl,
      scopes: scopes,
      parameters: parameters,