PHPackages                             culshaw/facebook - 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. culshaw/facebook

ActiveLibrary

culshaw/facebook
================

Facebook PHP SDK Package for Laravel 4.1

274PHP

Since Dec 20Pushed 12y ago2 watchersCompare

[ Source](https://github.com/culshaw/facebook)[ Packagist](https://packagist.org/packages/culshaw/facebook)[ RSS](/packages/culshaw-facebook/feed)WikiDiscussions master Synced today

READMEChangelogDependenciesVersions (1)Used By (0)

I take no credit for this at all, this is all boparaiamrit's work, this is just to preserve my sanity while they update they're package.
========================================================================================================================================

[](#i-take-no-credit-for-this-at-all-this-is-all-boparaiamrits-work-this-is-just-to-preserve-my-sanity-while-they-update-theyre-package)

Facebook
--------

[](#facebook)

Facebook PHP SDK for Laravel

Add `boparaiamrit/facebook` to `composer.json`.

```
"boparaiamrit/facebook": "dev-master"

```

Run `composer update` to pull down the latest version of Twitter.

Now open up `app/config/app.php` and add the service provider to your `providers` array.

```
'providers' => array(
    'Boparaiamrit\Facebook\FacebookServiceProvider',
)

```

Now add the alias.

```
'aliases' => array(
    'Facebook' => 'Boparaiamrit\Facebook\FacebookFacade',
)

```

Configuration
-------------

[](#configuration)

Run `php artisan config:publish boparaiamrit/facebook` and modify the config file with your own informations.

1. AppId =&gt; If you donot have appId then get it from facebook developer apps.
2. Secret =&gt; Its come with appId.
3. Redirect =&gt; Specify redirect url after logged in with facebook.
4. Logout =&gt; When somebody logout from your site, it redirects to logout url.
5. Scope =&gt; These are permission you want from your users.

Examples
--------

[](#examples)

1. Get Login Url with your credentials and scope.

    `Route::get('/', function() { return Facebook::loginUrl(); });`
2. Get User Id

    `Route::get('/', function() { return Facebook::getUser(); });`
3. Use facebook API

    `Route::get('/', function() { $profile = Facebook::api('/me?fields=id,name,first_name,last_name,username,email,gender,birthday,hometown,location,picture.width(100)'); });`
4. Get Logout Url

    `Route::get('/', function() { return Facebook::logoutUrl(); });`
5. FQL

    `Route::get('/', function() { return Facebook::api(array( 'method' => 'fql.query', 'query' => "SELECT uid, sex, username, birthday, education, work FROM user WHERE uid = me()", )); });`

###  Health Score

23

—

LowBetter than 30% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 83.3% 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/1db3cc1f6131067c60a88f5ea2e04afbcc6c99d7acbcf4400b0062ef8f1522d2?d=identicon)[culshaw](/maintainers/culshaw)

---

Top Contributors

[![boparaiamrit](https://avatars.githubusercontent.com/u/1220153?v=4)](https://github.com/boparaiamrit "boparaiamrit (15 commits)")[![culshaw](https://avatars.githubusercontent.com/u/673948?v=4)](https://github.com/culshaw "culshaw (2 commits)")[![ceesvanegmond](https://avatars.githubusercontent.com/u/883497?v=4)](https://github.com/ceesvanegmond "ceesvanegmond (1 commits)")

### Embed Badge

![Health badge](/badges/culshaw-facebook/health.svg)

```
[![Health](https://phpackages.com/badges/culshaw-facebook/health.svg)](https://phpackages.com/packages/culshaw-facebook)
```

PHPackages © 2026

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