I am trying to create the users in keycloak from java application. I am able to create users and also assign roles to the newly created users in the master realm. I have created my own realm and also added some roles in the newly created realm. While adding the users and assigning roles to the newly created users I am getting the below exception
javax.ws.rs.ForbiddenException: HTTP 403 Forbidden
I am getting an exception in the below line
RoleRepresentation testerRealmRole = realmResource.roles().get("rolename}").toRepresentation();
I have created the {rolename} in the realm. I am not able to find what is missing. Please, anyone, help me. Thanks in advance