// Path: services/facade/src/main/java/eu/hlavki/identity/services/rest/model/UserInfo.java
// @Getter
// @Setter
// @NoArgsConstructor
// @XmlRootElement
// public class UserInfo {
// 
//     private String name;
//     private String email;
//     private URI imageUri;
//     private boolean amAdmin;
// 
// 
//     public UserInfo(String name, String email) {
//         this.name = name;
//         this.email = email;
//     }
// 
// 
//     public UserInfo(String name, String email, boolean amAdmin, URI imageUri) {
//         this.name = name;
//         this.email = email;
//         this.amAdmin = amAdmin;
//         this.imageUri = imageUri;
//     }
// }
// 
// Path: services/facade/src/main/java/eu/hlavki/identity/services/rest/security/AuthzRole.java
// public interface AuthzRole {
// 
//     public static final String INTERNAL = "internal";
//     public static final String EXTERNAL = "external";
//     public static final String ADMIN = "admin";
// }


import eu.hlavki.identity.services.rest.model.UserInfo;
import eu.hlavki.identity.services.rest.security.AuthzRole;
import java.net.URI;
import java.nio.charset.Charset;
import java.util.Set;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.core.Context;
import javax.ws.rs.core.UriBuilder;
import org.apache.cxf.rs.security.oidc.rp.OidcClientTokenContext;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
package eu.hlavki.identity.services.rest.service;


@Path("user")
public class UserInfoService {

    private static final Logger log = LoggerFactory.getLogger(UserInfoService.class);
    private static final Charset UTF_8 = Charset.forName("UTF-8");

    @Context
    private OidcClientTokenContext oidcContext;


    public UserInfoService() {
    }


    @GET
// Path: services/facade/src/main/java/eu/hlavki/identity/services/rest/model/UserInfo.java
// @Getter
// @Setter
// @NoArgsConstructor
// @XmlRootElement
// public class UserInfo {
// 
//     private String name;
//     private String email;
//     private URI imageUri;
//     private boolean amAdmin;
// 
// 
//     public UserInfo(String name, String email) {
//         this.name = name;
//         this.email = email;
//     }
// 
// 
//     public UserInfo(String name, String email, boolean amAdmin, URI imageUri) {
//         this.name = name;
//         this.email = email;
//         this.amAdmin = amAdmin;
//         this.imageUri = imageUri;
//     }
// }
// 
// Path: services/facade/src/main/java/eu/hlavki/identity/services/rest/security/AuthzRole.java
// public interface AuthzRole {
// 
//     public static final String INTERNAL = "internal";
//     public static final String EXTERNAL = "external";
//     public static final String ADMIN = "admin";
// }


// Path: services/facade/src/main/java/eu/hlavki/identity/services/rest/service/UserInfoService.java
import eu.hlavki.identity.services.rest.model.UserInfo;
import eu.hlavki.identity.services.rest.security.AuthzRole;
import java.net.URI;
import java.nio.charset.Charset;
import java.util.Set;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.core.Context;
import javax.ws.rs.core.UriBuilder;
import org.apache.cxf.rs.security.oidc.rp.OidcClientTokenContext;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

package eu.hlavki.identity.services.rest.service;


@Path("user")
public class UserInfoService {

    private static final Logger log = LoggerFactory.getLogger(UserInfoService.class);
    private static final Charset UTF_8 = Charset.forName("UTF-8");

    @Context
    private OidcClientTokenContext oidcContext;


    public UserInfoService() {
    }


    @GET
    public UserInfo getUserInfo() {