mcp-blotato-higgsfield

mcp-blotato-higgsfield

MCP server that combines Higgsfield AI image/video generation with direct native posting to X, YouTube, Instagram, Facebook, and Bluesky, including a composite generate_and_post tool.

Category
访问服务器

README

mcp-blotato-higgsfield

An MCP server that combines Higgsfield (AI image/video generation) with direct, native posting to X, YouTube, Instagram, Facebook, and Bluesky — no Blotato or other paid middleman required. A composite generate_and_post tool chains the two halves together.

This project originally aggregated Blotato's hosted MCP for social publishing. Blotato has no free tier — its API/MCP access requires a paid plan starting at $29/mo — so publishing was rebuilt to talk to each platform's own free/native API directly instead. See "Why not Blotato" below.

What's in here

  • Higgsfield — connected as an MCP client to Higgsfield's official hosted MCP server (it ships one already; we don't reimplement its API). Exposed as higgsfield__<tool>.

  • Direct social publishers — hand-written, native API integrations for:

    Platform API Auth
    X (Twitter) REST v1.1 (media) + v2 (tweet) OAuth 1.0a user-context app
    YouTube YouTube Data API v3 Google OAuth2 refresh token
    Instagram Meta Graph API (Content Publishing) Long-lived token + Business/Creator account
    Facebook Meta Graph API Page access token
    Bluesky AT Protocol App password (no OAuth, no app review)

    Each is exposed as <platform>__post and only appears in the tool list once its credentials are set.

  • generate_and_post — generate media from a prompt via Higgsfield, then fan out and publish it to whichever of the above platforms you ask for, in one call.

Why not Blotato

Blotato is a paid unified API/MCP over these same platforms. Wrapping it yourself doesn't avoid the cost — its API key is gated the same way whether you call it through Blotato's hosted MCP or your own client. Going direct means:

  • Free for X (limited tier), YouTube (free daily quota), and Bluesky (fully open).
  • Meta (Instagram/Facebook) is free but requires app review for anything beyond your own test accounts.
  • You take on what Blotato was abstracting: a separate developer app + OAuth flow per platform, and keeping up with each API's own quirks.

Setup

npm install
cp .env.example .env   # fill in credentials for the platforms you want, see below
npm run build

You don't need every platform configured — the server only advertises tools for what's set. Start with Bluesky (easiest, no approval process) if you want to try it end-to-end quickly.

Higgsfield

Higgsfield's hosted MCP is OAuth-only. Authorize once via mcp-remote, which opens a browser and caches the token locally:

npx -y mcp-remote https://mcp.higgsfield.ai/mcp

Then set in .env:

HIGGSFIELD_TRANSPORT=stdio
HIGGSFIELD_MCP_COMMAND=npx
HIGGSFIELD_MCP_ARGS=-y mcp-remote https://mcp.higgsfield.ai/mcp

Bluesky (start here — easiest)

  1. In the Bluesky app: Settings → App Passwords → create one.
  2. Set BLUESKY_IDENTIFIER (your handle, e.g. you.bsky.social) and BLUESKY_APP_PASSWORD.

No developer account, no app review, no OAuth. Works immediately.

X (Twitter)

  1. Create a project/app at developer.x.com.
  2. Under the app's "Keys and tokens", generate: API Key/Secret and an Access Token & Secret with Read and Write permissions (regenerate the access token after changing permissions, or it stays read-only).
  3. Set X_API_KEY, X_API_SECRET, X_ACCESS_TOKEN, X_ACCESS_TOKEN_SECRET.

⚠️ X's free-tier limits (post volume, whether media upload is included) have changed more than once — check your app's current tier in the developer portal.

YouTube

  1. In Google Cloud Console, create a project, enable the YouTube Data API v3, and create an OAuth2 Desktop app client ID (gives you a client ID + secret).
  2. Get a refresh token once via the OAuth consent flow with scope https://www.googleapis.com/auth/youtube.upload (e.g. using Google's OAuth Playground with your own client ID/secret plugged in under its settings gear icon).
  3. Set YOUTUBE_CLIENT_ID, YOUTUBE_CLIENT_SECRET, YOUTUBE_REFRESH_TOKEN.

Free tier: 10,000 quota units/day; one video upload costs ~1,600 units (~6 uploads/day).

Instagram

  1. Requires an Instagram Business or Creator account connected to a Facebook Page.
  2. Create a Meta app at developers.facebook.com, add the Instagram + Facebook Login products.
  3. Generate a long-lived access token with the instagram_content_publish permission (works immediately for your own account in dev mode; posting on behalf of others needs Meta App Review).
  4. Set IG_ACCESS_TOKEN and IG_USER_ID (your Instagram Business Account ID, fetched via GET /me/accountsGET /{page-id}?fields=instagram_business_account).

Facebook

  1. Same Meta app as above.
  2. Generate a Page access token (not a user token) with pages_manage_posts.
  3. Set FB_PAGE_ACCESS_TOKEN and FB_PAGE_ID.

Running

npm run build && npm start
# or, for local development without a build step:
npm run dev

This starts an MCP server on stdio.

Add it to Claude Code / Claude Desktop

{
  "mcpServers": {
    "blotato-higgsfield": {
      "command": "node",
      "args": ["/absolute/path/to/mcp_blotato_higgsfield/dist/index.js"],
      "env": {
        "HIGGSFIELD_TRANSPORT": "stdio",
        "HIGGSFIELD_MCP_COMMAND": "npx",
        "HIGGSFIELD_MCP_ARGS": "-y mcp-remote https://mcp.higgsfield.ai/mcp",
        "BLUESKY_IDENTIFIER": "you.bsky.social",
        "BLUESKY_APP_PASSWORD": "...",
        "X_API_KEY": "...", "X_API_SECRET": "...",
        "X_ACCESS_TOKEN": "...", "X_ACCESS_TOKEN_SECRET": "..."
      }
    }
  }
}

Or with the Claude Code CLI:

claude mcp add blotato-higgsfield -- node /absolute/path/to/dist/index.js

How it works

src/
  config.ts              # env-driven config for the Higgsfield upstream connection
  clients/
    upstream.ts            # generic MCP client wrapper (http or stdio transport)
  publishers/
    types.ts                # Publisher interface + fetchMediaBytes helper
    x.ts                     # X (Twitter) via twitter-api-v2
    youtube.ts                 # YouTube Data API v3, multipart upload
    instagram.ts                 # Meta Graph API content-publishing flow
    facebook.ts                    # Meta Graph API page posting
    bluesky.ts                      # AT Protocol via @atproto/api
    metaGraph.ts                     # shared helpers for instagram.ts/facebook.ts
    index.ts                         # publisher registry
  tools/
    passthrough.ts          # namespaces + re-lists Higgsfield's MCP tools
    publishers.ts             # exposes each configured publisher as <platform>__post
    composite.ts                # generate_and_post: Higgsfield -> fan out to publishers
  index.ts                # our own MCP server (stdio), wires it all together
  • On tools/list, we return Higgsfield's upstream tools (prefixed higgsfield__), one <platform>__post tool per configured publisher, and generate_and_post when Higgsfield + at least one publisher are configured.
  • On tools/call, a higgsfield__* name routes to the upstream MCP client; a <platform>__post name routes to that publisher; generate_and_post runs the composite flow.
  • We don't hardcode Higgsfield's exact tool/field names (they can change) — generate_and_post discovers the right Higgsfield tool at runtime by matching tool names (e.g. /generate.*video/i) and guesses common field names against its real input schema. Pass higgsfield_args to override explicitly if the guess is wrong. Publisher-side fields (media URL, caption, platform-specific options) are handled directly by each publisher, since we wrote those ourselves against each platform's real, stable API — no guessing needed there.

Known limitations

  • Media handling: X, YouTube, and Bluesky's upload APIs take raw bytes, so those publishers download the generated media first. Instagram/Facebook's Graph API accepts a remote URL directly, so no download happens there.
  • YouTube upload uses a single multipart request rather than the full resumable- upload protocol — fine for short AI-generated clips, but large files should use resumable upload instead.
  • Higgsfield's tool discovery is heuristic (see above) since its schema isn't hardcoded here.
  • None of the publishers implement an in-process OAuth authorization flow — you obtain each platform's token/credentials out-of-band (see Setup above) and the server just uses them.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选
mcp-server-qdrant

mcp-server-qdrant

这个仓库展示了如何为向量搜索引擎 Qdrant 创建一个 MCP (Managed Control Plane) 服务器的示例。

官方
精选