PHPackages                             hyancat/socialite-baidu - 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. hyancat/socialite-baidu

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

hyancat/socialite-baidu
=======================

v1.0(10y ago)273MITPHPPHP &gt;=5.5.0

Since Aug 29Pushed 10y ago1 watchersCompare

[ Source](https://github.com/HyanCat/Socialite-Baidu)[ Packagist](https://packagist.org/packages/hyancat/socialite-baidu)[ RSS](/packages/hyancat-socialite-baidu/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (1)Versions (2)Used By (0)

Socialite-Baidu
===============

[](#socialite-baidu)

百度 OAuth2 账号连接 for Laravel 5.x.

Installation
------------

[](#installation)

1. 安装 composer package:

    ```
     composer require hyancat/socialite-baidu

    ```
2. config/app.php 中 `Laravel\Socialite\SocialiteServiceProvider` 替换成 `SocialiteProviders\Manager\ServiceProvider`
3. `app/Providers/EventServiceProvider.php` 中添加一个监听器：`SocialiteProviders\Manager\SocialiteWasCalled`，如果已存在则忽略；并添加监听响应事件：`Hyancat\SocialiteBaidu\BaiduExtendSocialite@handle`

    ```
    'SocialiteProviders\Manager\SocialiteWasCalled' => [
    	// ...
    	'Hyancat\SocialiteBaidu\BaiduExtendSocialite@handle',
    ],

    ```
4. config/service.php 中添加一个配置项：

    ```
    'baidu' => [
    	'client_id'     => env('BAIDU_KEY'),
    	'client_secret' => env('BAIDU_SECRET'),
    	'redirect'      => env('BAIDU_REDIRECT_URL'),
    ],

    ```

Usage
-----

[](#usage)

详见官方文档 [socialite](http://laravel.com/docs/5.1/authentication#social-authentication) 用法。

License
-------

[](#license)

MIT License.

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

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

Unknown

Total

1

Last Release

3915d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3190081?v=4)[流光不加少](/maintainers/HyanCat)[@HyanCat](https://github.com/HyanCat)

### Embed Badge

![Health badge](/badges/hyancat-socialite-baidu/health.svg)

```
[![Health](https://phpackages.com/badges/hyancat-socialite-baidu/health.svg)](https://phpackages.com/packages/hyancat-socialite-baidu)
```

###  Alternatives

[socialiteproviders/microsoft

Microsoft OAuth2 Provider for Laravel Socialite

326.1M13](/packages/socialiteproviders-microsoft)[socialiteproviders/apple

Apple OAuth2 Provider for Laravel Socialite

618.4M8](/packages/socialiteproviders-apple)[socialiteproviders/instagram

Instagram OAuth2 Provider for Laravel Socialite

421.9M5](/packages/socialiteproviders-instagram)[socialiteproviders/microsoft-azure

Microsoft Azure OAuth2 Provider for Laravel Socialite

556.0M19](/packages/socialiteproviders-microsoft-azure)[socialiteproviders/laravelpassport

LaravelPassport OAuth2 Provider for Laravel Socialite

621.3M7](/packages/socialiteproviders-laravelpassport)[socialiteproviders/discord

Discord OAuth2 Provider for Laravel Socialite

422.0M17](/packages/socialiteproviders-discord)

PHPackages © 2026

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