Skip to main content

Slack transport plugin for Takopi.

Project description

takopi-slack-plugin

Slack transport plugin for Takopi. Supports Socket Mode (recommended) or Web API polling, and responds in a single channel or DM.

Requirements

  • Python 3.14+
  • takopi >=0.20.0
  • Slack bot token with chat:write
  • For polling: a history scope for the channel type (e.g. channels:history)
  • For Socket Mode: an app token (xapp-) with connections:write

Install

Install into the same Python environment as Takopi.

Using uv tool installs:

uv tool install -U takopi --with takopi-slack-plugin

Using a virtualenv:

pip install takopi-slack-plugin

Configure

Add to your ~/.takopi/takopi.toml:

transport = "slack"

[transports.slack]
bot_token = "xoxb-..."
channel_id = "C12345678"
# message_overflow = "trim"  # or "split"
# reply_in_thread = false
# require_mention = false
# poll_interval_s = 1.0

Socket Mode (recommended)

Socket Mode avoids polling and rate limits. Enable it in your Slack app and create an app-level token with connections:write, then configure:

[transports.slack]
bot_token = "xoxb-..."
app_token = "xapp-..."
socket_mode = true
channel_id = "C12345678"
require_mention = true

Enable Slack events for message.channels, message.groups, message.im, message.mpim, and/or app_mention, depending on your channel type.

Context shortcuts

Slack treats / at the start of a message as a slash command and will not deliver it to the bot. Use a mention first so the message is delivered:

@takopi /<project> @<branch> do the thing

If you send only directives (no prompt), the bot saves the context for the channel/thread:

@takopi /<project> @<branch>

If you use a plugin allowlist, enable this distribution:

[plugins]
enabled = ["takopi-slack-plugin"]

Start

Run Takopi with the Slack transport:

takopi --transport slack

If you already set transport = "slack" in the config, takopi is enough.

Optional interactive setup:

takopi --onboard --transport slack

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

takopi_slack_plugin-0.0.5.tar.gz (11.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

takopi_slack_plugin-0.0.5-py3-none-any.whl (14.7 kB view details)

Uploaded Python 3

File details

Details for the file takopi_slack_plugin-0.0.5.tar.gz.

File metadata

  • Download URL: takopi_slack_plugin-0.0.5.tar.gz
  • Upload date:
  • Size: 11.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for takopi_slack_plugin-0.0.5.tar.gz
Algorithm Hash digest
SHA256 5e31fdb9cd77a96967b112703cee17b9db5ab85ef1fb18053d84628813f9858d
MD5 3c390e228ccd404adf39ee9228427b5e
BLAKE2b-256 804e92f23e3809ea6e871aa8c173cc12cc36ee4c6a7b3d7801e2ed95d39b4776

See more details on using hashes here.

Provenance

The following attestation bundles were made for takopi_slack_plugin-0.0.5.tar.gz:

Publisher: workflow.yml on richardliang/takopi-slack-plugin

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file takopi_slack_plugin-0.0.5-py3-none-any.whl.

File metadata

File hashes

Hashes for takopi_slack_plugin-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 28e87929a3a9a3616add8a451d2d739db80460db44fc78545e254af55e1d1352
MD5 91ab168bd1501a27e2e0876837df4706
BLAKE2b-256 36b94b6011f039f6017d17ade557ee5459becd9bf542754750b1da23e3a45d9f

See more details on using hashes here.

Provenance

The following attestation bundles were made for takopi_slack_plugin-0.0.5-py3-none-any.whl:

Publisher: workflow.yml on richardliang/takopi-slack-plugin

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page