@orchestree/chorus
v1.4.0
Published
Chorus module — Real-time channels, threaded conversations, rich messages, bot framework
Maintainers
Readme
@orchestree/chorus
Team communication and bot framework for Orchestree. Build collaborative channels, threads, and intelligent bots for team coordination.
Installation
npm install @orchestree/chorusQuick Start
const { ChorusClient } = require('@orchestree/chorus');
const client = new ChorusClient({
apiKey: 'your-api-key',
});
// Create a channel
const channel = await client.createChannel({
name: 'announcements',
type: 'public',
description: 'Company announcements',
});
// Send a message
await client.sendMessage(channel.id, 'Welcome to the team!');
// Create a thread
const thread = await client.createThread(channel.id, {
subject: 'Q2 Planning',
});
// Reply to thread
await client.replyToThread(thread.id, 'I have some ideas...');API Reference
ChorusClient
createChannel(channelDef)
Create a new channel.
const channel = await client.createChannel({
name: 'engineering',
type: 'private',
description: 'Engineering team discussions',
});sendMessage(channelId, message, options)
Send a message to a channel.
await client.sendMessage(channel.id, 'New deployment ready!', {
mentions: ['@devops'],
});createThread(channelId, threadDef)
Create a thread in a channel.
const thread = await client.createThread(channel.id, {
subject: 'Project Kickoff',
});replyToThread(threadId, message, options)
Reply to a thread.
await client.replyToThread(thread.id, 'Count me in!');registerBot(botDef)
Register a bot for channel events.
const bot = await client.registerBot({
name: 'notifier',
endpoint: 'https://bot.example.com/webhook',
events: ['message.created', 'message.updated'],
});listChannels(filters)
List all channels.
const channels = await client.listChannels({ type: 'public' });License
MIT
