Facebook Open Graph Object Debugger CLI.
The Facebook Object Debugger CLI is command-line interface used to refresh the information of any page shared on Facebook. Unfortunately this operation can be done manually using the Facebook Open Graph Object Debugger. To overcome this limitation I have created this command-line interface, using the official Facebook SDK for PHP.
curl -s https://getcomposer.org/installer | php
You can run this command to easily access composer from anywhere on your system:
sudo mv composer.phar /usr/local/bin/composer
Once you have installed Composer, it's easy install Facebook Object Debugger CLI.
- Move into the directory where you prefer install Facebook Object Debugger CLI:
- Create a project for Facebook Object Debugger CLI:
sudo composer create-project 3f/facebook-od
- For your convenience create a symbolic link for the
fbodexecutable in your
sudo ln -s /user/local/facebook-od/bin/fbod.php /usr/local/bin/fbod
fbod list [--xml] [--raw] [--format="..."] [namespace]
Displays help for a command.
fbod help [--xml] [--format="..."] [--raw] [command_name]
Fetches new scrape information and update the Facebook cache.
fbod refresh [-i|--file[="..."]] [-u|--url[="..."]] [-d|--id[="..."]] [-s|--secret[="..."]] [-t|--token[="..."]] [-e|--encode]
Using the Facebook Object Debugger CLI is really simple. You can refresh a single URL or a bunch of URLs providing a text file with a list of URLs, one for each line.
fbod refresh -u http://www.example.com/foo-bar-123
fbod refresh -i urls.txt
You must also provide an App ID, an App Secret and an App Access Token or a User Access Token. To see
your token please use the Access Token Tool. You can use both
the App Access Token or the User Access Token, just keep in mind the first one does not expire.
For your convenience you can rename (or copy) the
config.ini, then replace the
values for your application. Otherwise you can provide those parameters using the designed options from the command-line.
The documentation can be generated using Doxygen. A
Doxyfile is provided for your convenience.
- PHP 5.4.0 or above.
Lint is licensed under the Apache License, Version 2.0 - see the LICENSE file for details.