Creating a channel automatically assigns you ownership, granting full administrative rights. React Hook Example for Creating Channels:
import { useChannel } from '@sageprotocol/sdk/react';
import { useWallet } from '@suiet/wallet-kit';

function CreateChannel({ ownedUserId }) {
  const { createChannel } = useChannel();
  const { account, signAndExecuteTransaction } = useWallet();

  async function handleCreateChannel() {
    const result = await createChannel({
      amounts: [0, 0],   // Protocol fees (default: [0,0])
      avatar: 12345,   // Walrus blob ID for avatar (optional, default 0)
      banner: 67890,   // Walrus blob ID for banner (optional, default 0)
      channelName: 'crypto-art',   // Name: Allowed chars a-z, A-Z, 0-9, dashes
      description: '**Digital art and NFT discussions**',   // Markdown-supported description
      ownedUserId,   // Creator's owned user ID
      self: account.address   // Creator's wallet address
    });

    if (result.ok) {
      await signAndExecuteTransaction({ transaction: result.transaction });
      console.log("Channel created successfully!");
    } else {
      console.error("Channel creation error:", result.err);
    }
  }

  return <button onClick={handleCreateChannel}>Create Channel</button>;
}

export default CreateChannel;

Example Channel Use-cases

  • Topic-based Communities: defi-protocols for decentralized finance discussions.
  • Project Channels: project-updates for development announcements.
  • Regional Groups: nyc-blockchain-meetups for local blockchain events.

Channel Best Practices

  • Clearly Define and Enforce Community Guidelines
    Clearly communicate community guidelines and utilize built-in moderation tools to maintain high-quality interactions. See channel moderation.
  • Encourage Meaningful Discussions and Contributions
    Utilize built-in incentives and Proof of Social Contribution (PoSC) rewards to foster thoughtful, engaging interactions. Ensure members understand how participation translates into tangible rewards.
  • Regularly Update Channel Details
    Keep your channel’s descriptions, avatars, and banners current to maintain community engagement. See updating channels.