openseawave / keycloak
The keyclock plugin provides a simple way to integrate Keycloak admin api with full support for Laravel framework.
Fund package maintenance!
OpenSeaWave
Requires
- php: ^8.2
- illuminate/contracts: ^10.0||^11.0
- spatie/laravel-package-tools: ^1.16
Requires (Dev)
- laravel/pint: ^1.14
- nunomaduro/collision: ^8.1.1||^7.10.0
- orchestra/testbench: ^9.0.0||^8.22.0
- pestphp/pest: ^2.34
- pestphp/pest-plugin-arch: ^2.7
- pestphp/pest-plugin-laravel: ^2.3
README
The keyclock plugin provides a simple way to integrate Keycloak admin api with full support for Laravel framework.
Installation
You can install the package via composer:
composer require openseawave/keycloak
You can publish the config file with:
php artisan vendor:publish --tag="keycloak-config"
Usage
you can use it like this:
use Openseawave\Keycloak\Keycloak; use OpenSeaWave\Keycloak\Enums\GrantType; $keycloak = new Keycloak( baseUrl: 'http://localhost:8080', username: 'admin', password: 'admin', grantType: GrantType::PASSWORD, clientId: 'admin-cli', ); $keycloak->getUsers();
Also you can use it using Laravel Facade:
use Openseawave\Keycloak\Facades\Keycloak; Keycloak::getUsers();
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
License
The MIT License (MIT). Please see License File for more information.