Facebook public group API
What a public group's About page shows.
- Cost
- 1 credit
- Cached repeats
- 0 creditssend max_age_days, results kept 30 days
- Failed requests
- 0 credits
- Status
- Betashape may still gain fields
Description, privacy, member and activity counts, categories, admins and moderators where shown, history and rules.
You send one of url or id.
Request
Send your key in the x-api-key header.
curl -G "https://api.socialscrape.io/v1/facebook/group" \
-H "x-api-key: $SOCIALSCRAPE_API_KEY" \
--data-urlencode 'url=https://www.facebook.com/groups/366190054572553'import os
import requests
params = {
"url": "https://www.facebook.com/groups/366190054572553",
}
res = requests.get(
"https://api.socialscrape.io/v1/facebook/group",
headers={"x-api-key": os.environ["SOCIALSCRAPE_API_KEY"]},
params=params,
timeout=60,
)
body = res.json()
if body["ok"]:
print(body["data"])
else:
print(body["error"]["code"], body["error"]["message"])const url = new URL("https://api.socialscrape.io/v1/facebook/group");
url.search = new URLSearchParams({
url: "https://www.facebook.com/groups/366190054572553",
}).toString();
const res = await fetch(url, {
headers: { "x-api-key": process.env.SOCIALSCRAPE_API_KEY! },
});
const body = await res.json();
if (body.ok) {
console.log(body.data);
} else {
console.error(body.error.code, body.error.message);
}{
"nodes": [
{
"name": "SocialScrape Facebook public group",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
0,
0
],
"parameters": {
"method": "GET",
"url": "https://api.socialscrape.io/v1/facebook/group",
"sendQuery": true,
"queryParameters": {
"parameters": [
{
"name": "url",
"value": "https://www.facebook.com/groups/366190054572553"
}
]
},
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "x-api-key",
"value": "={{ $env.SOCIALSCRAPE_API_KEY }}"
}
]
}
}
}
],
"connections": {}
}Parameters
| Name | Type | Required | Description |
|---|---|---|---|
url | url | one of | Public group URL (facebook.com/groups/...). Sub-pages such as /about work too. |
id | string | one of | Numeric group id; use it instead of `url` if you have it. Also accepted as group_id. |
Every request also accepts trim, raw and max_age_days.
Response
Sample from a recorded response, shortened. Values are public data, not yours.
{
"ok": true,
"credits_charged": 1,
"credits_remaining": 4999,
"cached": false,
"cached_at": null,
"request_id": "req_d05ae521cb97f1a25d8a6524",
"data": {
"object": "community",
"platform": "facebook",
"id": "366190054572553",
"url": "https://www.facebook.com/groups/366190054572553/",
"kind": "group",
"name": "Python Programming",
"title": "Python Programming",
"description": "Let's share our knowledge on Python Programming",
"avatar_url": "https://scontent-iad6-1.xx.fbcdn.net/v/t1.6435-9/121615771_3201454343306997_2348901429098757975_n.jpg?stp=dst-jpg_tt6&cstp=mx640x400&ctp=s640x400&_nc_cat=106...",
"banner_url": null,
"member_count": 759600,
"online_count": null,
"is_nsfw": null,
"is_private": false,
"verified": null,
"created_at": "2020-10-14T11:05:03Z",
"extra": {
"activity": {
"new_members_text": "No new members in the last week",
"posts_last_day": 28,
"posts_last_month": 1542
},
"administrator_count": 3,
"administrators": [
{
"id": "pfbid029gmqPLAMDT2z4drrFEsicJ4ivhnAGkEPBNUPTujKbSYf6bMCjTzRKrNNPmePAotrl",
"name": "Nusrat Jahan",
"profile_picture_url": "https://scontent-iad6-1.xx.fbcdn.net/v/t39.30808-1/297738489_149183324449711_6655284279259187616_n.jpg?stp=cp0_dst-jpg_tt6&cstp=mx720x730&ctp=s32x32&_nc_cat=...",
"url": null
},
{
"id": "100079525026696",
"name": "Thesoftwarelion",
"profile_picture_url": "https://scontent-iad3-1.xx.fbcdn.net/v/t39.30808-1/242977119_109642788145497_5023972278328162431_n.jpg?stp=cp0_dst-jpg_tt6&cstp=mx1200x1200&ctp=s32x32&_nc_ca...",
"url": null
},
{
"id": "pfbid0pzs33rRB9YA54hRjvjaPeA62UVZTg73Aqbnn8jSjS9Mo1DUAZNyzV6wFUgYgnDwhl",
"name": "Jamil Ahmed",
"profile_picture_url": "https://scontent-iad3-1.xx.fbcdn.net/v/t39.30808-1/795255518_27959759933716428_4332290339331851799_n.jpg?stp=cp0_dst-jpg_tt6&cstp=mx1568x1556&ctp=s32x32&_nc_...",
"url": null
}
],
"categories": [
{
"id": "242504017103922",
"name": "Software & tech"
},
{
"id": "202183377053878",
"name": "Engineering"
}
],
"history_summary": "Group created on October 14, 2020. Name last changed on October 16, 2020.",
"member_count_text": "759.6K members"
}
},
"cursor": null,
"has_more": null
}Fields
One Community in data.
A field the platform does not give is null, never made up. Extra platform details are in extra.
| Field | Type | Always | Notes |
|---|---|---|---|
object | "community" | ||
platform | Platform | yes | |
id | string or null | ||
url | string or null | ||
kind | "subreddit" or "group" or "community" or "channel" or "unknown" | ||
name | string or null | the slug, "python" for r/python | |
title | string or null | ||
description | string or null | ||
avatar_url | string or null | ||
banner_url | string or null | ||
member_count | integer or null | ||
online_count | integer or null | ||
is_nsfw | boolean or null | ||
is_private | boolean or null |
Show the other 3 fields
| Field | Type | Always | Notes |
|---|---|---|---|
verified | boolean or null | the platform's verified badge (Telegram channels) | |
created_at | string (ISO 8601 date-time) or null | ||
extra | object or null |
Full field list in the reference for this endpoint and the data models. Errors are listed under Errors.
Questions
Which errors can it return?
invalid_params (do not retry), unsupported_url (do not retry), not_found (do not retry). Account and platform errors from the errors list can also happen. A failure always costs 0 credits.
Is there an SDK call for it?
The preview Python client has client.facebook.group(...) and the TypeScript client client.facebook.group(). Both return the same envelope as the HTTP API. The packages are not published yet; plain HTTP works today in any language.
Can an AI agent call it?
Yes. The MCP server reaches every built endpoint, with the same prices.