validateApiKey method

Future<bool> validateApiKey(
  1. String apiKey
)

Checks if the given api key is valid

Implementation

Future<bool> validateApiKey(String apiKey) async {
  try {
    await _head('/api/login');

    return true;
  } catch (e) {
    return false;
  }
}