matrix_channel
matrix_channel
¶
MatrixChannel — Matrix homeserver adapter.
Classes¶
MatrixChannel
¶
MatrixChannel(
homeserver: str = "",
*,
access_token: str = "",
bus: Optional[EventBus] = None,
)
Bases: BaseChannel
Matrix homeserver channel adapter.
| PARAMETER | DESCRIPTION |
|---|---|
homeserver
|
Matrix homeserver URL. Falls back to
TYPE:
|
access_token
|
Matrix access token. Falls back to
TYPE:
|
bus
|
Optional event bus for publishing channel events.
TYPE:
|
Source code in src/diapason/channels/matrix_channel.py
Methods:¶
connect
¶
Mark as connected (send-only — no persistent connection).
Source code in src/diapason/channels/matrix_channel.py
disconnect
¶
send
¶
send(
channel: str,
content: str,
*,
conversation_id: str = "",
metadata: Dict[str, Any] | None = None,
) -> bool
Send a message to a Matrix room via the Client-Server API.
Source code in src/diapason/channels/matrix_channel.py
status
¶
status() -> ChannelStatus