PHPackages                             hokibgs/auth-center - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. hokibgs/auth-center

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

hokibgs/auth-center
===================

v1.0.1(4mo ago)02PHP

Since Dec 12Pushed 4mo agoCompare

[ Source](https://github.com/smboutsource/auth-center-php)[ Packagist](https://packagist.org/packages/hokibgs/auth-center)[ RSS](/packages/hokibgs-auth-center/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (3)Used By (0)

Auth Center PHP
===============

[](#auth-center-php)

Library PHP untuk login ke SMB Auth Center

Instalasi
---------

[](#instalasi)

```
composer require hokibgs/auth-center
```

Cara Penggunaan
---------------

[](#cara-penggunaan)

#### 🔧 Inisialisasi Client

[](#-inisialisasi-client)

```
use Hokibgs\AuthCenter\AuthCenter;

$auth = new AuthCenter(
    apiUrl: 'https://auth-center.example.com',
    clientId: 'your-client-id',
    clientSecret: 'your-client-secret'
);
```

#### 🔐 Login

[](#-login)

```
$response = $auth->login('email@example.com', 'password123');
```

#### 👤 Ambil Profile

[](#-ambil-profile)

```
$auth->setToken('auth-token');
$profile = $auth->getProfile('email@example.com');
```

#### 📡 Request GET

[](#-request-get)

```
$auth->setToken('auth-token');
$response = $auth->get('/users');
```

#### 📝 Request POST

[](#-request-post)

```
$response = $auth->post('/auth/register', [
    'email' => 'user@example.com',
    'password' => 'secret',
    'password_confirmation' => 'secret',
]);
```

#### 🔄 Request PUT

[](#-request-put)

```
$auth->setToken('auth-token');
$response = $auth->put('/auth/change-password', [
    'old_password' => 'oldpass',
    'password' => 'newpass',
]);
```

#### ❌ Request DELETE

[](#-request-delete)

```
$auth->setToken('auth-token');
$response = $auth->delete('/account/remove', ['email' => 'user@example.com']);
```

#### 📤 Menambahkan Custom Headers

[](#-menambahkan-custom-headers)

```
$auth->setHeaders([
    'X-My-App' => 'CustomHeaderValue'
]);
```

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance74

Regular maintenance activity

Popularity2

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

148d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/da454c963c06614f8f29adc1a5f694da251f26b31a12f0994e8d7067c2f6fd7f?d=identicon)[haverox](/maintainers/haverox)

---

Top Contributors

[![haverox](https://avatars.githubusercontent.com/u/209065989?v=4)](https://github.com/haverox "haverox (6 commits)")

### Embed Badge

![Health badge](/badges/hokibgs-auth-center/health.svg)

```
[![Health](https://phpackages.com/badges/hokibgs-auth-center/health.svg)](https://phpackages.com/packages/hokibgs-auth-center)
```

###  Alternatives

[namshi/jose

JSON Object Signing and Encryption library for PHP.

1.8k99.6M101](/packages/namshi-jose)[league/oauth1-client

OAuth 1.0 Client Library

99698.8M106](/packages/league-oauth1-client)[bezhansalleh/filament-shield

Filament support for `spatie/laravel-permission`.

2.8k2.9M88](/packages/bezhansalleh-filament-shield)[gesdinet/jwt-refresh-token-bundle

Implements a refresh token system over Json Web Tokens in Symfony

70516.4M35](/packages/gesdinet-jwt-refresh-token-bundle)[league/oauth2-google

Google OAuth 2.0 Client Provider for The PHP League OAuth2-Client

41721.2M118](/packages/league-oauth2-google)[illuminate/auth

The Illuminate Auth package.

9327.3M1.0k](/packages/illuminate-auth)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
