|
| 1 | +# symbi-channel-adapter |
| 2 | + |
| 3 | +[](https://crates.io/crates/symbi-channel-adapter) |
| 4 | +[](https://opensource.org/licenses/MIT) |
| 5 | + |
| 6 | +Chat channel adapters for the [Symbi](https://crates.io/crates/symbi) platform — bidirectional Slack, Teams, and Mattermost integration for AI agents. |
| 7 | + |
| 8 | +## Overview |
| 9 | + |
| 10 | +`symbi-channel-adapter` provides a `ChannelAdapter` trait and platform-specific implementations that let users invoke Symbi agents directly from chat platforms and receive policy-enforced, audit-logged responses. |
| 11 | + |
| 12 | +## Features |
| 13 | + |
| 14 | +| Feature | Default | Platform | |
| 15 | +|---------|---------|----------| |
| 16 | +| `slack` | Yes | Slack Events API, slash commands, Socket Mode | |
| 17 | +| `teams` | No | Microsoft Teams Bot Framework, OAuth2 | |
| 18 | +| `mattermost` | No | Mattermost outgoing webhooks, REST API | |
| 19 | +| `enterprise-hooks` | No | Policy, DLP, and crypto audit hooks | |
| 20 | + |
| 21 | +## Usage |
| 22 | + |
| 23 | +```rust |
| 24 | +use symbi_channel_adapter::{ChannelAdapterManager, ChannelConfig, SlackConfig}; |
| 25 | + |
| 26 | +let config = ChannelConfig { |
| 27 | + platform: SlackConfig { |
| 28 | + bot_token: std::env::var("SLACK_BOT_TOKEN").unwrap(), |
| 29 | + app_token: std::env::var("SLACK_APP_TOKEN").unwrap(), |
| 30 | + signing_secret: std::env::var("SLACK_SIGNING_SECRET").unwrap(), |
| 31 | + ..Default::default() |
| 32 | + }.into(), |
| 33 | + ..Default::default() |
| 34 | +}; |
| 35 | + |
| 36 | +let manager = ChannelAdapterManager::new(config); |
| 37 | +``` |
| 38 | + |
| 39 | +### Enabling additional platforms |
| 40 | + |
| 41 | +```toml |
| 42 | +[dependencies] |
| 43 | +symbi-channel-adapter = { version = "0.1", features = ["slack", "teams", "mattermost"] } |
| 44 | +``` |
| 45 | + |
| 46 | +## Architecture |
| 47 | + |
| 48 | +The crate is built around a few core abstractions: |
| 49 | + |
| 50 | +- **`ChannelAdapter`** — trait for sending/receiving messages on a chat platform |
| 51 | +- **`InboundHandler`** — trait for processing incoming messages and slash commands |
| 52 | +- **`ChannelAdapterManager`** — orchestrates multiple adapters with health checks and lifecycle management |
| 53 | +- **`AgentInvoker`** — trait bridging chat messages to Symbi agent execution |
| 54 | + |
| 55 | +Each platform adapter handles authentication, signature verification, and message formatting specific to its platform. |
| 56 | + |
| 57 | +## Part of Symbiont |
| 58 | + |
| 59 | +This crate is part of the [Symbiont](https://github.com/thirdkeyai/symbiont) workspace. For the full agent framework, see the [`symbi`](https://crates.io/crates/symbi) crate. |
| 60 | + |
| 61 | +## License |
| 62 | + |
| 63 | +MIT |
0 commit comments