String passwordOrSecretKey = input.credential;
C creds = createCredentials(usernameOrAccessKey, passwordOrSecretKey);
Access access;
if (tenantId.isPresent()) {
access = authenticateWithTenantId(tenantId, creds);
} else if (tenantName.isPresent()) {
access = authenticateWithTenantName(tenantName, creds);
} else if (!requiresTenant) {