I am trying to add a user in keyclaok server using postman but i am not able to create.
Postman request:
first of all i got the token from keycloak:
http://54.218.218.85:8080/auth/realms/ctms/protocol/openid-connect/token
request:
client_id=ctms-app
grant_type=password
username=admin
password=password
response:
{
"access_token": $Token,
"expires_in": 300,
"refresh_expires_in": 1800,
"refresh_token": $Token
"token_type": "bearer",
"not-before-policy": 0,
"session_state": "4425bee9-c243-4d1d-89ed-7c6bcc3f37a0",
"scope": "email profile"
}
I was got the token from keyclaok After that i was trying to create the user using postman from below api request:
Method : POST URL : http://localhost:8080/auth/admin/realms/ctms/users
Header : key : Authorization , Value : bearer @Token
Request JSON Type in Body:
{
"enabled": true,
"attributes": {},
"emailVerified": "",
"firstName": "DDDDDD",
"lastName": "WWWWWWW",
"email": "wwww@aaa.com",
"credentials":{"type":"password",
"value":"password",
"temporary":false
}
}
Getting Response 403 Forbidden
{ “error”: “unknown_error” }
I am making a custom lonin page with New User & Sign-up user option but i am not able to create new user If anyone please tell me how to add new user in keyclaok using postman