Skip to main content

channelstack for Python

The Python SDK of channelstack, a test harness for the apps and agents you build for Slack, GitHub, Linear, Notion, Resend and Gmail. channelstack runs fake versions of those platforms on your machine. Your code scripts the people, your app answers through its real code path, and you check what a person would see.

For tests, use pytest-channelstack, which is built on this SDK.

Install

pip install channelstack

It needs Python 3.12 or later. The SDK doesn't bundle the server. It finds it at CHANNELSTACK_SERVER_BIN, or as channelstack on the PATH: install it with npm i -g channelstack, or download it from the GitHub releases.

Example

import asyncio

from channelstack import connect


async def main() -> None:
    async with await connect(mode="auto") as client:
        async with await client.open_session(name="example") as session:
            slack = await session.slack()
            ana = await slack.create_user(name="Ana")
            channel = await slack.create_channel(participants=[ana, slack.app])

            msg = await ana.say("@my-agent hi", channel=channel)
            reply = await msg.thread.wait_for_reply(from_="my-agent")
            print(reply.text)


if __name__ == "__main__":
    asyncio.run(main())

MIT licensed.

Metadata

Release files for channelstack 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for channelstack 0.1.0
File Interpreter ABI Platform Actions
channelstack-0.1.0-py3-none-any.whl Python 3 none any Details for channelstack-0.1.0-py3-none-any.whl

Release files / channelstack-0.1.0-py3-none-any.whl

Download URL channelstack-0.1.0-py3-none-any.whl
Size 37.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
089dd13badd55c19793208984fee031240b97dca94654545f3c56560509597d2
BLAKE2b-256 checksum
How to use checksums
905969b35b66f1f88f38457b3d1668b62835471deb99aaa8c922fc35ed5159e7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.1 {"installer":{"name":"uv","version":"0.13.1","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for channelstack 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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A 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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page