private static List<NameValuePair> toNamedValuePair(Map<String, List<String>> in) {
        return in.entrySet().stream()
                .map(e -> new BasicNameValuePair(e.getKey(), e.getValue().get(0)))
                .collect(Collectors.toList());
    }
Source of implementation <a href="https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/auth-iam.html#auth-iam-Connecting">
    Authenticating with IAM</a>.
storage/src/main/java/com/epam/aidial/core/storage/cache/IamAuthTokenRequest.java