sonleu / id-connect
ID API integration with Laravel by Son Leu
v1.0.7
2023-03-20 09:21 UTC
Requires
- guzzlehttp/guzzle: ^6|^7
This package is not auto-updated.
Last update: 2024-06-10 15:29:54 UTC
README
ID Integration with Laravel
Table of Contents
Installation
Execute the following command to get the latest version of the package:
composer require sonleu/id-connect
Configuration
Add these inside of .env
ID_URL=<ID_BASE_API_URL>
ID_API_KEY=<ID_API_KEY>
Publish configs
php artisan vendor:publish --tag=id_connect_config
Custom models
By default, packages' models will be returned in api responses.
In case you want to customize the models, change the namespaces inside config.id_connect.models. For example:
// config/id_connect.php
return [
/*
|--------------------------------------------------------------------------
| Custom models
|--------------------------------------------------------------------------
| Your models to which data should be returned.
|
| Your own models should extends the base models.
|
*/
'models' => [
'user' => \App\User::class,
'position' => \SonLeu\IDConnect\Models\Position::class,
'department' => \SonLeu\IDConnect\Models\Department::class,
]
];