Skip to content

feat: ship the facebook-scraper-api package (v0.1.0) - #7

Merged
OussemaFr merged 1 commit into
mainfrom
feat/facebook-scraper-api-package
Nov 19, 2026
Merged

OussemaFr merged 1 commit into
mainfrom
feat/facebook-scraper-api-package

Conversation

@OussemaFr

Copy link
Copy Markdown
Member

Makes this repo the source of a new PyPI package, facebook-scraper-api (name free on PyPI as of today).

What it is

  • facebook-scraper style functions on top of socialapis-sdk: get_page_info, get_posts(account, pages=…, limit=…), get_group_posts, get_group_info, get_reels, get_videos, get_post, get_comments, search_posts, search_pages, plus a FacebookScraperAPI class with the same methods.
  • Listings are generators that follow end_cursor; pages is a hard ceiling on calls (credits), and they stop early when has_next_page is false or a cursor repeats.
  • Records are taken as the longest list of objects outside our meta / message envelope (the rule the Sheets add-on uses on live answers), so no per-endpoint field path is guessed.
  • facebook-scraper-api command: page, group, posts, group-posts, reels, videos, comments, search-posts, search-pages, CSV (nested fields flattened) or JSON lines.
  • README top now leads with the package; PACKAGE.md is the PyPI page. The rest of the README (migration with socialapis-sdk) is unchanged, so it doesn't conflict with readme: free live follower badge #6.
  • CI: ruff + pytest on Python 3.10–3.13. Release: tag vX.Y.Z → PyPI via trusted publishing.

Checked

  • pytest: 7 passed; ruff check / ruff format --check clean; python -m build builds the wheel with the right files.
  • Not checked: a live call against api.socialapis.io (tests use a fake client).

Publish (after merging)

  1. pypi.org → Your account → Publishing → Add a pending publisher: project facebook-scraper-api, owner SocialAPIsHub, repository facebook-scraper-python, workflow release.yml, environment pypi.
  2. Tag and push:
cd facebook-scraper-python
git checkout main
git pull
git tag v0.1.0
git push origin v0.1.0
  1. Check: https://pypi.org/project/facebook-scraper-api/ and
pip install facebook-scraper-api
SOCIALAPIS_TOKEN=your_key facebook-scraper-api page nasa

facebook-scraper style functions (get_page_info, get_posts(account, pages=...), get_group_info, get_comments, search) and a command-line tool, built on socialapis-sdk. Listings follow end_cursor with a hard page ceiling; CSV export flattens nested fields.
@OussemaFr
OussemaFr merged commit c984dac into main Nov 19, 2026
4 checks passed
@OussemaFr
OussemaFr deleted the feat/facebook-scraper-api-package branch November 19, 2026 13:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant