Skip to content

Save in a CSV file threads with their comments of a Facebook group.

License

Notifications You must be signed in to change notification settings

YnsDev1/FacebookGroupScraper

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Due to the disappearance of the version 2.3 of the Facebook API, it is no longer possible to get the data of those groups in which you are not admin.


Facebook Group Scraper

Save in a CSV file threads with their comments, and associated data, of a Facebook group (even closed groups where you are not an admin but a member).

Usage

Just download the file fb_group_scraper.py and run the script:

$ python fb_group_scraper.py <group_id> <access_token> [max_threads]

Group ID

You usually can find the group ID looking on your browser. If you access to the chosen group, you will see a URL like https://www.facebook.com/groups/1234567890, where the group ID is 1234567890. In the case of there is no number, try with a tool like Lookup-ID.com.

Access Token

Moreover, you will need an access token to use this script. Go to the Graph API Explorer and get a User Access Token. Pay attention to select the version 2.3, because is the last one that allows get data from a closed group if you are only a member. Select the user_groups option and click on the Get Access Token button. Then you can see a long alphanumeric word, which will be your token.

Max Threads

This is an optional argument that limits the amount of threads you can scrape. Note that if there are a lot of posts in the group, the script will require a fairly long time.

About

Save in a CSV file threads with their comments of a Facebook group.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%