koolsam / facebook-leads-example
Complete example on how to grab leads from Facebook Ad Leads
Installs: 10
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/koolsam/facebook-leads-example
Requires
- facebook/php-sdk-v4: ~5.0
This package is not auto-updated.
Last update: 2025-10-12 10:49:35 UTC
README
Full running example on how to retrieve leads from Facebook's Lead Ads
1 - Retrieving Facebook Access Tokens and Subscribing App do Page
On this section you'll learn how to:
- Grant an App access to manage your Facebook Pages
- Retrieve a lifetime Page Access Token
- Subscribe an App to a Page
Before you start
Make sure:
- You have already created a Facebook Web App
- You already own a Facebook Page
- You are running at least PHP 5.4
Install
All required files for this demo can be installed via composer via composer:
$ composer require "tixastronauta/facebook-leads-example:0.1.0"
Configure
Create a config/config.php with your facebook credentials
$ cp config/config.php.sample config/config.php
Execute
Point your http server to web/
Note: This script must be installed on the same domain you've ser for your Facebook App
2 - Setting up a Facebook Webhook handler
[Not available yet] Please refer to https://gist.github.com/tixastronauta/0b9c3b409a7ba96edffc in the meanwhile
Grabbing Leads from Facebook
[Not available yet] Please refer to https://gist.github.com/tixastronauta/0b9c3b409a7ba96edffc in the meanwhile