> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sageprotocol.xyz/llms.txt
> Use this file to discover all available pages before exploring further.

# Creating Channels

>  

Creating a channel automatically assigns you ownership, granting full administrative rights.

**React Hook Example for Creating Channels**:

```typescript theme={null}
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;
```

<Accordion title="Direct JavaScript Example for Creating Channels" icon="rectangle-code" iconType="sharp-solid">
  ```javascript theme={null}
  import { SageClient } from '@sageprotocol/sdk';

  const sageClient = new SageClient({
    appId: 'your-app-id',                      // explicitly required unique app ID
    channelRegistryId: 'your-registry-id',     // required channel registry ID
    network: 'testnet'                         // 'testnet' or 'mainnet'
  });

  await sageClient.initialize();

  async function createChannel() {
    const result = await sageClient.createChannel({
      amounts: [0, 0],                         // Protocol fees (default: [0,0])
      avatar: 12345,                           // Walrus blob ID for avatar (optional)
      banner: 67890,                           // Walrus blob ID for banner (optional)
      channelName: 'crypto-art',               // Allowed characters: a-z, A-Z, 0-9, dash
      description: '**Digital art and NFT discussions**', // Markdown-supported description
      ownedUserId: 'your-owned-user-id',       // Creator's owned user ID
      self: walletAddress                      // 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);
    }
  }

  createChannel();
  ```
</Accordion>

### 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](#).
