A very quick update post.
As part of the Day Job tm we have been doing a lot of work with Keycloak, and the Keycloak API. Specifically, interfacing with the new, and largely undocumented, Account management API.
Add it to your project by using:
composer require aria-php/keycloak-api
Then you can do the following, example:
use ARIA\KeycloakAPI\AccountAPI; ... $api = new AccountAPI($client_id, $secret, 'master', 'http://localhost:8080'); $api->setBearer($access_token); $profile = $api->getProfile(); // Make your updates here $api->setProfile($profile);
Early days right now, but hopefully this will save some of you some time!