コンテンツにスキップ

Slack アプリを作成

Slack アプリは、くらちゃんが使うボットの身分です。必要なスコープ・イベント・8 つのスラッシュコマンドをまとめて用意する一番速い方法が、マニフェストから作成することです。設定のかたまりを貼り付けるだけで済みます。

  1. アプリ一覧を開く

    api.slack.com/apps を開き、Create New App をクリックします。

  2. 「From a manifest」を選ぶ

    くらちゃんを常駐させたいワークスペースを選び、Next をクリックします。

  3. マニフェストを貼り付ける

    YAML タブに切り替え、中身を下のブロックに置き換えて、NextCreate をクリックします。namedisplay_name は好きな名前に変えて構いません。

    display_information:
    name: くらちゃん
    description: Slack の中のあなたのパーソナル AI エージェント
    background_color: "#000000"
    features:
    app_home:
    home_tab_enabled: true
    messages_tab_enabled: false
    messages_tab_read_only_enabled: false
    bot_user:
    display_name: くらちゃん
    always_online: true
    shortcuts:
    - name: Capture to Kura
    type: message
    callback_id: kura_capture
    description: このメッセージをくらちゃんに保存
    slash_commands:
    - command: /kura-ask
    description: Quick question
    should_escape: false
    - command: /kura-search
    description: Search knowledge base
    should_escape: false
    - command: /kura-summary
    description: Channel summary
    should_escape: false
    - command: /kura-digest
    description: Daily digest
    should_escape: false
    - command: /kura-remind
    description: Set reminder
    should_escape: false
    - command: /kura-files
    description: Recent files
    should_escape: false
    - command: /kura-model
    description: Switch model
    should_escape: false
    - command: /kura-help
    description: Show help
    should_escape: false
    oauth_config:
    scopes:
    bot:
    - app_mentions:read
    - channels:history
    - chat:write
    - commands
    - files:read
    - files:write
    - groups:history
    - im:history
    - im:read
    - im:write
    - im:write.topic
    - mpim:history
    - mpim:read
    - mpim:write
    - reactions:read
    - reactions:write
    - users:read
    pkce_enabled: true
    settings:
    event_subscriptions:
    bot_events:
    - app_home_opened
    - app_mention
    - message.channels
    - message.groups
    - message.im
    interactivity:
    is_enabled: true
    org_deploy_enabled: false
    socket_mode_enabled: true
    token_rotation_enabled: false
    is_mcp_enabled: false
  • Socket Mode — 外向き接続。公開 URL は不要です。
  • Bot スコープ — 投稿(chat:write)、スラッシュコマンド(commands)、ファイルの読み取り・アップロード(files:readfiles:write)、DM・グループ DM・チャンネルのメッセージ読み取り(im:*mpim:*groups:historychannels:history)、DM の開始と名前付け(im:writeim:write.topic)、メンション(app_mentions:read)、リアクション(reactions:readreactions:write)、発言者の解決(users:read)。
  • イベントapp_mention、DM・グループ・チャンネルのメッセージ(message.immessage.groupsmessage.channels)、app_home_opened
  • InteractivityApp Home タブ、そして 「Capture to Kura」 メッセージショートカット(メッセージを右クリック → くらちゃんに保存)。
  • 8 つの /kura-* スラッシュコマンドすべて。

次に、認証情報を生成してコピーします。2 つのトークン へ進みましょう。

手動セットアップのチェックリスト(マニフェストなし)

Create New App → From scratch で作成したあと、各セクションを設定します。

  1. Socket Mode(Settings → Socket Mode): Enable Socket Mode をオンにします。
  2. OAuth & PermissionsBot Token Scopes に、次をすべて追加します。 app_mentions:readchannels:historychat:writecommandsfiles:readfiles:writegroups:historyim:historyim:readim:writeim:write.topicmpim:historympim:readmpim:writereactions:readreactions:writeusers:read
  3. Event Subscriptions: イベントを有効化し、Subscribe to bot events に次を追加します。 app_home_openedapp_mentionmessage.channelsmessage.groupsmessage.im
  4. Interactivity & Shortcuts: Interactivity をオンにし、Create New ShortcutOn messages で、名前 Capture to Kura、callback ID kura_capture のショートカットを作成します。
  5. App Home: Home Tab を有効化します(Messages タブはオフのままで構いません)。
  6. Slash Commands: 8 つのコマンドを手動で作成します — /kura-ask/kura-search/kura-summary/kura-digest/kura-remind/kura-files/kura-model/kura-help。 Socket Mode がオンなら、Request URL は空欄のままで構いません。