# Facebook Groups Search: Find Groups by Keyword (`automation_craft/facebook-groups-search-scraper`) Actor

Find Facebook groups by keyword, no login: found on Brave Search and DuckDuckGo, read live on Facebook. You get name, URL, group ID, Public or Private group and members; Group details adds posts in the last month, created date, admins and rules. JSON, CSV, API; pay per group and search page.

- **URL**: https://apify.com/automation_craft/facebook-groups-search-scraper.md
- **Developed by:** [Automation Craft](https://apify.com/automation_craft) (community)
- **Categories:** Social media, Lead generation, Marketing
- **Features:** Limited permissions
- **Stats:** 8 total users, 4 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.28 / 1,000 groups

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

### Facebook Groups Search Scraper

**Find Facebook groups by keyword without a login**: type "real estate investors", "yoga london" or "tesla owners" and get the matching Facebook groups as rows: name, link, numeric group id, public or private, member count, membership questions and how each group was found. Turn on **Group details** for Facebook's own about facts: the exact member count, posts in the last day and month, created date and name history, description with its links and e-mails, locations, topic tags, admin and moderator counts and names, and the group's rules. You can also give group links or ids you already know.

No Facebook account, cookie or password is ever used. Results export to JSON, CSV or Excel, run on a schedule, or come through the Apify API.

#### At a glance

- **Keyword in, groups out**: each keyword is looked up on Brave Search and DuckDuckGo for Facebook group pages, then every group is read on Facebook itself, so names, privacy and member counts are Facebook's current ones, not a search snippet.
- **About 30 to 200 groups a keyword**, depending on the keyword (57 to 193 on the 5 keywords measured with both engines and all three phrases: see "How deep a search goes").
- **Private groups included**: Facebook shows a private group's name, member count and about facts to visitors; this Actor delivers those (never its posts or members).
- **One row per group per run**: a group found by several keywords, phrases or engines is delivered and charged once.
- **Filters**: public or private, member range, keyword in the name, words to leave out, and with Group details posts per day or month, the group's own location and its created date.
- **Never a silent empty run**: every search ends with a free coverage row that says what was read, what was left out and why it ended.

### Quick start

1. Open the **Input** tab and type one or more keywords under **Search keywords** (one per line).
2. Optionally add **Search locations** (each keyword is searched once per place), set **Groups per search**, and the filters.
3. Leave **Group details** on for the exact members and activity, or turn it off for the cheapest rows.
4. Click **Start**. Group rows appear in the **Output** tab as they are read; download them as JSON, CSV or Excel.

### What you get

Every delivered group is one row with `type: "group"`. Fill rates were measured on 500 groups found by 5 English keywords on 2026-11-09 (a run of this Actor with Group details on).

| Field | What it holds | Filled |
|---|---|---|
| `groupId` | Facebook's numeric group id, as a string | 100% |
| `name` | The group's name as Facebook shows it | 100% |
| `url` | The group's link (its vanity name when it has one) | 100% |
| `vanity` | The group's vanity name | 49% |
| `privacy`, `privacyText` | `public` or `private`, and Facebook's label ("Public group") | 100% |
| `membersCount`, `membersText` | The member count (exact with Group details, else Facebook's rounded count as a number) and Facebook's text ("70.6K members") | 100% |
| `membersCountIsApproximate` | true when the count is the rounded one | 100% |
| `hasMembershipQuestions` | Whether joining asks membership questions | 100% |
| `joinState` | What a visitor can do: `CAN_JOIN` (public) or `CANNOT_JOIN_OR_REQUEST` (private, logged out) | 100% |
| `isBuySellGroup`, `tabs` | The group's tabs (a buy and sell group has `BUY_SELL_GROUP_DISCUSSIONS`) | 100% |
| `pausedNotice` | "An admin paused this group on ..." when it is paused | 1% |
| `linkedProfile` | The Page or person the group is linked to | 16% |
| `coverPhotoUrl`, `profilePictureUrl` | The group's cover photo and profile picture | 96%, 100% |
| `query`, `searchLocation`, `rank` | The keyword and place that found it, and its place among the groups that search delivered | search rows |
| `searchPhrase`, `foundBy` | The phrase sent and the engine (`brave` or `duckduckgo`) | search rows |
| `searchResultUrl`, `searchResultTitle`, `searchResultSnippet` | The search result that led to the group, as the engine served it | search rows |
| `source`, `input` | `search` or `link`, and for a link its place in your list (`groupUrls[3]`) | 100% |
| `matchedIn` | Where the keyword matched (`name`, `description`, `tags`, `locations`) | with the keyword match on |
| `detailsStatus` | What happened to the Group details add-on for this row | 100% |

With **Group details** on, the same row also carries:

| Field | What it holds | Filled |
|---|---|---|
| `membersExact`, `membersExactText` | The exact member count ("70,607 total members") | 100% |
| `postsLastDay`, `postsLastMonth` | Posts in the last day and month (non zero on 66% and 93% of groups); Facebook shows at most 10,000 for the month, so a busier group reads 10,000 | 100% |
| `postsPerDayAverage` | `postsLastMonth` divided by 30 (at most 333.3, from the 10,000 Facebook shows) | 100% |
| `createdAt`, `historyText`, `nameLastChangedOn` | Created time, Facebook's history sentence, and the last name change when the sentence gives one (English) | 100%, 100%, 30% |
| `description`, `descriptionLinks` | The description exactly as served, and the links Facebook marks in it | 94%, 20% |
| `emails`, `websites` | E-mail addresses and web addresses written in the description | 6%, 21% |
| `locations` | The group's own locations (`id`, `name`) | 56% |
| `tags` | Facebook's topic tags (`id`, `name`), e.g. "Real Estate", "Foods" | 21% |
| `visibility`, `visibilityText`, `privacyDescription` | "Visible", "Anyone can find this group.", and the privacy sentence | 100% |
| `adminCount`, `moderatorCount`, `leaderCount` | Admins, moderators and leaders | 100% |
| `admins`, `moderators`, `adminsSentence` | The admins and moderators Facebook names to visitors (`id`, `name`, `url`) and its sentence | 60%, 17%, 60% |
| `rules`, `rulesCount` | The group's rules (`title`, `text`), up to 10 | 59% |

`detailsStatus` is `read` when these facts were read and charged, `not_requested` when the add-on is off, `failed` when Facebook did not answer the about query (not charged), `read_in_part` when its answer carried an error inside one of these fields (delivered, not charged), `allowance_spent` when the add-on's own allowance had no room left (not charged). After a platform restart a run delivers the rest of its rows free, the add-on included.

#### Free rows

- `coverage`: one per search (a keyword, with one search location when given): the phrases and engines read (`walks`, each with its pages and how it ended), results and group links read, candidates, groups Facebook does not know (`notAvailable`), groups an earlier search of the run already delivered (`foundAgain`), groups left out by each filter (`filteredOut`), groups delivered and billed, Search page events billed, `stopReason` and `complete`.
- `links`: one per input list and outcome of your group links (delivered, repeat, not found, share link not resolved, filtered, lookup failed, not reached), with the positions in that list (200 a row; more rows when needed).
- `skipped`: entries of your keyword or link list that could not be used, one row per reason, with their positions (200 a row).
- `status`: written instead of everything else when the input cannot be used as given (`status: "invalid_input"`, the problems found); nothing is fetched and only the start fee is charged.
- `summary`: the run's counters, requests, bytes and billing.

#### Example group row (Group details on)

```json
{
  "type": "group",
  "groupId": "1640359419585652",
  "name": "Houston Real Estate Investors",
  "url": "https://www.facebook.com/groups/houstonrealestateinvestors/",
  "vanity": "houstonrealestateinvestors",
  "privacy": "public",
  "privacyText": "Public group",
  "membersCount": 70607,
  "membersCountIsApproximate": false,
  "membersText": "70.6K members",
  "hasMembershipQuestions": false,
  "joinState": "CAN_JOIN",
  "isBuySellGroup": false,
  "query": "real estate investors",
  "rank": 1,
  "foundBy": "brave",
  "matchedIn": ["name", "description"],
  "detailsStatus": "read",
  "membersExact": 70607,
  "postsLastDay": 12,
  "postsLastMonth": 536,
  "postsPerDayAverage": 17.87,
  "createdAt": "2015-11-15T16:12:06.000Z",
  "historyText": "Group created on November 15, 2015",
  "locations": [{ "id": "115963528414384", "name": "Houston, Texas" }],
  "adminCount": 3,
  "moderatorCount": 8,
  "rulesCount": 3
}
```

#### How deep a search goes

Facebook's own group search is closed to logged out visitors, so this Actor finds groups the way people do without an account: through search engines. Each keyword is searched as up to three phrases (`site:facebook.com/groups <keyword>`, the same with "group", and "<keyword> facebook group"; **Deep search** off sends the first only) on Brave Search (20 results a page, up to 6 pages) and DuckDuckGo (10 to 15 a page). Measured on 2026-11-08: Brave alone found 10 to 51 groups a keyword with the first phrase and 34 to 114 over the phrases; with both engines 57 to 193 groups a keyword after removing repeats (5 keywords). A search ends where the engines run out of new results, at **Groups per search**, or when the run stops.

The search engines ration searches per address. A page an engine refuses ends that phrase on that engine (it is never asked again from another address); the search's coverage row then says `complete: false` and the run's status message names the refusals. When one engine refuses this Actor's searches 3 times in a row it is not asked again in the run: the coverage rows and the run's status message say so, and searches then find fewer groups (nothing is charged for what was not read; a later run reads normally). When every engine of the run is refused, the run stops there and the searches not started are listed in free rows (200 a row). Large runs of many keywords meet this sooner: Brave rations each address of Apify's shared datacenter pool to about 7 searches, then an address comes back after a while (about 35 minutes, an estimate of the build's tests; FEASIBILITY.md section 2).

### How much does it cost to scrape Facebook groups?

Pay per event: you pay for the groups delivered, the search pages that delivered them and the Group details add-on, never for a group left out by your filters, a repeat, a group Facebook does not know, a refused or failed call, or a search page that delivered no new group.

| Event | Free | Bronze | Silver | Gold |
|---|---|---|---|---|
| Group (`group`), per 1,000 groups | $0.40 | $0.36 | $0.33 | $0.284 |
| Search page (`search_page`), per 1,000 pages | $12.60 | $11.50 | $10.40 | $9.00 |
| Group details (`group_details`), per 1,000 groups, add-on | $1.70 | $1.50 | $1.40 | $1.20 |
| Group lookup (`group_lookup`), per 1,000 groups delivered from your group links | $0.70 | $0.64 | $0.58 | $0.50 |
| Actor start (`apify-actor-start`), once per run | $0.007 | $0.007 | $0.007 | $0.007 |

Platinum and Diamond plans pay the Gold price. There is no discount on the Actor start event. The Store pricing card shows these same prices per 1,000 events: "$0.284 / 1,000" on the Group row means one group costs less than three hundredths of a cent on the Gold plan, and "$9.00 / 1,000" on the Search page row means one search page costs 0.9 cents (1.26 cents or less on every plan).

- **Group** is charged once per group per run, whatever number of searches, phrases or engines find it.
- **Search page** is charged for a page of Brave or DuckDuckGo results that delivered at least one charged group (5 to 20 new groups a page early in a search, fewer deeper in it: about 6 groups a page on average in the build's runs); a page that brought no new group is free. On a run of 1,000 groups without Group details most of the price is in this event (about $1.53 of $1.82).
- **Group details** is charged only for a delivered group whose about facts were read (`detailsStatus: "read"`).
- **Group lookup** is charged for a group delivered from a link, id, name or share link you gave (the run reads it on Facebook without a search page to carry it); a link that leads to no group, a repeat and a group your filters leave out are free.

Worked examples on the Gold plan, start fee included: the prefill (one keyword, 10 groups with Group details, usually 2 search pages) costs about $0.007 + 10 x ($0.000284 + $0.0012) + 2 x $0.009 = $0.040; 1,000 groups over 10 keywords (about 170 search pages, the build's average of 6 groups a page) cost about $0.007 + $0.284 + 170 x $0.009 = $1.82 without Group details and $3.02 with it; 1,000 group links cost $0.007 + 1,000 x ($0.000284 + $0.0005) = $0.79, and $1.99 with Group details.

#### The work allowance

Work that earns nothing (search pages whose groups were all left out, groups Facebook does not know, refused calls) is bounded by an allowance in real cost that grows with every event the run bills. A run whose filters leave out nearly every group stops early with `work_allowance` in its summary; the rows already delivered stay delivered and are charged once. The Group details add-on reads from a small allowance of its own: about reads that fail never stop the search, and when that allowance is spent the rest of the rows go out without the add-on, not charged for it, with `detailsStatus: "allowance_spent"`.

### Input

| Setting | What it does |
|---|---|
| `searchQueries` | Keywords or phrases, one search each (up to 100). Group links put here are read as links. |
| `groupUrls` | Group links, share links, numeric ids or names (up to 1,000), delivered as rows the same way. |
| `searchLocations` | Places added to every keyword (up to 20): each keyword is searched once per place. |
| `maxGroupsPerQuery` | The most groups one search delivers (1 to 1,000; 50 when left out). Sent as `maxResults` or `maxGroups`, the number also caps the whole run unless `maxItems` is given. |
| `maxItems` | The most groups in the whole run. |
| `deepSearch` | Three phrases per keyword (on when left out) or one. |
| `searchEngines` | `brave`, `duckduckgo` or both (both when left out). |
| `privacy` | `any`, `public` or `private`. |
| `minMembers`, `maxMembers` | A member range (rounded counts across a bound are left out unless Group details read the exact count). |
| `requireKeywordMatch` | Keep only groups whose name (or, with Group details, description, tags or locations) holds every word of the keyword of three letters or more and every word with a digit (on when left out). |
| `excludeKeywords` | Leave out groups whose name (or about facts with Group details) holds any of these words. |
| `groupDetails` | The Group details add-on (off when left out; the Console form has it on). |
| `minPostsPerDay`, `minPostsPerMonth`, `locationContains`, `createdAfter`, `createdBefore` | Filters on the about facts; each turns Group details on. Facebook shows at most 10,000 posts a month, so `minPostsPerMonth` above 10,000 (or `minPostsPerDay` above 333) matches no group. |
| `maxConcurrency` | Groups read at once (1 to 5). At the start of a run, and where most groups are left out by the filters, the groups are read one at a time until the delivered rows cover parallel reads. |
| `proxyCountry` | The country of the residential exits that read Facebook (US when left out). |

A run with no keyword and no link runs the sample search ("sourdough", 10 groups, Group details off unless you turn it on). Alias setting names are read too (`queries`, `keywords`, `startUrls`, `maxResults`, `fetchDetails`, `locations` and more, listed in each field's description); an unknown setting name refuses the run, free but for the start fee, so a typo never runs a wider search than you meant.

### Personal data

Group rows can name people (admins and moderators Facebook shows to visitors, e-mail addresses written in a description). You are responsible for a lawful use of personal data, the GDPR included.

### What this Actor does NOT do

- **Log in, or use your cookies or account**: never. Group members, the posts of private groups and anything Facebook shows only to members are not read.
- **Facebook's own group search**: closed to logged out visitors (36 of 36 empty answers on 2026-10-27), so groups are found through search engines. Facebook's logged out post search refused every call on 2026-11-08 (26 of 26, every exit since 2026-11-07 18:11 UTC) and is not used.
- **Monitor groups for new or changed groups between runs**: not built (each run is a fresh search; schedule the Actor and compare in your own sheet).
- **New members in the last week**: Facebook shows visitors the same placeholder ("No new members in the last week") on every group, so it is not delivered.
- **A posts in the last week figure, a language field, a website field of the group's own or a verified badge for groups**: Facebook's group answers carry none of these for visitors (`websites` holds the web addresses written in the description and the links Facebook marks in it).
- **Search Google or Yahoo**: not used.
- **Other kinds of Facebook search** (posts, pages, people, events): this Actor delivers group rows only; the tools listed under "More data tools by Automation Craft" below read posts, comments and pages.
- **Your own proxy URLs**: the Actor uses Apify Proxy only.

### API examples

Run it and get the groups (Node.js, `apify-client`):

```javascript
import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: 'YOUR_APIFY_TOKEN' });
const run = await client.actor('automation_craft/facebook-groups-search-scraper').call({
    searchQueries: ['real estate investors', 'house flipping'],
    maxGroupsPerQuery: 100,
    groupDetails: true,
    minMembers: 1000,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items.filter((i) => i.type === 'group'));
```

Python:

```python
from apify_client import ApifyClient
client = ApifyClient("YOUR_APIFY_TOKEN")
run = client.actor("automation_craft/facebook-groups-search-scraper").call(run_input={"searchQueries": ["yoga"], "searchLocations": ["London"], "privacy": "public"})
groups = [i for i in client.dataset(run["defaultDatasetId"]).iterate_items() if i["type"] == "group"]
```

cURL (runs and returns the rows in one call):

```bash
curl -X POST "https://api.apify.com/v2/acts/automation_craft~facebook-groups-search-scraper/run-sync-get-dataset-items?token=YOUR_APIFY_TOKEN" \
  -H "Content-Type: application/json" -d '{"searchQueries": ["tesla owners"], "maxGroupsPerQuery": 30}'
```

### FAQ

#### Is there a way to search Facebook groups without logging in?

Facebook's own group search needs an account. This Actor finds groups through Brave Search and DuckDuckGo results for Facebook group pages, then reads each group on Facebook logged out, so you get current names, privacy and member counts without an account or cookies.

#### How do I search for Facebook groups by location?

Add places under **Search locations** (each keyword is searched once per place, "yoga" with "London"), or turn on Group details and use **Group location contains** to keep only groups whose own location names the place.

#### How can I sort or filter Facebook groups by number of members?

Use **Minimum members** and **Maximum members**; every row carries `membersCount`, so you can also sort the dataset by it. With Group details on the count is exact.

#### Can I see a private Facebook group's details without joining?

Yes for what Facebook shows visitors: name, member count, privacy, and with Group details its description, activity, created date, rules, locations and admins. Its posts and member list stay closed.

#### How much does it cost to find 1,000 Facebook groups?

About $1.82 on the Gold plan without Group details (1,000 Group events, about 170 Search page events and the start fee), and about $3.02 with Group details, over a 10 keyword run; fewer pages (denser keywords) cost less. Groups left out by filters, repeats and refused calls are not charged.

#### Why does this Actor run with limited permissions?

It runs with the least privilege Apify offers: it reads and writes only its own run's storages (its dataset and a small run record that keeps a restarted run from charging a row twice). It cannot see your other Actors, datasets or account data.

### More data tools by Automation Craft

- [Posts of Public Facebook Groups, No Login](https://apify.com/automation_craft/facebook-groups-scraper)
- [Facebook Posts Scraper - Page Posts, No Login](https://apify.com/automation_craft/facebook-posts-scraper)
- [Facebook Comments Scraper: Replies, No Login](https://apify.com/automation_craft/facebook-comments-scraper)
- [Facebook Page ID Finder: Names to Page IDs](https://apify.com/automation_craft/facebook-page-id-finder)
- [Facebook Marketplace Scraper with Sold Tracker](https://apify.com/automation_craft/facebook-marketplace-scraper)
- [Instagram Posts Scraper: Profiles, Reels, No Login](https://apify.com/automation_craft/instagram-posts-scraper)
- [Threads Scraper: Posts, Search, Tags, Replies](https://apify.com/automation_craft/threads-scraper)

### Changelog

- 0.1 (2026-11-08): first release: groups by keyword through Brave Search and DuckDuckGo, read on Facebook logged out; group links, ids, names and share links; privacy, member, keyword and excluded word filters; the Group details add-on with exact members, activity, created date, locations, tags, admins and rules, and filters on them.

# Changelog

This Actor's version history is a separate document: https://apify.com/automation_craft/facebook-groups-search-scraper/changelog.md

# Actor input Schema

## `searchQueries` (type: `array`):

Keywords or phrases to find Facebook groups for, one per line ("real estate investors", "yoga london"). Up to 100 a run. Each keyword is one search: its groups come from Brave Search and DuckDuckGo results for Facebook group pages, then each group is read on Facebook itself (logged out). A Facebook group link or a facebook.com/search/groups/?q= link put here is read as a link or as its search words. Also read from queries, keywords, searchTerms, searchQuery, query and keyword.

## `groupUrls` (type: `array`):

Facebook groups you already know, one per line: a group link (facebook.com/groups/sourdoughbakers, also a post, about or members link of the group), a share link (facebook.com/share/g/...), a numeric group id or a group name. Up to 1,000 a run. Each is delivered as a group row, read the same way as a search result (the filters below apply, the keyword match does not), billed as a Group and a Group lookup (see Pricing). Also read from startUrls (strings or {"url": ...}), groupLinks, groupIds and urls.

## `searchLocations` (type: `array`):

Place names added to every keyword ("London", "Texas"), one per line, up to 20: each keyword is searched once per place ("yoga" with "London" searches "yoga London"). Leave empty to search the keywords alone. To keep only groups whose own location names a place, use locationContains (Group details). Also read from locations, searchLocation and location.

## `maxGroupsPerQuery` (type: `integer`):

The most groups delivered for one search (one keyword, with one search location when given). A search ends earlier where the search engines run out of new results: about 30 to 200 groups a keyword, depending on the keyword (FEASIBILITY.md). 50 when left out. Also read from maxResultsPerQuery, resultsPerQuery, maxGroups and maxResults (the last two also cap the whole run when maxItems is not given).

## `maxItems` (type: `integer`):

The most groups delivered in the whole run, all searches and links together (each group once). 100,000 when left out.

## `deepSearch` (type: `boolean`):

On (the default when left out): each keyword is searched as three phrases (site:facebook.com/groups <keyword>, the same with "group", and "<keyword> facebook group"), which finds about two to four times more groups. Off: the first phrase only (faster, fewer groups).

## `searchEngines` (type: `array`):

The search engines a keyword is looked up on: Brave Search (about 20 results a page, up to 6 pages a phrase) and DuckDuckGo (about 10 to 15 a page). Both when left out. An engine that refuses this Actor's searches 3 times in a row is not asked again in the run; when every engine of the run is refused, the run stops and the searches not started are listed in free rows (200 a row). The coverage rows say which engine pages were read. Also read from sources.

## `privacy` (type: `string`):

Keep only public or only private groups. Private groups are delivered with their name, members, privacy and (with Group details) their about facts: Facebook shows those to visitors; their posts and members are not read. Any when left out. Also read from groupPrivacy.

## `minMembers` (type: `integer`):

Keep only groups with at least this many members. Without Group details the count is Facebook's rounded one ("70.6K"), and a group whose rounded count could be on either side of your bound is left out, free; with Group details on, the exact count decides.

## `maxMembers` (type: `integer`):

Keep only groups with at most this many members (the same rounding rule as minMembers).

## `requireKeywordMatch` (type: `boolean`):

On (the default when left out): a search result is kept only when every word of the keyword (words of three letters or more and words with a digit; all words if none is like that) stands as a whole word in the group's name, or, with Group details on, in its description, topic tags or locations. Search engines also return groups that are only near the topic; turn this off to keep them. Search locations are not part of the match. Group links are never checked.

## `excludeKeywords` (type: `array`):

Leave out a group whose name (and, with Group details on, its description, topic tags or locations) holds any of these words or phrases as whole words, up to 50. Left out groups are free. Also read from excludedKeywords.

## `groupDetails` (type: `boolean`):

Adds Facebook's about facts to each group row, billed as Group details (see Pricing): exact member count, posts in the last day and month, created date and name history, description with its links and e-mails, locations, topic tags, admin and moderator counts and names, rules. Off when left out. Any filter below turns it on. When its own allowance is spent a row goes out without it, unbilled, and says so in detailsStatus. Also read from fetchDetails, enrichGroupDetails and includeDetails.

## `minPostsPerDay` (type: `number`):

Keep only groups with at least this many posts a day on average over the last month (posts in the last month divided by 30). Needs Group details (turned on).

## `minPostsPerMonth` (type: `integer`):

Keep only groups with at least this many posts in the last month. Needs Group details (turned on).

## `locationContains` (type: `string`):

Keep only groups whose own location list (set by the group's admins, shown on about half of groups) names this place as whole words ("Texas" keeps "Houston, Texas"). Groups without a location are left out. Needs Group details (turned on). Also read from locationText.

## `createdAfter` (type: `string`):

Keep only groups created on or after this day (YYYY-MM-DD, UTC). Needs Group details (turned on).

## `createdBefore` (type: `string`):

Keep only groups created on or before this day (YYYY-MM-DD, UTC). Needs Group details (turned on).

## `maxConcurrency` (type: `integer`):

How many groups are read at the same time, each on its own residential exits (1 when left out, up to 5). More is faster on large runs and costs the same; at the start of a run, and on runs where most groups are left out by the filters, the groups are read one at a time until the delivered rows cover parallel reads. Also read from concurrency.

## `proxyCountry` (type: `string`):

The country of the Apify residential exits that read the groups on Facebook, as a two letter code (US when left out). The search engines are read from Apify's datacenter exits.

## Actor input object example

```json
{
  "searchQueries": [
    "sourdough"
  ],
  "groupUrls": [],
  "searchLocations": [],
  "maxGroupsPerQuery": 10,
  "deepSearch": true,
  "searchEngines": [
    "brave",
    "duckduckgo"
  ],
  "privacy": "any",
  "requireKeywordMatch": true,
  "excludeKeywords": [],
  "groupDetails": true
}
```

# Actor output Schema

## `items` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "searchQueries": [
        "sourdough"
    ],
    "groupUrls": [],
    "searchLocations": [],
    "maxGroupsPerQuery": 10,
    "deepSearch": true,
    "searchEngines": [
        "brave",
        "duckduckgo"
    ],
    "privacy": "any",
    "requireKeywordMatch": true,
    "excludeKeywords": [],
    "groupDetails": true
};

// Run the Actor and wait for it to finish
const run = await client.actor("automation_craft/facebook-groups-search-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "searchQueries": ["sourdough"],
    "groupUrls": [],
    "searchLocations": [],
    "maxGroupsPerQuery": 10,
    "deepSearch": True,
    "searchEngines": [
        "brave",
        "duckduckgo",
    ],
    "privacy": "any",
    "requireKeywordMatch": True,
    "excludeKeywords": [],
    "groupDetails": True,
}

# Run the Actor and wait for it to finish
run = client.actor("automation_craft/facebook-groups-search-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "searchQueries": [
    "sourdough"
  ],
  "groupUrls": [],
  "searchLocations": [],
  "maxGroupsPerQuery": 10,
  "deepSearch": true,
  "searchEngines": [
    "brave",
    "duckduckgo"
  ],
  "privacy": "any",
  "requireKeywordMatch": true,
  "excludeKeywords": [],
  "groupDetails": true
}' |
apify call automation_craft/facebook-groups-search-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,automation_craft/facebook-groups-search-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/mVxhwM5tfFBklwgAi/builds/e3HZNRgAYQnMVRm6O/openapi.json
