Dave Tompkins :: fbcmd :: Command Line for Facebook
NEWS
- 2009.07.10 :: Version 1.0 coming soon + A new Home Page / Wiki
1) There's a new version coming soon (version 1.0) with lots of new features regarding accessing the 'stream' (wall posts) as well as some structural changes. I'll release a BETA version within a few days.
2) There's a new home page for FBCMD and it's a wiki... It's still preliminary and in development, but you can check it out at: http://fbcmd.dtompkins.com. It will be more complete when 1.0 is released.
If you have a wishlist item / feature request for version 1.0 or would like to help out on the wiki, email me at:
mail+fbcmd [@at@] dtompkins.com
(Don't use the message boards... I rarely visit them)
- 2009.03.10 :: Version 0.96 has been released
It fixes a few bugs and adds commands for interacting with photos.
Also: The new facebook 'homepage' is coming very soon. I'll post any changes (for example, FEED3 may be depricated) after the dust has settled.
- 2009.02.19 :: Version 0.95 has (finally) been released!
It's a big update with a lots of new commands and features.
- 2008.10.17 :: Version 0.90 was released sooner than planned because Facebook depricated some of the 'old' methods to the 'new' facebook. The FEED command has been replaced with the FEED1,FEED2 & FEED3 commands.
INTRODUCTION
- fbcmd is a command-line interface for Facebook
- it is currently written in PHP and requires you to have PHP installed (CLI Version)
- it was originally created for fast status updates and to allow adding items directly to the mini-feed, but it has lots of other cool things you can do.
- it works in windows, mac, and linux environments (anywhere with internet and PHP, really)
- in windows it is intended for a single-user environment with a secure machine
- it's assumes a general familiarity with a command line environment
DOWNLOAD
- Version 0.96 (March 10, 2009) (download .tgz) (download .zip)
WARNING! If you are upgrading from a previous version, backup your sessionkeys.txt file before installing the new version to avoid having to re-authorize your installation.
- The current revision history
INSTALLATION
First Time Installation:
- you will need to have PHP installed on your machine
(try typing at a command prompt: php -r "echo phpversion();" to see if it's working)
- install the files to c:\fbcmd (windows) or /yourhome/fbcmd/ (linux)
(or create a FBCMD environment variable to point to your installed directory)
- try php fbcmd.php to see if it works (it should say you're missing an authorization code)
- visit this website to get an AUTH code
(AUTH codes are time-sensitive and can only be used once. If one fails, try generating another)
- run php fbcmd.php AUTH YOURCODE and you should be working
(note that you should only use the AUTH command once: fbcmd stores your keys for future use)
Additional Installation Notes:
- you may want add your installation directory to your path and/or set up a FBMCD path environment
- linux users will probably want to:
> chmod +x fbcmd.php
> mv fbcmd.php fbcmd (and/or place an alias in your login script)
- The STATUS, FEEDLINK and (FEEDNOTE|LOADNOTE) commands require additional permissions:
click
(here,
here and
here) to grant fbcmd the respective permissions.
- The ADDPIC and TAGPIC commands will require your approval in facebook before they take effect. To avoid this step and automatically pre-authorize these commands, click (here)
- The (DISPLAY|LOADDISP)and LOADINFO commands require additional authorization:
Use the commands first (e.g.: fbcmd DISPLAY "hello") and then an icon for authorization should appear on your apps page: http://apps.facebook.com/cmdline/
HELP / FAQ / TIPS
- Why do I need to install PHP?
Currently fbcmd is written in the native Facebook API language (PHP). In the future it may be available in other languages and/or in binary (executable) form. PHP is automatically installed on many linux distributions and is easy and painless to install on most windows machines.
- I run fbcmd.php but it doesn't do anything.
Try explicitly running php before fbcmd.php, i.e.: php fbcmd.php.
(this was necessary in my default windows installation)
- Typing php fbcmd.php is too wordy.
create an alias or another script... for example, in linux you can put alias status php fbcmd.php status in your login script and in windows you can create a dos prompt status.bat that is simply php c:\phpcmd\phpcmd.php status %*
- Why are the commands all in UPPERCASE?
Lower case works too.
- Why can't I see someone's status updates / information?
They likely have their security settings set to not allow applications to access their data.
- What is this FBML I can use in the DISPLAY command?
It's a fancy version of HTML with some extra stuff: FBML Reference
USAGE / EXAMPLES
CONTRIBUTORS / OTHER LINKS
- contributions are encouraged and welcome!
- if you would like to contribute contact the author and/or send him your modified code
- feel free to make feature suggestions at the application page
FBCMD Contributors and other links: (arranged alphabetically)
- Naail AbdulRahman has done some interesting work automating facebook birthday wishes
(this inspired the use of the =bday in flists)
- Josiah Boning made excellent suggestions re: RegEx matching that inspired the way flists work now
- Jim Downie made suggestions that have been incorporated into the new help (USAGE command)
- Massimiliano Leone has created a bash utility
- Phillip M made suggestsions that led to the FONLINE command
- Tyler Rusk has been working on install/remove scripts for Ubuntu here.
DISCLAIMER
- Please do not use FBCMD to voilate the Facebook Terms Of Use, which currently says: [...] you agree not to use the Service or the Site to: [...] use automated scripts to collect information from or otherwise interact with the Service or the Site;