Skip to main content
Glama

postiz-mcp

あらゆるMCP互換クライアント向けの標準的なPostizクライアントです。PostizのパブリックAPI(統合、投稿、アップロード、分析、動画)を完全にカバーしており、環境変数による書き込み制限、削除時の確認要求、組み込みのレート制限ガードを備えています。

stdio MCPサーバーとして、かつ同一パッケージからOpenClawネイティブプラグインとして提供されます。

理由

Postizをセルフホストしており、Claude / Codex / OpenClaw / Hermes / その他のMCPクライアントから操作したい場合、ワークフローごとに手動でHTTP呼び出しを作成する代わりに、型定義されテスト済みの単一目的のツールインターフェースを提供します。

Related MCP server: Postoria MCP Server

接続前の警告

  • Postizの書き込みは公開される副作用を伴います。 type: "now"(または近い将来のスケジュール)を指定した postiz_create_post の実行は、実際のソーシャルアカウントに投稿されます。一度公開されると、Postizから投稿を削除することはできますが、プラットフォーム側の投稿は残ります — Postizはそれを取り消すことができません。

  • PostizのパブリックAPIは、デフォルトで1時間あたり30リクエストのレート制限があります。 このサーバーはローカルで制限を追跡し、予算が尽きた場合は送信を拒否します。Postizインスタンスの設定がより高い場合は、POSTIZ_RATE_LIMIT_PER_HOUR で上書きしてください。

  • 書き込みと削除はデフォルトで無効になっています。 読み取りは常に機能します。書き込みを有効にするには、明示的に POSTIZ_ENABLE_WRITE=true を設定する必要があります。削除を有効にするには、さらに POSTIZ_ENABLE_DELETE=true を設定し、ツール呼び出しで confirm: true を渡す必要があります。

ツール

読み取り(常に有効)

  • postiz_list_integrations — 接続済みチャンネルの一覧表示

  • postiz_check_integration — APIキーの検証

  • postiz_find_next_slot — チャンネルの次の空き投稿枠の検索

  • postiz_list_posts — 指定期間内の投稿一覧

  • postiz_get_missing_content — releaseId が欠落しているPostiz投稿のプラットフォームコンテンツの復元

  • postiz_list_notifications — Postiz UI通知

  • postiz_get_platform_analytics — フォロワー / インプレッション / エンゲージメント

  • postiz_get_post_analytics — いいね / コメント / シェア

  • postiz_list_voices — AI動画音声カタログ

  • postiz_get_provider_settings_schema — プロバイダーごとの settings スキーマ(X、LinkedIn、Redditなど、ビルド時にバンドル)

書き込み(POSTIZ_ENABLE_WRITE=true が必要)

  • postiz_create_post — 予約 / 即時投稿 / 下書き

  • postiz_connect_integration — 新しいチャンネル用のOAuth URL生成

  • postiz_update_post_status — DRAFT ↔ QUEUE の切り替え

  • postiz_update_post_release_id — Postiz投稿をプラットフォーム側のリリースに再紐付け

  • postiz_upload_file — ローカルファイルまたはbase64からのマルチパートアップロード

  • postiz_upload_from_url — サーバーサイドフェッチ

  • postiz_generate_video — AI動画生成

削除(POSTIZ_ENABLE_WRITE=true + POSTIZ_ENABLE_DELETE=true + confirm: true が必要)

  • postiz_delete_post — グループ全体に波及

  • postiz_delete_post_group — クロス投稿グループ内のすべての投稿を削除

  • postiz_delete_integration — チャンネルの切断 + 予約済み投稿のすべてを削除

インストール

npm install -g postiz-mcp

またはソースから:

git clone https://github.com/solomonneas/postiz-mcp.git
cd postiz-mcp
npm install
npm run build

設定

MCPクライアントの設定で以下の環境変数を設定してください:

変数

必須

デフォルト

説明

POSTIZ_URL

はい

—

ベースURL(例: http://localhost:5000 または https://postiz.example.com)

POSTIZ_API_KEY

はい

—

Postiz設定 → パブリックAPI からのAPIキー

POSTIZ_ENABLE_WRITE

いいえ

false

作成 / 更新 / アップロード / 接続 / 動画生成ツールを公開するには true に設定

POSTIZ_ENABLE_DELETE

いいえ

false

削除ツールを公開するには(書き込みに加えて) true に設定

POSTIZ_REQUEST_TIMEOUT_MS

いいえ

30000

HTTPタイムアウト(ミリ秒)

POSTIZ_RATE_LIMIT_PER_HOUR

いいえ

30

ローカルガードの制限値。サーバーは存在する場合、応答ヘッダーを優先します。

POSTIZ_CF_ACCESS_CLIENT_ID

いいえ

—

Cloudflare AccessサービストークンのクライアントID(PostizがCF Accessの背後にある場合のみ必要)

POSTIZ_CF_ACCESS_CLIENT_SECRET

いいえ

—

Cloudflare Accessサービストークンのシークレット

APIキーの取得

  1. 管理者としてPostizにログイン

  2. 設定 → パブリックAPI → APIキーを生成

  3. 値をコピー(Postizのバージョンに応じて pos_ で始まるか、生のUUIDになります)

Claude Desktop

~/Library/Application Support/Claude/claude_desktop_config.json (macOS) または %APPDATA%\Claude\claude_desktop_config.json (Windows) に追加:

{
  "mcpServers": {
    "postiz": {
      "command": "postiz-mcp",
      "env": {
        "POSTIZ_URL": "http://localhost:5000",
        "POSTIZ_API_KEY": "your-api-key-here",
        "POSTIZ_ENABLE_WRITE": "true",
        "POSTIZ_ENABLE_DELETE": "false"
      }
    }
  }
}

Claude Code

claude mcp add postiz \
  --env POSTIZ_URL=http://localhost:5000 \
  --env POSTIZ_API_KEY=your-api-key-here \
  --env POSTIZ_ENABLE_WRITE=true \
  -- postiz-mcp

現在のプロジェクトだけでなく、どのディレクトリからでも利用できるようにするには --scope user を追加してください。

OpenClaw

postiz-mcpはOpenClawネイティブプラグインでもあります。ソースチェックアウトから:

openclaw plugin add /absolute/path/to/postiz-mcp \
  --config '{
    "baseUrl": "http://localhost:5000",
    "apiKeyEnv": "POSTIZ_API_KEY",
    "enableWrite": true,
    "enableDelete": false
  }'

次にAPIキーをエクスポートしてゲートウェイを再起動します:

export POSTIZ_API_KEY=your-api-key-here
systemctl --user restart openclaw-gateway
openclaw plugin list   # confirm "postiz" is enabled

OpenClawの下で通常のMCPサーバーとして実行することもできます:

openclaw mcp set postiz '{
  "command": "postiz-mcp",
  "env": {
    "POSTIZ_URL": "http://localhost:5000",
    "POSTIZ_API_KEY": "your-api-key-here",
    "POSTIZ_ENABLE_WRITE": "true"
  }
}'

Hermes Agent

Hermes Agent は ~/.hermes/config.yaml の mcp_servers からMCP設定を読み取ります。エントリを追加してください:

mcp_servers:
  postiz:
    command: "postiz-mcp"
    env:
      POSTIZ_URL: "http://localhost:5000"
      POSTIZ_API_KEY: "your-api-key-here"
      POSTIZ_ENABLE_WRITE: "true"

またはソースチェックアウトから:

mcp_servers:
  postiz:
    command: "node"
    args: ["/absolute/path/to/postiz-mcp/dist/mcp-server.js"]
    env:
      POSTIZ_URL: "http://localhost:5000"
      POSTIZ_API_KEY: "your-api-key-here"
      POSTIZ_ENABLE_WRITE: "true"

Hermesセッション内からMCPをリロードします:

/reload-mcp

Codex CLI

Codex CLI は codex mcp add を介してMCPサーバーを登録します:

codex mcp add postiz \
  --env POSTIZ_URL=http://localhost:5000 \
  --env POSTIZ_API_KEY=your-api-key-here \
  --env POSTIZ_ENABLE_WRITE=true \
  -- postiz-mcp

またはソースチェックアウトから:

codex mcp add postiz \
  --env POSTIZ_URL=http://localhost:5000 \
  --env POSTIZ_API_KEY=your-api-key-here \
  --env POSTIZ_ENABLE_WRITE=true \
  -- node /absolute/path/to/postiz-mcp/dist/mcp-server.js

Codexは ~/.codex/config.toml の [mcp_servers.postiz] にエントリを書き込みます。以下で確認してください:

codex mcp list

Cloudflare Accessの背後にあるPostiz

PostizがCloudflare Tunnel + Access(例: https://postiz.example.com)経由で公開されている場合は、Cloudflare Zero Trustダッシュボードでサービストークンを生成し、環境変数を追加してください:

export POSTIZ_CF_ACCESS_CLIENT_ID=your-cf-id.access
export POSTIZ_CF_ACCESS_CLIENT_SECRET=your-cf-secret

MCPサーバーは、すべてのリクエストでそれらを CF-Access-Client-Id / CF-Access-Client-Secret として転送します。忘れた場合は、紛らわしいHTML応答の代わりに明確な PostizCfAccessChallengeError が返されます。

プロンプト例

  • "Postizの統合一覧を表示して。"

  • "明日の午前9時にBlueskyの投稿を予約して:'Just shipped postiz-mcp.'"

  • "LinkedInの次の空き枠はいつ?この4ツイートのスレッドをその時間にXで予約して。返信は認証済みユーザーのみに設定して。"

  • "先週は何が投稿された?火曜日のXの投稿はどうだった?"

  • "スレッドのペイロードを作成するために、Xのプロバイダー設定スキーマを見せて。"

プロバイダー設定スキーマ

postiz_get_provider_settings_schema は、バンドルされたプロバイダーごとの settings リファレンス(docs.postiz.com/public-api/providers/{slug}.md から解析)を返します。Xの who_can_reply_post やLinkedInの audience のようなプロバイダー固有のフィールドが必要な場合は、postiz_create_post の前にこれを使用してください。

スキーマは、Postizがプロバイダーのドキュメントを更新した場合にPRを開くGitHub Actionsワークフローによって毎月更新されます。手動で更新するには:

npm run refresh-schemas

開発

npm install
npm run typecheck
npm test
npm run build

ライセンス

MIT

Available Tools

20 tools
postiz_check_integrationA

Verify the configured Postiz API key is valid and reaches the configured baseUrl. Useful as a first call before any other tool — if this returns ok, every other tool can authenticate against the same instance.

Inputs: no named parameters.

postiz_connect_integrationA

Generate the OAuth authorization URL for connecting a new social channel. Returns a url the user must open in a browser to finish the flow — Postiz redirects back to its own callback. This tool does NOT run a callback server. Requires enableWrite.

Inputs: provider (required), refresh.

postiz_create_postA

Create, schedule, or immediately publish one or more posts via POST /api/posts. PUBLIC SIDE EFFECT: with type='now' or a near-term schedule, this lands on real social accounts. Use postiz_get_provider_settings_schema first to construct valid settings blocks. Requires enableWrite.

Inputs: type (required), date (required), posts (required), shortLink, +1 more.

postiz_delete_integrationA

Disconnect a connected social channel. Cascades — Postiz also deletes every scheduled post for that integration. Requires enableWrite + enableDelete + confirm=true. Returns ok:false / not_found on 404 (already disconnected).

Inputs: integrationId (required), confirm (required).

postiz_delete_postA

Delete a Postiz post by id. CASCADES — every post in the same group is removed. Already-published platform posts remain live. Requires enableWrite + enableDelete + confirm=true.

Inputs: postId (required), confirm (required).

postiz_delete_post_groupA

Delete every post in a group (cross-post unit) via DELETE /api/posts/group/{group}. Use when you want to retract a whole cross-post in one call. Requires enableWrite + enableDelete + confirm=true.

Inputs: group (required), confirm (required).

postiz_find_next_slotA

Return the next available posting time for a given integration. The slot respects the org's configured posting schedule, so this is the right answer to use as date in postiz_create_post when you don't have a specific time in mind.

Inputs: integrationId (required).

postiz_generate_videoA

Generate an AI video via POST /api/video/generate. COST IMPLICATION: video generation may bill against the configured Postiz video integration's credit pool. Requires enableWrite. Body shape is provider-specific — see Postiz video docs.

Inputs: body (required).

postiz_get_missing_contentA

Fetch recent platform-side content for a post whose Postiz releaseId is marked missing. Pair with postiz_update_post_release_id to reattach.

Inputs: postId (required).

postiz_get_platform_analyticsA

Get follower / impression / engagement analytics for a connected channel via GET /api/analytics/platform. Available metrics depend on what the platform exposes to Postiz.

Inputs: integrationId (required), date.

postiz_get_post_analyticsA

Get per-post engagement metrics (likes, comments, shares) via GET /api/analytics/post. Returns whatever the source platform exposes — different shape per provider.

Inputs: postId (required).

postiz_get_provider_settings_schemaA

Look up the settings block schema for a Postiz provider (X, LinkedIn, Reddit, etc.) — bundled at build time from docs.postiz.com. Returns a default-settings template, the provider's __type value, and (by default) the full markdown reference. Call this before postiz_create_post when you need provider-specific fields.

Inputs: provider (required), includeMarkdown.

postiz_list_integrationsA

List every connected social-media channel for the org behind the configured Postiz API key. Returns id, name, providerIdentifier (the value used as __type in post settings), profile, and disabled state. Use this BEFORE postiz_create_post to get the integration id you need to target.

Inputs: no named parameters.

postiz_list_notificationsA

List notifications, sorted most-recent first. Useful for surfacing posting failures, OAuth re-auth prompts, and new-feature notices Postiz shows in its UI.

Inputs: page.

postiz_list_postsA

List posts in a date range via GET /api/posts. Returns scheduled, queued, and published posts with their integration, content, state, and any platform release URL.

Inputs: startDate, endDate, display, customer.

postiz_list_voicesA

List available AI voices for video generation via GET /api/video/function?functionName=voices. Required input for postiz_generate_video — pick a voice id from the returned catalog.

Inputs: integrationId.

postiz_update_post_release_idA

Update the releaseId (and optionally releaseURL) of a Postiz post via PATCH /api/posts/{id}/release-id. Use to reconcile a Postiz post with the actual platform-side release after a missing-content event. Requires enableWrite.

Inputs: postId (required), releaseId (required), releaseURL.

postiz_update_post_statusA

Transition a Postiz post between DRAFT and QUEUE via PATCH /api/posts/{id}/status. Moving DRAFT→QUEUE re-enters the schedule using the post's existing publishDate. Requires enableWrite.

Inputs: postId (required), state (required).

postiz_upload_fileA

Upload a media file (image, video) to Postiz storage via POST /api/uploads/file. Returns { id, path } that you can pass into postiz_create_post value[].image[]. Requires enableWrite.

Inputs: filePath, base64, fileName, mimeType.

postiz_upload_from_urlA

Upload a media file from a public URL via POST /api/uploads/url. Postiz fetches the URL server-side, so this works for sources the MCP host can't reach. Returns { id, path } usable in postiz_create_post value[].image[]. Requires enableWrite.

Inputs: url (required).

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.1/5.0

    Scored across 20 tools

    Disambiguation5/5

    Each tool targets a unique action and resource type. For example, postiz_create_post, postiz_delete_post, and postiz_list_posts are clearly distinct. Even overlapping actions like postiz_delete_post and postiz_delete_post_group are differentiated by scope (single vs. group). Descriptions clarify boundaries effectively.

    Naming Consistency5/5

    All tools follow a consistent 'postiz_verb_noun' pattern with underscore separation. Verbs like check, connect, create, delete, find, generate, get, list, update, and upload are used uniformly. There is no mixing of camelCase or other conventions.

    Tool Count4/5

    With 20 tools, the set is slightly above the typical 'well-scoped' range (3-15) but still reasonable given the breadth of Postiz's functionality (post management, analytics, AI video, integrations, file uploads). Each tool serves a distinct purpose.

    Completeness4/5

    The tools cover the main lifecycle: integration management, post CRUD, analytics, file uploads, and AI video generation. Minor gaps include no direct 'get post by ID' (though list_posts can retrieve it) and no interaction management (comments, etc.), but core workflows are well-supported.

    Maintenance

    ActivitySlowing
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      D
      maintenance
      Enables interaction with the Postiz social media management platform through MCP tools. Supports creating and managing posts, retrieving integrations, and accessing account information through multiple transport protocols.
      2
      -
    • A
      license
      Not graded
      quality
      F
      maintenance
      MCP server for managing social media posts across multiple platforms using the Postiz API. Supports creating, updating, deleting posts, and generating videos.
      3
      MIT
    • A
      license
      A
      quality
      B
      maintenance
      Enables managing social media posts, accounts, and AI-powered content features from any MCP client, including scheduling, publishing, analysis, and AI caption generation.
      14
      68 npm
      MIT