HybridAuth

开源社交登录php库。(open source social login php library.)

Github星跟蹤圖

HybridAuth 是一个开源社会化登录PHP库。Hybridauth使开发人员可以轻松构建社交应用程序和工具,从而在社交层面上吸引访问者和客户,开始社会登录,并扩展到社交分享,用户个人资料,朋友列表,活动流,状态更新等。

Hybridauth的主要目标是在您的应用程序和各种社交网络API和身份提供程序(如Facebook,Twitter和Google)之间充当抽象API。

用法

Hybridauth提供了一些基本的例子。 您还可以在https://hybridauth.github.io 找到完整的Hybridauth文档。

$config = [    'callback' => 'https://example.com/path/to/script.php',    'keys' => [ 'key' => 'your-twitter-consumer-key', 'secret' => 'your-twitter-consumer-secret' ]];try {    $twitter = new Hybridauth\Provider\Twitter($config);    $twitter->authenticate();    $accessToken = $twitter->getAccessToken();    $userProfile = $twitter->getUserProfile();    $apiResponse = $twitter->apiRequest( 'statuses/home_timeline.json' );}catch(\Exception $e){    echo 'Oops, we ran into an issue! ' . $e->getMessage();}

要求

  • PHP 5.4+
  • PHP Session
  • PHP cURL

主要指標

概覽
名稱與所有者hybridauth/hybridauth
主編程語言PHP
編程語言HTML (語言數: 2)
平台
許可證Other
所有者活动
創建於2011-11-15 23:38:39
推送於2025-04-22 05:23:44
最后一次提交2025-04-22 08:22:57
發布數70
最新版本名稱v3.12.1 (發布於 )
第一版名稱v2.0.8 (發布於 )
用户参与
星數3.4k
關注者數206
派生數1.1k
提交數1.7k
已啟用問題?
問題數766
打開的問題數74
拉請求數550
打開的拉請求數16
關閉的拉請求數100
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?

Hybridauth 3.1

Build Status Scrutinizer Code Quality Latest Stable Version Join the chat at https://gitter.im/hybridauth/hybridauth

Hybridauth enables developers to easily build social applications and tools to engage websites visitors and customers on a social level that starts off with social sign-in and extends to social sharing, users profiles, friends lists, activities streams, status updates and more.

The main goal of Hybridauth is to act as an abstract API between your application and the various social networks APIs and identities providers such as Facebook, Twitter and Google.

Usage

Hybridauth provides a number of basic examples. You can also find complete Hybridauth documentation at https://hybridauth.github.io

$config = [
    'callback' => 'https://example.com/path/to/script.php',
    'keys' => [ 'key' => 'your-twitter-consumer-key', 'secret' => 'your-twitter-consumer-secret' ]
];

try {
    $twitter = new Hybridauth\Provider\Twitter($config);

    $twitter->authenticate();

    $accessToken = $twitter->getAccessToken();
    $userProfile = $twitter->getUserProfile();
    $apiResponse = $twitter->apiRequest('statuses/home_timeline.json');
}
catch (\Exception $e) {
    echo 'Oops, we ran into an issue! ' . $e->getMessage();
}

Requirements

  • PHP 5.4+
  • PHP Session
  • PHP cURL

Installation

To install Hybridauth we recommend Composer, the now defacto dependency manager for PHP. Alternatively, you can download and use the latest release available at Github.

Versions Status, Version, Status, Repository, Documentation, PHP Version, ---------, -------------, -------------------------, -------------------------, -------------, 2.x, Maintenance, [v2][hybridauth-2-repo], v2, >= 5.3, 3.x, Development, v3, v3, >= 5.4, [hybridauth-2-repo]: https://github.com/hybridauth/hybridauth/tree/v2

Questions, Help and Support?

For general questions (i.e, "how-to" questions), please consider using StackOverflow instead of the Github issues tracker. For convenience, we also have a [low-activity] Gitter channel if you want to get help directly from the community.

License

Hybridauth PHP Library is released under the terms of MIT License.

For the full Copyright Notice and Disclaimer, see COPYING.md.