social-connect-mcp-poc
Social Connect MCP POC
Node.js-22-POC ohne npm-Abhängigkeiten zum Testen der Facebook-/TikTok-Verbindung, von OAuth und der MCP-Connection-Tools.
1. Sofort mit Mock ausführen
cp .env.example .env
npm test
npm startÖffne http://localhost:3000 und klicke anschließend auf Test Facebook, Test TikTok oder Run test-all.
.env.example hat standardmäßig MOCK_SOCIAL=true, sodass die Demo sofort ohne Secrets ausgeführt werden kann.
Related MCP server: Meta Ads MCP Server
2. Zugriff auf echte Endpoints testen
npm run probeEin HTTP-Statuscode 400/401 ohne Token bedeutet trotzdem, dass der Provider-Endpoint erreichbar ist.
3. Facebook LIVE ausführen
Erstelle eine Meta Developer App, füge Facebook Login hinzu und konfiguriere:
MOCK_SOCIAL=false
META_GRAPH_VERSION=v26.0
META_APP_ID=...
META_APP_SECRET=...
META_REDIRECT_URI=http://localhost:3000/api/facebook/callbackOAuth-Scopes für das POC:
pages_show_list
pages_read_engagement
pages_manage_posts
pages_manage_engagement
pages_messagingÖffne dann:
http://localhost:3000/api/facebook/loginDer Callback tauscht den Autorisierungscode gegen einen User-Access-Token, ruft /me und /me/accounts auf und hält den Token temporär im Speicher.
Du kannst OAuth auch umgehen, um Token/Page direkt zu testen:
META_USER_ACCESS_TOKEN=...
# hoặc
META_PAGE_ID=...
META_PAGE_ACCESS_TOKEN=...4. TikTok LIVE ausführen
Erstelle eine TikTok Developer App + Login Kit und konfiguriere:
MOCK_SOCIAL=false
TIKTOK_CLIENT_KEY=...
TIKTOK_CLIENT_SECRET=...
TIKTOK_REDIRECT_URI=http://localhost:3000/api/tiktok/callback
TIKTOK_SCOPES=user.info.basic,video.listÖffne:
http://localhost:3000/api/tiktok/loginDer Callback verwendet den Token-v2-Endpoint und testet danach /v2/user/info/. Wenn die App video.list hat, testet das PUnzOC auch /v2/video/list/.
Oder teste den Token direkt:
TIKTOK_ACCESS_TOKEN=...5. Interne API
GET /api/health
GET /api/facebook/login
GET /api/facebook/callback
GET /api/facebook/test
GET /api/tiktok/login
GET /api/tiktok/callback
GET /api/tiktok/test
GET /api/test-all6. MCP POC
npm run mcpTools:
social_status
facebook_test_connection
tiktok_test_connectionsrc/mcp-server.js ist eine minimale stdio-JSON-RPC-MCP-Implementierung, damit das POC nicht von externen Paketen abhängt. Beim Wechsel in die Produktion sollte sie durch das offizielle MCP SDK ersetzt werden.
7. TODO für die Produktion
Das POC hält OAuth-Tokens absichtlich nur im Speicher. Die Produktion benötigt eine Datenbank bzw. einen verschlüsselten Secret Store, Refresh-Token-Rotation, Meta/TikTok-Webhook-Verifizierung, RBAC, Audit-Log, Rate-Limit/Retry, App Review und einen Token-Revocation-Flow.
8. Git
Das Repository wurde bereits mit git init initialisiert. Zum Pushen auf GitHub nach dem Erstellen des Remote-Repositorys:
git remote add origin git@github.com:<username>/social-connect-mcp-poc.git
git push -u origin mainTool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
OAuth MCP for Google, Meta, X, LinkedIn, Reddit, TikTok, GSC, GA4, WordPress and GHL.
Hosted TikTok ads MCP with OAuth, bounded reads, and prepare/confirm writes.
One-link client onboarding & ad-access MCP server for digital agencies (OAuth 2.1).
Human-approved social media publishing and AI media Studio via hosted OAuth MCP.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceA remote MCP server that provides tools to query live Meta (Facebook+Instagram) and TikTok organic social data, such as follower counts, insights, recent posts, and aggregated overviews.-
- AlicenseNot gradedqualityAmaintenanceEnables connecting to the Meta Marketing API to manage ad accounts, campaigns, ad sets, creatives, audiences, reporting, and batch workflows through an authenticated, multi-tenant MCP endpoint.39 npmMIT
- AlicenseNot gradedqualityAmaintenanceEnables connecting Meta Ads accounts to an MCP client so users can manage ad accounts, campaigns, ad sets, creatives, audiences, reporting, and batch workflows through the Meta Marketing API.39 npmMIT
- AlicenseNot gradedqualityAmaintenanceEnables connecting to the Meta Marketing API to manage ad accounts, campaigns, ad sets, creatives, audiences, reporting, and batch workflows through authenticated MCP tools.39 npmMIT