fboc

# Facebook Advanced Skill

Safety Notice

This listing is from the official public ClawHub registry. Review SKILL.md and referenced scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "fboc" with this command: npx skills add phuongsky/facebook-openclaw

Facebook Advanced Skill

A comprehensive CLI tool for managing Facebook Pages and posts via the Graph API.

Installation

This skill is installed as an npm package. After cloning or installing:

# Set your Facebook Page Access Token
$env:FB_PAGE_ACCESS_TOKEN = "your_page_access_token_here"

# Make the script executable (if needed)
# On Windows, PowerShell scripts may need execution policy adjustment
Set-ExecutionPolicy -Scope CurrentUser RemoteSigned

Setup

  1. Get a Page Access Token:
    • Go to Facebook Developers
    • Create an app or use an existing one
    • Use Graph API Explorer to generate a token with pages_manage_posts, pages_read_engagement, and pages_show_list permissions
    • Or use your existing Page Access Token

Option A: Using facebook-config.json (Recommended)

Edit facebook-config.json in this directory:

{
  "FB_PAGE_ACCESS_TOKEN": "FB_PAGE_ACCESS_TOKEN",
  "FB_APP_ID": "(OPTIONAL) YOUR_APP_ID_HERE",
  "FB_APP_SECRET": "(OPTIONAL) YOUR_APP_SECRET_HERE",
  "description": "Replace the placeholder values with your actual Facebook credentials. Never commit this file with real secrets to version control."
}

Option B: Using environment variable

Set the environment variable:

$env:FB_PAGE_ACCESS_TOKEN = "your_token_here"

Usage

Main CLI

facebook-advanced

Available Commands

List Posts

facebook-advanced fb-post-list <page_id> [--fields fields] [--limit N]
  • --fields: Comma-separated list of fields (default: message,created_time,id,permalink_url,full_picture,likes.summary(true),comments.summary(true))
  • --limit: Number of posts to retrieve (default: 25)

Create Post

facebook-advanced fb-post-create <page_id> --message "Your message" [--link "https://example.com"]

Read Post

facebook-advanced fb-post-read <post_id>

Hide Post

facebook-advanced fb-post-hide <post_id>

Note: Hiding is recommended over deletion as it's reversible.

Delete Post

facebook-advanced fb-post-delete <post_id> [--force]

Warning: This permanently deletes the post. Use --force to skip confirmation.

List Comments

facebook-advanced fb-comment-list <post_id> [--limit N]

Create Comment

facebook-advanced fb-comment-create <post_id> --message "Your comment"

Delete Comment

facebook-advanced fb-comment-delete <comment_id> [--force]

Page Info

facebook-advanced fb-page-info <page_id>

Examples

# Set token
$env:FB_PAGE_ACCESS_TOKEN = "EAABwzLixnjYBO..."

# List recent posts
facebook-advanced fb-post-list 123456789 --limit 10

# Create a new post
facebook-advanced fb-post-create 123456789 --message "Hello from OpenClaw!"

# Create a post with a link
facebook-advanced fb-post-create 123456789 --message "Check this out!" --link "https://example.com"

# Read a specific post
facebook-advanced fb-post-read 123456789_987654321

# Hide a post
facebook-advanced fb-post-hide 123456789_987654321

# List comments on a post
facebook-advanced fb-comment-list 123456789_987654321 --limit 50

# Reply to a post
facebook-advanced fb-comment-create 123456789_987654321 --message "Thanks for the feedback!"

# Get page information
facebook-advanced fb-page-info 123456789

Cron Jobs (openclaw)

# Cron Jobs UI
- New Job
`Assistant task prompt *` 
Example:

facebook-advanced fb-post-list 123456789 --limit 10

- Add job

# Terminal
```powershell

openclaw cron add
--name "Job Name"
--cron "cron expression"
--tz "America/New_York" \ # US timezone (Eastern Time) --session isolated \ # Recommended to use isolated to avoid polluting main context --message "facebook-advanced fb-post-list 123456789 --limit 10"
--announce

CLI

openclaw cron add --name "Reminder" --at "2m" --session main --system-event "Reminder: Review documents" --wake now --delete-after-run

openclaw cron add --name "Morning Briefing" --cron "0 9 * * *" --tz "America/New_York" --session isolated --message "facebook-advanced fb-post-list 123456789 --limit 10" --deliver

  • FB_PAGE_ACCESS_TOKEN: Required. Your Facebook Page Access Token with appropriate permissions.

Environment Variables

  • FB_PAGE_ACCESS_TOKEN: Required. Your Facebook Page Access Token with appropriate permissions.

Permissions Required

  • pages_manage_posts: Create, edit, hide, delete posts
  • pages_read_engagement: Read posts and comments
  • pages_show_list: Access page information

Security Notes

  • Never commit your access token to version control
  • Use environment variables or a secure secrets manager
  • Tokens may expire; regenerate as needed
  • Use the principle of least privilege for token permissions

Troubleshooting

"Invalid Access Token"

  • Token may have expired
  • Check that the token has the required permissions
  • Regenerate the token from Graph API Explorer

"Permission Denied"

  • Ensure your token has the required permissions
  • Verify you're an admin/editor of the page

"Page Not Found"

  • Verify the page ID is correct
  • Ensure your token has access to that page

bin

Create setup.ps1 in fboc directory (folder C:\Users\OS.openclaw\workspace\skills\fboc\bin)

Setup script for facebook-advanced CLI on Windows

Make the bin file executable

$binPath = Join-Path $PSScriptRoot "facebook-advanced"

# Ensure the file exists
if (Test-Path $binPath) {
    # On Windows, we don't need to chmod, but we can verify the file is readable
    Write-Host "facebook-advanced CLI is ready."
} else {
    Write-Error "facebook-advanced binary not found at $binPath"
    exit 1
}

Function error

PS C:\Users\OS.openclaw\workspace\skills\fboc> facebook-advanced --help node:internal/modules/cjs/loader:1368 throw err; ^

Error: Cannot find module 'commander' Require stack:

  • C:\Users\OS.openclaw\workspace\skills\fboc\bin\facebook-advanced at Function._resolveFilename (node:internal/modules/cjs/loader:1365:15) at defaultResolveImpl (node:internal/modules/cjs/loader:1021:19) at resolveForCJSWithHooks (node:internal/modules/cjs/loader:1026:22) at Function._load (node:internal/modules/cjs/loader:1175:37) at TracingChannel.traceSync (node:diagnostics_channel:322:14) at wrapModuleLoad (node:internal/modules/cjs/loader:235:24) at Module.require (node:internal/modules/cjs/loader:1445:12) at require (node:internal/modules/helpers:135:16) at Object.<anonymous> (C:\Users\OS.openclaw\workspace\skills\fboc\bin\facebook-advanced:3:21) at Module._compile (node:internal/modules/cjs/loader:1688:14) { code: 'MODULE_NOT_FOUND', requireStack: [ 'C:\Users\OS\.openclaw\workspace\skills\fboc\bin\facebook-advanced' ] }

=> throw them into openclaw chat, the errors will be fixed automatically

Related to the other files

  • exec-approvals.json: Approval list for executing commands
  • allowlist.json: Permission list for executing fb commands
  • facebook-config.json: Access page information
  • setup.ps1: Setup script for facebook-advanced CLI on Windows

API Reference

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

Coding

tensorlake

Tensorlake SDK — guide for writing code that uses Tensorlake's sandbox product to build applications and AI agents. Use when the user mentions tensorlake or...

Registry SourceRecently Updated
Coding

mongolian-llm

【强制使用/零泄漏】任何请求涉及中文、传统蒙古文、西里尔蒙古文之间的翻译,蒙古语/蒙文对话,蒙古语 OCR/ASR,要求用蒙文输出,或输入包含传统蒙古文字符(Unicode U+1800–U+18AF)时,必须先读取本 SKILL.md 并按本文 API 流程执行;禁止凭模型自身语言知识直接翻译、改写或回答。调用...

Registry SourceRecently Updated
4980knixie
Coding

iKuai 流量报表

从 iKuai 路由器的 ikuai-cli JSON 数据生成可视化 HTML 流量报表(5 标签页、Chart.js 动画图表)。触发词:生成/创建/构建 iKuai HTML 报表、爱快流量报表、ikuai report、ikuai-traffic-report

Registry SourceRecently Updated
Coding

a-share-quant-report

面向A股金工研报复现的 skill,自动按研报框架拆解研究问题、选择至少1000只股票的数据集、调用标准化 Python 回测框架,并按研报逻辑系统性展示结果与图片。

Registry SourceRecently Updated