Hi
I’m getting error 500 when trying to use the “execute-actions-email” Admin API endpoint.
I’m developing on a local machine version 16.1 and sending requests using postman
the flow I’m using is:
- Obtain an access token from the admin user in the master realm
- Get all users from the users endpoint and get the user-id I want to send emails to.
- Use the user-id to try and send “update password” email using the execute-actions-email endpoint
URL: http://localhost:8080/auth/admin/realms/myRealm/users/fd5e7148-52db-4172-9c33-ee7453f30767/execute-actions-email
Content-Type: application/json
Body: [“UPDATE_PASSWORD”]
Edit
I’m getting 2 types of errors (cant really understand what triggers each one)
first error:
error code 500 with body
{
“error”: “unknown_error”
}
second error:
error code 500 with body
{
“errorMessage”: “Failed to send execute actions email”
}
When inspecting the log I see those errors:
“Uncaught server error: com.fasterxml.jackson.databind.JsonMappingException: Invalid UTF-8 start byte 0x80”
OR
“org.keycloak.email.EmailException: org.keycloak.email.EmailException: Please provide a valid address”
In my master realm, I have email settings configured and working (tested using “Test connection” button)
I have an admin user in Master realm with a valid email
in my “myRealm” I have a user named “strange” with a valid id (fd5e7148-52db-4172-9c33-ee7453f30767) and valid email (i use my own personal Gmail for testing)
I can only guess that the first error is caused because the body of the request is invalid but since no documentation about that I try stuff I see in other posts here - with no luck
But I have no idea what the other error means “Please provide a valid address” - all emails are valid as stated before
please help