slackwright
Building blocks for AI agents that live in Slack.
slackwright is a library, not a framework. Your bot keeps its own event loop and agent; slackwright gives it the Slack parts:
- Render: post LLM Markdown answers with Slack's native Markdown support, split long answers, and stream replies with task cards.
- Tools: expose the parts below to an LLM agent as tools, with Anthropic tool definitions and validated inputs.
- Forms: forms that an agent designs, in a modal or inline in a message, with validated submissions.
- Canvases: create, edit, and read canvas documents.
- Ingest: turn a Slack thread, its mentions, and its files into LLM messages.
- Lifecycle: progress updates and an in-flight drain for graceful shutdown.
Status: early development. The API will change.
Installation
pip install slackwright
pip install 'slackwright[valkey]' # ValkeyFormStore
pip install 'slackwright[postgres]' # PostgresFormStore
Example
import slackwright
from slackwright import forms, stores
runtime = forms.Runtime(stores.ValkeyFormStore(valkey), on_submit)
runtime.register(bolt_app) # handles form buttons and modals
toolkit = slackwright.Toolkit(
slack_client,
channel_id=channel_id,
thread_ts=thread_ts,
user_id=user_id,
forms=runtime,
canvases=True,
)
tools = toolkit.anthropic() # give these to Claude
result = await toolkit.call(name, tool_input) # run a tool_use block
See docs/design.md for the design.
Development
uv sync --all-groups
docker compose up -d --wait # Valkey and PostgreSQL for integration tests
uv run pre-commit run --all-files
uv run coverage run
uv run coverage report
Without the compose services, the Valkey and PostgreSQL tests are
skipped. When VALKEY_URL or POSTGRES_URL is set (CI sets both),
those tests always run against that URL.
License
BSD 3-Clause. See LICENSE.
Metadata
Release files for slackwright 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| slackwright-0.1.0.tar.gz | 174.7 kB | With provenance | Details for slackwright-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| slackwright-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for slackwright-0.1.0-py3-none-any.whl |
Total release size: 210.6 kB
Release files / slackwright-0.1.0.tar.gz
| Download URL | slackwright-0.1.0.tar.gz |
|---|---|
| Size | 174.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a5e5604e2370a103796c202efd0616b7716ab2e3d355536c2140789bf1b1b8ae
|
|
BLAKE2b-256 checksum How to use checksums |
e184d47e13c3be98642c6a7899b6c359abd33c54d77f699bddc184ca72849b81
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 20, 2026.
Transparency logRelease files / slackwright-0.1.0-py3-none-any.whl
| Download URL | slackwright-0.1.0-py3-none-any.whl |
|---|---|
| Size | 35.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
39f65d4b7000cc62c121fb4fc95d2cfaa2b92d1d016acf31c91686bdef6b43ec
|
|
BLAKE2b-256 checksum How to use checksums |
6e6316f7d443040ace66a42011d0ada2c2833a5ea72adce61b8b0a792011a23b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 20, 2026.
Transparency logSecurity for slackwright 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for slackwright-0.1.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 20, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.