Communityライティング&編集github.com

publora/x-post

Publoraを介してX(Twitter)に投稿やスケジュール投稿を行います。280文字を超えると自動スレッド分割、最大4枚の画像、または最大140秒の動画をサポートします。Xの利用には有料のPubloraプランが必要です。ThreadsやBlueskyには対応していません(それぞれ専用スキルがあります)。

x-post とは?

このスキルは、Publora MCPサーバーを使用してX(Twitter)への投稿作成とスケジュール設定を行うためのものです。テキスト投稿、画像(最大4枚)、動画、および280文字を超える長文コンテンツの自動スレッド分割をサポートします。AIエージェント(Claude Code、Cursor、Codexなど)と連携し、MCPプロトコル経由でシームレスにXへ投稿できます。無料のStarterプランではX APIコストの関係で利用できないため、ProまたはPremiumプランが必要です。REST APIフォールバックも提供されており、MCPが利用できない場合でも直接API経由で投稿できます。画像は自動的にPNGに変換され、動画は最大140秒、ファイルサイズは512MBまで対応します。また、`mediaUrls`パラメータを使用することで、メディアのアップロードとスケジュール投稿を1回の呼び出しで完了できます。

対応✓Claude Code✓Codex CLI✓Cursor
npx skills add https://github.com/publora/skills/tree/main/skills/x-post

Installed? Explore more ライティング&編集 skills: steipete/notion, langchain-ai/langchain, bytedance/podcast-generation · View all 6 →

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

X/Twitter投稿

Publora MCPサーバーを使用してX(Twitter)への投稿を作成・スケジュールします。テキスト投稿、画像(最大4枚)、動画、および長文コンテンツの自動スレッド分割に対応しています。

前提条件

プラン: 有料プランが必要です(X APIコストは実費請求)。現在の制限と料金はこちら:publora.com/pricing をご確認ください。

重要: Twitter APIコストのため、無料のStarterプランではX/Twitterを利用できません。

はじめに

  1. アカウントを作成 publora.com/register
  2. ProまたはPremiumプランを選択(X/Twitterは有料プランが必要)
  3. PubloraダッシュボードでOAuth経由でX/Twitterを接続 app.publora.com/dashboard
  4. APIキーを取得 app.publora.com/dashboard/api
  5. エージェントをMCPサーバーに接続(https://mcp.publora.com、認証はAuthorization: Bearer sk_YOUR_API_KEYヘッダー)。Claude Codeの例:
claude mcp add publora --transport http https://mcp.publora.com \
  --header "Authorization: Bearer sk_YOUR_API_KEY"

Claude Desktop、Cursor、Codex、OpenClaw、claude.aiコネクタにはそれぞれ異なる設定ファイルまたはフローが必要です。正確なパスとスニペットについてはクライアント設定を参照してください。

REST APIフォールバック

MCPが利用できない場合は、REST APIを直接使用します。

ベースURL: https://api.publora.com/api/v1

認証: x-publora-keyヘッダー

# 接続済みプラットフォームを取得
curl -X GET "https://api.publora.com/api/v1/platform-connections" \
  -H "x-publora-key: sk_your_api_key"

# 投稿を作成
curl -X POST "https://api.publora.com/api/v1/create-post" \
  -H "x-publora-key: sk_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "platforms": ["twitter-123456789"],
    "content": "ツイート内容",
    "scheduledTime": "2026-03-25T10:00:00Z"
  }'

プラットフォームID形式: twitter-{id}(例:twitter-123456789)

📖 ドキュメント: docs.publora.com

プラットフォーム制限

機能API制限備考
文字数280絵文字は2文字としてカウント
画像最大4枚自動でPNGに変換(最大幅1000px)
動画時間2分20秒(140秒)PubloraはXの動画を140秒で検証
動画サイズ512 MBMP4、MOV形式
スレッド化自動280文字超のコンテンツは(1/N)マーカーで分割

文字カウント

Xには独自の文字カウントルールがあり、Publoraが自動的に処理します。

  • 標準文字 = 1
  • 絵文字 = 2文字
  • URLはリテラル長でカウント
  • スレッドマーカーはツイートごとに10文字を予約

自動スレッド化

コンテンツが280文字を超える場合、Publoraは自動的に接続されたスレッドを作成します。

  1. コンテンツを段落区切り、次に文の区切り、最後に単語の区切りで分割
  2. 各部分に(1/N)、(2/N)の形式で番号を付与
  3. Xのreply_to_idパラメータを使用してツイートを接続

手動スレッド区切り

---を単独の行に記述すると、強制的にスレッドを分割できます。

これがスレッドの最初のツイートです。

---

これがスレッドの2番目のツイートです。

---

そしてこれが3番目のツイートです!

利用可能なツール

create_post

新しいX/Twitterの投稿またはスレッドを作成します。

パラメータ:

  • platforms:X接続IDを含む配列(例:["twitter-12345678"])
  • content:投稿テキスト(280文字を超えると自動スレッド化)
  • scheduledTime:ISO 8601 UTC日時。オプション: 省略すると下書きとして作成されます。未来の時間を指定するとスケジュール投稿になります。5分以上過去の時間はSCHEDULED_TIME_IN_PASTエラーで拒否されるため、即時投稿の場合は現在時刻+1分を指定してください。
  • mediaUrls:最大10個の公開https画像または動画URL。Publoraがサーバーサイドでダウンロードし、検証前に添付します。これにより、メディアとスケジュールを1回の呼び出しで処理できます。これは、下書き作成→get_upload_url→complete_mediaフローのワンショット代替手段です。取り込みは1時間あたり60URLにレート制限されています。

get_upload_url

メディアアップロード用の署名付きURLを取得します。

パラメータ:

  • postGroupId:メディアを添付する投稿ID
  • fileName:ファイル名(例:"image.png"、"video.mp4")
  • contentType:image/png、image/jpeg、video/mp4
  • type:"image" または "video"

complete_media

署名付きPUTが成功した後、get_upload_urlを通じてアップロードされたファイルを確定します。スケジュール設定でも保留中のメディアは確定されますが、このツールを早期に呼び出すことで、公開前にフォーマットやプローブエラーを検出できます。mediaUrlsで添付されたメディアには不要です。

パラメータ:

  • mediaId:get_upload_urlから返されたID

list_connections

接続済みアカウントをプラットフォームIDとともに一覧表示します。最初にこれを呼び出し、IDをそのままコピーしてください。IDは推測不可能です。

list_posts / get_post / update_post / delete_post

スケジュール済みおよび下書きの投稿を管理します。update_postは下書きまたはスケジュール済み投稿のcontentとplatformsも更新できるため、タイプミスの修正やターゲットの変更を削除と再作成なしで行えます。delete_mediaとprune_media_referenceでアップロード済みファイルをクリーンアップできます。

使用例

シンプルなツイート

これをXに投稿してください:
"新しいAPIドキュメントをリリースしました。ぜひチェックしてみてください!"

画像付きツイート

新しいダッシュボードのスクリーンショットを添えてTwitterに投稿:
"リデザイン前と後。どう思いますか?"

注:画像は最大4枚まで。すべての画像は自動的にPNGに変換されます。

長文スレッド

Twitterスレッドを作成:
"スレッド:スタートアップを構築して学んだ5つの教訓

---

1. 早く出荷して、素早く反復する。私たちはバグだらけのMVPでローンチし、実際のフィードバックに基づいて改善しました。

---

2. 毎日ユーザーと話す。最高の機能は顧客との会話から生まれました。

---

3. 機能よりも集中。うまくいった1つの製品に集中するため、3つの製品をやめました。"

スケジュールツイート

これを明日の午前9時にスケジュール:
"月曜日のモチベーション:準備ができる前に始めよう。"

重要な制限事項

  1. Proプラン必須:Twitter APIコストのため、X/Twitterは無料のStarterプランでは利用できません。

  2. 140秒の動画制限:PubloraはXの動画を2分20秒(140秒)で検証します。それより長い動画は検証に失敗します。

  3. 画像自動変換:すべての画像はアップロード前にPNG(最大幅1000px)に変換されます。アニメーションGIFはアニメーションを失います。

  4. 画像と動画の混合不可:1つのツイートには画像または動画のどちらか一方のみ添付できます。

  5. スレッド内のメディアは最初のツイートのみ:スレッドでは、画像・動画は最初のツイートにのみ添付されます。

ベストプラクティス

コンテンツ

  1. 最初の行でフック:エンゲージメントのほとんどは最初のツイートで発生
  2. 最適なスレッド長:エンゲージメントを最大化するには3〜7ツイート
  3. 絵文字の認識:絵文字は2文字としてカウントされることを忘れずに

タイミング

  • 最適な時間帯:ターゲットタイムゾーンの8〜10時、12〜13時、17〜18時
  • 頻度:成長のためには1日3〜5ツイート
  • スレッド:最大の可視性を得るために朝に投稿

エンゲージメント

  • 最初の1時間以内にコメントに返信
  • 自分のスレッドを引用ツイートして可視性を高める
  • 関連するハッシュタグを使用(ツイートあたり1〜2個)

トラブルシューティング

エラー原因解決策
"X/TwitterにはProプランが必要です"Starterプランを使用中publora.com/settings でProにアップグレード
"コンテンツが長すぎます"280文字を超え、スレッド化に失敗手動で---区切りを追加
"動画が長すぎます"140秒を超えている動画を2分20秒未満にトリミング
"画像が多すぎます"4枚を超えている4枚以下に減らす
"レート制限に達しました"X API制限に到達待ってから再試行

Individual skills in this repo

This repo contains 8 individual skills — each has its own dedicated page.

publora/bluesky-post

Use when the user wants to post or schedule to Bluesky through Publora. Handles the 300-character cap, auto-detected hashtags and links, up to 4 images, and videos. Alt text cannot be set through the API. Needs a Bluesky app password, never the main password. Not for Mastodon (use social-post).

publora/instagram-post

Use when the user wants to post or schedule to Instagram through Publora: a single image, a 2-10 image carousel, a Reel or a Story. Requires a Business account and an image or video; text-only posts are rejected by the API. Not for Threads (use threads-post).

publora/linkedin-analytics

Analyze LinkedIn performance and manage engagement through Publora. Use when the user asks how a LinkedIn post or account performed (impressions, reach, reactions, comments, reshares, follower growth) or wants to react, comment, reshare or resolve an @mention. Statistics run over the REST API, engagement over MCP tools. Not for creating posts (use linkedin-post).

publora/linkedin-post

Use when the user wants to publish or schedule a LinkedIn post through Publora: text, a multi-image grid, a video, a PDF document, or @mentions. Not for analytics, reactions, comments or reshares (use linkedin-analytics), and not for other platforms.

publora/social-post

Use when the user wants to post or schedule to YouTube, a Facebook Page or Mastodon through Publora. YouTube needs a video on every post, Facebook publishes to Pages only, Mastodon caps at 500 characters. Not for the platforms that have their own skill.

publora/telegram-post

Use when the user wants to post or schedule to a Telegram channel or group through Publora, using a bot. Covers Telegram markdown, silent delivery, link previews and forward protection. Bot API caps media captions at 1,024 characters and videos at 50 MB. Not for other platforms (each has its own skill).

publora/threads-post

Create and schedule Threads posts with image carousels and reply control via Publora MCP. Use when the user wants to post to Meta's Threads. Multi-part threading is currently disabled by the platform, so long content stays a single post. Not for Instagram (use instagram-post) or X threads (use x-post).

publora/tiktok-post

Use when the user wants to upload or schedule a TikTok video through Publora, with privacy, comment, duet, stitch and commercial-disclosure settings. Video runs 3 seconds to 10 minutes at 23+ FPS; carousels take up to 35 images. Unaudited apps can publish private videos only. Not for Reels (use instagram-post).

関連スキル